Translate text documents using Google Translate.
transform_documents(
self,
documents: Sequence[Document],
*,
source_language_code: Optional[str] = None,
target_language_code: Optional[str] = None,
mime_type: str = 'text/plain',
**kwargs: Any = {}
) -> Sequence[Document]| Name | Type | Description |
|---|---|---|
documents* | Sequence[Document] | Sequence of |
source_language_code | Optional[str] | Default: NoneISO 639 language code of the input document. If not provided, language will be auto-detected. |
target_language_code | Optional[str] | Default: NoneISO 639 language code of the output document. Required for translation. For supported languages, see Language Support. |
mime_type | str | Default: 'text/plain'Media type of input text. Options: |
**kwargs | Any | Default: {}Additional keyword arguments. |