返回 Skill 列表
extension
分类: 开发与工程无需 API Key

dev:interrogate

审问代码变更以揭示决策、替代方案和置信水平。当用户要求“审问”、“哪些决策”、“最难的部分”、“替代方案”,或希望理解代码变更背后的理由时使用。

person作者: jakexiaohubgithub

Interrogate Code Changes

Ask "why" instead of just reading code. Surfaces assumptions, decisions, and confidence levels.

Workflow

@context/workflows/interrogate.md

Input: $ARGUMENTS

Parse arguments to determine:

  • Target: unstaged (default), staged, changes (staged+unstaged), commit <hash>, pr <number>, or range <ref1>..<ref2>
  • Mode: --quick (minimal output) or --skeptical (extra validation)

Gather Context

Based on target, gather the code diff:

Target: unstaged (default)

git diff

Target: staged

git diff --cached

Target: changes

git diff HEAD

Target: commit <hash>

git show <hash>

Target: pr <number>

gh pr diff <number>

Target: range <ref1>..<ref2>

git diff <ref1>..<ref2>

Execute Interrogation

Apply the three core questions from the workflow to the gathered diff:

  1. What was the hardest decision?
  2. What alternatives did you reject?
  3. What are you least confident about?

Mode Behavior

  • Default: Full explanations with confidence levels and structured tables
  • --quick: Compact table with brief answers only
  • --skeptical: Full output plus follow-up probes:
    • "Walk me through the logic step by step"
    • "What edge cases could break this?"
    • "If this code has a bug, where is it most likely?"

Output

Format output per @context/workflows/interrogate.md#Output-Format based on selected mode.