Skip to main content
Glama

run_managed_lesson_agent

Destructive

Process accumulated feedback to infer lessons and generate rules for preventing future agent mistakes. Falls back to heuristics if LLM key is unavailable.

Instructions

Run the LLM-powered lesson inference and rule generation agent over accumulated feedback. Requires ANTHROPIC_API_KEY for LLM mode; falls back to heuristics if unavailable.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dryRunNoPreview what would be written without persisting
limitNoMax feedback entries to process (default: 20)
modelNoOverride the Claude model (default: claude-haiku-4-5)
Behavior3/5

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

Annotations already signal destructiveHint=true, lowering the burden. The description adds value by disclosing the heuristic fallback when the API key is missing, but it does not detail what side effects occur (e.g., new lessons/rules created, overwritten) or any other behavioral traits like rate limits or cost implications. The mode switching is helpful, but deeper behavioral context is absent.

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 extremely concise with two sentences. The first sentence is front-loaded with the core purpose, and the second adds essential configuration detail. Every word contributes value; no redundancy or fluff.

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?

Given the tool's complexity (LLM agent with possible state mutation, 3 optional parameters, no output schema), the description is incomplete. It does not explain what the tool returns, whether it is synchronous or asynchronous, how 'accumulated feedback' is defined, or what happens after execution. Even though there is no output schema, the description should at least mention the nature of the output (e.g., lessons generated, status).

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 the baseline is 3. The description does not add any extra explanation for the parameters (dryRun, limit, model); it relies entirely on the schema. No additional meaning or usage hints are provided beyond what is already in the schema.

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 the tool runs an LLM-powered agent that infers lessons and generates rules from accumulated feedback. It uses specific verbs ('run', 'inference', 'generate') and identifies the resource ('lesson inference and rule generation agent'), distinguishing it from read-only siblings like retrieve_lessons or search_lessons.

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?

The description provides a useful condition (requires ANTHROPIC_API_KEY, falls back to heuristics) but offers no guidance on when to use this tool over alternatives like infer_lesson_from_history or context_stuff_lessons. Given the numerous sibling tools, explicit context on when to invoke this vs. others is missing.

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/IgorGanapolsky/ThumbGate'

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