browsermt / bergamot-translator

Cross platform C++ library focusing on optimized machine translation on the consumer-grade device.
http://browser.mt
Mozilla Public License 2.0
341 stars 38 forks source link

Test cases for HTML/Non-HTML translation per item of Batch Translation API #363

Open abhi-agg opened 2 years ago

abhi-agg commented 2 years ago

filed because of https://github.com/browsermt/bergamot-translator/issues/345#issuecomment-1034977189 and https://github.com/browsermt/bergamot-translator/issues/345#issuecomment-1036201708.

jerinphilip commented 2 years ago

Tests are missing in the JavaScript layer entirely. Note that C++ tests will not cover the JavaScript, and the sloppy development operation in JavaScript has led to configuration faults that have led to blame at the engine (https://github.com/mozilla/firefox-translations/issues/51) despite getting it correct in https://github.com/browsermt/bergamot-translator/pull/269, due to manual movement human error in place of continuous testing and integration.

I'm currently capturing possibilities in #330, but this is outside my assigned tasks - so it will have to come out of spare time.

I will also make an offer for WebAssembly devs to take ownership of https://github.com/browsermt/bergamot-translator/blob/main/src/tests/wasm.cpp and associated tests so WebAssembly requirements can be codified. Note that the tests I bring in are going to be c5cea4b (#346), and I'm waiting to get access to var or an avx512vnni machine again (cc @kpu).

abhi-agg commented 2 years ago

@jerinphilip As you are not responsible for any JS/WASM work, please feel free to not do it. Nobody is asking you to do it.

The feature was added to the engine and it was a major API change. So C++ tests are kind of needed. There is no assignee on this issue. I created it so that we could close the original one (which unblocked the integration in extension) and not forget about tests.