diff --git a/libai/src/main/java/ai/api/AIConfiguration.java b/libai/src/main/java/ai/api/AIConfiguration.java index 1c24be9..bf93c1b 100644 --- a/libai/src/main/java/ai/api/AIConfiguration.java +++ b/libai/src/main/java/ai/api/AIConfiguration.java @@ -250,10 +250,23 @@ String getContextsUrl(final String sessionId, final String suffix) { * Currently supported languages */ public static enum SupportedLanguages { - English("en"), EnglishUS("en-US", "en"), EnglishGB("en-GB", "en"), Russian("ru"), German( - "de"), Portuguese("pt"), PortugueseBrazil("pt-BR"), Spanish("es"), French("fr"), Italian( - "it"), Japanese("ja"), Korean( - "ko"), ChineseChina("zh-CN"), ChineseHongKong("zh-HK"), ChineseTaiwan("zh-TW"); + ChineseChina("zh-CN"), + ChineseHongKong("zh-HK"), + ChineseTaiwan("zh-TW"), + English("en"), + EnglishUS("en-US", "en"), + EnglishGB("en-GB", "en"), + Dutch("nl"), + French("fr"), + German("de"), + Italian("it"), + Japanese("ja"), + Korean("ko"), + Portuguese("pt"), + PortugueseBrazil("pt-BR"), + Russian("ru"), + Spanish("es"), + Ukrainian("uk"); /** * Default language value diff --git a/libai/src/test/java/ai/api/AIConfigurationTest.java b/libai/src/test/java/ai/api/AIConfigurationTest.java index b74a8a3..2d676d5 100644 --- a/libai/src/test/java/ai/api/AIConfigurationTest.java +++ b/libai/src/test/java/ai/api/AIConfigurationTest.java @@ -19,6 +19,8 @@ public void testSupportedLanguage() { assertEquals(SupportedLanguages.DEFAULT, SupportedLanguages.fromLanguageTag(null)); assertEquals(SupportedLanguages.DEFAULT, SupportedLanguages.fromLanguageTag("")); assertEquals(SupportedLanguages.DEFAULT, SupportedLanguages.fromLanguageTag("uu-UU")); + assertEquals(SupportedLanguages.Dutch, SupportedLanguages.fromLanguageTag("nl")); + assertEquals(SupportedLanguages.Ukrainian, SupportedLanguages.fromLanguageTag("uk")); } @Test(expected=IllegalArgumentException.class)