Skip to main content
Glama

codebase_prune

Identify and remove stale project identities from the code index. Run a report-only inventory first; apply deletion only with confirmation token and acknowledgment that no remote writers exist.

Instructions

Inventory stored project identities and their resources. Report-only by default. Applying requires an exact identity, the confirmation token from a fresh inventory, and an acknowledgement that no other host is writing to it; path absence on this host is advisory, not proof of abandonment.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
applyNoDelete the selected identity only when true. Omit for the report-only inventory.
identityNoExact identity returned by codebase_prune.
confirmationTokenNoOpaque token returned for that identity by codebase_prune.
acknowledgeNoRemoteWritersNoRequired with apply. Locks on this host cannot see another host sharing the same Qdrant; true states that none is writing to this identity.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.14.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations provided, the description carries the full behavioral disclosure burden. It states that the tool is report-only by default, that applying is destructive, and that path absence on this host is advisory—not proof of abandonment. This covers the key safety and operational nuances, though it does not describe the output format or any permissions.

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 two sentences with no fluff. The first sentence front-loads the primary purpose, and the second packs the essential conditions for the destructive path. Every clause earns its place, making it highly efficient.

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 no output schema and no annotations, the description covers the main operational aspects: the dual mode (report-only vs apply), prerequisites for apply, and a critical caveat about path absence. It does not mention the return format, but that is a minor gap given the tool's complexity and the other details provided.

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 description coverage is 100%, so each parameter is documented. The description adds extra meaning beyond the schema by specifying that the confirmation token must come from a fresh inventory and that path absence is advisory, which clarifies the identity and confirmationToken semantics. This exceeds the baseline 3.

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 inventories stored project identities and their resources, with a report-only default. This distinguishes it from sibling removal tools like codebase_remove or codebase_context_remove, which likely target different resources. The verb 'inventory' and the resource 'stored project identities' are specific and unambiguous.

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 provides explicit guidance on when to apply (destructive mode) versus the default report-only, and lists the required conditions: exact identity, fresh confirmation token, and acknowledgment of no remote writers. It does not name alternative tools, but the context makes the usage scenario clear enough for an agent to decide.

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