Skip to main content
Glama

List project lessons

list_lessons
Read-onlyIdempotent

Retrieve all promoted lessons for the current project, highest frequency first. Filter by severity or limit to browse the full catalog of encoded heuristics.

Instructions

List promoted learning rules ("lessons") for the current project, highest-frequency first. Returns { lessons: [{ id, rule_text, severity, frequency, anti_pattern, … }] }. Read-only. Use to browse the full catalog of encoded heuristics; use query_lessons to retrieve only lessons relevant to a specific diff or PR within a token budget.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMax lessons to return (default 50, max 200)
severityNoFilter to one severity level
projectIdNoProject UUID — defaults to configured project (`project_id` is accepted too.)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
lessonsYesPromoted lesson rows ordered by frequency

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.1.12
    • addedInput schema / properties / projectId
      Added value: +{
      +  "description": "Project UUID — defaults to configured project (`project_id` is accepted too.)",
      +  "type": "string"
      +}
    • removedInput schema / properties / project_id
      Removed value: -{
      -  "description": "Project UUID — defaults to configured project",
      -  "type": "string"
      -}
  2. Changed2 schema fields changedv0.1.10
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  3. Changed4 schema fields changedv0.1.2
    • changedInput schema / properties / limit / description
      Previous value: -"Max number of lessons to return (default 50, max 200)."New value: +"Max lessons to return (default 50, max 200)"
    • changedInput schema / properties / project_id / description
      Previous value: -"Project UUID. Defaults to configured project."New value: +"Project UUID — defaults to configured project"
    • changedInput schema / properties / severity / description
      Previous value: -"Filter by severity level."New value: +"Filter to one severity level"
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": false,
      +  "properties": {
      +    "lessons": {
      +      "description": "Promoted lesson rows ordered by frequency",
      +      "items": {},
      +      "type": "array"
      +    }
      +  },
      +  "required": [
      +    "lessons"
      +  ],
      +  "type": "object"
      +}
  4. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already cover read-only, idempotent, and open-world behavior, and the description reinforces 'Read-only'. Beyond that, it adds behavioral context about 'promoted' lessons and highest-frequency-first ordering. The return shape is mentioned but the output schema already covers it, so this is useful but not critical extra disclosure.

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?

Three sentences deliver the purpose, output shape, read-only trait, and usage alternative with zero filler. The most decision-relevant information (what it lists and how it is ordered) is front-loaded.

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

Completeness5/5

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

Given the output schema, annotations, and fully documented parameters, nothing essential is missing. The description also supplies the key sibling-routing information, making it complete for an agent to select and call this tool correctly.

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 limit, severity, and projectId are already fully documented. The description adds minimal parameter-level meaning beyond confirming the 'current project' default, which is consistent with projectId. It does not need to compensate for schema gaps.

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 states a specific action (List), a specific resource (promoted learning rules/lessons for the current project), and a concrete behavior (highest-frequency first). It also distinguishes itself from query_lessons by describing the full-catalog browsing purpose, making it easy to tell apart from siblings.

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?

The description explicitly says when to use this tool ('browse the full catalog of encoded heuristics') and when not to, naming query_lessons as the alternative for diff/PR-specific retrieval within a token budget. This gives clear routing guidance with no inference required.

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