Skip to main content
Glama

Find lean declaration

find_lean_declaration
Read-only

Where a Lean declaration of a claim is declared — 'theorem rank5' in a .lean file — searched in the project's repositories that are open to its agents: the repository, the file, the line, the line's text and the commit the index is at. Pass the full name, e.g. 'D5.rank5_decided'; the file names its last part inside its namespace, so read the file when two places answer. Then bind a claim's basis to it with set_claim, {"kind":"lean","ref":"D5.rank5_decided","repo":"ispacex/d5"}. Members of the project who may write only.

Input Schema

NameRequiredDescriptionDefault
nameYesThe declaration's full name, e.g. 'D5.rank5_decided'.
repoNoLook in this repository only, by its path, e.g. 'ispacex/d5'.
projectYesThe project key, e.g. D5.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already cover safety (readOnly, non-destructive, closed-world), and the description adds real behavioral context: the search is limited to the project's repositories open to its agents, results reflect an index pinned to a commit, and the caller must be a project member who may write. That permission requirement is the kind of thing annotations cannot express.

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 purpose is front-loaded and every piece of information is relevant, but the opening is an awkward em-dash run-on that is hard to parse ('Where a Lean declaration of a claim is declared — ... — searched in ...: the repository, ...'). The content is fine; the grammar and density cost it.

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

Completeness4/5

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

There is no output schema, so the description's enumeration of returned fields (repo, file, line, text, commit) is load-bearing and present. It also covers ambiguity resolution and the downstream set_claim binding. Minor gaps: no indication of behavior when nothing is found, and the indexing/commit meaning could be spelled out more.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3. The description earns a bump by explaining why 'name' must be the fully qualified name and by tying 'repo' to the project's repositories, adding rationale the schema's one-line descriptions do not provide.

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 (find/locate) and a specific resource (a Lean declaration) and even enumerates what an answer consists of: repository, file, line, line text, and the commit the index is at. This is clearly distinguishable from generic siblings like read_code, search_code, or code_symbols.

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

Usage Guidelines4/5

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

Gives concrete operating guidance: pass the full name (e.g. 'D5.rank5_decided'), and read the file when two places answer because the file names only the last name part inside its namespace. It also names the follow-up call (set_claim with a concrete JSON payload). It does not explicitly say when to prefer this over search_code/code_symbols, so usage context is inferred rather than stated.

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