Skip to main content
Glama
qddfxp

conversation-branch

by qddfxp

cb_discard

Destructive

Discard experimental conversation branches by naming them or keeping a single winner; archives by default, or permanently deletes with the purge flag to clean up parallel work.

Instructions

舍弃实验分支:names 指定要舍弃的分支,keep 指定保留的赢家(其余全舍弃);names 与 keep 互斥,必须给其一。默认归档到 archive/,加 purge 则真删目录(不可恢复)。舍弃 HEAD 所在分支时 HEAD 自动回 main

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keepNo要保留的分支名,其余分支全部舍弃(与 names 互斥)
rootYesConversation Branch 工作区根目录
namesNo要舍弃的分支名列表
purgeNo真删除分支目录而不是归档(不可恢复,需用户明确同意)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior5/5

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

Annotations already mark destructiveHint=true, but the description adds valuable nuance: default behavior archives to archive/, purge causes true irreversible deletion, and HEAD automatically moves to main when its branch is discarded. This is exactly the kind of behavioral context that goes beyond structured 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?

Three concise sentences cover purpose, the two modes, mutual exclusivity, default vs purge behavior, and HEAD handling. Every clause contributes necessary information with no filler or repetition.

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 4-parameter schema, annotations, and absence of an output schema, the description is complete for invocation: it states required input constraints, destructive behavior, default archival, and edge-case HEAD handling. No critical gap remains for correct use.

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. The description adds useful semantics beyond the schema: names and keep are mutually exclusive and one must be provided, and it clarifies the default archive destination (archive/), which is not in the schema. This meaningfully raises the score.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a clear verb+resource ('舍弃实验分支') and explains the two mutually exclusive modes (names/keep). It does not explicitly name a sibling alternative, but the behavior described (discard vs rename/checkout/promote) is distinct enough to separate it from the sibling list.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives clear prerequisites: names and keep are mutually exclusive and exactly one is required, and purge changes the operation from archive to irreversible deletion. However, it does not explicitly say when to prefer cb_discard over related tools like cb_rollback or cb_promote, so usage guidance vs alternatives is only implied.

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