Tuesday, November 5, 2024

New Google Chrome feature will translate complex pages in real time

Must read

Google is testing a new API that uses machine learning models to offer real-time language translation for inputted text and to make it easier to translate web pages.

According to a proposal spotted by Bleeping Computer, the feature is being developed by Chrome’s built-in AI team and is aimed at exposing the web browser’s built-in translation functionality and the ability to download additional language models to translate text.

While Chrome and Edge already have built-in translation features, they can sometimes have issues translating web pages that have dynamic or complex content. For example, Chrome may not be able to translate all sections of an interactive website correctly.

In such cases, websites have their own translation tool, which could consume a lot of resources and can be slow compared to the browser’s built-in feature. Google plans to give developers access to Chrome’s upcoming AI-based translation feature through a simple JavaScript API.

“To perform translation in such cases, web sites currently have to either call out to cloud APIs, or bring their own translation models and run them using technologies like WebAssembly and WebGPU,” explains Google.

“This proposal introduces a new JavaScript API for exposing a browser’s existing language translation abilities to web pages, so that if present, they can serve as a simpler and less resource-intensive alternative.” explains Google.

The new AI/API feature would simplify this process by using Chrome’s built-in translation engine for existing content or with inputted text, such as a forum or real-time chat service.

The feature will download a machine learning model to correctly translate the text if the required translation model is not built into the browser.

The proposal, as it stands, currently has some privacy issues, as it could potentially allow a website to fingerprint a user based on the browser’s supported languages and availability status.

“The most obvious identifier in the current API design is the list of supported languages, and especially their availability status (“no”, “readily”, or “after-download”),” warns Google.

“For example, as of the time of this writing Firefox supports 9 languages, which can each be independently downloaded. With a naive implementation, this gives 9 bits of identifying information, which various sites can all correlate.”

The developers outlined potential mitigations, such as grouping language packs to reduce the number of bits or only exposing a fixed set of languages based on a user’s locale.

The proposal also mentions allowing developers to determine if the translation is done on-device or using cloud services so they can make sure no sensitive text is sent to a third-party service, which could cause data leaks.

It’s unclear when the feature would be added to Chrome, but Google is actively exploring and discussing the idea with the open-source community.

Latest article