Skip to main content
Glama

Record feedback on a scan

record_feedback

Record the user's feedback on a scan. The scan reads it while it runs.

Trent reasons from code, sites, and documents. Feedback supplies intent,
deployment facts, and accepted risks that those sources cannot show:
"that host is internal", "we accept that risk", or "this finding misreads
our auth flow". Use this for feedback that needs reasoning. Use
edit_analysis for a mechanical correction to one field of one finding.

Record the feedback the user expresses in their current message, in
their own words. A correction in passing counts as a request to record it.
Do not reconstruct feedback from earlier turns, infer or embellish it,
or resubmit it on your own initiative; that can invent the user's intent.
Do not record feedback twice, even if an earlier item is missing from a
listing; recording it again creates a duplicate.

Each item is acted on by one stage, so record one item per claim, each
with its own stage_id. Do not add items for effects the user did not
state: "we added Redis as a cache" is one item at understand. A
consequence the user states ("so F-12 should be Low") is its own claim.
One fact that explains several findings is one item at understand that
names them; accepting a risk is one item at secure. Repeat a shared reason
in each item so each stands alone. Tell the user how you split their
message, listing only the items that recorded.

Name the project with project_id or project_name; with neither, the call
is refused. Check attached_to_scan. When false, say the feedback is stored
without a scan to read it.

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": {
      "content": "<content>"
    },
    "name": "record_feedback"
  }
}

Input Schema

NameRequiredDescriptionDefault
contentYesThe user's feedback in their own words from their current message.
stage_idNoThe earliest analysis stage that owns what the feedback is about: 'understand' (components, data flows, trust boundaries, assets, diagrams, deployment and exposure facts), 'plan' (security requirements) or 'secure' (findings, severity, attack chains, controls, fixes, accepted risks). Always pass it: if omitted, the item goes to whatever stage the scan is on, which may not be the stage that owns it.
project_idNoProject ID (provide either project_id or project_name)
project_nameNoProject name (provide either project_id or project_name)

Output Schema

NameRequiredDescriptionDefault
errorNoTrue when the call itself failed. False for successful calls, including a scan still running, an already approved plan, or a repository classified as non-agentic. The reason field describes these workflow states.
reasonNoA stable snake_case code from the allowed set. Present on every error and on successful calls that carry a workflow state.
statusNoLifecycle status of the feedback row.
item_idNoLasting identifier of the item. It stays the same across corrections.
messageNoExactly one sentence written for the user. Never raw exception text or a backend error string, which may expose private details.
scan_idNoThe scan the server attached the feedback to.
versionNoVersion of the item this call wrote. A new item is version 1.
metadataNoCaller metadata, such as 'expiration_warning'. Substantive results have their own fields. Never includes exception or backend error text, which may expose private details.
stage_idNoThe analysis stage the feedback was recorded against.
next_stepsNoRecommended next actions, in order.
feedback_idNoIdentifier of the recorded feedback.
attached_to_scanNoFalse means the feedback is stored without a scan to read it. Say that it is stored but will not be used by a scan.
retry_after_secondsNoWith reason rate_limited, how many seconds Trent asks the caller to wait.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / stage_id / description
      Previous value: -"Which analysis stage the feedback is about: 'understand' (what the system is), 'plan' (what to require) or 'secure' (findings and fixes). Omit it and the server uses the stage the scan is on."New value: +"The earliest analysis stage that owns what the feedback is about: 'understand' (components, data flows, trust boundaries, assets, diagrams, deployment and exposure facts), 'plan' (security requirements) or 'secure' (findings, severity, attack chains, controls, fixes, accepted risks). Always pass it: if omitted, the item goes to whatever stage the scan is on, which may not be the stage that owns it."
  2. Changed1 schema field changed
    • addedOutput schema / properties / retry_after_seconds
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "With reason rate_limited, how many seconds Trent asks the caller to wait.",
      +  "title": "Retry After Seconds"
      +}
  3. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already flag readOnlyHint=false, idempotentHint=false, destructiveHint=false; the description adds the reason for the non-idempotency (re-recording creates a duplicate) and a refusal condition (no project_id/project_name = call refused). It also discloses the attached_to_scan flag outcome, telling the agent to warn the user when feedback is stored with no scan to read it. Remaining gap: it does not say what happens to already-recorded items when a later item is re-split.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The content is valuable but the ordering is loose: the Trent/code-sites-documents rationale sits between the core instruction and the routing rule, and the split policy is a dense run-on paragraph. The critical constraint (project_id or project_name required) is buried at the very end. It is front-loaded on purpose but could be tightened considerably.

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 non-idempotent write with an output schema and four fully documented params, the description covers purpose, dedupe risk, refusal condition, splitting rules, and user-facing confirmation. It says to "tell the user how you split their message, listing only the items that recorded," which closes the loop on multi-call behavior. Minor gap: it never states the scope of a single call (whether content is one item or may hold several).

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 content, stage_id, and the project identifier pair are already documented, and the baseline is 3. The description adds genuine call-granularity meaning — one item per claim, each with its own stage_id, repeat a shared reason so each item stands alone, project identifier is mandatory or the call is refused — but most of that is splitting policy rather than per-parameter semantics.

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?

States a specific verb and object ("Record the user's feedback on a scan") and immediately names the sibling it is not — edit_analysis for "a mechanical correction to one field of one finding." An agent can route between the two without opening either schema.

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?

Gives explicit when-to-use (reasoning-grade facts: intent, deployment, accepted risks), when-not-to-use (edit_analysis for mechanical corrections), and hard exclusions: do not reconstruct from earlier turns, infer, embellish, resubmit on your own initiative, or record twice even if a listing looks incomplete. A correction in passing is explicitly counted as a request to record.

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.