123 Necmttn

ax-extract-workflow Skill

还原某个历史产物背后的工作流程——“X 是怎么成功的”/“从 <日期|sha> 提取工作流”/“我们当时是怎么发布 Y 的”。使用 ax 找到相关会话,并按顺序讲述产生该结果的技能流程。当用户说“what made X work”、“how did we build Y”、“extract workflow from <date>”、“extract workflow from <sha>”、“<topic> 当时的工作流是什么”、“show me how I shipped <feature>”、“reconstruct the recipe for <artifact>”时触发。不要在泛泛的“显示最近活动”时触发——这个技能专门用于还原特定产物背后的工作流程。

安装方式:把技能目录放入 ~/.claude/skills/(Claude Code)或在 claude.ai 设置中启用;也可复制右侧安装命令一键添加。

查看源码

技能指令原文(SKILL.md)

ax:extract-workflow - reconstruct the recipe behind a shipped artifact

Given a deliverable (a demo, a PR, a feature) the user wants to know:
what skills, in what order, produced it? This skill resolves an anchor
(date or sha), windows the relevant sessions, and narrates the ordered
skill arcs in plain text. Eats its own dogfood: it is itself a framing
skill.

Assumes ax (axctl) is on PATH. If ax sessions here fails, tell the user
to check docs/development.md#setup (DuckDB dylib setup - no daemon
required) and stop.

When to fire

ONLY on explicit reconstruction triggers:

  • "what made work" / "how did we ship "
  • "extract workflow from " / "extract workflow from "
  • "what was the workflow around "
  • "reconstruct the recipe for "
  • "show me how I built "

Do NOT fire on generic "what did I do today" or "show recent activity".
That is ax sessions here territory, not this skill.

Step 1 - resolve the anchor

Decide one of three modes based on what the user gave you:

| User said | Mode | Action |
|---|---|---|
| commit sha (full or short) | sha | use it directly |
| date or date range (YYYY-MM-DD) | date | use ax sessions around |
| topic / feature / artifact name | topic | ax recall "" --sources=commit --json to find candidate shas |
| "this repo, recently" | pwd | ax sessions here --days=14 |

For topic mode pick the most relevant sha and proceed in sha mode. If
results are ambiguous, ask the user to pick one before continuing.

Step 2 - window the sessions

Pick the right command for the resolved anchor:

  • sha mode: ax sessions near --json
  • date mode: ax sessions around --days=3 --json
  • pwd mode: ax sessions here --days=14 --json

Pick the N most relevant sessions from the JSON (default N=5). Bias to
sessions with the highest turn counts and that touch files related to
the artifact.

Step 3 - inspect each session

For each picked session:

ax sessions show --json
ax sessions show --by-role # optional, see Step 4

Read the top_skills and agent_delegations arrays. If a subagent's
work looks central to the artifact, drill in:

ax sessions show --expand=

Step 4 - narrate

Produce two artifacts inline (no files written - keep the answer in chat).

4a. Ordered skill arc

Lead with the framing skill that opened the work (use --by-role output
if available - the framing group goes first). Then execution skills,
then verification. For each skill, name it and write one line on what
it produced.

Example:

  1. brainstorming -> defined the workflow extraction problem
  2. writing-plans -> turned 13 grilled questions into a plan
  3. subagent-driven -> executed the plan as 17 typed-CLI tasks
  4. code-review -> two-stage spec + quality review per task
  5. test-driven-dev -> 100% green throughout

4b. Key decisions

Pull 2-4 turn excerpts where the user steered the work. Use:

ax recall "" --skill= --limit=5 --json

Quote one line per decision; cite the session id.

4c. Reproducer brief (optional, if user asks)

A one-paragraph "to do this again, you would" summary - the skills, the
order, and the key user inputs at the steering points.

When to recommend ax skills classify

If ax sessions show --by-role returns many skills in the
(unclassified) group, the role-weighted output above will be noisy.
Suggest the user run ax skills classify once - it generates briefs
the user can fill in to seed roles. Don't block on it; the
artifact-reconstruction story still works without roles.

Output contract

Write everything inline. Do not create files under .ax/tasks/ or
anywhere else. Do not modify the repo. This is a read-only,
reconstruction-focused skill.

If the user asks for a permanent recipe, recommend they paste your
output into docs/recipes/.md themselves - ax intentionally has
no recipe save format yet (per the workflow-extraction-frictions plan).