Skip to content

Commit c865e77

Browse files
committed
OPENNLP-1753: Switch to pre-trained Model binaries v1.3
- adjusts version strings - adjusts index.html template to latest v1.3 copy for DownloadParserTest - adjusts examples in Dev manual
1 parent c4c3883 commit c865e77

File tree

23 files changed

+621
-557
lines changed

23 files changed

+621
-557
lines changed

opennlp-api/src/main/java/opennlp/tools/monitoring/StopCriteria.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
*/
2727
public interface StopCriteria<T extends Number> extends Predicate<T> {
2828

29-
String FINISHED = "Training Finished after completing %s Iterations successfully.";
29+
String FINISHED = "Training finished after completing %s iterations successfully.";
3030

3131
/**
3232
* @return A detailed message captured upon hitting the {@link StopCriteria} during model training.

opennlp-core/opennlp-cli/src/test/java/opennlp/tools/AbstractModelLoaderTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public abstract class AbstractModelLoaderTest {
3838
private static final String BASE_URL_MODELS_V183 = "https://dlcdn.apache.org/opennlp/models/langdetect/1.8.3/";
3939
protected static final Path OPENNLP_DIR = Paths.get(System.getProperty("OPENNLP_DOWNLOAD_HOME",
4040
System.getProperty("user.home"))).resolve(".opennlp");
41-
protected static final String VER = "1.2-2.5.0";
41+
protected static final String VER = "1.3-2.5.4";
4242
protected static final String BIN = ".bin";
4343
protected static List<String> SUPPORTED_LANG_CODES = List.of(
4444
"en", "fr", "de", "it", "nl", "bg", "ca", "cs", "da", "el",

opennlp-core/opennlp-cli/src/test/java/opennlp/tools/cmdline/lemmatizer/LemmatizerModelLoaderIT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public void setup() {
5656

5757
@ParameterizedTest(name = "Verify \"{0}\" tokenizer model loading")
5858
@ValueSource(strings = {"en-ud-ewt", "fr-ud-gsd", "de-ud-gsd", "it-ud-vit", "nl-ud-alpino",
59-
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdt", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
59+
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdtc", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
6060
"eu-ud-bdt", "fi-ud-tdt", "hr-ud-set", "hy-ud-bsut", "is-ud-icepahc", "ka-ud-glc", "kk-ud-ktb",
6161
"ko-ud-kaist", "lv-ud-lvtb", "no-ud-bokmaal", "pl-ud-pdb", "pt-ud-gsd", "ro-ud-rrt", "ru-ud-gsd",
6262
"sr-ud-set", "sk-ud-snk", "sl-ud-ssj", "sv-ud-talbanken", "tr-ud-boun", "uk-ud-iu"})

opennlp-core/opennlp-cli/src/test/java/opennlp/tools/cmdline/postag/POSModelLoaderIT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public void setup() {
5656

5757
@ParameterizedTest(name = "Verify \"{0}\" POS model loading")
5858
@ValueSource(strings = {"en-ud-ewt", "fr-ud-gsd", "de-ud-gsd", "it-ud-vit", "nl-ud-alpino",
59-
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdt", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
59+
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdtc", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
6060
"eu-ud-bdt", "fi-ud-tdt", "hr-ud-set", "hy-ud-bsut", "is-ud-icepahc", "ka-ud-glc", "kk-ud-ktb",
6161
"ko-ud-kaist", "lv-ud-lvtb", "no-ud-bokmaal", "pl-ud-pdb", "pt-ud-gsd", "ro-ud-rrt", "ru-ud-gsd",
6262
"sr-ud-set", "sk-ud-snk", "sl-ud-ssj", "sv-ud-talbanken", "tr-ud-boun", "uk-ud-iu"})

opennlp-core/opennlp-cli/src/test/java/opennlp/tools/cmdline/sentdetect/SentenceModelLoaderIT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public void setup() {
5656

5757
@ParameterizedTest(name = "Verify \"{0}\" sentence model loading")
5858
@ValueSource(strings = {"en-ud-ewt", "fr-ud-gsd", "de-ud-gsd", "it-ud-vit", "nl-ud-alpino",
59-
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdt", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
59+
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdtc", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
6060
"eu-ud-bdt", "fi-ud-tdt", "hr-ud-set", "hy-ud-bsut", "is-ud-icepahc", "ka-ud-glc", "kk-ud-ktb",
6161
"ko-ud-kaist", "lv-ud-lvtb", "no-ud-bokmaal", "pl-ud-pdb", "pt-ud-gsd", "ro-ud-rrt", "ru-ud-gsd",
6262
"sr-ud-set", "sk-ud-snk", "sl-ud-ssj", "sv-ud-talbanken", "tr-ud-boun", "uk-ud-iu"})

opennlp-core/opennlp-cli/src/test/java/opennlp/tools/cmdline/tokenizer/TokenizerModelLoaderIT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public void setup() {
5656

5757
@ParameterizedTest(name = "Verify \"{0}\" tokenizer model loading")
5858
@ValueSource(strings = {"en-ud-ewt", "fr-ud-gsd", "de-ud-gsd", "it-ud-vit", "nl-ud-alpino",
59-
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdt", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
59+
"bg-ud-btb", "ca-ud-ancora", "cs-ud-pdtc", "da-ud-ddt", "el-ud-gdt", "es-ud-gsd", "et-ud-edt",
6060
"eu-ud-bdt", "fi-ud-tdt", "hr-ud-set", "hy-ud-bsut", "is-ud-icepahc", "ka-ud-glc", "kk-ud-ktb",
6161
"ko-ud-kaist", "lv-ud-lvtb", "no-ud-bokmaal", "pl-ud-pdb", "pt-ud-gsd", "ro-ud-rrt", "ru-ud-gsd",
6262
"sr-ud-set", "sk-ud-snk", "sl-ud-ssj", "sv-ud-talbanken", "tr-ud-boun", "uk-ud-iu"})

opennlp-core/opennlp-formats/src/test/java/opennlp/tools/formats/TwentyNewsgroupSampleStreamFactoryTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public class TwentyNewsgroupSampleStreamFactoryTest extends
4949

5050
private static final Path OPENNLP_DIR = Paths.get(System.getProperty("OPENNLP_DOWNLOAD_HOME",
5151
System.getProperty("user.home"))).resolve(".opennlp");
52-
private static final String TOKENIZER_MODEL_NAME = "opennlp-en-ud-ewt-tokens-1.2-2.5.0.bin";
52+
private static final String TOKENIZER_MODEL_NAME = "opennlp-en-ud-ewt-tokens-1.3-2.5.4.bin";
5353

5454
// SUT
5555
private TwentyNewsgroupSampleStreamFactory factory;

opennlp-core/opennlp-formats/src/test/java/opennlp/tools/formats/brat/BratNameSampleStreamFactoryTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public class BratNameSampleStreamFactoryTest extends
5252

5353
private static final Path OPENNLP_DIR = Paths.get(System.getProperty("OPENNLP_DOWNLOAD_HOME",
5454
System.getProperty("user.home"))).resolve(".opennlp");
55-
private static final String TOKENIZER_MODEL_NAME = "opennlp-en-ud-ewt-tokens-1.2-2.5.0.bin";
55+
private static final String TOKENIZER_MODEL_NAME = "opennlp-en-ud-ewt-tokens-1.3-2.5.4.bin";
5656

5757
// SUT
5858
private BratNameSampleStreamFactory factory;

opennlp-core/opennlp-formats/src/test/java/opennlp/tools/formats/muc/Muc6NameSampleStreamFactoryTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public class Muc6NameSampleStreamFactoryTest extends
4848

4949
private static final Path OPENNLP_DIR = Paths.get(System.getProperty("OPENNLP_DOWNLOAD_HOME",
5050
System.getProperty("user.home"))).resolve(".opennlp");
51-
private static final String TOKENIZER_MODEL_NAME = "opennlp-en-ud-ewt-tokens-1.2-2.5.0.bin";
51+
private static final String TOKENIZER_MODEL_NAME = "opennlp-en-ud-ewt-tokens-1.3-2.5.4.bin";
5252

5353
// SUT
5454
private Muc6NameSampleStreamFactory factory;

opennlp-core/opennlp-runtime/src/main/java/opennlp/tools/util/DownloadUtil.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ public class DownloadUtil {
5858
private static final String BASE_URL =
5959
System.getProperty("OPENNLP_DOWNLOAD_BASE_URL", "https://dlcdn.apache.org/opennlp/");
6060
private static final String MODEL_URI_PATH =
61-
System.getProperty("OPENNLP_DOWNLOAD_MODEL_PATH", "models/ud-models-1.2/");
61+
System.getProperty("OPENNLP_DOWNLOAD_MODEL_PATH", "models/ud-models-1.3/");
6262
private static final String OPENNLP_DOWNLOAD_HOME = "OPENNLP_DOWNLOAD_HOME";
6363

6464
private static Map<String, Map<ModelType, String>> availableModels;

0 commit comments

Comments
 (0)