ai-translator-and-language-detector
Reactive icon

AI Translator and Language Detector

Stable version 1.0.0 (Compatible with OutSystems 11)
Uploaded
 on 17 Jul
 by 
0.0
 (0 ratings)
ai-translator-and-language-detector

AI Translator and Language Detector

Documentation
1.0.0

The AI Translator and Language Detector is a powerful tools that enable web applications to understand and interact with users across different languages. They leverage machine learning models to provide two primary functions:

  1. Language Detection: The AI Translator and Language Detector analyze a given text string and determine the language it's written in. This is crucial for applications that receive user input in various languages, allowing them to dynamically adjust content, offer targeted services, or prepare text for translation. They often return not just the detected language code (e.g., "en" for English, "fr" for French) but also a confidence level, indicating the certainty of the detection.

  2. Text Translation: The AI Translator and Language Detector take text in one language and convert it into another. This can be used for a wide range of purposes, from localizing website content and user interfaces to facilitating real-time communication in chat applications. Many modern APIs abstract away the complexities of the underlying machine learning, providing a simple interface to perform translations.


The AI Translator and Language Detector has set of 4 client actions, listed below -

1.CheckLanguageDetectorAvailability -

To determine if the AI Language Detector model is ready to use, It returns availability status with the following values -

"unavailable" means that the implementation does not support the requested options.

"downloadable" means that the implementation supports the requested options, but first, the browser has to download something, such as a model (in Chrome's case, Gemini Nano) or fine-tuning for the model.

"downloading" means that the implementation supports the requested options, but it has to finish an ongoing download before it can proceed.

"available" means that the implementation supports the requested options and the summarizer can proceed.


2.CheckTranslatorAvailability -

To determine if the AI Translator model is ready to use, It returns availability status with the following values -

"unavailable" means that the implementation does not support the requested options.

"downloadable" means that the implementation supports the requested options, but first, the browser has to download something, such as a model (in Chrome's case, Gemini Nano) or fine-tuning for the model.

"downloading" means that the implementation supports the requested options, but it has to finish an ongoing download before it can proceed.

"available" means that the implementation supports the requested options and the summarizer can proceed.


3.DetectTextLanguage -

Detects the closest matching language or languages that a given text string is most likely to be written in.

This action has following input parameters  -

  • -> TextToDetect - A string representing the text to have its language detected.


This action has following output parameters -

  • <- DetectedLanguage- A BCP 47 language tag representing the detected language.
  • <- Confidence- A number between 0 and 1 representing the AI model's confidence that the detected language is correct.
  • <- Error- Error, if any..

4.Translate -

Translate the given text via a browser's internal AI model (which may differ between browsers).

This action has following input parameters -

  • -> TextToTranslate- The text that you want to translate.
  • -> TargetLanguage- The language that the input text will be translated into.
  • -> SourceLanguage- The language of the input text to be translated.


This action has following output parameters -

  • <- TranslatedText- Return generated translation.
  • <- Error- Error, if any..