{"record":{"id":"520e1a326f236461","repo":"stanfordnlp/CoreNLP","slug":"unknown-language-language","errorCode":null,"errorMessage":"unknown language: \" + language","messagePattern":"unknown language: \" \\+ language","errorType":"validation","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"src/edu/stanford/nlp/tagger/maxent/TTags.java","lineNumber":281,"sourceCode":"      closed.add(\"DB\");\n      closed.add(\"GE\");\n      closed.add(\"PND\");\n      closed.add(\"PNG\");\n      closed.add(\"TO\");\n      closed.add(Tagger.EOS_TAG);\n      closed.add(\"-LRB-\");\n      closed.add(\"-RRB-\");\n      isEnglish = false;\n    } else if (language.equalsIgnoreCase(\"testing\")) {\n      closed.add(\".\");\n      closed.add(Tagger.EOS_TAG);\n      isEnglish = false;\n    } else if (language.equalsIgnoreCase(\"\")) {\n      isEnglish = false;\n    }\n    /* add closed-class lists for other languages here */\n    else {\n      throw new RuntimeException(\"unknown language: \" + language);\n    }\n  }\n\n\n  /** Return the Set of tags used by this tagger (available after training the tagger).\n   *\n   * @return The Set of tags used by this tagger\n   */\n  public Set<String> tagSet() {\n    return new HashSet<>(index.objectsList());\n  }\n\n\n  /**\n   * Returns a list of all open class tags\n   * @return set of open tags\n   */\n  public synchronized Set<String> getOpenTags() {","sourceCodeStart":263,"sourceCodeEnd":299,"githubUrl":"https://github.com/stanfordnlp/CoreNLP/blob/1b7edd19c4d0d7b1f13a2591425b9b60a0b1af7a/src/edu/stanford/nlp/tagger/maxent/TTags.java#L263-L299","documentation":"RuntimeException from TTags when initializing closed-class tag lists for a language name that matches none of the built-in language tables (english, french, german, spanish, chinese, testing, empty, etc.); the tagger cannot select POS tag inventories for that language.","triggerScenarios":"Thrown at src/edu/stanford/nlp/tagger/maxent/TTags.java:281 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass a supported -lang value (e.g., english) or omit it for the default","Add a closed-class list for the language if extending the tagger","Check spelling of the language option"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"1b7edd19c4d0d7b1f13a2591425b9b60a0b1af7a","analyzedAt":"2026-09-10T02:24:07.274Z","contentChangedAt":"2026-09-10T02:24:07.274Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}