{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://github.com/mmerterden/multi-agent-pipeline/pipeline/schemas/answer-request.schema.json",
  "title": "Answer request",
  "description": "The body of POST /v1/runs/{id}/answer: the answer to the question a run stopped on, as `answer-question.mjs <state> --question <questionId> --answer <optionIds>` takes it. questionId is the pendingQuestion.id the client read from the runs index; a run that has moved on to another question refuses the answer. Every option id must be one the question offered. Nothing here is free text, so nothing here can become an instruction.",
  "type": "object",
  "additionalProperties": false,
  "required": ["questionId", "optionIds"],
  "properties": {
    "questionId": {
      "type": "string",
      "pattern": "^[a-z][a-z0-9-]*$",
      "maxLength": 100,
      "x-sensitivity": "none"
    },
    "optionIds": {
      "type": "array",
      "minItems": 1,
      "maxItems": 50,
      "x-sensitivity": "none",
      "items": { "type": "string", "pattern": "^[a-z0-9][a-z0-9+_-]*$", "maxLength": 100 }
    }
  }
}
