specs-explore
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinesespecs-explore Skill
specs-explore Skill
Investigate the codebase, think through problems, compare approaches, and return a structured analysis. Only create when is provided.
exploration.md--spec调研代码库,梳理问题,对比不同方案,并返回结构化分析结果。仅当提供参数时才创建文件。
--specexploration.mdWhat You Receive
你将收到的内容
The orchestrator will give you:
- A topic or feature to explore
- path (optional)
--spec - framework (optional)
--lang
编排器会提供给你:
- 待探索的主题或功能
- 路径(可选)
--spec - 框架(可选)
--lang
Execution Steps
执行步骤
Step 1: Understand the Request
步骤1:理解需求
Parse what the user wants to explore:
- Is this a new feature? A bug fix? A refactor?
- What domain does it touch?
解析用户的探索需求:
- 这是新功能开发?Bug修复?还是代码重构?
- 涉及哪些业务领域?
Step 2: Investigate the Codebase
步骤2:调研代码库
Read relevant code to understand:
- Current architecture and patterns
- Files and modules that would be affected
- Existing behavior that relates to the request
- Potential constraints or risks
INVESTIGATE:
├── Read entry points and key files
├── Search for related functionality (Grep)
├── Check existing tests (Glob)
├── Look for patterns already in use
└── Identify dependencies and coupling阅读相关代码以理解:
- 当前的架构和模式
- 会受到影响的文件和模块
- 与需求相关的现有功能逻辑
- 潜在的限制或风险
INVESTIGATE:
├── Read entry points and key files
├── Search for related functionality (Grep)
├── Check existing tests (Glob)
├── Look for patterns already in use
└── Identify dependencies and couplingStep 3: Analyze Options
步骤3:分析可选方案
If there are multiple approaches, compare them:
| Approach | Pros | Cons | Complexity |
|---|---|---|---|
| Option A | ... | ... | Low/Med/High |
| Option B | ... | ... | Low/Med/High |
如果有多种实现方案,对它们进行对比:
| 方案 | 优势 | 劣势 | 复杂度 |
|---|---|---|---|
| 方案A | ... | ... | 低/中/高 |
| 方案B | ... | ... | 低/中/高 |
Step 4: Persist Artifact (if --spec
is provided)
--spec步骤4:保存成果(若提供--spec
参数)
--specIf is specified, write to :
--spec=docs/specs/001-add-jwt-authdocs/specs/001-add-jwt-auth/exploration.mdmarkdown
undefined如果指定了,则将内容写入:
--spec=docs/specs/001-add-jwt-authdocs/specs/001-add-jwt-auth/exploration.mdmarkdown
undefinedExploration: {topic}
Exploration: {topic}
Current State
Current State
{How the system works today relevant to this topic}
{How the system works today relevant to this topic}
Affected Areas
Affected Areas
- — {why it's affected}
path/to/file.ext - — {why it's affected}
path/to/other.ext
- — {why it's affected}
path/to/file.ext - — {why it's affected}
path/to/other.ext
Approaches
Approaches
-
{Approach name} — {brief description}
- Pros: {list}
- Cons: {list}
- Effort: {Low/Medium/High}
-
{Approach name} — {brief description}
- Pros: {list}
- Cons: {list}
- Effort: {Low/Medium/High}
-
{Approach name} — {brief description}
- Pros: {list}
- Cons: {list}
- Effort: {Low/Medium/High}
-
{Approach name} — {brief description}
- Pros: {list}
- Cons: {list}
- Effort: {Low/Medium/High}
Recommendation
Recommendation
{Your recommended approach and why}
{Your recommended approach and why}
Risks
Risks
- {Risk 1}
- {Risk 2}
- {Risk 1}
- {Risk 2}
Ready for Proposal
Ready for Proposal
{Yes/No — and what the user should know}
undefined{Yes/No — and what the user should know}
undefinedStep 5: Return Result
步骤5:返回结果
Return the same structured analysis (inline), plus:
Status Report:
- status: |
done|blockedpartial - executive_summary: 1-sentence description of what was explored and key recommendation
- artifact: (if
{spec}/exploration.mdprovided) or "none"--spec - next_recommended: (if spec provided) or
specs.brainstorm(if standalone)none - risks: risks discovered, or "None"
返回相同的结构化分析内容(内嵌形式),并附加:
状态报告:
- status: |
done|blockedpartial - executive_summary:一句话描述探索内容及核心建议
- artifact: (若提供spec参数)或"none"
{spec}/exploration.md - next_recommended: (若提供spec参数)或
specs.brainstorm(若为独立探索)none - risks: 发现的风险,或"无"
Rules
规则
- The ONLY file you MAY create is inside the spec folder (if
exploration.mdprovided)--spec - DO NOT modify any existing code or files
- ALWAYS read real code, never guess about the codebase
- Keep your analysis CONCISE — summary, not a novel
- If you can't find enough information, say so clearly
- If the request is too vague, ask for clarification
- 仅允许在spec文件夹内创建文件(若提供
exploration.md参数)--spec - 不得修改任何现有代码或文件
- 务必阅读真实代码,切勿猜测代码库内容
- 分析内容需简洁——仅做总结,勿长篇大论
- 若无法获取足够信息,请明确说明
- 若需求过于模糊,请请求用户澄清