haiku-method 3.13.1 → 3.14.1
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/.claude-plugin/plugin.json +1 -1
- package/CHANGELOG.md +24 -0
- package/bin/haiku.mjs +686 -673
- package/package.json +1 -1
- package/schemas/intent.schema.json +8 -2
- package/skills/change-mode/SKILL.md +33 -0
- package/skills/quick/SKILL.md +8 -7
- package/skills/start/SKILL.md +10 -4
- package/studios/ARCHITECTURE.md +6 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "haiku-method",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.14.1",
|
|
4
4
|
"description": "H·AI·K·U methodology — universal lifecycle orchestration with hat-based workflows, completion criteria, and automatic context preservation.",
|
|
5
5
|
"homepage": "https://haikumethod.ai",
|
|
6
6
|
"repository": {
|
|
@@ -43,8 +43,14 @@
|
|
|
43
43
|
},
|
|
44
44
|
"mode": {
|
|
45
45
|
"type": "string",
|
|
46
|
-
"enum": [
|
|
47
|
-
|
|
46
|
+
"enum": [
|
|
47
|
+
"continuous",
|
|
48
|
+
"discrete",
|
|
49
|
+
"autopilot",
|
|
50
|
+
"discrete-hybrid",
|
|
51
|
+
"quick"
|
|
52
|
+
],
|
|
53
|
+
"description": "Execution mode. Engine-managed via haiku_select_mode — never set directly by the agent."
|
|
48
54
|
},
|
|
49
55
|
"autopilot": {
|
|
50
56
|
"type": "boolean",
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: change-mode
|
|
3
|
+
description: Change the execution mode of an active H·AI·K·U intent — dial up or dial back human involvement mid-flight
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Change Mode
|
|
7
|
+
|
|
8
|
+
Change the execution mode of an in-flight intent. Use when:
|
|
9
|
+
|
|
10
|
+
- The mode chosen at start no longer fits (e.g. `discrete` is too heavy for a small change, or `continuous` is too autonomous for high-risk work).
|
|
11
|
+
- A teammate picked up an intent and wants different review semantics than the original owner.
|
|
12
|
+
- An intent was created with the wrong mode and you need to correct it before too much state accumulates.
|
|
13
|
+
|
|
14
|
+
## Process
|
|
15
|
+
|
|
16
|
+
1. **Resolve the intent.** If no slug is in scope (current branch isn't a `haiku/<slug>/...` branch), ask which intent to change. Otherwise infer from the branch.
|
|
17
|
+
|
|
18
|
+
2. **Call `haiku_select_mode`** with the intent slug. The tool elicits a mode value from the user. It will automatically:
|
|
19
|
+
- Hide `quick` from the picker if the intent has already started a stage (you cannot enter or leave `quick` mid-flight — it's single-stage by definition).
|
|
20
|
+
- Hide all options except the current mode if the intent is in `quick` and has started (no transition out is allowed).
|
|
21
|
+
- For non-quick destinations: write `mode` to intent.md and set `stages` to the studio's full stage list (idempotent — restoring the full list is safe even if it was already there).
|
|
22
|
+
|
|
23
|
+
3. **Drive forward.** After the mode is picked, call `haiku_run_next { intent: "<slug>" }`. The workflow engine continues from wherever the intent currently is — mode changes don't reset stage progress.
|
|
24
|
+
|
|
25
|
+
## Constraints
|
|
26
|
+
|
|
27
|
+
- **No `quick` transitions mid-flight.** Quick mode is single-stage and chosen at intent creation only. Switching into quick would amputate the rest of the workflow; switching out would suddenly add stages the user never reviewed. The engine refuses both.
|
|
28
|
+
- **Cannot change mode pre-studio.** If `studio` isn't set yet, the intent hasn't reached mode selection — use `/haiku:start` to drive the initial elicitation chain instead of this skill.
|
|
29
|
+
|
|
30
|
+
## Notes
|
|
31
|
+
|
|
32
|
+
- This skill never accepts a free-form mode value as an argument. Mode is engine-managed; the only way to set it is through `haiku_select_mode`'s elicitation.
|
|
33
|
+
- `discrete-hybrid` is a derived mode, not directly selectable. The engine computes it from `continuous` + per-stage external gates.
|
package/skills/quick/SKILL.md
CHANGED
|
@@ -5,21 +5,22 @@ description: Quick mode for small tasks — single-stage intent with auto-advanc
|
|
|
5
5
|
|
|
6
6
|
# Quick Mode
|
|
7
7
|
|
|
8
|
-
A quick task is a regular intent
|
|
8
|
+
A quick task is a regular intent in `quick` mode (single-stage). The workflow engine's elicitation chain handles studio + stage selection; the only difference vs `/haiku:start` is that mode is locked to `quick` (skipping the mode-elicit step).
|
|
9
9
|
|
|
10
10
|
## Process
|
|
11
11
|
|
|
12
12
|
1. **Prelaborate briefly.** If the task description is vague, ask ONE clarifying question via `AskUserQuestion` with `options[]`. Otherwise skip.
|
|
13
13
|
2. **Create the intent** with `haiku_intent_create`:
|
|
14
|
-
- `mode: "continuous"`
|
|
15
14
|
- `title`: 3–8 words, ≤80 chars, single line. NOT a truncated description. Good: `"Fix login button padding"`. Bad: `"Fix login button padding on mobile because…"`
|
|
16
15
|
- `description`: 2–5 sentences of context.
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
- **Do NOT pass `mode` or `stages`** — engine-managed. The tool will reject them.
|
|
17
|
+
3. **Drive the lifecycle** by calling `haiku_run_next { intent: "<slug>" }`. The workflow engine routes to `select_studio` first; the agent calls `haiku_select_studio`.
|
|
18
|
+
4. **After studio is selected**, the engine routes to `select_mode`. Call `haiku_select_mode { intent: "<slug>", options: ["quick"] }` — passing `options: ["quick"]` locks the mode without showing the picker (this is the only thing that distinguishes `/haiku:quick` from `/haiku:start`).
|
|
19
|
+
5. **The engine then routes to `select_stage`.** Call `haiku_select_stage { intent: "<slug>" }` — this elicits a single stage from the studio's stage list.
|
|
20
|
+
6. **Drive forward.** Each subsequent `haiku_run_next` advances through the pre-stage intent review and into the chosen stage.
|
|
21
21
|
|
|
22
22
|
## Guardrails
|
|
23
23
|
|
|
24
24
|
- If the task needs multiple stages, stop and suggest `/haiku:start` instead — don't cram it into a single stage.
|
|
25
|
-
-
|
|
25
|
+
- The agent NEVER passes `mode` or `stages` directly to `haiku_intent_create`. Both are engine-controlled.
|
|
26
|
+
- The user picks the stage via `haiku_select_stage`'s elicit — the agent does not pre-fill it unless the user already explicitly chose one in conversation, in which case pass `options: ["<chosen-stage>"]`.
|
package/skills/start/SKILL.md
CHANGED
|
@@ -22,10 +22,16 @@ description: Start a new H·AI·K·U intent — describe what you want to accomp
|
|
|
22
22
|
|
|
23
23
|
The title and description are distinct fields — the tool does NOT derive one from the other. Writing a lazy title (e.g. the first chunk of the description) will be rejected.
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
**Do NOT pass `mode` or `stages`.** Those fields are engine-managed and chosen by the user via elicitation. The tool's input schema does not accept them; trying to pass them will fail validation.
|
|
26
|
+
|
|
27
|
+
4. **Follow the tool's instructions** — The tool will direct you to call `haiku_run_next`, which then drives the elicitation chain in order:
|
|
28
|
+
1. `haiku_select_studio` — user picks the studio.
|
|
29
|
+
2. `haiku_select_mode` — user picks the mode (continuous, discrete, autopilot, quick).
|
|
30
|
+
3. `haiku_select_stage` — fires only when mode == `quick`, user picks the single stage to run.
|
|
31
|
+
4. The pre-stage intent review gate opens for the user's approval before any stage starts.
|
|
26
32
|
|
|
27
33
|
## Notes
|
|
28
34
|
|
|
29
|
-
-
|
|
30
|
-
- Do NOT ask the user to pick a studio — the workflow engine handles studio selection via elicitation
|
|
31
|
-
- If the user already provided a detailed description, skip prelaboration and go straight to step 3
|
|
35
|
+
- **Never dictate mode or stages.** If the user mentions "discrete" or "single stage" or "just inception" in their description, that's *context for the user when they make the elicit choice* — pass it along into the description if it's load-bearing, but do not pre-set the field. The agent MUST let the user pick via elicitation.
|
|
36
|
+
- Do NOT ask the user to pick a studio — the workflow engine handles studio selection via elicitation.
|
|
37
|
+
- If the user already provided a detailed description, skip prelaboration and go straight to step 3.
|
package/studios/ARCHITECTURE.md
CHANGED
|
@@ -284,6 +284,10 @@ When all pre-advance checks pass, the tick emits one mainline action describing
|
|
|
284
284
|
|
|
285
285
|
| Action | Meaning | What the agent does |
|
|
286
286
|
|---|---|---|
|
|
287
|
+
| `select_studio` | Studio not yet chosen on the intent | Call `haiku_select_studio` (elicits a studio from the user) |
|
|
288
|
+
| `select_mode` | Studio chosen, mode not yet chosen | Call `haiku_select_mode` (elicits a mode: continuous, discrete, autopilot, quick). Mode is engine-managed — agents never set it directly. |
|
|
289
|
+
| `select_stage` | Mode is `quick` and the single stage isn't picked yet | Call `haiku_select_stage` (elicits exactly one stage from the studio's stage list) |
|
|
290
|
+
| `gate_review` (intent_review) | Pre-stage approval of the minimal intent — fires after studio + mode + (if quick) stage are set, before stage 0 begins | Surface the review URL to the user; call `haiku_await_gate` |
|
|
287
291
|
| `start_stage` | First entry to a new stage | Acknowledge, retick |
|
|
288
292
|
| `elaborate` | Stage is in elaborate phase | Collaborate with the user, draft units, record decisions |
|
|
289
293
|
| `pre_review` | Pre-execute review of unit specs | Spawn review-agent subagents |
|
|
@@ -301,6 +305,8 @@ When all pre-advance checks pass, the tick emits one mainline action describing
|
|
|
301
305
|
| `escalate` | Terminal — needs human intervention | Stop and surface to user |
|
|
302
306
|
| `error` | Terminal — engine cannot proceed | Stop and surface to user |
|
|
303
307
|
|
|
308
|
+
The pre-stage chain — `select_studio → select_mode → (quick? → select_stage) → intent_review (gate_review)` — is the only place orientation choices are made. The agent **never** writes `mode` or `stages` directly; both fields are FSM-driven (rejected by `haiku_intent_set` with `intent_field_engine_only`). `haiku_intent_create` does not accept `mode` or `stages` either — every orientation choice flows through real elicitation.
|
|
309
|
+
|
|
304
310
|
The agent **never branches on action type for workflow-routing decisions**. They just follow the instruction the action's prompt builder rendered.
|
|
305
311
|
|
|
306
312
|
### 5.5 Properties this gives us
|