{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/callidus-legal-ai/json-schema/callidus-legal-ai-basic-bot-optional-researched-case-request-schema.json",
  "title": "BasicBotOptionalResearchedCaseRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/callidus-legal-ai-basic-bot-api-openapi.yml#/components/schemas/BasicBotOptionalResearchedCaseRequest",
  "properties": {
    "request": {
      "type": "string",
      "title": "Request"
    },
    "conversationId": {
      "type": "string",
      "title": "Conversationid"
    },
    "history": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "History",
      "default": []
    },
    "control_options": {
      "anyOf": [
        {
          "$ref": "#/$defs/BasicBotControlPanelOptions"
        },
        {
          "type": "null"
        }
      ],
      "default": {
        "creativity": 0.0,
        "analysisDepth": 1,
        "legalFocus": "True",
        "jurisdictions": ""
      }
    },
    "needs_citations": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Needs Citations"
    },
    "is_advanced_mode": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Is Advanced Mode",
      "default": false
    },
    "allowed_cases": {
      "anyOf": [
        {
          "items": {
            "$ref": "#/$defs/CaseSearchResult"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Cases"
    },
    "allowed_statutes": {
      "anyOf": [
        {
          "items": {
            "additionalProperties": {
              "type": "string"
            },
            "type": "object"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Statutes"
    },
    "allowed_web_search": {
      "anyOf": [
        {
          "items": {
            "additionalProperties": {
              "type": "string"
            },
            "type": "object"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Web Search"
    }
  },
  "type": "object",
  "required": [
    "request",
    "conversationId"
  ],
  "$defs": {
    "BasicBotControlPanelOptions": {
      "properties": {
        "creativity": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "title": "Creativity",
          "default": 0
        },
        "analysisDepth": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Analysisdepth",
          "default": 1
        },
        "legalFocus": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Legalfocus",
          "default": "True"
        },
        "jurisdictions": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Jurisdictions",
          "default": ""
        }
      },
      "type": "object",
      "title": "BasicBotControlPanelOptions"
    },
    "CaseSearchResult": {
      "properties": {
        "case_id": {
          "anyOf": [
            {
              "type": "string",
              "format": "uuid"
            },
            {
              "type": "null"
            }
          ],
          "title": "Case Id"
        },
        "title": {
          "type": "string",
          "title": "Title"
        },
        "url": {
          "type": "string",
          "title": "Url"
        },
        "bluebook": {
          "type": "string",
          "title": "Bluebook",
          "default": ""
        },
        "snippet": {
          "type": "string",
          "title": "Snippet",
          "default": ""
        },
        "source": {
          "type": "string",
          "title": "Source",
          "default": "Unknown"
        },
        "jurisdiction": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Jurisdiction"
        },
        "holdings": {
          "anyOf": [
            {
              "items": {
                "$ref": "#/$defs/HoldingModel"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Holdings"
        },
        "shepardizing": {
          "anyOf": [
            {
              "$ref": "#/$defs/ShepardizingSummary"
            },
            {
              "type": "null"
            }
          ]
        },
        "citator_status": {
          "anyOf": [
            {
              "type": "string",
              "const": "unavailable"
            },
            {
              "type": "null"
            }
          ],
          "title": "Citator Status"
        }
      },
      "type": "object",
      "required": [
        "title",
        "url"
      ],
      "title": "CaseSearchResult"
    },
    "HoldingModel": {
      "properties": {
        "holding": {
          "type": "string",
          "title": "Holding"
        },
        "generalized_holding": {
          "type": "string",
          "title": "Generalized Holding"
        }
      },
      "type": "object",
      "required": [
        "holding",
        "generalized_holding"
      ],
      "title": "HoldingModel"
    },
    "PrecedentTreatment": {
      "type": "string",
      "enum": [
        "OVERRULES_FULLY",
        "OVERRULES_PARTIALLY",
        "LIMITS",
        "REVERSES",
        "VACATES",
        "QUESTIONS",
        "DEPARTS",
        "DISTINGUISHES",
        "CLARIFIES",
        "HARMONIZES",
        "FOLLOWS",
        "EXTENDS",
        "CITES",
        "OTHER"
      ],
      "title": "PrecedentTreatment",
      "description": "A more complete version of PrecedentInteraction."
    },
    "ShepardizingChainEntry": {
      "properties": {
        "case_id": {
          "anyOf": [
            {
              "type": "string",
              "format": "uuid"
            },
            {
              "type": "null"
            }
          ],
          "title": "Case Id"
        },
        "case_name": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Case Name"
        },
        "url": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Url"
        },
        "treatment": {
          "anyOf": [
            {
              "$ref": "#/$defs/PrecedentTreatment"
            },
            {
              "type": "null"
            }
          ]
        },
        "analysis": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Analysis"
        },
        "confidence": {
          "anyOf": [
            {
              "$ref": "#/$defs/TreatmentConfidence"
            },
            {
              "type": "null"
            }
          ]
        },
        "depth": {
          "type": "integer",
          "title": "Depth",
          "default": 0
        },
        "color": {
          "type": "string",
          "enum": [
            "red",
            "yellow",
            "gray"
          ],
          "title": "Color",
          "default": "gray"
        }
      },
      "type": "object",
      "title": "ShepardizingChainEntry"
    },
    "ShepardizingSummary": {
      "properties": {
        "flag_color": {
          "type": "string",
          "enum": [
            "red",
            "yellow"
          ],
          "title": "Flag Color"
        },
        "top_overruling": {
          "$ref": "#/$defs/ShepardizingChainEntry"
        },
        "chain": {
          "items": {
            "$ref": "#/$defs/ShepardizingChainEntry"
          },
          "type": "array",
          "title": "Chain"
        }
      },
      "type": "object",
      "required": [
        "flag_color",
        "top_overruling",
        "chain"
      ],
      "title": "ShepardizingSummary"
    },
    "TreatmentConfidence": {
      "type": "string",
      "enum": [
        "EXTREMELY_LOW",
        "LOW",
        "MEDIUM",
        "HIGH",
        "EXTREMELY_HIGH"
      ],
      "title": "TreatmentConfidence"
    }
  }
}