Skip to main content
Glama

Capture Lesson

capture_lesson

Capture lessons from project work: define context, problem, and solution, extract lessons automatically from text, or look up existing lessons by keyword to reinforce knowledge.

Instructions

Capture lessons: inline / batch write, or lookup by keyword.

Inline mode (default): provide title, context, problem, solution. Batch mode: provide text to extract lessons automatically via worker. Lookup mode: provide find to surface top-ranked existing lessons whose heading matches the keyword.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
findNoKeyword to look up in existing lesson headings (lookup mode).
tagsNoOptional tags (e.g. ["python", "testing"]).
textNoRaw text to extract lessons from (batch mode).
titleNoShort descriptive title (inline mode).
contextNoWhat you were doing (inline mode).
problemNoWhat went wrong or what decision was needed (inline mode).
projectYesProject slug (directory under 10_projects/).
rank_byNoLookup ranking — 'reinforcements' (default), 'confidence', or 'hybrid'. Ignored unless ``find`` is set.reinforcements
solutionNoWhat fixed it or what was decided (inline mode).
max_lessonsNoMaximum lessons to extract / surface. Default 5.
min_confidenceNoMinimum confidence for batch extraction. Default 0.7.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.21.0
  2. Removedv1.13.0
  3. First observedv1.11.0

TDQS

A4.4/5.0
Behavior4/5

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

With annotations only providing readOnlyHint=false, idempotentHint=false, and destructiveHint=false, the description adds useful behavioral context: batch mode 'extract[s] lessons automatically via worker' suggests asynchronous/delegated processing, and lookup mode 'surface[s] top-ranked existing lessons' clarifies read behavior. This goes beyond the sparse annotations.

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 compact and well-structured: a one-line summary followed by three bullet-like mode explanations. Every sentence earns its place, and the core purpose is front-loaded. No redundancy or filler exists.

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 tool with 11 parameters and three modes, the description provides sufficient high-level context to choose and invoke the tool correctly, especially with an output schema present. It explains the main parameter roles and mode selection. A possible improvement is explicitly stating mode-selection precedence (e.g., if find is set, lookup wins), but the schema defaults and parameter descriptions make this inferable.

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, but the description adds meaningful mode-based grouping: inline mode maps to title/context/problem/solution, batch mode to text, and lookup mode to find. It also reinforces that rank_by is ignored unless find is set. This is above baseline because it organizes parameters semantically rather than just repeating schema field descriptions.

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 opens with 'Capture lessons: inline / batch write, or lookup by keyword,' which names a specific verb and resource. It then enumerates three distinct modes (inline, batch, lookup), making it clearly distinguishable from sibling vault_* tools that handle generic vault content.

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?

The description gives clear guidance on when to use each mode: inline for title/context/problem/solution, batch for text extraction via worker, and lookup for keyword search. However, it does not explicitly compare this tool to alternatives like vault_write or vault_query, so some competitive routing is left to inference.

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