{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/evalgate-com/json-schema/evalgate-com-post-api-arena-compare-response201-application-json-schema.json",
  "title": "PostApiArenaCompareResponse201ApplicationJson",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/evalgate-com-arena-api-openapi.yml#/components/schemas/PostApiArenaCompareResponse201ApplicationJson",
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "matchId": {
          "type": "number"
        },
        "review": {
          "oneOf": [
            {
              "type": "null"
            },
            {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "matchId": {
                  "type": "number"
                },
                "reviewerId": {
                  "type": "string"
                },
                "reviewerKind": {
                  "oneOf": [
                    {
                      "type": "string",
                      "enum": [
                        "automation"
                      ]
                    },
                    {
                      "type": "string",
                      "enum": [
                        "human"
                      ]
                    }
                  ]
                },
                "choice": {
                  "oneOf": [
                    {
                      "type": "null"
                    },
                    {
                      "type": "string"
                    }
                  ]
                },
                "decidedAt": {
                  "oneOf": [
                    {
                      "type": "null"
                    },
                    {
                      "type": "string"
                    }
                  ]
                },
                "responses": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "label": {
                        "oneOf": [
                          {
                            "type": "string",
                            "enum": [
                              "A"
                            ]
                          },
                          {
                            "type": "string",
                            "enum": [
                              "B"
                            ]
                          },
                          {
                            "type": "string",
                            "enum": [
                              "C"
                            ]
                          },
                          {
                            "type": "string",
                            "enum": [
                              "D"
                            ]
                          },
                          {
                            "type": "string",
                            "enum": [
                              "E"
                            ]
                          }
                        ]
                      },
                      "output": {
                        "oneOf": [
                          {
                            "type": "null"
                          },
                          {
                            "type": "string"
                          }
                        ]
                      }
                    },
                    "additionalProperties": false,
                    "required": [
                      "label",
                      "output"
                    ]
                  }
                },
                "revealed": {
                  "oneOf": [
                    {
                      "type": "null"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "assignments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "label": {
                                "oneOf": [
                                  {
                                    "type": "string",
                                    "enum": [
                                      "A"
                                    ]
                                  },
                                  {
                                    "type": "string",
                                    "enum": [
                                      "B"
                                    ]
                                  },
                                  {
                                    "type": "string",
                                    "enum": [
                                      "C"
                                    ]
                                  },
                                  {
                                    "type": "string",
                                    "enum": [
                                      "D"
                                    ]
                                  },
                                  {
                                    "type": "string",
                                    "enum": [
                                      "E"
                                    ]
                                  }
                                ]
                              },
                              "modelId": {
                                "type": "string"
                              }
                            },
                            "additionalProperties": false,
                            "required": [
                              "label",
                              "modelId"
                            ]
                          }
                        },
                        "results": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "modelId": {
                                "type": "string"
                              },
                              "modelLabel": {
                                "type": "string"
                              },
                              "score": {
                                "type": "number"
                              },
                              "output": {
                                "type": "string"
                              },
                              "responseTime": {
                                "type": "number"
                              },
                              "tokenCount": {
                                "type": "number"
                              },
                              "cost": {
                                "oneOf": [
                                  {
                                    "type": "null"
                                  },
                                  {
                                    "type": "number"
                                  }
                                ]
                              },
                              "costConfidence": {
                                "oneOf": [
                                  {
                                    "type": "string",
                                    "enum": [
                                      "estimated"
                                    ]
                                  },
                                  {
                                    "type": "string",
                                    "enum": [
                                      "unknown"
                                    ]
                                  },
                                  {
                                    "type": "string",
                                    "enum": [
                                      "verified"
                                    ]
                                  }
                                ]
                              },
                              "costRecordId": {
                                "type": "number"
                              },
                              "costSource": {
                                "type": "string"
                              },
                              "modelCallId": {
                                "type": "string"
                              }
                            },
                            "additionalProperties": false,
                            "required": [
                              "modelId",
                              "modelLabel",
                              "score",
                              "output",
                              "responseTime",
                              "tokenCount",
                              "cost",
                              "costConfidence"
                            ]
                          }
                        },
                        "winnerId": {
                          "type": "string"
                        },
                        "scores": {
                          "oneOf": [
                            {
                              "type": "null"
                            },
                            {
                              "type": "object",
                              "additionalProperties": {
                                "type": "number"
                              }
                            }
                          ]
                        },
                        "judgeReasoning": {
                          "oneOf": [
                            {
                              "type": "null"
                            },
                            {
                              "type": "string"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false,
                      "required": [
                        "assignments",
                        "results",
                        "winnerId",
                        "scores",
                        "judgeReasoning"
                      ]
                    }
                  ]
                }
              },
              "additionalProperties": false,
              "required": [
                "id",
                "matchId",
                "reviewerId",
                "reviewerKind",
                "choice",
                "decidedAt",
                "responses",
                "revealed"
              ]
            }
          ]
        }
      },
      "additionalProperties": false,
      "required": [
        "matchId",
        "review"
      ]
    },
    {
      "type": "object",
      "properties": {
        "matchId": {
          "type": "number"
        },
        "winner": {
          "type": "object",
          "properties": {
            "modelId": {
              "type": "string"
            },
            "label": {
              "type": "string"
            }
          },
          "additionalProperties": false,
          "required": [
            "modelId",
            "label"
          ]
        },
        "judgeReasoning": {
          "type": "string"
        },
        "responses": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "modelId": {
                "type": "string"
              },
              "output": {
                "type": "string"
              },
              "latencyMs": {
                "type": "number"
              },
              "tokenCount": {
                "type": "number"
              },
              "cost": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "type": "number"
                  }
                ]
              },
              "costConfidence": {
                "oneOf": [
                  {
                    "type": "string",
                    "enum": [
                      "estimated"
                    ]
                  },
                  {
                    "type": "string",
                    "enum": [
                      "unknown"
                    ]
                  },
                  {
                    "type": "string",
                    "enum": [
                      "verified"
                    ]
                  }
                ]
              }
            },
            "additionalProperties": false,
            "required": [
              "modelId",
              "output",
              "latencyMs",
              "tokenCount",
              "cost",
              "costConfidence"
            ]
          }
        },
        "scores": {
          "type": "object",
          "additionalProperties": {
            "type": "number"
          }
        }
      },
      "additionalProperties": false,
      "required": [
        "matchId",
        "winner",
        "judgeReasoning",
        "responses",
        "scores"
      ]
    }
  ]
}