Skip to main content
Glama

WritersLogic verifiable AI agents

precedent-search

Case-law precedent search (CourtListener, US) — Finds US court opinions most on point for a legal question or fact pattern: searches CourtListener's case-law index (optionally limited to courts and filing dates), reads the top opinions, and returns the best matches with a holding passage verified verbatim against the opinion text, plus citation, court, date, precedential status and a source hash. A second skeptical pass flags matches that look

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": {
      "question": "<question>"
    },
    "name": "precedent-search"
  }
}

Input Schema

NameRequiredDescriptionDefault
courtsNoCourtListener court ids such as "scotus", "ca9", "cal", "calctapp". Omit to search all courts.
questionYesThe legal issue and key facts. Quote a phrase to require it verbatim in the search.
filed_afterNoEarliest filing date, YYYY-MM-DD.
max_resultsNoDefault 5.
filed_beforeNoLatest filing date, YYYY-MM-DD.
include_excerptsNoDefault true. When false, the holding passage text is omitted from the output (quote_verified and quote_offset are still reported).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: it discloses the pipeline (search index, read top opinions, rank), the verbatim-verification guarantee on the holding quote, and a 'second skeptical pass'. It omits operational traits such as latency, rate limits, or upstream API/auth requirements, and the sentence describing the skeptical pass is cut off mid-thought.

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

Conciseness3/5

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

The core purpose is front-loaded and dense without filler, which is good. But the definition is one run-on sentence that trails off at 'flags matches that look ', leaving an unfinished clause that reads as broken rather than concise.

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

Completeness3/5

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

For a 6-parameter tool with no output schema and no annotations, the description usefully enumerates return fields, which compensates for the missing output schema. The truncation is the real gap: the agent never learns what the skeptical pass flags or how to react to it, and nothing is said about cost or turnaround for a multi-step search-plus-read pipeline.

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 description coverage is 100%, so every parameter is already documented in the schema. The description only echoes that courts and filing dates act as optional limits; it adds no new syntax, defaults, or trade-off guidance beyond the schema. Baseline 3 is appropriate.

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 resource — search CourtListener's US case-law index for opinions on point — and enumerates what comes back (holding passage verified verbatim, citation, court, date, precedential status, source hash). That is clearly distinct from siblings like legal-cite-verifier or prior-art-invalidator, so an agent can route on the description alone.

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

Usage Guidelines3/5

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

Usage is implied by 'Finds US court opinions most on point for a legal question or fact pattern' and by noting the search can be limited to courts and filing dates. However, no sibling is named as an alternative and there are no explicit when-not-to-use conditions (e.g., verifying a citation you already have versus discovering new authority).

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