Skip to main content
Glama

agda_retrieve_context

Retrieve the type and local context for an Agda goal handle, with options to control rewriting, blocking behavior, and timeouts during interactive type checking.

Instructions

Retrieve the type and local context for an opaque goal handle

Input Schema

NameRequiredDescriptionDefault
goalYesOpaque goal handle returned by the latest module state
asyncNotrue always returns a job handle; false blocks until Agda finishes
rewriteNo
timeoutMsNoOverride the configured Agda command timeout for this call
includeRawNoInclude Agda's native event log; omitted by default because it is large
deferAfterMsNoHow long this call may block before returning a job handle; capped by maxJobWaitMs

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.1
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. First observedv0.3.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It does not mention read-only behavior, async/job-handle semantics, blocking versus non-blocking behavior, timeout implications, or side effects, despite parameters like async, deferAfterMs, and includeRaw implying non-trivial execution behavior.

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

Conciseness5/5

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

The description is a single front-loaded sentence with no filler or redundancy. It is efficiently sized and easy to scan, even though its brevity contributes to gaps captured in other dimensions.

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

Completeness2/5

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

This is a 6-parameter tool with no annotations and no output schema, yet the description omits return shape, async/job behavior, error semantics, and relationship to the plural sibling agda_retrieve_contexts. It gives the basic purpose but is not complete enough for confident invocation in non-trivial cases.

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 83%, so the schema already documents most parameters, and this sets the baseline at 3. The description reinforces that the goal parameter is an opaque handle, but it adds no meaning for rewrite, async, timeoutMs, includeRaw, or deferAfterMs beyond what the schema provides.

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

Purpose4/5

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

The description states a specific verb and resource: retrieve the type and local context for a goal handle. It is clear what the tool returns, but it does not distinguish itself from the near-duplicate sibling agda_retrieve_contexts (plural) or from agda_retrieve_goals.

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

Usage Guidelines2/5

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

There is no when-to-use guidance, no prerequisites, and no mention of alternatives. With a sibling named agda_retrieve_contexts, an agent has no description-based way to decide which context-retrieval tool to call.

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