Skip to main content
Glama

Search legal questions

caselaw_search_questions
Read-onlyIdempotent

Find judgments by the QUESTION they settle, rather than by words they contain.

Every judgment summary on this corpus records the questions that judgment actually decides — e.g.
"Does delay in lodging the FIR by itself entitle the accused to bail?" This searches those
questions, so it matches the shape a legal problem arrives in rather than the vocabulary a
1987 bench happened to use.

COVERAGE IS PARTIAL: only some judgments have a summary with questions yet (the response's
`coverage_note` gives the current live ratio, which keeps growing). An empty result means no
*summarised* judgment matched — it does NOT mean no such judgment exists. Fall back to
caselaw_search, which covers the whole corpus.

The questions are prepared from the judgment text. They are a finding aid, not a
holding: cite the judgment, never the question. Pass an id to caselaw_get_case to read it.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "<query>"
    },
    "name": "caselaw_search_questions"
  }
}

Input Schema

NameRequiredDescriptionDefault
courtNoOnly this court, e.g. 'Supreme Court' or 'Lahore High Court'
judgeNoOnly judgments where this judge sat on the bench (spelling-tolerant, e.g. 'Mansoor Ali Shah')
limitNo
queryYesThe legal question or its subject, in the words a judgment would use — 'delay in lodging FIR', 'concurrent findings of fact', 'pre-arrest bail murder'
offsetNo
year_toNoLatest year (inclusive)
year_fromNoEarliest year (inclusive)
response_formatNomarkdown

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • removedInput schema / $defs
      Removed value: -{
      -  "Fmt": {
      -    "enum": [
      -      "markdown",
      -      "json"
      -    ],
      -    "title": "Fmt",
      -    "type": "string"
      -  }
      -}
    • removedInput schema / properties / response_format / $ref
      Removed value: -"#/$defs/Fmt"
    • addedInput schema / properties / response_format / enum
      Added value: +[
      +  "markdown",
      +  "json"
      +]
    • addedInput schema / properties / response_format / title
      Added value: +"Response Format"
    • addedInput schema / properties / response_format / type
      Added value: +"string"
  2. Changed1 schema field changed
    • addedInput schema / properties / judge
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maxLength": 100,
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Only judgments where this judge sat on the bench (spelling-tolerant, e.g. 'Mansoor Ali Shah')",
      +  "title": "Judge"
      +}
  3. Changed3 schema fields changed
    • addedInput schema / properties / court
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maxLength": 100,
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Only this court, e.g. 'Supreme Court' or 'Lahore High Court'",
      +  "title": "Court"
      +}
    • addedInput schema / properties / year_from
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maximum": 2100,
      +      "minimum": 1900,
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Earliest year (inclusive)",
      +  "title": "Year From"
      +}
    • addedInput schema / properties / year_to
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maximum": 2100,
      +      "minimum": 1900,
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Latest year (inclusive)",
      +  "title": "Year To"
      +}
  4. First observed

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), so the description correctly spends its words elsewhere: partial corpus coverage, the live coverage_note field, the crucial non-obvious fact that an empty result does not mean no such judgment exists, and the epistemic caveat that questions are a finding aid not citable authority. These are exactly the behaviors an agent could not infer from structured fields.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core distinction, then the coverage caveat in bold, then the citation caveat — a sensible priority order. Slightly padded by the rhetorical aside about a 1987 bench and a mild restatement of the question-matching idea across the first and third paragraphs, but no sentence is wasted outright.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter search tool with an output schema, the description covers what the schema cannot: coverage limits, empty-result interpretation, fallback path, and output trust level. An agent has everything needed to call it correctly and to recover gracefully when it returns nothing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 63%, and the description adds real conceptual meaning for the required `query` parameter — it matches against recorded questions, not document text, which changes how the agent should phrase input. However, it says nothing about the court, judge, or year filters, leaving the agent to rely on the schema descriptions alone for those.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and a precisely scoped resource: matching judgments by the legal question they decide rather than by keyword. The contrast with word-based retrieval immediately distinguishes it from the sibling caselaw_search without requiring the agent to open either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit routing: use this when the query is shaped like a legal problem, and fall back to caselaw_search when a result set is empty. It also names the downstream step (pass an id to caselaw_get_case), so the agent knows the full workflow rather than treating this as terminal.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources