Vertex AI Translation is one of the three Vertex AI pre-trained APIs on Google Distributed Cloud (GDC) air-gapped appliance. With the Vertex AI Translation service, you can translate text written in more than ten languages into English.
Vertex AI Translation offers the following methods available in GDC air-gapped appliance:
Method | Description |
---|---|
detectLanguage |
Get the name of the language you are translating. |
getSupportedLanguages |
Return a list of languages supported by the Vertex AI Translation API. For the complete list of the supported languages, see Supported languages for Vertex AI Translation. |
translateText |
Translate input text from one language to another. |
Before making translation requests, set up a translation project. You can test the Vertex AI Translation API on GDC air-gapped appliance by translating text from one language to another.
Considerations
When using the Vertex AI Translation API, particularly the translateText
method, consider the following aspects:
- The maximum input length of contents for translation is 1024 characters.
- You can translate up to 61,000 characters per minute, equivalent to 1,024 characters per second.
- The
translateText
method doesn't support batching. Types of characters and large portions of text affect translation quality. Therefore, if you experience translation issues, follow these steps:
- Remove all special and escape characters that might affect the processing of the request.
- Reduce the input size by splitting the contents into smaller sentences.
- Translate each of the smaller sentences again by sending them in separate requests to the endpoint.
Failure to follow these limiting considerations might result in errors.