harnessed 3.4.3 → 3.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -0
- package/dist/cli.mjs +1119 -745
- package/dist/cli.mjs.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/workflows/auto/SKILL.md +10 -4
- package/workflows/capabilities.yaml +18 -19
- package/workflows/disciplines/karpathy.yaml +1 -1
- package/workflows/disciplines/language.yaml +1 -1
- package/workflows/disciplines/operational.yaml +2 -2
- package/workflows/disciplines/output-style.yaml +1 -1
- package/workflows/disciplines/priority.yaml +1 -1
- package/workflows/disciplines/protocols.yaml +1 -1
- package/workflows/discuss/auto/SKILL.md +10 -6
- package/workflows/discuss/auto/workflow.yaml +1 -2
- package/workflows/discuss/phase/SKILL.md +11 -30
- package/workflows/discuss/phase/workflow.yaml +1 -1
- package/workflows/discuss/strategic/SKILL.md +12 -33
- package/workflows/discuss/strategic/workflow.yaml +2 -3
- package/workflows/discuss/subtask/SKILL.md +11 -30
- package/workflows/discuss/subtask/workflow.yaml +1 -1
- package/workflows/execute-task/SKILL.md +7 -6
- package/workflows/execute-task/workflow.yaml +93 -0
- package/workflows/judgments/fallback.yaml +1 -1
- package/workflows/judgments/parallelism-gate.yaml +4 -3
- package/workflows/judgments/phase-gate.yaml +2 -2
- package/workflows/judgments/strategic-gate.yaml +2 -2
- package/workflows/judgments/subtask-gate.yaml +2 -2
- package/workflows/judgments/tdd-gate.yaml +2 -2
- package/workflows/judgments/web-design-routing.yaml +1 -1
- package/workflows/judgments/web-search-routing.yaml +1 -1
- package/workflows/judgments/web-testing-routing.yaml +1 -1
- package/workflows/plan/architecture/SKILL.md +13 -34
- package/workflows/plan/architecture/workflow.yaml +2 -2
- package/workflows/plan/auto/SKILL.md +10 -6
- package/workflows/plan/auto/workflow.yaml +1 -2
- package/workflows/plan/phase/SKILL.md +14 -35
- package/workflows/plan/phase/workflow.yaml +3 -3
- package/workflows/plan-feature/SKILL.md +4 -4
- package/workflows/research/SKILL.md +19 -6
- package/workflows/research/workflow.yaml +4 -4
- package/workflows/retro/SKILL.md +13 -32
- package/workflows/retro/workflow.yaml +1 -2
- package/workflows/role-prompts.yaml +4 -3
- package/workflows/task/auto/SKILL.md +11 -7
- package/workflows/task/auto/workflow.yaml +2 -3
- package/workflows/task/clarify/SKILL.md +11 -30
- package/workflows/task/code/SKILL.md +14 -35
- package/workflows/task/code/workflow.yaml +0 -1
- package/workflows/task/deliver/SKILL.md +15 -38
- package/workflows/task/deliver/workflow.yaml +7 -6
- package/workflows/task/test/SKILL.md +11 -32
- package/workflows/task/test/workflow.yaml +1 -2
- package/workflows/verify/auto/SKILL.md +14 -10
- package/workflows/verify/auto/workflow.yaml +4 -5
- package/workflows/verify/code-review/SKILL.md +14 -38
- package/workflows/verify/code-review/workflow.yaml +1 -3
- package/workflows/verify/design/SKILL.md +14 -38
- package/workflows/verify/design/workflow.yaml +4 -5
- package/workflows/verify/multispec/SKILL.md +17 -39
- package/workflows/verify/multispec/workflow.yaml +5 -8
- package/workflows/verify/paranoid/SKILL.md +13 -38
- package/workflows/verify/paranoid/workflow.yaml +1 -2
- package/workflows/verify/progress/SKILL.md +13 -32
- package/workflows/verify/progress/workflow.yaml +0 -1
- package/workflows/verify/qa/SKILL.md +15 -36
- package/workflows/verify/qa/workflow.yaml +1 -2
- package/workflows/verify/security/SKILL.md +12 -35
- package/workflows/verify/security/workflow.yaml +1 -2
- package/workflows/verify/simplify/SKILL.md +13 -34
- package/workflows/verify/simplify/workflow.yaml +1 -2
- package/workflows/verify-work/SKILL.md +5 -7
- package/workflows/verify-work/workflow.yaml +5 -7
- package/workflows/execute-task/phases.yaml +0 -73
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# workflows/execute-task/workflow.yaml — v3.4.4 Phase 4 Commit 1 NEW (Path A)
|
|
2
|
+
# Former v2 `phases.yaml` (74L) deleted v3.4.4 Phase 6 Wave 3c — this v3
|
|
3
|
+
# workflow.yaml is now the single SoT. Authored fresh per HANDOFF-v3.4.4 L745
|
|
4
|
+
# Path A decision + PHASE-4-SPEC L101-180 verbatim.
|
|
5
|
+
#
|
|
6
|
+
# 4-phase chain mirrors v2 verbatim:
|
|
7
|
+
# 01-clarify superpowers-brainstorming opus gate: subtask-gate.brainstorming.fires
|
|
8
|
+
# 02-code karpathy 心法 + on[] sonnet conditional: tdd / grill-with-docs / zoom-out
|
|
9
|
+
# 03-test superpowers TDD sonnet on: test_fail → diagnose
|
|
10
|
+
# 04-deliver ralph-loop haiku args.completion_promise=COMPLETE + fallback
|
|
11
|
+
#
|
|
12
|
+
# v2 → v3 字段 delta (PHASE-4-SPEC L13 + L116-178):
|
|
13
|
+
# BUMP `schema_version: harnessed.workflow.v3` (sister Phase 3.3 W0.5 WorkflowSchemaV3)
|
|
14
|
+
# ADD `disciplines_applied: [6 basename]` (D-09 L0 Discipline Substrate, Pattern A A.1 strict Literal Union)
|
|
15
|
+
# ADD `tools_available: [7 capabilities.yaml entry name]` (D-05 Contract C1 cross-validate)
|
|
16
|
+
# KEEP phases verbatim from former v2 phases.yaml (Path A1 — coexisted through Phase 5; v2 deleted Phase 6 Wave 3c)
|
|
17
|
+
#
|
|
18
|
+
# Per-phase model tier (intel CD-2 § 第 4 条) preserved verbatim from v2:
|
|
19
|
+
# opus / sonnet / sonnet / haiku
|
|
20
|
+
# Override via CLI: `--model-tier inherit` (B-10 escape hatch).
|
|
21
|
+
#
|
|
22
|
+
# Sister refs:
|
|
23
|
+
# - .planning/v3.4.4/PHASE-4-SPEC.md L101-180 (NEW yaml shape verbatim)
|
|
24
|
+
# - workflows/execute-task/phases.yaml (former v2 SoT — DELETED v3.4.4 Phase 6 Wave 3c; this workflow.yaml is sole SoT)
|
|
25
|
+
# - workflows/research/workflow.yaml (v3 standalone shape reference)
|
|
26
|
+
# - workflows/verify/simplify/workflow.yaml (v3 sub-workflow shape reference)
|
|
27
|
+
# - workflows/capabilities.yaml (7 capability refs: superpowers-brainstorming/tdd/grill-with-docs/zoom-out/diagnose/ralph-loop/planning-with-files)
|
|
28
|
+
# - workflows/defaults.yaml ralph_max_iterations.execute-task.{01..04}
|
|
29
|
+
# - workflows/disciplines/{karpathy,output-style,language,operational,priority,protocols}.yaml (L0 substrate)
|
|
30
|
+
# - src/workflow/schema/workflow.ts WorkflowSchemaV3 (Phase 3.3 W0.5 SHIPPED 122L)
|
|
31
|
+
|
|
32
|
+
schema_version: harnessed.workflow.v3
|
|
33
|
+
workflow: execute-task
|
|
34
|
+
description: |
|
|
35
|
+
子任务执行 workflow — 4-phase chain (brainstorming → karpathy + mattpocock route by
|
|
36
|
+
condition → TDD + diagnose → ralph-loop COMPLETE) triggered by harnessed CLI
|
|
37
|
+
`harnessed execute-task --task <text>` OR universal `harnessed run execute-task`.
|
|
38
|
+
|
|
39
|
+
disciplines_applied: [karpathy, output-style, language, operational, priority, protocols]
|
|
40
|
+
tools_available: [superpowers-brainstorming, tdd, grill-with-docs, zoom-out, diagnose, ralph-loop, planning-with-files]
|
|
41
|
+
|
|
42
|
+
phases:
|
|
43
|
+
- id: 01-clarify
|
|
44
|
+
name: brainstorming
|
|
45
|
+
upstream: superpowers brainstorming
|
|
46
|
+
capability: '{{ capabilities.superpowers-brainstorming.cmd }}'
|
|
47
|
+
model: opus
|
|
48
|
+
max_iterations: '{{ defaults.ralph_max_iterations.execute-task.01-clarify }}'
|
|
49
|
+
gate: judgments.subtask-gate.brainstorming.fires
|
|
50
|
+
|
|
51
|
+
- id: 02-code
|
|
52
|
+
name: code (karpathy 心法 always-on + mattpocock conditional route)
|
|
53
|
+
upstream: karpathy
|
|
54
|
+
model: sonnet
|
|
55
|
+
max_iterations: '{{ defaults.ralph_max_iterations.execute-task.02-code }}'
|
|
56
|
+
on:
|
|
57
|
+
- if: 'judgments.tdd-gate.tdd-strongly-suggested.fires'
|
|
58
|
+
invoke: '{{ capabilities.tdd.cmd }}'
|
|
59
|
+
- if: 'phase.spec_ambiguous == true'
|
|
60
|
+
invoke: '{{ capabilities.grill-with-docs.cmd }}'
|
|
61
|
+
- if: 'phase.unfamiliar_module == true'
|
|
62
|
+
invoke: '{{ capabilities.zoom-out.cmd }}'
|
|
63
|
+
|
|
64
|
+
- id: 03-test
|
|
65
|
+
name: test (conditional TDD + diagnose on fail)
|
|
66
|
+
upstream: superpowers TDD
|
|
67
|
+
capability: '{{ capabilities.tdd.cmd }}'
|
|
68
|
+
model: sonnet
|
|
69
|
+
max_iterations: '{{ defaults.ralph_max_iterations.execute-task.03-test }}'
|
|
70
|
+
on:
|
|
71
|
+
- if: 'test_fail == true'
|
|
72
|
+
invoke: '{{ capabilities.diagnose.cmd }}'
|
|
73
|
+
|
|
74
|
+
- id: 04-deliver
|
|
75
|
+
name: deliver (ralph-loop COMPLETE gate + max-iter fallback)
|
|
76
|
+
upstream: ralph-loop
|
|
77
|
+
capability: '{{ capabilities.ralph-loop.cmd }}'
|
|
78
|
+
model: haiku
|
|
79
|
+
args:
|
|
80
|
+
completion_promise: COMPLETE
|
|
81
|
+
max_iterations: '{{ defaults.ralph_max_iterations.execute-task.04-deliver }}'
|
|
82
|
+
gate: judgments.parallelism-gate.fires
|
|
83
|
+
parallelism: judgments.parallelism-gate.ralph-loop-wrapper.fires
|
|
84
|
+
on:
|
|
85
|
+
- if: 'subtask.lines >= 20 and subtask.type != "single_command_query"'
|
|
86
|
+
invoke: '{{ capabilities.ralph-loop.cmd }}'
|
|
87
|
+
- if: 'subtask.lines < 20 or subtask.type == "single_command_query"'
|
|
88
|
+
action: skip
|
|
89
|
+
fallback:
|
|
90
|
+
max_iterations_exceeded:
|
|
91
|
+
action: emit_warning_and_halt
|
|
92
|
+
message: '⚠️ ralph-loop max-iterations ({{ args.max_iterations }}) exceeded for execute-task 04-deliver. Sub-task likely incomplete — see workflow engine catch handler for manual options.'
|
|
93
|
+
exit_code: 1
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# workflows/judgments/fallback.yaml
|
|
2
|
-
# Fallback 三条铁律 —
|
|
2
|
+
# Fallback 三条铁律 — bundled judgment (unsure → tend to skip with transparent disclosure / explicit user signal overrides / tiers independent)
|
|
3
3
|
# Sister: 不同于 triggers (fires_when/skips_when 模式), 本 file 使用 'rules' 顶级 key
|
|
4
4
|
# Phase v2.0-2.3 Wave 0 T2.3.W0.2 ship per R20.16 + D-16
|
|
5
5
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# workflows/judgments/parallelism-gate.yaml
|
|
2
|
-
# Parallelism 判据 —
|
|
3
|
-
#
|
|
2
|
+
# Parallelism 判据 — bundled subagent vs Agent Teams routing rules
|
|
3
|
+
# (4 triggers: subagent-default / main-session-fallback / agent-teams-upgrade / ralph-loop-wrapper)
|
|
4
|
+
# Bundled Agent Teams lifecycle: 5 upgrade triggers + cleanup discipline
|
|
4
5
|
# Phase v2.0-2.3 Wave 0 T2.3.W0.2 ship per D-11 (parallelism-gate) + R20.10 (ralph-loop 正交 wrapper)
|
|
5
6
|
|
|
6
7
|
schema_version: harnessed.judgment.v1
|
|
@@ -23,7 +24,7 @@ triggers:
|
|
|
23
24
|
|
|
24
25
|
agent-teams-upgrade:
|
|
25
26
|
description: |
|
|
26
|
-
Upgrade — Claude Code Agent Teams 升级
|
|
27
|
+
Upgrade — Claude Code Agent Teams 升级 (bundled rule):
|
|
27
28
|
5 任一触发即可 (teammate SendMessage 互通 / subagent context overflow /
|
|
28
29
|
共享 task list 自协调 / 对立假设辩论 / 全栈三路协同)。
|
|
29
30
|
开 team 前 token 成本估算 team_cost < 2 × subagent_cost 才划算。
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# workflows/judgments/phase-gate.yaml
|
|
2
|
-
# Phase 层 (Phase tier) 判据 —
|
|
3
|
-
#
|
|
2
|
+
# Phase 层 (Phase tier) 判据 — bundled judgment (3-tier independent clarification: strategic / phase / subtask)
|
|
3
|
+
# Pairs with: GSD /gsd-discuss-phase orchestration gate (also /gsd-new-project, /gsd-next; when capability available)
|
|
4
4
|
# Phase v2.0-2.3 Wave 0 T2.3.W0.2 ship per D-04 + D-16 multi-file 分类
|
|
5
5
|
|
|
6
6
|
schema_version: harnessed.judgment.v1
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# workflows/judgments/strategic-gate.yaml
|
|
2
|
-
# 战略层 (Strategy tier) 判据 —
|
|
3
|
-
#
|
|
2
|
+
# 战略层 (Strategy tier) 判据 — bundled judgment (3-tier independent clarification: strategic / phase / subtask)
|
|
3
|
+
# Pairs with: gstack /office-hours + /plan-ceo-review governance gate (when capability available)
|
|
4
4
|
# Phase v2.0-2.3 Wave 0 T2.3.W0.2 ship per D-04 + D-16 multi-file 分类
|
|
5
5
|
|
|
6
6
|
schema_version: harnessed.judgment.v1
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# workflows/judgments/subtask-gate.yaml
|
|
2
|
-
# 子任务层 (Subtask tier) 判据 —
|
|
3
|
-
#
|
|
2
|
+
# 子任务层 (Subtask tier) 判据 — bundled judgment (3-tier independent clarification: strategic / phase / subtask)
|
|
3
|
+
# Pairs with: superpowers:brainstorming skill (与 superpowers TDD red-green-refactor 并行评估; when capability available)
|
|
4
4
|
# Phase v2.0-2.3 Wave 0 T2.3.W0.2 ship per D-04 + D-16 multi-file 分类
|
|
5
5
|
|
|
6
6
|
schema_version: harnessed.judgment.v1
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# workflows/judgments/tdd-gate.yaml
|
|
2
|
-
# TDD 判据 —
|
|
3
|
-
#
|
|
2
|
+
# TDD 判据 — bundled judgment (Execute-stage TDD: red-green-refactor strongly recommended for core logic / algorithms / high-reliability)
|
|
3
|
+
# Pairs with: superpowers:test-driven-development skill (alias mattpocock /tdd per D-13; when capability available)
|
|
4
4
|
# Phase v2.0-2.3 Wave 0 T2.3.W0.2 ship per D-13 (6 fires + 3 skips)
|
|
5
5
|
|
|
6
6
|
schema_version: harnessed.judgment.v1
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# workflows/judgments/web-design-routing.yaml
|
|
2
|
-
#
|
|
2
|
+
# Bundled routing rule: ui-ux-pro-max 默认主方案 (数据驱动) + frontend-design 创意补充 + arbitration
|
|
3
3
|
# Phase v3.0-3.2 Wave A RESEARCH → 3.3 W0.3 ship per D-11
|
|
4
4
|
#
|
|
5
5
|
# 默认 ui-ux-pro-max 优先 (数据驱动 / 标准化 / 可解释);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# workflows/judgments/web-search-routing.yaml
|
|
2
|
-
#
|
|
2
|
+
# Bundled routing rule: 条件式 fallback + Tavily/Exa MCP routing (with WebFetch / gh CLI / ctx7 CLI fallbacks)
|
|
3
3
|
# Phase v3.0-3.2 Wave A RESEARCH → 3.3 W0.3 ship per D-11
|
|
4
4
|
#
|
|
5
5
|
# 路由优先级 (per rules/web-search.md):
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# workflows/judgments/web-testing-routing.yaml
|
|
2
|
-
#
|
|
2
|
+
# Bundled routing rule: 三层职责矩阵 (脑 @playwright/test / 手 playwright-cli / 筋骨 webapp-testing) + 决策树
|
|
3
3
|
# Phase v3.0-3.2 Wave A RESEARCH → 3.3 W0.3 ship per D-11
|
|
4
4
|
#
|
|
5
5
|
# 三层职责矩阵 verbatim:
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: plan-architecture
|
|
3
3
|
description: |
|
|
4
|
-
Stage ②.a 架构层 plan sub-workflow — gstack /plan-eng-review (
|
|
5
|
-
|
|
4
|
+
Stage ②.a 架构层 plan sub-workflow — gstack /plan-eng-review (复杂架构强制治理关卡;
|
|
5
|
+
bundled plan-stage cadence: mandatory before complex-architecture phases)。schema_version:
|
|
6
6
|
harnessed.workflow.v3 with disciplines_applied (6 default) + tools_available
|
|
7
7
|
[plan-eng-review] + 1 phase (01-plan-eng-review) + gate literal expr
|
|
8
8
|
`phase.is_complex_architecture == true`。Triggered by harnessed CLI `harnessed
|
|
@@ -52,44 +52,23 @@ trigger `is-complex-architecture` 重构 ref。
|
|
|
52
52
|
- 性能 / scaling 关键路径
|
|
53
53
|
- 引入显著技术债 / migration 风险
|
|
54
54
|
|
|
55
|
-
<!-- v3.4.3-dual-path-invocation -->
|
|
56
55
|
## How to invoke
|
|
57
56
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
> 1. Identify the smallest architecture change that satisfies all requirements
|
|
70
|
-
>
|
|
71
|
-
> 2. Diagram component boundaries (data flow / call direction / ownership)
|
|
72
|
-
>
|
|
73
|
-
> 3. List interfaces / contracts between components (function signatures, API shapes)
|
|
74
|
-
>
|
|
75
|
-
> 4. Failure modes: what happens when each component is slow / down / inconsistent?
|
|
76
|
-
>
|
|
77
|
-
> 5. Migration / rollback path — can we ship in slices, or all-at-once?
|
|
78
|
-
>
|
|
79
|
-
> 6. Choose mechanisms with the lowest blast radius and lowest unique vocabulary
|
|
80
|
-
>
|
|
81
|
-
> 7. Document tradeoffs of the rejected alternatives (so reviewers see the road not taken)
|
|
82
|
-
>
|
|
83
|
-
> **Output format**: structured report with severity-classified findings (approved / approved-with-changes / blocked). One finding per line: `[severity] file:line — problem (one sentence); fix: suggested change`. If no findings, say so explicitly. No preamble, no end-of-report summary.
|
|
84
|
-
|
|
85
|
-
(Role prompt is self-contained — works even when the upstream `plan-eng-review` user-skill / plugin isn't installed.)
|
|
86
|
-
|
|
87
|
-
(Sister `~/.claude/commands/plan-architecture.md` is also generated by `harnessed setup` so `/plan-architecture` is a real platform slash command — both files carry the same dual-path instruction. Previous v3.4.x `harnessed plan-architecture --apply` CLI claims are removed; that subcommand was never implemented.)
|
|
57
|
+
Use the Bash tool to run:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
echo "$ARGUMENTS" | harnessed run plan-architecture --task-stdin
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
If `$ARGUMENTS` is empty, run `harnessed run plan-architecture` (no stdin pipe).
|
|
64
|
+
|
|
65
|
+
After completion, the Bash output prints a `Next:` hint on stderr suggesting the next stage. Decide whether to invoke based on conversation context — the hint is informational, not prescriptive.
|
|
66
|
+
|
|
67
|
+
<!-- harnessed-generated:v3.4.4 -->
|
|
88
68
|
|
|
89
69
|
## References
|
|
90
70
|
|
|
91
71
|
- D-04 Stage ② Plan 二层 (架构 / 计划)
|
|
92
72
|
- D-12 gstack 治理关卡 (复杂架构强制)
|
|
93
|
-
- ~/.claude/CLAUDE.md "⚠️ 复杂架构前: /plan-eng-review"
|
|
94
73
|
- workflows/capabilities.yaml — plan-eng-review (Bucket 7)
|
|
95
74
|
- workflows/defaults.yaml — ralph_max_iterations.plan-architecture.* values (W2.2 backfill)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# workflows/plan/architecture/workflow.yaml — Phase v3.0-3.4 W0 T3.4.W0.4
|
|
2
2
|
#
|
|
3
|
-
# Stage ②.a 架构层 sub-workflow — gstack /plan-eng-review (
|
|
4
|
-
#
|
|
3
|
+
# Stage ②.a 架构层 sub-workflow — gstack /plan-eng-review (mandatory before
|
|
4
|
+
# complex-architecture phases per bundled plan-stage cadence).
|
|
5
5
|
#
|
|
6
6
|
# Sister refs:
|
|
7
7
|
# - workflows/capabilities.yaml — plan-eng-review (Bucket 7 gstack 33 optional registry)
|
|
@@ -21,7 +21,7 @@ trigger_phrases:
|
|
|
21
21
|
## Overview
|
|
22
22
|
|
|
23
23
|
4-stage cadence Stage ② master orchestrator delegating to 2 sequential sub-workflows
|
|
24
|
-
(
|
|
24
|
+
(bundled Plan-stage cadence + D-06 planning-with-files cross-cutting tool):
|
|
25
25
|
|
|
26
26
|
| order | sub | gate ref | mode | when fires |
|
|
27
27
|
| ----- | --- | -------- | ---- | ---------- |
|
|
@@ -52,20 +52,24 @@ Sister `workflows/capabilities.yaml`:
|
|
|
52
52
|
|
|
53
53
|
- Slash command: `/plan <text>` (bare per ADR 0030 namespace policy D-02 LOCK after `harnessed setup`)
|
|
54
54
|
|
|
55
|
-
<!-- v3.4.3-dual-path-invocation -->
|
|
56
55
|
## How to invoke
|
|
57
56
|
|
|
58
|
-
|
|
57
|
+
Use the Bash tool to run:
|
|
59
58
|
|
|
60
|
-
|
|
59
|
+
```bash
|
|
60
|
+
echo "$ARGUMENTS" | harnessed run plan --task-stdin
|
|
61
|
+
```
|
|
61
62
|
|
|
62
|
-
|
|
63
|
+
If `$ARGUMENTS` is empty, run `harnessed run plan` (no stdin pipe).
|
|
64
|
+
|
|
65
|
+
After completion, the Bash output prints a `Next:` hint on stderr suggesting the next stage. Decide whether to invoke based on conversation context — the hint is informational, not prescriptive.
|
|
66
|
+
|
|
67
|
+
<!-- harnessed-generated:v3.4.4 -->
|
|
63
68
|
|
|
64
69
|
## References
|
|
65
70
|
|
|
66
71
|
- D-01 master orchestrator delegation pattern
|
|
67
72
|
- D-02 bare slash cmd convention (ADR 0030 namespace policy LOCK)
|
|
68
73
|
- D-06 planning-with-files cross-cutting tool (NOT 独立 sub-workflow)
|
|
69
|
-
- ~/.claude/CLAUDE.md "Plan 阶段" 节 verbatim
|
|
70
74
|
- workflows/judgments/stage-routing.yaml — plan-{architecture,phase}-delegate triggers
|
|
71
75
|
- workflows/plan/{architecture,phase}/workflow.yaml — 2 sub-workflow Phase 3.4 SHIPPED
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
# workflows/plan/auto/workflow.yaml — Phase v3.0-3.5 W1 T3.5.W1.2
|
|
2
2
|
#
|
|
3
3
|
# Stage ② Plan master orchestrator — 串行 invoke 2 sub (architecture conditional → phase always)
|
|
4
|
-
# per
|
|
4
|
+
# per bundled Plan-stage cadence + RESEARCH-workflows § Area 2。
|
|
5
5
|
# planning-with-files /plan 是 D-06 cross-cutting tool (NOT 独立 sub-workflow per user clarification 2)。
|
|
6
6
|
#
|
|
7
7
|
# Sister refs:
|
|
8
|
-
# - ~/.claude/CLAUDE.md "Plan 阶段 (GSD + planning-with-files, 可选 gstack 架构审查)" 节
|
|
9
8
|
# - workflows/judgments/stage-routing.yaml — plan-{architecture,phase}-delegate triggers
|
|
10
9
|
# - workflows/plan/{architecture,phase}/workflow.yaml — 2 sub-workflow Phase 3.4 SHIPPED
|
|
11
10
|
# - workflows/capabilities.yaml — planning-with-files + plan-eng-review + gsd-plan-phase
|
|
@@ -3,7 +3,7 @@ name: plan-phase
|
|
|
3
3
|
description: |
|
|
4
4
|
Stage ②.b 计划层 plan sub-workflow — GSD /gsd-plan-phase Wave A research + Wave B planner +
|
|
5
5
|
Wave C plan-checker + planning-with-files Claude Code plugin /plan 持久化 task_plan.md +
|
|
6
|
-
progress.md (
|
|
6
|
+
progress.md (bundled Plan-stage cadence: GSD + planning-with-files)。Stage ② 铁律:
|
|
7
7
|
dual capability (GSD orchestration + planning-with-files plugin)。schema_version:
|
|
8
8
|
harnessed.workflow.v3 with disciplines_applied (6 default) + tools_available [gsd-plan-phase,
|
|
9
9
|
planning-with-files] + 2 phases (01-gsd-plan + 02-persist)。Triggered by harnessed CLI
|
|
@@ -34,8 +34,8 @@ claude-code-plugin /plan + Pattern A sub-workflow ship)。
|
|
|
34
34
|
Sister `workflows/capabilities.yaml` entries:
|
|
35
35
|
- `gsd-plan-phase` — Bucket 2 (impl: gsd, cmd: /gsd-plan-phase)
|
|
36
36
|
- `planning-with-files` — Bucket 4 (impl: claude-code-plugin, cmd: /plan;
|
|
37
|
-
|
|
38
|
-
task_plan.md + progress.md + findings.md)
|
|
37
|
+
requires the `planning-with-files` Claude Code plugin to be installed via the
|
|
38
|
+
Claude Code plugin marketplace; outputs: task_plan.md + progress.md + findings.md)
|
|
39
39
|
|
|
40
40
|
## Stage ② 铁律 — dual capability
|
|
41
41
|
|
|
@@ -54,44 +54,23 @@ reframe)。
|
|
|
54
54
|
- `progress.md` — phase 进度跟踪 + cross-session 恢复
|
|
55
55
|
- (`findings.md` 由 discuss-* sub-workflow 产出, 此处不重复)
|
|
56
56
|
|
|
57
|
-
<!-- v3.4.3-dual-path-invocation -->
|
|
58
57
|
## How to invoke
|
|
59
58
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
> 1. Each task names the exact files it touches (NOT just 'auth module')
|
|
72
|
-
>
|
|
73
|
-
> 2. Each task has acceptance criteria a third party can verify
|
|
74
|
-
>
|
|
75
|
-
> 3. Dependencies are explicit (task N requires task M output)
|
|
76
|
-
>
|
|
77
|
-
> 4. Tasks are ≤1 day each; split if larger
|
|
78
|
-
>
|
|
79
|
-
> 5. Identify the verification step (test / lint / typecheck) for each task
|
|
80
|
-
>
|
|
81
|
-
> 6. Persist as `task_plan.md` + `progress.md` via planning-with-files `/plan`
|
|
82
|
-
>
|
|
83
|
-
> 7. Final pass: a fresh agent should be able to execute from these files alone
|
|
84
|
-
>
|
|
85
|
-
> **Output format**: structured report with severity-classified findings (ready-to-execute / needs-revision / blocked). One finding per line: `[severity] file:line — problem (one sentence); fix: suggested change`. If no findings, say so explicitly. No preamble, no end-of-report summary.
|
|
86
|
-
|
|
87
|
-
(Role prompt is self-contained — works even when the upstream `gsd-plan-phase` user-skill / plugin isn't installed.)
|
|
88
|
-
|
|
89
|
-
(Sister `~/.claude/commands/plan-phase.md` is also generated by `harnessed setup` so `/plan-phase` is a real platform slash command — both files carry the same dual-path instruction. Previous v3.4.x `harnessed plan-phase --apply` CLI claims are removed; that subcommand was never implemented.)
|
|
59
|
+
Use the Bash tool to run:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
echo "$ARGUMENTS" | harnessed run plan-phase --task-stdin
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
If `$ARGUMENTS` is empty, run `harnessed run plan-phase` (no stdin pipe).
|
|
66
|
+
|
|
67
|
+
After completion, the Bash output prints a `Next:` hint on stderr suggesting the next stage. Decide whether to invoke based on conversation context — the hint is informational, not prescriptive.
|
|
68
|
+
|
|
69
|
+
<!-- harnessed-generated:v3.4.4 -->
|
|
90
70
|
|
|
91
71
|
## References
|
|
92
72
|
|
|
93
73
|
- D-04 Stage ② Plan 二层 (架构 / 计划)
|
|
94
74
|
- D-15 Q-AUDIT-5a planning-with-files claude-code-plugin reframe (NOT npm-sdk)
|
|
95
|
-
- ~/.claude/CLAUDE.md "Plan 阶段 GSD + planning-with-files"
|
|
96
75
|
- workflows/capabilities.yaml — gsd-plan-phase / planning-with-files (Bucket 4)
|
|
97
76
|
- workflows/defaults.yaml — ralph_max_iterations.plan-phase.* values (W2.2 backfill)
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# workflows/plan/phase/workflow.yaml — Phase v3.0-3.4 W0 T3.4.W0.5
|
|
2
2
|
#
|
|
3
3
|
# Stage ②.b 计划层 sub-workflow — GSD /gsd-plan-phase Wave A research + Wave B planner +
|
|
4
|
-
# Wave C plan-checker + planning-with-files /plan 持久化 task_plan.md
|
|
5
|
-
#
|
|
6
|
-
# (gsd-plan-phase + planning-with-files /plan invokes)。
|
|
4
|
+
# Wave C plan-checker + planning-with-files /plan 持久化 task_plan.md
|
|
5
|
+
# (bundled Plan-stage cadence: GSD + planning-with-files).
|
|
6
|
+
# Stage ② 铁律: dual capability (gsd-plan-phase + planning-with-files /plan invokes)。
|
|
7
7
|
#
|
|
8
8
|
# Sister refs:
|
|
9
9
|
# - workflows/capabilities.yaml — gsd-plan-phase / planning-with-files
|
|
@@ -54,9 +54,9 @@ to brainstorm or planning (D-04 PUSH 任 1 phase 转换前 read = vetoed → 全
|
|
|
54
54
|
|
|
55
55
|
### Phase 5 planning-with-files plugin 真接 (Q-AUDIT-5a LOCKED Option A)
|
|
56
56
|
|
|
57
|
-
05-persist invokes the **Claude Code plugin** slash command `/plan
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
05-persist invokes the **Claude Code plugin** slash command `/plan`. Requires
|
|
58
|
+
the `planning-with-files` Claude Code plugin to be installed via the Claude Code
|
|
59
|
+
plugin marketplace. The plugin generates 3 markdown files in
|
|
60
60
|
`.planning/<phase-id>/`:
|
|
61
61
|
|
|
62
62
|
- `task_plan.md` — 主计划 (task 列表 + 文件路径 + 依赖顺序 + 验收标准)
|
|
@@ -84,7 +84,7 @@ harnessed plan-feature --task "<text>" --apply
|
|
|
84
84
|
## Forward-looking note
|
|
85
85
|
|
|
86
86
|
The `trigger_phrases:` frontmatter is active after `harnessed setup` copies this
|
|
87
|
-
SKILL.md to
|
|
87
|
+
SKILL.md to `<claude-home>/skills/plan-feature/` — Claude Code then loads the slash
|
|
88
88
|
command `/plan-feature` automatically (Gap B fix — v1.0.2).
|
|
89
89
|
|
|
90
90
|
## References
|
|
@@ -16,7 +16,7 @@ phases content (01-fan-out + 02-synth) verbatim reused from v2 SHIPPED unchanged
|
|
|
16
16
|
|
|
17
17
|
| # | Phase | Upstream | Capability | Model | Description |
|
|
18
18
|
|---|-------|----------|-----------|-------|-------------|
|
|
19
|
-
| 01 | `01-fan-out` | web-search | (route-by-subtask) | sonnet | 3 source fan-out (Tavily MCP / Exa MCP / ctx7 CLI per
|
|
19
|
+
| 01 | `01-fan-out` | web-search | (route-by-subtask) | sonnet | 3 source fan-out (Tavily MCP / Exa MCP / ctx7 CLI per bundled web-search + context7 routing) |
|
|
20
20
|
| 02 | `02-synth` | gsd | `gsd-discuss-phase` | opus | GSD discuss-phase aggregate + dedup + reconcile |
|
|
21
21
|
|
|
22
22
|
## Capability refs
|
|
@@ -30,17 +30,16 @@ Sister `workflows/capabilities.yaml` entries:
|
|
|
30
30
|
## Invocation
|
|
31
31
|
- Slash command: `/research <topic>` (after `harnessed setup`)
|
|
32
32
|
|
|
33
|
-
## Routing rules (
|
|
33
|
+
## Routing rules (bundled web-search routing — `workflows/judgments/web-search-routing.yaml`)
|
|
34
34
|
- 描述式查询 ("找一篇对比 X 和 Y 的博客") → Exa MCP
|
|
35
35
|
- 学术 / 论文 → Exa MCP
|
|
36
|
-
- 库 / API 文档 → ctx7 CLI
|
|
36
|
+
- 库 / API 文档 → ctx7 CLI
|
|
37
37
|
- 关键词 / 时效内容 → Tavily MCP (默认)
|
|
38
38
|
- 抓整站 / 站点结构 → Tavily crawl/map
|
|
39
39
|
|
|
40
|
-
<!-- v3.4.3-dual-path-invocation -->
|
|
41
40
|
## How to invoke
|
|
42
41
|
|
|
43
|
-
**Preferred path** (master orchestrator): dispatch to the per-sub-workflow slash commands in the order this stage prescribes. Each sub command lives at
|
|
42
|
+
**Preferred path** (master orchestrator): dispatch to the per-sub-workflow slash commands in the order this stage prescribes. Each sub command lives at `<claude-home>/commands/<sub-name>.md` (installed by `harnessed setup`) with its own dual-path fallback.
|
|
44
43
|
|
|
45
44
|
**Fallback path** (when the upstream isn't installed or returns no result): use the Task tool to spawn a general-purpose subagent with this prompt:
|
|
46
45
|
|
|
@@ -65,4 +64,18 @@ Sister `workflows/capabilities.yaml` entries:
|
|
|
65
64
|
|
|
66
65
|
(Role prompt is self-contained — works even when the upstream `specialist` user-skill / plugin isn't installed.)
|
|
67
66
|
|
|
68
|
-
(
|
|
67
|
+
(`harnessed setup` also installs a `research` Claude Code slash command at `<claude-home>/commands/research.md` so `/research` is a real platform slash command — both files carry the same dual-path instruction. Previous v3.4.x `harnessed research --apply` CLI claims are removed; that subcommand was never implemented.)
|
|
68
|
+
|
|
69
|
+
## How to invoke
|
|
70
|
+
|
|
71
|
+
Use the Bash tool to run:
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
echo "$ARGUMENTS" | harnessed run research --task-stdin
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
If `$ARGUMENTS` is empty, run `harnessed run research` (no stdin pipe).
|
|
78
|
+
|
|
79
|
+
After completion, the Bash output prints a `Next:` hint on stderr suggesting the next stage. Decide whether to invoke based on conversation context — the hint is informational, not prescriptive.
|
|
80
|
+
|
|
81
|
+
<!-- harnessed-generated:v3.4.4 -->
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
# (v2 19L → v3 ~25L schema bump per RESEARCH-workflows Area 2 Standalone section)
|
|
3
3
|
#
|
|
4
4
|
# Standalone Stage ① alternate — 多源调研 Tavily MCP (默认关键词) + Exa MCP (描述式 / 学术)
|
|
5
|
-
# + ctx7 CLI (库 API 文档) fan-out + GSD discuss synth aggregate;
|
|
6
|
-
#
|
|
5
|
+
# + ctx7 CLI (库 API 文档) fan-out + GSD discuss synth aggregate; bundled web-search +
|
|
6
|
+
# context7 routing rules (workflows/judgments/web-search-routing.yaml) 机器化 per R20.7 + D-08。
|
|
7
7
|
#
|
|
8
8
|
# v2 → v3 字段 delta (W1.1 schema bump scope):
|
|
9
9
|
# BUMP `schema_version: harnessed.workflow.v3` (17th surface — sister Phase 3.3 W0.11)
|
|
@@ -26,8 +26,8 @@ schema_version: harnessed.workflow.v3
|
|
|
26
26
|
workflow: research
|
|
27
27
|
description: |
|
|
28
28
|
Standalone Stage ① alternate — 多源调研 Tavily MCP (默认关键词) + Exa MCP (描述式 /
|
|
29
|
-
学术) + ctx7 CLI (库 API 文档) fan-out + GSD discuss synth aggregate;
|
|
30
|
-
|
|
29
|
+
学术) + ctx7 CLI (库 API 文档) fan-out + GSD discuss synth aggregate; bundled
|
|
30
|
+
web-search + context7 routing rules 机器化 per R20.7 + D-08。
|
|
31
31
|
|
|
32
32
|
disciplines_applied: [karpathy, output-style, language, operational, priority, protocols]
|
|
33
33
|
tools_available: [tavily-mcp, exa-mcp, ctx7, gsd-discuss-phase]
|
package/workflows/retro/SKILL.md
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
name: retro
|
|
3
3
|
description: |
|
|
4
4
|
Standalone post-④ Verify retrospective workflow — gstack /retro 经验教训 / 决策 / lessons
|
|
5
|
-
系统总结 (项目 / 里程碑结束可选,
|
|
6
|
-
|
|
5
|
+
系统总结 (项目 / 里程碑结束可选, bundled milestone-close retrospective cadence)
|
|
6
|
+
+ planning-with-files RETROSPECTIVE.md 持久化 (sister Phase
|
|
7
7
|
v2.0-2.5 RETROSPECTIVE pattern)。Capability ref retro-gstack alias suffix per Pattern A
|
|
8
8
|
E.2 LOCK (NOT bare retro 避免 standalone workflow / capability namespace 冲突)。
|
|
9
9
|
schema_version: harnessed.workflow.v3 with disciplines_applied (6 default) + tools_available
|
|
@@ -47,44 +47,25 @@ Sister `workflows/capabilities.yaml` entries:
|
|
|
47
47
|
- ✅ **触发**: 项目结束 / 里程碑结束 / 用户明示 "复盘 / retro / lessons learned"
|
|
48
48
|
- ❌ **跳过**: 日常 PR / 单 phase 完成 (常规 verify-progress 已够用)
|
|
49
49
|
|
|
50
|
-
<!-- v3.4.3-dual-path-invocation -->
|
|
51
50
|
## How to invoke
|
|
52
51
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
> 1. What did we set out to do, vs. what actually shipped?
|
|
65
|
-
>
|
|
66
|
-
> 2. Top 3 surprises (positive or negative) — root cause each
|
|
67
|
-
>
|
|
68
|
-
> 3. Decisions that paid off; decisions we would reverse
|
|
69
|
-
>
|
|
70
|
-
> 4. Process changes for next milestone (concrete, not vague)
|
|
71
|
-
>
|
|
72
|
-
> 5. What deserves a permanent rule entry (CLAUDE.md / docs/adr/)?
|
|
73
|
-
>
|
|
74
|
-
> 6. Persist verbatim to `.planning/RETROSPECTIVE.md` — append, do not overwrite
|
|
75
|
-
>
|
|
76
|
-
> **Output format**: structured report with severity-classified findings (lesson / decision / surprise / process-change). One finding per line: `[severity] file:line — problem (one sentence); fix: suggested change`. If no findings, say so explicitly. No preamble, no end-of-report summary.
|
|
77
|
-
|
|
78
|
-
(Role prompt is self-contained — works even when the upstream `retro-gstack` user-skill / plugin isn't installed.)
|
|
79
|
-
|
|
80
|
-
(Sister `~/.claude/commands/retro.md` is also generated by `harnessed setup` so `/retro` is a real platform slash command — both files carry the same dual-path instruction. Previous v3.4.x `harnessed retro --apply` CLI claims are removed; that subcommand was never implemented.)
|
|
52
|
+
Use the Bash tool to run:
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
echo "$ARGUMENTS" | harnessed run retro --task-stdin
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
If `$ARGUMENTS` is empty, run `harnessed run retro` (no stdin pipe).
|
|
59
|
+
|
|
60
|
+
After completion, the Bash output prints a `Next:` hint on stderr suggesting the next stage. Decide whether to invoke based on conversation context — the hint is informational, not prescriptive.
|
|
61
|
+
|
|
62
|
+
<!-- harnessed-generated:v3.4.4 -->
|
|
81
63
|
|
|
82
64
|
## References
|
|
83
65
|
|
|
84
66
|
- D-04 NEW v3 standalone workflow (research v3 bump + retro NEW)
|
|
85
67
|
- Pattern A E.2 LOCK — 2 alias suffix `-gstack` 解决 namespace 冲突 (retro-gstack + investigate-gstack)
|
|
86
68
|
- Pattern A reconcile D.2 — gstack 30 optional naming bare 例外
|
|
87
|
-
- ~/.claude/CLAUDE.md "项目 / 里程碑结束: 可选跑 /retro 总结" verbatim
|
|
88
69
|
- workflows/capabilities.yaml — retro-gstack (alias suffix) + planning-with-files
|
|
89
70
|
- workflows/defaults.yaml — ralph_max_iterations.retro.* values (W2.2 backfill)
|
|
90
71
|
- sister Phase v2.0-2.5 RETROSPECTIVE.md sink pattern
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
# workflows/retro/workflow.yaml — Phase v3.0-3.4 W1 T3.4.W1.2 NEW
|
|
2
2
|
#
|
|
3
3
|
# Standalone post-④ Verify — gstack /retro 经验教训总结 (项目 / 里程碑结束可选,
|
|
4
|
-
#
|
|
4
|
+
# bundled milestone-close retrospective cadence).
|
|
5
5
|
# Sink RETROSPECTIVE.md (sister Phase v2.0-2.5 RETROSPECTIVE pattern)。
|
|
6
6
|
#
|
|
7
7
|
# Sister refs:
|
|
8
|
-
# - ~/.claude/CLAUDE.md "项目 / 里程碑结束: 可选跑 /retro 总结" verbatim
|
|
9
8
|
# - workflows/capabilities.yaml — retro-gstack (Bucket 7 gstack optional alias suffix per
|
|
10
9
|
# Pattern A E.2 LOCK, 解决 namespace 冲突 — retro carrier 自带 gstack 字符串 NOT prefix policy)
|
|
11
10
|
# - workflows/capabilities.yaml — planning-with-files (Bucket 4 核心 capability /plan)
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
# <packageRoot>/workflows/role-prompts.yaml — harnessed v3.4.3 role-prompt registry.
|
|
2
2
|
#
|
|
3
3
|
# Per-sub-workflow metadata consumed by `src/cli/lib/generateCommands.ts` to
|
|
4
|
-
# emit
|
|
4
|
+
# emit `<claude-home>/commands/<slash-name>.md` files at `harnessed setup`
|
|
5
|
+
# time (Claude Code slash command install path).
|
|
5
6
|
#
|
|
6
7
|
# Each entry describes:
|
|
7
8
|
# primary_cap: Which capability key the "preferred path" invokes (the
|
|
@@ -13,7 +14,7 @@
|
|
|
13
14
|
# upstream gstack expert prompts where available (cited inline).
|
|
14
15
|
# Self-contained — works even when upstream user-skill missing.
|
|
15
16
|
# severity: Severity scale label used in the report format.
|
|
16
|
-
# description: YAML frontmatter `description` for
|
|
17
|
+
# description: YAML frontmatter `description` for <claude-home>/commands/<x>.md.
|
|
17
18
|
#
|
|
18
19
|
# Karpathy simplicity: 1 small yaml beats 23 hardcoded strings in TS.
|
|
19
20
|
|
|
@@ -45,7 +46,7 @@ prompts:
|
|
|
45
46
|
specialist: "Stage 1 discuss dispatcher"
|
|
46
47
|
responsibility: |
|
|
47
48
|
Independently evaluate three clarification layers (strategic / phase /
|
|
48
|
-
subtask) per
|
|
49
|
+
subtask) per the bundled 3-tier clarification gate and run only the
|
|
49
50
|
layers whose gate fires. Each layer's command is `/discuss-strategic`,
|
|
50
51
|
`/discuss-phase`, `/discuss-subtask`.
|
|
51
52
|
checklist: []
|