Skip to main content
Glama

ai_prompt_improve

Read-only

Prompt improver — Rewrite a prompt so an LLM gives better results: clear task and goal, context, output format, constraints and success criteria, placeholders for missing details (never invents facts). Returns the improved prompt, list of changes, issues found, questions to answer, before/after scores and token estimates. Price: $0.006 USDC (Base, via x402).

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": {
      "prompt": "<prompt>"
    },
    "name": "ai_prompt_improve"
  }
}

Input Schema

NameRequiredDescriptionDefault
goalNoWhat you want the output to achieve (optional)
styleNoconcise | balanced | detailed (default balanced)
promptYesPrompt to improve (required, max 8000 chars)
targetNoTarget model name (optional)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already cover read-only/non-destructive, and the description goes further by disclosing the paid access model ($0.006 USDC on Base via x402) and a behavioral guarantee that it "never invents facts" but inserts placeholders instead. It also lists the concrete return payload, which annotations cannot convey.

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?

Effectively two sentences: purpose first, then the return/cost facts. The enumerated lists are dense but each item carries information useful to an agent lacking an output schema. No filler prose.

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?

For a 4-parameter, no-output-schema tool, the description covers what it does, what comes back, and the payment requirement — enough to call it correctly. Missing only edge-case behavior (e.g., oversized prompts beyond the 8000-char cap, or failure/payment-refund semantics).

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 coverage is 100%, so the baseline is 3. The description's mentions of "goal," output format and constraints loosely echo the goal/style/target parameters but add no format, default, or interaction detail beyond what the schema already states.

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?

"Rewrite a prompt so an LLM gives better results" is a specific verb+resource, and the following clause enumerates the aspects it targets (task/goal, context, output format, constraints, placeholders). It is unmistakable vs. generation tools like ai_ask or ai_chat, though it never names a sibling to contrast with.

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?

The use case is implied clearly — reach for this when you have a prompt and want it improved before sending it to an LLM. However, there is no explicit when-to-use/when-not framing and no routing to alternatives, so the agent must infer the boundary from the enumerated prompt components.

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