Skip to main content
Glama

需求澄清

clarify

Converts vague requirements into a structured spec.json by asking focused questions, validating answers, and returning the next question or blocked next action for review.

Instructions

需求澄清:把一句模糊的需求逐步收窄成结构化 Spec,写入 spec.json 供 review 当判定基准。**每次调用都会返回当前该回答的问题(currentQuestion)——丢了上下文就空调用一次,它会告诉你现在该答什么。**典型流程:带 requirement 开始 → 带着 answer 与 questionId 逐问作答 → 全部答完后自动跑质量门禁,通过则产出 spec.json;不通过返回 status:"blocked" 与 nextAction,照着重答即可。想最快拿到 Spec:{requirement, skipOptional:true} 跳过可选项,两次调用即可完成。门禁未通过但确实要产出时用 force——它只放宽「验收标准条数」这类质量规则,不放宽「描述为空 / 一条标准都没有」这类结构规则(那是空基准,比没有基准更糟)。注意:.vibeguard/spec.json 不存在时 review 会降级为「无基准」分析(全部 implicit、不告警)。

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "clarify"
  }
}

Input Schema

NameRequiredDescriptionDefault
forceNo门禁 blocked 时强制产出,只放宽质量规则
answerNo对 currentQuestion 的回答,可以多行
restartNo丢弃当前会话重新开始(旧会话留在 .bak)
questionsNo覆盖内置的 6 问模板(仅新会话生效)。宿主 AI 可据此提出针对当前需求的问题,例如「搜索范围是仅标题还是含描述与讲师?」
questionIdNo这个答案针对哪一问(= 上次返回的 currentQuestion.id)。会话已有回答时必须回传
requirementNo初始需求描述。**直接作为「功能描述」的答案**,正常路径下不会再被问一次
skipOptionalNo一次性跳过全部未答的可选问题(不跳必答项,不清空待重答队列)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations, the description carries the full behavioral burden and does so well: it discloses file writes to spec.json, automatic quality gates, blocked status with nextAction, and the limits of force. It also explains that force relaxes only quality rules, not structural rules such as empty descriptions or missing acceptance criteria.

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

Conciseness4/5

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

The description is front-loaded with purpose and the currentQuestion recovery rule, then proceeds through the workflow and edge cases. It is information-dense rather than wasteful, though the final note about review degrading without spec.json is slightly ancillary and the paragraph could be split for readability.

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?

For a stateful, multi-turn tool with no annotations and no output schema, the description is unusually complete: it covers the normal path, recovery path, fast path, gate failure, forced output, and the downstream review consequence of missing spec.json. Nothing an agent needs in order to invoke it correctly appears to be missing.

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, but the description adds useful cross-parameter semantics: requirement also serves as the initial function-description answer, answer must pair with questionId after a session has answers, and skipOptional skips only unanswered optional questions. It adds less detail for restart and questions than the schema already provides, so it is not a full 5.

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 verb and resource: narrowing a vague requirement into a structured Spec and writing it to spec.json as the review baseline. It clearly distinguishes the tool from the downstream review sibling by explaining that spec.json is what review uses as its basis.

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?

It gives an explicit typical workflow, including how to recover from lost context with an empty call, how to answer currentQuestion using answer and questionId, and how to fast-path with skipOptional. It also names the force alternative and specifies exactly when to use it: when a gate is blocked but output is still required.

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