3 ms·
> Have you ever wondered how Chrome knows to ask you if you’d like a web page’s content to be translated? How difficult is it to automatically detect the langu
by seanwilson 7y ago
> Have you ever wondered how Chrome knows to ask you if you’d like a web page’s content to be translated?
How difficult is it to automatically detect the language? Probably naive but how far can you get by counting how many common words on the page are from a particular language (e.g. "the of then because I" for English and "je pour des les" for French)?
- mjlee 7y agoGoogle translate already has an auto-detect language feature. I suspect it would be reasonably simple to add a "Translate this" button somewhere in Chrome (perhaps it's already there, I don't have Chrome installed on this machine.) Perhaps automatically doing it for every site would be a little bit intrusive on the privacy front.
- seanwilson 7y ago> Google translate already has an auto-detect language feature. Yep, I'm asking how hard it is to build a quick and simple auto-detect feature. Is it harder than it looks?
- mjlee 7y agoIt kind of depends what you mean by build. From scratch - I have no idea. For Google Chrome? It's just an API call away - https://cloud.google.com/translate/docs/basic/detecting-language https://cloud.google.com/translate/docs/basic/detecting-lang...
- sergeykish 7y agohttps://github.com/google/cld3 https://github.com/google/cld3 build requires Chromium, not so hard
- naniwaduni 7y agoAs a rule of thumb, everything in NLP is harder than it looks.