Skip to main content
Glama

ampl_diagnose

Retrieve the last solve's status, message, and violated constraints to explain infeasible or unbounded results and avoid guesswork.

Instructions

Explain the last solve: status, message, and violated constraints.

Call this after an infeasible or unbounded result rather than guessing at the model.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sessionNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior3/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. It discloses what the tool outputs (status, message, violated constraints) but does not mention whether it is read-only, how it handles sessions, or any side effects. This leaves some ambiguity.

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 two sentences long, front-loaded with the purpose, and contains no filler. Every word adds value.

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?

The tool is simple, and an output schema exists to document return values. The description explains the core function and when to use it. However, it omits any mention of the session parameter and any potential dependency on a prior solve, so it is not fully complete.

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

Parameters2/5

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

The schema has one optional 'session' parameter, but the description never mentions it. With schema description coverage at 0%, the description provides no parameter guidance. The param name is somewhat self-explanatory, but the description fails to compensate for the lack of schema details.

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?

The description clearly states 'Explain the last solve: status, message, and violated constraints', using a specific verb and resource. This distinguishes it from sibling tools like ampl_solve or ampl_display, which have different functions.

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?

It explicitly says 'Call this after an infeasible or unbounded result rather than guessing at the model', providing clear when-to-use guidance and an exclusion (don't guess). This is direct and actionable.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/worc4021/ampl-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server