Mozilla continues to work on a machine translation system and has released a plugin

Firefox logo

During the last quarter of 2019, we shared here on the blog the news that the people of Mozilla had made known their interest in implementing their own automatic translation system within Firefox as part of the Bergamot project, something similar to Chrome’s translator, but with the difference that will be that the option to translate web pages in Firefox it will work without internet connection.

Firefox as such already has a built-in mechanism for translating pages, but it is tied to the use of external cloud services (supported by Google, Yandex and Bing) and is not activated by default. The translation engine also supports automatic language detection when opening a page in an unknown language and displays a special indicator with a proposal to translate the page.

And now, several months after that said project has already started to take shape, well Mozilla has released the Firefox Translations 0.4 plugin (previously developed under the name Bergamot Translate) with the implementation of an autonomous machine translation system that runs in the browser without accessing external services. The new plugin uses a similar interface to interact with the user, since an integrated controller is launched that processes data on the user’s system.

To translate from one language to another, the bergamot translation engine is involved, developed within the framework of the Bergamot initiative by Mozilla developers together with researchers from various universities in the UK, Estonia and the Czech Republic with financial support from the European Union.

The motor is written in C ++ and compiled into an intermediate binary representation of WebAssembly using the Emscripten compiler. The engine is a link on the machine translation framework, which uses a recurrent neural network (RNN) and transformer-based language models.

A GPU can be used to speed up learning and translation. Marian is used to power the Microsoft Translator translation service and is primarily developed by Microsoft engineers in collaboration with researchers from the Universities of Edinburgh and Poznan.

Firefox Translations supports the translation from Estonian and Spanish to English and vice versa, as well as from English to German. The translation performance is 500 to 600 words per minute.

There is support for prioritizing the translation of visible text in the browser window. LThe new version offers the possibility of automatically downloading files with models in the first translation attempt. The model files are approximately 15 MB for each language. Automatic download introduces a slight delay before the first translation begins, but drastically reduces the size of the plugin itself (3.6MB instead of 124MB).

The new version also significantly speeds up the loading of models into memory: It used to take 10-30 seconds to load a model, but now models load almost instantly. If the translation of a page takes more than 3 seconds, the interface provides an indication of the progress of the operation.

Translation is done sequentially from top to bottom, starting from the visible area. The translated parts are shown as ready and the untranslated parts remain in the original language.

Telemetry sending is included, the transmission of data about the user’s interaction with the additional interface (for example, about pressing the translation button or prohibiting translations for certain sites), information about the performance of operations and technical information about the system (CPU, memory).

The plugin can be installed so far only on nightly Firefox builds when plugin verification by digital signature is disabled and which should be enabled on the “about: config” page by changing to “true” and “xpinstall.signatures.required” to “false”.

After installing the plugin, Firefox will start to display a panel that will ask for the translation of pages whose language differs from the browser language and is compatible with the plugin, as well as providing the ability to disable the display of the additional panel for a specific language or site.

To be able to obtain the complement, just go to the following link.

Add Comment