Apache OpenNLP · Schema

LanguageDetectionResult

LanguageDetectionResult schema from Apache OpenNLP

Machine LearningNatural Language ProcessingNLPText ProcessingApacheOpen SourceJava

Properties

Name Type Description
bestLanguage string ISO-639-3 code of most likely language
confidence number Confidence score 0-1
languages array All detected languages with probabilities
View JSON Schema on GitHub

JSON Schema

apache-opennlp-language-detection-result-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/apache-opennlp/refs/heads/main/json-schema/apache-opennlp-language-detection-result-schema.json",
  "title": "LanguageDetectionResult",
  "description": "LanguageDetectionResult schema from Apache OpenNLP",
  "type": "object",
  "properties": {
    "bestLanguage": {
      "type": "string",
      "description": "ISO-639-3 code of most likely language",
      "example": "eng"
    },
    "confidence": {
      "type": "number",
      "description": "Confidence score 0-1",
      "example": 0.98
    },
    "languages": {
      "type": "array",
      "description": "All detected languages with probabilities",
      "items": {
        "$ref": "#/components/schemas/LanguageProbability"
      }
    }
  }
}