Class AthTranslation


  • public class AthTranslation
    extends Object
    • Constructor Detail

      • AthTranslation

        public AthTranslation()
    • Method Detail

      • translateBatch

        public static List<String> translateBatch​(List<String> texts,
                                                  String sourceLang,
                                                  String targetLang,
                                                  String mimeType,
                                                  String projectId,
                                                  String projectLocation,
                                                  String mtModelProjectId,
                                                  String mtModelProjectLocation,
                                                  String mtModelId,
                                                  String mtGlossaryProjectId,
                                                  String mtGlossaryProjectLocation,
                                                  String mtGlossaryId)
        Translate batch with a single model and glossary (processes in parallel batches if needed)
      • translateBatch

        public static List<String> translateBatch​(List<String> translations,
                                                  String sourceLang,
                                                  String targetLang,
                                                  String mimeType,
                                                  String projectId,
                                                  String projectLocation)
        Translate with the standard NMT model.
        Parameters:
        translations -
        sourceLang -
        targetLang -
        mimeType -
        projectId -
        projectLocation -
        Returns:
      • getClient

        public static com.google.cloud.translate.v3.TranslationServiceClient getClient()