Skip to main content
Glama
Mipiti
by Mipiti

Reconcile Model

reconcile_model

Reconcile a threat model with the code it describes: submit changed paths and observations to map them to components, report what changed, and let the platform decide and apply consequences.

Instructions

Reconcile a threat model with the code it describes. Call this after reading the code and before (or instead of) editing the model by hand: report what changed and what you observed, and the platform decides the consequence of each observation. Mutating only where the platform applies an observation (see below).

Two inputs, both optional:

  • changed_paths: the file paths that changed since the model's recorded commit. For a code-derived model compute them with git diff --name-only <commit_sha>..HEAD (the commit_sha from the model's provenance). The platform maps them onto components and reports which components changed, which paths no component claims, and whether a refresh is recommended.

  • observations: what you saw in the code that the model does not say. Each observation lands in one of four buckets by kind:

    • mechanism_named - the control's mechanism exists under another name (subject_id = control id). Follow up with refine_control using the codebase_findings returned in refine_suggested.

    • component_present - the code has a component the model lacks; include a proposal ({name, repo_url?, path?, trust_boundary_ids?}).

    • component_absent - a modelled component has no code (subject_id = component id).

    • forbidden_behavior - the code does something the model rules out (subject_id = control id, or empty).

The platform decides the consequence. Proposals are never applied on the agent's word, with one exception: a component change on a code-derived model (provenance kind="code") is applied immediately and queued for a person's review as applied_pending_review. Every other proposal waits for decide_proposal. Forbidden behaviors become findings. Observations the platform could not use come back in ignored with the reason.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
model_idYesID of the threat model.
repo_urlNoRepository the paths belong to (optional; helps map paths in multi-repo models).
observationsNoJSON string of an **array** of observation objects, each ``{kind, subject_id?, evidence?: {paths?: [], symbols?: [], note?: ""}, proposal?: {name, repo_url?, path?, trust_boundary_ids?}}`` with ``kind`` one of ``mechanism_named``, ``component_present``, ``component_absent``, ``forbidden_behavior``. Empty/None sends no observations.
changed_pathsNoComma- or newline-separated file paths that changed since the model's recorded commit. Empty/None skips path mapping (``changed_paths`` in the response is then null).
server_versionYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.75.0

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations provided, the description fully carries the behavioral transparency burden. It discloses mutation semantics ('Mutating only where the platform applies an observation'), the immediate-apply exception with 'applied_pending_review', the fallback to decide_proposal, forbidden behaviors becoming findings, and ignored observations with reasons. This is exemplary disclosure of side effects.

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 long but densely structured with a clear lead sentence, labeled optional inputs, and bullet-like kind explanations. Every section earns its place, and the most important guidance appears first. The formatting makes a complex set of behaviors scannable.

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 complex reconciliation tool with no annotations, the description is remarkably thorough: inputs, observation buckets, consequences, exceptions, and ignored outcomes are all covered. The only notable omission is that server_version, a required parameter, is not explained anywhere; otherwise, an agent has enough context to invoke the tool and interpret its role in the workflow.

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?

The description adds substantial meaning beyond the schema, especially for changed_paths (including the git diff command and provenance commit_sha) and observations (explaining each kind's meaning, required fields, and consequences). However, server_version is a required parameter with no schema description and is not mentioned in the description, leaving a small gap despite the 80% schema coverage.

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 a specific verb and resource: 'Reconcile a threat model with the code it describes.' It clearly distinguishes this tool from hand-editing and from related sibling tools like refine_control and decide_proposal by explaining that the platform decides consequences rather than the agent directly editing.

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?

Explicit usage guidance is front-loaded: 'Call this after reading the code and before (or instead of) editing the model by hand.' It also names follow-up actions ('Follow up with refine_control...'), states when proposals wait for decide_proposal, and explains the exception for code-derived models. This gives an agent clear decision rules.

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

Deploy Server

Other Tools