{"record":{"id":"1e9576ab4ddc7c0c","repo":"stanfordnlp/CoreNLP","slug":"unsupported-output-style-outputstyle","errorCode":null,"errorMessage":"Unsupported output style \" + outputStyle","messagePattern":"Unsupported output style \" \\+ outputStyle","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"src/edu/stanford/nlp/tagger/maxent/MaxentTagger.java","lineNumber":1880,"sourceCode":"  public void outputTaggedSentence(List<? extends HasWord> sentence,\n                                   boolean outputLemmas, OutputStyle outputStyle,\n                                   boolean outputVerbosity, int numSentences,\n                                   String separator, Writer writer) {\n    try {\n      switch (outputStyle) {\n      case TSV:\n        writer.write(getTsvWords(outputVerbosity, outputLemmas, sentence));\n        break;\n      case XML:\n      case INLINE_XML:\n        writeXMLSentence(writer, sentence, numSentences, outputLemmas);\n        break;\n      case SLASH_TAGS:\n        writer.write(SentenceUtils.listToString(sentence, false, config.getTagSeparator()));\n        writer.write(separator);\n        break;\n      default:\n        throw new IllegalArgumentException(\"Unsupported output style \" + outputStyle);\n      }\n    } catch (IOException e) {\n      throw new RuntimeIOException(e);\n    }\n  }\n\n  /**\n   * Command-line tagger interface.\n   * Can be used to train or test taggers, or to tag text, taking input from\n   * stdin or a file.\n   * See class documentation for usage.\n   *\n   * @param args Command-line arguments\n   * @throws IOException If any file problems\n   */\n  public static void main(String[] args) throws Exception {\n    TaggerConfig config = new TaggerConfig(args);\n","sourceCodeStart":1862,"sourceCodeEnd":1898,"githubUrl":"https://github.com/stanfordnlp/CoreNLP/blob/1b7edd19c4d0d7b1f13a2591425b9b60a0b1af7a/src/edu/stanford/nlp/tagger/maxent/MaxentTagger.java#L1862-L1898","documentation":"RuntimeException from MaxentTagger.outputTaggedSentence when the OutputStyle switch encounters an output style with no rendering branch; the requested tag-output format is not one of the supported styles (TSV, XML, INLINE_XML, SLASH_TAGS, etc.).","triggerScenarios":"Thrown at src/edu/stanford/nlp/tagger/maxent/MaxentTagger.java:1880 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set -outputFormat to a supported style (slashTags, xml, inlineXML, tsv)","Use OutputStyle's enum values programmatically","Check the config value's spelling"],"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"}