←back to thread

Web Translator API

(developer.mozilla.org)
97 points kozika | 1 comments | | HN request time: 0.208s | source
Show context
rhabarba ◴[] No.44375303[source]
You had me at "Browser compatibility".
replies(2): >>44375411 #>>44377716 #
Raed667 ◴[] No.44375411[source]
Chrome embeds a small LLM (never stops being a funny thing) in the browser allowing them to do local translations.

I assume every browser will do the same as on-device models start becoming more useful.

replies(2): >>44375422 #>>44375891 #
Asraelite ◴[] No.44375891[source]
What's the easiest way to get this functionality outside of the browser, e.g. as a CLI tool?

Last time I looked I wasn't able to find any easy to run models that supported more than a handful of languages.

replies(6): >>44376224 #>>44376260 #>>44376411 #>>44376506 #>>44378599 #>>44380230 #
1. mftrhu ◴[] No.44380230[source]
Setting aside general-purpose LLMs, there exist a handful of models geared towards translation between hundred of language pairs: Meta's NLLB-200 [0] and M2M-100 [1] can be run using HuggingFace's transformers (plus numpy and sentencepieces), while Google's MADLAD-400 [2], in GGUF format [3], is also supported by llama.cpp.

You could also look into Argos Translate, or just use the same models as Firefox through kotki [4].

[0] https://huggingface.co/facebook/nllb-200-distilled-600M [1] https://huggingface.co/facebook/m2m100_418M [2] https://huggingface.co/google/madlad400-3b-mt [3] https://huggingface.co/models?other=base_model:quantized:goo... [4] https://github.com/kroketio/kotki