{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-web-services/json-schema/amazon-web-services-system-one-response-schema.json",
  "title": "SystemOneResponse",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-web-services-systemone-api-openapi.yml#/components/schemas/SystemOneResponse",
  "properties": {
    "model": {
      "type": "string",
      "title": "Model"
    },
    "answers": {
      "additionalProperties": {
        "anyOf": [
          {
            "$ref": "#/$defs/NoulAnswer"
          },
          {
            "$ref": "#/$defs/ChoiceAnswer"
          },
          {
            "$ref": "#/$defs/ScoreAnswer"
          }
        ]
      },
      "type": "object",
      "title": "Answers"
    },
    "usage": {
      "$ref": "#/$defs/Usage"
    }
  },
  "type": "object",
  "required": [
    "model",
    "answers",
    "usage"
  ],
  "$defs": {
    "ChoiceAnswer": {
      "properties": {
        "type": {
          "type": "string",
          "const": "choice",
          "title": "Type",
          "default": "choice"
        },
        "choice": {
          "type": "string",
          "title": "Choice"
        },
        "probabilities": {
          "additionalProperties": {
            "type": "number"
          },
          "type": "object",
          "title": "Probabilities"
        },
        "confidence": {
          "type": "number",
          "title": "Confidence"
        }
      },
      "type": "object",
      "required": [
        "choice",
        "probabilities",
        "confidence"
      ],
      "title": "ChoiceAnswer"
    },
    "NoulAnswer": {
      "properties": {
        "type": {
          "type": "string",
          "const": "noul",
          "title": "Type",
          "default": "noul"
        },
        "noul": {
          "type": "number",
          "title": "Noul"
        }
      },
      "type": "object",
      "required": [
        "noul"
      ],
      "title": "NoulAnswer"
    },
    "ScoreAnswer": {
      "properties": {
        "type": {
          "type": "string",
          "const": "score",
          "title": "Type",
          "default": "score"
        },
        "score": {
          "type": "number",
          "title": "Score"
        },
        "legend": {
          "additionalProperties": {
            "type": "string"
          },
          "type": "object",
          "title": "Legend"
        },
        "probabilities": {
          "additionalProperties": {
            "type": "number"
          },
          "type": "object",
          "title": "Probabilities"
        },
        "confidence": {
          "type": "number",
          "title": "Confidence"
        }
      },
      "type": "object",
      "required": [
        "score",
        "legend",
        "probabilities",
        "confidence"
      ],
      "title": "ScoreAnswer"
    },
    "Usage": {
      "properties": {
        "input_tokens": {
          "type": "integer",
          "title": "Input Tokens",
          "default": 0
        },
        "output_tokens": {
          "type": "integer",
          "title": "Output Tokens",
          "default": 0
        }
      },
      "type": "object",
      "title": "Usage"
    }
  }
}