Skip to main content
Glama

Get Surrounding Provisions

legal_get_context
Read-onlyIdempotent

Get adjacent norms (paragraphs/articles) before and after a target provision in document order. Serves questions that span consecutive provisions or need the surrounding context of a norm's scope.

Requires a norm_id from a legal_search or legal_lookup result. Returns the target norm plus up to 10 neighbors in each direction. legal_get_toc gives the law-wide overview.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
afterNoNumber of norms after the target (max 10).
beforeNoNumber of norms before the target (max 10).
norm_idYesnorm_id from a prior legal_search or legal_lookup result.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already cover the read-only, idempotent, non-destructive profile. The description adds meaningful context that the result includes the target norm plus up to 10 neighbors in each direction, which clarifies behavior beyond the schema.

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?

The description is compact and front-loaded with the core behavior, then adds the prerequisite and alternative tool in efficient sentences. There is slight redundancy between 'adjacent norms before and after' and 'Returns the target norm plus up to 10 neighbors', but it remains well structured.

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?

Given the simple parameter set, rich annotations, and existing output schema, the description covers the essential context: what it returns, how many neighbors, where the norm_id comes from, and which sibling tool to use for broader overview. Nothing critical is missing.

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 parameters are already well documented. The description adds context about directions and limits, but doesn't provide significant new meaning beyond what the schema already states.

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 ('get') and resource ('adjacent norms/paragraphs/articles before and after a target provision'). Clearly distinguishes itself from siblings by describing document-order neighborhood retrieval.

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?

Explicitly requires a norm_id from legal_search or legal_lookup, describes the type of question it serves, and contrasts itself with legal_get_toc for law-wide context. No ambiguity about when to use it.

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.