immune-brain 3.6.4 → 3.6.6
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 +45 -0
- package/package.json +1 -1
- package/plugins/immune-brain/.claude-plugin/plugin.json +1 -1
- package/plugins/immune-brain/.pi-extension/imm-canary-work.ts +76 -20
- package/plugins/immune-brain/.pi-extension/pi-canary-interaction.ts +38 -10
- package/plugins/immune-brain/dist/BASELINE.md +48 -15
- package/plugins/immune-brain/dist/claude/mcp-server.mjs +166 -57
- package/plugins/immune-brain/dist/docs/reference/planning-quality-gate.md +1 -1
- package/plugins/immune-brain/dist/docs/reference/subagent-dispatch-protocol.md +1 -1
- package/plugins/immune-brain/dist/imm-agent-doc-maintain.md +9 -1
- package/plugins/immune-brain/dist/imm-brainstorm.md +49 -35
- package/plugins/immune-brain/dist/imm-doc-prune.md +7 -1
- package/plugins/immune-brain/dist/imm-loop.md +31 -13
- package/plugins/immune-brain/dist/imm-planner.md +74 -32
- package/plugins/immune-brain/dist/imm-pr-fix.md +6 -2
- package/plugins/immune-brain/dist/role-prompts/executor.md +18 -10
- package/plugins/immune-brain/dist/role-prompts/pr-fix.md +5 -2
- package/plugins/immune-brain/runtime/assurance/coordinator.ts +18 -0
- package/plugins/immune-brain/runtime/assurance/verification.ts +13 -2
- package/plugins/immune-brain/runtime/claude/kernel_ports.ts +31 -9
- package/plugins/immune-brain/runtime/claude/mcp_server.ts +14 -1
- package/plugins/immune-brain/runtime/commands/kernel.ts +15 -13
- package/plugins/immune-brain/runtime/github_issue_tracker.ts +1112 -20
- package/plugins/immune-brain/runtime/kernel/application.ts +1 -0
- package/plugins/immune-brain/runtime/kernel/assurance_projection.ts +4 -1
- package/plugins/immune-brain/runtime/kernel/batch_authority.ts +407 -0
- package/plugins/immune-brain/runtime/kernel/canary_application.ts +24 -9
- package/plugins/immune-brain/runtime/kernel/enrollment.ts +72 -13
- package/plugins/immune-brain/runtime/kernel/intent.ts +67 -23
- package/plugins/immune-brain/runtime/kernel/reducer.ts +37 -9
- package/plugins/immune-brain/runtime/kernel/types.ts +1 -0
- package/plugins/immune-brain/runtime/kernel/validation.ts +10 -6
- package/plugins/immune-brain/runtime/plugin_version.ts +1 -1
- package/plugins/immune-brain/runtime/prompts/executor.md +18 -10
- package/plugins/immune-brain/runtime/prompts/pr-fix.md +5 -2
- package/plugins/immune-brain/skills/BASELINE.md +48 -15
- package/plugins/immune-brain/skills/imm-agent-doc-maintain/SKILL.md +20 -4
- package/plugins/immune-brain/skills/imm-brainstorm/SKILL.md +24 -64
- package/plugins/immune-brain/skills/imm-doc-prune/SKILL.md +18 -3
- package/plugins/immune-brain/skills/imm-loop/SKILL.md +20 -6
- package/plugins/immune-brain/skills/imm-planner/SKILL.md +35 -8
- package/plugins/immune-brain/skills/imm-pr-fix/SKILL.md +17 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: imm-brainstorm
|
|
3
|
-
description: Use when
|
|
3
|
+
description: Use when the user explicitly requests Immune-Brain requirement clarification.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Immune-Brain: Brainstormer
|
|
@@ -17,46 +17,47 @@ This skill adheres to the **[BASELINE.md](BASELINE.md)**.
|
|
|
17
17
|
|
|
18
18
|
## Invocation modes
|
|
19
19
|
|
|
20
|
-
`imm-brainstorm`
|
|
21
|
-
|
|
20
|
+
`imm-brainstorm` owns proportionate clarification. Its modes share decision
|
|
21
|
+
provenance and authority constraints:
|
|
22
22
|
|
|
23
|
-
- `default`:
|
|
23
|
+
- `default`: resolve facts and delegated choices; ask only material unresolved decisions.
|
|
24
24
|
- `roundtable`: add bounded multi-role perspectives, visible agreement and
|
|
25
25
|
disagreement, and decision criteria.
|
|
26
26
|
- `adversarial`: add high-pressure security, migration, rollback, verification,
|
|
27
27
|
audit, and cross-boundary analysis.
|
|
28
28
|
|
|
29
|
-
All modes produce the same `brainstorm_framing` shape and
|
|
30
|
-
exhaustive frontier protocol. `roundtable` and `adversarial` are analysis lenses
|
|
29
|
+
All modes produce the same `brainstorm_framing` shape. `roundtable` and `adversarial` are analysis lenses
|
|
31
30
|
only when explicitly selected by the user; model task-type or risk
|
|
32
|
-
classification never selects them.
|
|
33
|
-
|
|
31
|
+
classification never selects them. Exhaustive interviewing requires an explicit
|
|
32
|
+
request for thorough interrogation; selecting a lens alone does not require it.
|
|
34
33
|
|
|
35
|
-
## Default
|
|
34
|
+
## Default clarification
|
|
36
35
|
|
|
37
|
-
Exhaustive means every sourced current-goal branch, not a fixed question count.
|
|
38
36
|
Every branch must trace to the current user request, repository evidence, or a
|
|
39
|
-
settled parent decision.
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
37
|
+
settled parent decision. For a clear request, use a zero-question fast path when
|
|
38
|
+
no material decision or required fact remains unresolved. Do not seed or expand
|
|
39
|
+
a complete tree by default. Failure, compatibility, rollback, and risk questions
|
|
40
|
+
are relevant when evidence shows they can change the current outcome.
|
|
41
|
+
|
|
42
|
+
Classify each unresolved node as a repository fact, a delegated technical
|
|
43
|
+
choice, or a material user-owned decision. Resolve repository facts with
|
|
44
|
+
bounded, on-demand read-only evidence. If evidence is unavailable, record a
|
|
45
|
+
blocked fact and block only its dependent subtree; never turn the fact into a
|
|
46
|
+
user preference. A delegated technical choice is verifiable through existing
|
|
47
|
+
conventions, a reversible local probe, or an existing recorded decision when it
|
|
48
|
+
does not change the goal, scope, observable behavior, compatibility, risk
|
|
49
|
+
acceptance, or a protected effect; resolve it with evidence and record the
|
|
50
|
+
chosen assumption instead of asking. When a technical choice does change one of
|
|
51
|
+
those, it is material and belongs on the user frontier. Place every material
|
|
52
|
+
user-owned decision on the current frontier.
|
|
51
53
|
|
|
52
54
|
Ask every independent question on the complete currently unblocked frontier
|
|
53
55
|
together. Hold downstream questions until their prerequisites are decided.
|
|
54
56
|
Number every question, include grounded options and one recommended answer with
|
|
55
57
|
a short reason, and accept bulk approval of all recommendations with explicit
|
|
56
|
-
exceptions. Direct requirements and adopted recommendations settle
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
downstream branches.
|
|
58
|
+
exceptions. Direct requirements and adopted recommendations settle their
|
|
59
|
+
decisions without another approval round. After an answer, ask again only for
|
|
60
|
+
a newly evidenced material decision, not to manufacture further rounds.
|
|
60
61
|
|
|
61
62
|
Minimally clarify an ambiguous answer while independent branches continue. If a
|
|
62
63
|
later answer or new fact invalidates an earlier choice, reopen only that decision
|
|
@@ -64,13 +65,13 @@ delta and explain the new evidence. An explicit defer stops its subtree and is
|
|
|
64
65
|
recorded as `BR-DEFER-*`; if the subtree still changes the current Result,
|
|
65
66
|
interface, or compatibility, explain why it cannot be deferred.
|
|
66
67
|
|
|
67
|
-
Brainstorm finishes
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
Brainstorm finishes when the material decision frontier is empty and no blocked
|
|
69
|
+
fact prevents the current handoff. Independent framing may continue while a
|
|
70
|
+
dependent subtree is blocked. If the user
|
|
70
71
|
stops early, record every open node as `BR-Q-*` and do not mark the framing
|
|
71
72
|
planning-ready.
|
|
72
73
|
|
|
73
|
-
When
|
|
74
|
+
When clarification completes, present a concise result-only summary as a
|
|
74
75
|
non-blocking correction window. Do not ask the user to reconfirm decisions
|
|
75
76
|
reflected without change. If the summary introduces or changes a
|
|
76
77
|
decision, ask for explicit confirmation of only that decision delta
|
|
@@ -79,16 +80,29 @@ confirms a proposed direction or scope. Persist only final decisions: map them
|
|
|
79
80
|
to `BR-REQ-*`, `BR-DEC-*`, `BR-OUT-*`, `BR-DEFER-*`, and resolved `BR-Q-*`
|
|
80
81
|
manifest entries; do not copy the question transcript into repository artifacts.
|
|
81
82
|
|
|
83
|
+
## Explicit exhaustive interrogation
|
|
84
|
+
|
|
85
|
+
Read this section only when the user explicitly requests thorough or exhaustive
|
|
86
|
+
interrogation. Exhaustive means every sourced current-goal branch, not a fixed
|
|
87
|
+
question count. Seed the fixed framing roots: goal, beneficiary and scenario,
|
|
88
|
+
current state, desired behavior, scope and non-goals, constraints, failure and
|
|
89
|
+
edge behavior, compatibility and migration, success and Verification, and
|
|
90
|
+
deferred items. Recompute the tree after every response and traverse newly
|
|
91
|
+
unlocked downstream branches. Adoption closes current nodes, not unexplored
|
|
92
|
+
branches. Resolve facts and delegated choices locally; ask material user-owned
|
|
93
|
+
decisions. Stop when the sourced tree is traversed and its material frontier is
|
|
94
|
+
empty, or report remaining blocked/open nodes if the user stops early.
|
|
95
|
+
|
|
82
96
|
## Workflow Rules
|
|
83
97
|
|
|
84
|
-
- **Trigger Shape**:
|
|
85
|
-
- **Decision Provenance**:
|
|
98
|
+
- **Trigger Shape**: Explicit Brainstorm entry permits proportionate clarification, including a zero-question handoff for a clear request. Read the exhaustive protocol only on an explicit request for thorough interrogation. Do not add a second confirmation for an unchanged final summary.
|
|
99
|
+
- **Decision Provenance**: Investigate evidenced current-goal uncertainty. A concrete scenario is relevant when the request, repository, or a settled parent decision makes it material; do not invent speculative future needs.
|
|
86
100
|
- **Dependency-Aware Rounds**: Ask every independent question on the complete currently unblocked frontier together. Ask fewer questions only because dependencies keep downstream branches blocked, never because of an arbitrary question budget.
|
|
87
101
|
- **Read-only by default**: Inspect context and summarize the problem. do not implement inside this skill.
|
|
88
102
|
- **Handoff**: Write concise design notes under `docs/brainstorms/` only if explicitly requested.
|
|
89
103
|
- **Handoff Manifest**: When framing is stable, user-confirmed, and routes to planner, include a compact `Brainstorm manifest` with stable IDs for every planner-relevant item: `BR-REQ-*` for confirmed requirements, `BR-DEC-*` for confirmed decisions, `BR-OUT-*` for non-goals, `BR-DEFER-*` for explicitly deferred items, and `BR-Q-*` for open questions. The manifest is the closed-world handoff; the planner must account for every ID instead of relying on prose memory.
|
|
90
|
-
- **Default Next Route**: Route to `imm-planner`
|
|
91
|
-
- **Subagents**:
|
|
104
|
+
- **Default Next Route**: Route to `imm-planner` when the material frontier is empty, no required fact blocks the handoff, and every material user decision is settled by a direct requirement, explicit answer, or adopted recommendation. An unchanged final summary is a correction window, not another gate. If Brainstorm introduces a new decision, ask for that delta and do not name `imm-planner` as the current next skill.
|
|
105
|
+
- **Subagents**: Only when optional research is needed, read Research Dispatch and its shared dispatch reference. Default to inline evidence gathering; do not load dispatch instructions merely because Brainstorm was invoked.
|
|
92
106
|
- **Rejected Decision Evidence**: Use on-demand rejected-decision evidence instead of a global preflight. When a live branch resembles a rejected decision, resolve its recorded reason and optional `reconsider_if` conditions through code/docs inspection before asking the user. Treat each `reconsider_if` list item as an independently sufficient trigger (OR semantics): if available evidence satisfies none, keep the rejection as a current constraint or non-goal without re-litigation; if evidence satisfies one, reopen the decision and cite the condition plus changed evidence; if a condition cannot be resolved, ask only for that concrete missing fact. When `reconsider_if` is absent, preserve the backwards-compatible "what has changed?" fallback after inspection. When `rejection_reason` is absent, inspect an explicit rejection-reason section in the body; if no reason exists, report the metadata gap without inventing a reason or reconsideration condition.
|
|
93
107
|
- **CONTEXT.md Awareness**: When the user uses vague or conflicting domain terms, check `CONTEXT.md` at the repo root. If a canonical term exists, surface the conflict: "CONTEXT.md defines X as Y, but you seem to mean Z — which is it?" If CONTEXT.md does not exist, note the gap and recommend the planner create it during planning. Use CONTEXT.md vocabulary in the output artifact when available.
|
|
94
108
|
- **Discovery Protocol**: Before broad searching, read `CONTEXT.md` `## Architecture Map` and the active `.imm/memory/current_iteration.json` step `discovery_cache` when present. Use matching `docs/solutions/` `key_files` frontmatter as the pattern layer. If these pointers are missing or stale, note the discovery gap in the framing instead of compensating with unbounded search.
|
|
@@ -135,6 +149,6 @@ Default user-facing shape: `Conclusion -> Scope -> Next Action`. For the normal
|
|
|
135
149
|
|
|
136
150
|
## Next Action
|
|
137
151
|
|
|
138
|
-
- Gate: The
|
|
152
|
+
- Gate: The material frontier is empty; no required fact blocks the handoff; every material user decision is settled by a direct requirement, explicit answer, or adopted recommendation; and the result-only summary introduces no unconfirmed decision delta. **If any required clarification remains unanswered, you MUST NOT proceed to planning or suggest the next skill.** **If a decision delta is still unconfirmed, you MUST NOT proceed to planning, must not name a next skill, and should ask the user to confirm only that delta.**
|
|
139
153
|
- If gates pass: suggest `imm-planner` with a one-line reason.
|
|
140
154
|
- If gates are not met: state which questions or decision deltas remain open; do not name a next skill and wait for the user's answer.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: imm-doc-prune
|
|
3
|
-
description: Use
|
|
3
|
+
description: Use when the user explicitly requests Immune-Brain pruning of stale current documentation.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Immune-Brain: Doc Prune
|
|
@@ -36,6 +36,8 @@ no persistent report, and no automatic commit.
|
|
|
36
36
|
|
|
37
37
|
## Ordered Pruning Protocol
|
|
38
38
|
|
|
39
|
+
### Inventory and Manifest
|
|
40
|
+
|
|
39
41
|
1. **Establish repository safety.** Mutation requires a Git worktree. A
|
|
40
42
|
non-Git repository or an untracked candidate is audit-only. Record the
|
|
41
43
|
candidate path, blob/content hash, tracked status, and candidate-local
|
|
@@ -91,6 +93,8 @@ no persistent report, and no automatic commit.
|
|
|
91
93
|
"clean stale docs" is insufficient. Interruption starts a fresh scan; no
|
|
92
94
|
manifest is persisted.
|
|
93
95
|
|
|
96
|
+
### Approved Mutation
|
|
97
|
+
|
|
94
98
|
9. **Revalidate and mutate minimally.** Re-read candidate bytes, Git status,
|
|
95
99
|
inbound references, generated ownership, and active scope immediately
|
|
96
100
|
before each approved change. Drift blocks that item. Delete a whole file
|
|
@@ -99,6 +103,8 @@ no persistent report, and no automatic commit.
|
|
|
99
103
|
owner before deleting the obsolete source. Never renumber ADRs and never
|
|
100
104
|
create a new ADR or Solution merely to complete pruning.
|
|
101
105
|
|
|
106
|
+
### Verify and Report
|
|
107
|
+
|
|
102
108
|
10. **Verify and report.** Re-scan residual names and paths, current local
|
|
103
109
|
links on current documentation, source/generated parity, existing documentation contract tests,
|
|
104
110
|
and `git diff --check`. This Skill does not execute arbitrary documented
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: imm-loop
|
|
3
|
-
description: Use
|
|
3
|
+
description: Use when the user explicitly requests execution or resumption of an Immune-Brain task.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Immune-Brain: Loop
|
|
@@ -16,7 +16,12 @@ claim, TaskIntent, and TaskRecord. Invalid or contradictory projections fail
|
|
|
16
16
|
closed. A candidate TaskIntent is not Enrollment authority.
|
|
17
17
|
|
|
18
18
|
Before the first Enrollment of a candidate TaskIntent, confirm the Planner
|
|
19
|
-
returned `tracker_associated`
|
|
19
|
+
returned `tracker_associated` — but only when the candidate belongs to an
|
|
20
|
+
identified GitHub-carried Initiative. Standalone TaskIntents and Local
|
|
21
|
+
Initiatives carry no tracker prerequisite: their Enrollment needs only the
|
|
22
|
+
validated candidate. When membership is uncertain, resolve it against the
|
|
23
|
+
Planner's carrier decision before treating the candidate as exempt; do not
|
|
24
|
+
assume either way. For a GitHub-carried Initiative, `tracker_projection_failed` or
|
|
20
25
|
`awaiting_user_initiative_confirmation` blocks that Enrollment until the same
|
|
21
26
|
complete carrier batch succeeds; report the stable carrier reason and its exact
|
|
22
27
|
retry action instead of enrolling. A carrier command the Host refused, cancelled,
|
|
@@ -36,7 +41,7 @@ At every internal role boundary call the read-only `imm_loop_action` Tool. Use
|
|
|
36
41
|
exploration, advisory review, Compounder, Kernel ownership, or scope expansion.
|
|
37
42
|
Use Kernel ownership for an enrolled task. This Tool projects authority; it does
|
|
38
43
|
not record execution evidence, mutate task state, or replace Kernel operations.
|
|
39
|
-
|
|
44
|
+
Before a child dispatch, read the [Subagent Dispatch Protocol](docs/reference/subagent-dispatch-protocol.md#authorization-authority).
|
|
40
45
|
Never load an internal role as a public Skill or spawn another loop process.
|
|
41
46
|
The standalone `imm-pr-fix`, `imm-doc-prune`, and `imm-agent-doc-maintain` are host-native
|
|
42
47
|
maintenance entries, never dispatched as the Loop role. Internal `test-fixer`
|
|
@@ -65,8 +70,12 @@ Continue while the current projection has a valid action:
|
|
|
65
70
|
6. For rework, follow the projected artifact state before editing. Resolve
|
|
66
71
|
findings only after fixing and verifying their cause. Changed snapshots
|
|
67
72
|
invalidate old evidence; freeze and run the newly required obligations.
|
|
68
|
-
7.
|
|
69
|
-
|
|
73
|
+
7. An unresolved decision pauses only dependent execution. On `awaiting_user`,
|
|
74
|
+
invoke `request_authorization` directly before ending the turn; use the
|
|
75
|
+
Decisions and Recovery route for its native-gate handling. End the turn if
|
|
76
|
+
the decision remains unresolved, is cancelled, or the gate fails. Otherwise
|
|
77
|
+
continue from the returned projection. Stop on terminal `done` or `stopped`,
|
|
78
|
+
explicit cancellation, or a failure without a safe projected action.
|
|
70
79
|
|
|
71
80
|
Use the fresh projection returned by a successful operation when supplied. Read
|
|
72
81
|
`status` after interruption, ambiguous mutation results, absent projections, or
|
|
@@ -76,15 +85,24 @@ not bypass them. Do not poll or create detached jobs.
|
|
|
76
85
|
|
|
77
86
|
## Decisions and Recovery
|
|
78
87
|
|
|
79
|
-
- Scope expansion
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
88
|
+
- Scope expansion returns to Planner's Enrolled Intent Revision route. Planner
|
|
89
|
+
prepares the complete proposed revision without replacing the active owner;
|
|
90
|
+
the current Loop submits it through Kernel revision authority. Collect all
|
|
91
|
+
currently known missing paths, caller/test/generated mirrors, and verification
|
|
92
|
+
reasons in one request. Do not edit outside scope while waiting or widen it
|
|
93
|
+
piecemeal without new evidence. Bounded test or PR repair stays inside the same
|
|
94
|
+
TaskIntent.
|
|
83
95
|
- Invoke `approve_breaking_intent_revision` with the complete next intent
|
|
84
96
|
directly; the native Host gate is the single user decision. Do not overwrite
|
|
85
97
|
enrolled intent sidecars or ask for chat pre-confirmation.
|
|
86
|
-
- On `awaiting_user`, invoke `request_authorization` directly
|
|
87
|
-
|
|
98
|
+
- On `awaiting_user`, invoke `request_authorization` directly for a concrete
|
|
99
|
+
unresolved decision or rework authorization, not risk tier alone.
|
|
100
|
+
- When the user explicitly asks to stop a Pi task, invoke
|
|
101
|
+
`imm_kernel_canary({ task_id, action: { op: "request_stop" } })` directly.
|
|
102
|
+
Its single native confirmation authorizes existing Kernel stop settlement.
|
|
103
|
+
Cancellation is not task termination. A busy invocation must finish or be
|
|
104
|
+
cancelled through existing Host controls before requesting stop; never clear
|
|
105
|
+
claims manually or use this operation to force-kill QA.
|
|
88
106
|
- Invoke `repair_authority_state` directly for a proven stale claim. Kernel
|
|
89
107
|
revalidation removes only the redundant claim without user interaction.
|
|
90
108
|
- A Managed native authority failure stays fail-closed. Report its stable reason
|
|
@@ -117,8 +135,6 @@ The internal Compounder is optional: only closed work with structured evidence
|
|
|
117
135
|
of a reusable Learning may route to it. Routine completion creates no Learning.
|
|
118
136
|
It cannot approve successors or delay terminal settlement. A projection with
|
|
119
137
|
`recommended_authority: user` must not dispatch successor work automatically.
|
|
120
|
-
Do not create, switch,
|
|
121
|
-
or delete Git worktrees; operate only in the Host launch directory.
|
|
122
138
|
|
|
123
139
|
The Host may attach an opted-in GitHub projection after settlement. Only a fresh claimless
|
|
124
140
|
`done`/`stopped` projection plus its exact terminal tombstone projects
|
|
@@ -145,6 +161,8 @@ Stop reason:
|
|
|
145
161
|
Next action:
|
|
146
162
|
```
|
|
147
163
|
|
|
164
|
+
## Failure Output
|
|
165
|
+
|
|
148
166
|
For `settlement_unknown`, call `advance_assurance` once to reconcile the Kernel
|
|
149
167
|
projection before resuming; never replay the uncertain write directly. The runtime
|
|
150
168
|
retries only explicit `EINTR`/`EAGAIN` failures of its initial projection read, once,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: imm-planner
|
|
3
|
-
description: Use
|
|
3
|
+
description: Use when the user explicitly requests Immune-Brain Spec and TaskIntent planning.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Immune-Brain: Planner
|
|
@@ -16,8 +16,8 @@ an explicit `imm-loop` entry; explicit Planner entry owns planning and the later
|
|
|
16
16
|
native Enrollment gate.
|
|
17
17
|
|
|
18
18
|
Plan-only output remains non-authoritative. Planner creates or validates a
|
|
19
|
-
candidate Spec/TaskIntent
|
|
20
|
-
|
|
19
|
+
candidate Spec/TaskIntent. Planner may request the native Enrollment gate;
|
|
20
|
+
only that gate grants execution authority. Explicit Plan-only requests stop after returning the
|
|
21
21
|
planning artifacts. A later literal-user request to start Enrollment is a
|
|
22
22
|
non-authoritative execution trigger: invoke the native Enrollment gate directly,
|
|
23
23
|
without asking for chat pre-confirmation. For a clear mutation request that
|
|
@@ -32,9 +32,10 @@ cannot bypass that boundary, QA, Review, authorization, or completion.
|
|
|
32
32
|
## Clarification supplement
|
|
33
33
|
|
|
34
34
|
Planner consumes an upstream Brainstorm manifest as closed-world framing and
|
|
35
|
-
must not repeat, reopen, or rewrite confirmed decisions.
|
|
36
|
-
and
|
|
37
|
-
|
|
35
|
+
must not repeat, reopen, or rewrite confirmed decisions. Consult relevant ADRs
|
|
36
|
+
and rejected Learnings only when an architectural decision, known historical
|
|
37
|
+
constraint, or conflict with the existing design makes them relevant. Reuse
|
|
38
|
+
upstream evidence; absent relevant history is not a planning blocker. It resolves repository facts, performs reference closure, and owns
|
|
38
39
|
ordinary technical choices:
|
|
39
40
|
component boundaries, internal interfaces, failure behavior, compatibility,
|
|
40
41
|
migration, recovery and rollback, Verification, execution slices, dependencies,
|
|
@@ -71,15 +72,16 @@ resolved wrapper and use the resolved `imm-kernel` wrapper for every Kernel
|
|
|
71
72
|
command below. Do not assume either bare command is available on shell `PATH`.
|
|
72
73
|
Then route deterministically:
|
|
73
74
|
|
|
74
|
-
- an active Kernel claim
|
|
75
|
-
coordination,
|
|
75
|
+
- an active Kernel claim remains with `imm-loop` for foreground Kernel Tool
|
|
76
|
+
coordination, except a Loop-requested revision follows Enrolled Intent Revision
|
|
77
|
+
below to prepare a non-authoritative proposal for that same owner;
|
|
76
78
|
- an active or otherwise nonterminal v3 Plan remains on its existing v3 route;
|
|
77
79
|
- no routing policy preserves the legacy v3 Planner behavior;
|
|
78
80
|
- a valid `kernel_task_intent` retirement policy produces one TaskIntent draft
|
|
79
81
|
through the current Host's explicit `imm-planner`;
|
|
80
82
|
- an invalid, unreadable, untracked, or tracked-deleted policy rejects new
|
|
81
83
|
planning authority with `routing_policy_invalid`;
|
|
82
|
-
- no Planner path
|
|
84
|
+
- no Planner path grants execution authority or falls back to v3 after retirement.
|
|
83
85
|
|
|
84
86
|
Current owner, phase, completion, and authority facts are authoritative only
|
|
85
87
|
when read from the Assurance projection and TaskRecord. `CONTEXT.md` is
|
|
@@ -105,6 +107,11 @@ workspace claim, and final authority preconditions without executing acceptance
|
|
|
105
107
|
descriptors. A routine task proceeds from that single confirmation through
|
|
106
108
|
enrollment, execution and QA without a second human stop.
|
|
107
109
|
|
|
110
|
+
## Candidate Authoring
|
|
111
|
+
|
|
112
|
+
Read this section before creating new candidate artifacts, after request routing
|
|
113
|
+
and clarification. It does not apply to Enrolled Intent Revision.
|
|
114
|
+
|
|
108
115
|
Before authoring a TaskIntent, trace each expected behavior from its public or
|
|
109
116
|
runtime entry point through existing imports and callers to the highest focused
|
|
110
117
|
behavioral tests. Include generated or packaged mirrors and every owner of the
|
|
@@ -163,18 +170,23 @@ After approval, author, stage, and validate every TaskIntent in the decompositio
|
|
|
163
170
|
with `valid: true` and `enrollment_ready: true`. Resolve `../bin/imm-tracker` from this packaged contract; do not assume a bare command is on `PATH`. Submit the entire approved set once through
|
|
164
171
|
`imm-tracker publish-initiative --stdin --json`. Its input contains the confirmed
|
|
165
172
|
Initiative slug and goal, Parent projection, and every Child's `slice_id`,
|
|
166
|
-
canonical TaskIntent path,
|
|
173
|
+
canonical TaskIntent path, bounded public `acceptance` summaries, and public
|
|
174
|
+
projection. The Parent projection requires
|
|
167
175
|
`problem`, `result`, and `design`, and may include `decisions`,
|
|
168
176
|
`testing_strategy`, and `out_of_scope`. `design` records Initiative-level
|
|
169
177
|
invariants, Slice boundaries and ordering, shared interfaces or state flow, and
|
|
170
178
|
material compatibility decisions. Every Parent Slice must correspond to one
|
|
171
179
|
published Child; future checklist-only Slices are not allowed in the batch.
|
|
172
180
|
|
|
173
|
-
Each Child
|
|
181
|
+
Each Child must provide public `acceptance` entries with `id` and a 1-500
|
|
182
|
+
character `summary`. Their IDs must match every canonical TaskIntent acceptance
|
|
183
|
+
ID exactly once. Canonical assertion prose is authority evidence and must never
|
|
184
|
+
be copied into public GitHub projection. Each Child projection may contain
|
|
185
|
+
`result`, `current_behavior`,
|
|
174
186
|
`desired_behavior`, `key_interfaces`, `verification`, `blocked_by` Task IDs,
|
|
175
187
|
`out_of_scope`, and `agent_handoff`. The tracker rereads every canonical
|
|
176
|
-
TaskIntent for identity, risk, and acceptance; projection fields
|
|
177
|
-
TaskIntent scope or authority. It validates the complete dependency graph before
|
|
188
|
+
TaskIntent for identity, risk, and acceptance IDs; projection fields and public
|
|
189
|
+
summaries never widen TaskIntent scope or authority. It validates the complete dependency graph before
|
|
178
190
|
remote writes, creates the Parent once, creates all Children, attaches every
|
|
179
191
|
Child as a native Sub-issue, creates native `blocked_by` relations, and rereads
|
|
180
192
|
the complete topology. The Child Agent Brief includes a direct Parent Issue link.
|
|
@@ -207,6 +219,19 @@ TaskIntent or TaskRecord. Existing Issue markers grant permission only for
|
|
|
207
219
|
idempotent retry of that same approved Initiative; they never grant execution
|
|
208
220
|
authority.
|
|
209
221
|
|
|
222
|
+
For amending an already-published Initiative, the same
|
|
223
|
+
`imm-tracker publish-initiative --stdin --json` operation accepts an optional
|
|
224
|
+
`amendment` input after the literal user approves the changed pending frontier.
|
|
225
|
+
Provide the complete approved pending Tasks plus the complete read-only
|
|
226
|
+
historical Child list, each binding the observed `issue_number`, title, body,
|
|
227
|
+
and state at approval. The tracker verifies every bound Issue against that
|
|
228
|
+
baseline before any write, updates only approved pending briefs, converges the
|
|
229
|
+
exact approved pending `blocked_by` set, creates newly added pending Children,
|
|
230
|
+
and preserves historical Children byte-for-byte with their native Sub-issue
|
|
231
|
+
links and dependency relations. Omitted membership, baseline drift, or a
|
|
232
|
+
stopped historical prerequisite fails closed with zero or bounded mutations
|
|
233
|
+
and an exact retry action; the strict no-amendment default is unchanged.
|
|
234
|
+
|
|
210
235
|
### Verification Descriptor Discipline
|
|
211
236
|
|
|
212
237
|
Every acceptance verification descriptor must be a focused, deterministic,
|
|
@@ -232,10 +257,10 @@ descriptors or add a mandatory user confirmation. Use the smallest `timeout_ms`
|
|
|
232
257
|
- **Design-view selection**: For Medium and High risk, select every materially relevant technical-design view from architecture layers, service/component interfaces, data flow, state transitions, and temporal sequence. Record a short `Design views` statement naming the selected views and why any omitted view cannot affect the design. Do not write empty architecture, interface, data-flow, state, or sequence sections. Low risk remains concise and may omit Technical Design. When a selected view is recorded, also record its required decision content: architecture layers need layer responsibilities, dependency direction, ownership, and prohibited coupling; service/component interfaces need inputs, outputs, errors, compatibility/versioning, and caller/callee ownership; data flow needs source, transformations, validation, destination, and failure handling; state transitions need states, legal transitions, trigger, invariant, terminal ownership, and recovery; temporal sequence needs ordered interactions, authority at each point, interruption behavior, and idempotency.
|
|
233
258
|
- **Technical Design Authority**: The Spec is the single Technical Design baseline. TaskIntent acceptance and scope reference the applicable design decisions or invariants without copying Technical Design prose. If discovery invalidates the baseline, stop execution and return to Planner to update the Spec and decide whether `replan` is required. TaskIntent and Initiative text do not duplicate Technical Design prose or become a prose Plan substitute.
|
|
234
259
|
- **TaskIntent decomposition**: Use the selected design boundaries as one retain/split criterion for TaskIntent slices. Keep work in one TaskIntent when the selected views describe one coherent executable slice with shared acceptance, risk treatment, rollback, and authority. Split a successor TaskIntent when a service boundary, state-machine owner, migration/compatibility boundary, independently promotable layer, or sequence dependency needs independent verification, rollback, authorization, or settlement. Do not split merely because the design names several layers, files, or services. Treat trust-boundary changes as the same kind of decomposition evidence: a TaskIntent should normally change one primary trust-boundary invariant, while merely traversing several boundaries or updating both sides of one end-to-end authority chain does not require a split. Split separate trust invariants when they can be independently verified, rolled back, authorized, migrated, or settled. Keep multiple trust-boundary changes together only when they form one atomic security outcome and splitting would create an unsafe or unusable intermediate state; record that reason in the Spec. This is Planner judgment, not a TaskIntent schema field or an Enrollment counting rule. This does not revive prose Plan, Roadmap, or Phase authority.
|
|
235
|
-
- **Mermaid Use**: Mermaid is required only when a medium/high-risk design contains structure, sequence, data flow, or state transition relationships that a diagram materially clarifies. Mermaid is not a universal gate; a diagram supplements adjacent prose and never becomes a second design authority.
|
|
260
|
+
- **Mermaid Use**: Mermaid is required only when a medium/high-risk design contains structure, sequence, data flow, or state transition relationships that a diagram materially clarifies. Mermaid is not a universal gate; a diagram supplements adjacent prose and never becomes a second design authority. Medium/High risk Specs record `**Diagram decision**: required|not_required` and a non-empty `**Diagram reason**:`. A `required` decision must have a Mermaid block; `not_required` explains why prose is sufficient. Low-risk Specs omit the empty ceremony and record neither field.
|
|
236
261
|
- **Verification**: Every acceptance assertion has a concrete focused descriptor that can fail on the intended regression. Hypothetical evidence is not execution-ready.
|
|
237
262
|
- **Executable Scope**: `scope_hint` is the mutation envelope, not discovery context. Close references across callers, tests, generated mirrors, and state-machine owners before authoring. Include bound active and archive Spec paths needed for `freeze_artifacts`. Collect all known scope gaps in one revision request; ask again only when new evidence changes the boundary.
|
|
238
|
-
- **Devil's Advocate Preplan Audit**:
|
|
263
|
+
- **Devil's Advocate Preplan Audit**: Medium/High risk work records a `Devil's Advocate Audit` in the Spec covering rollback resilience, verification vanity, and spec dilution detection. Explain recovery from partial implementation, why verification detects the regression, and how accepted requirements remain covered. Low-risk work omits the empty template; the Spec records outcome, boundary, and concrete verification only.
|
|
239
264
|
- **Execution posture**: Record `test-first` or `characterization-first` in the Spec when explicitly requested or justified by fragile untested behavior. The Executor owns the local choreography; do not create prototype or RED/GREEN/REFACTOR authority Steps. Throwaway probes must have a cleanup condition and a durable decision output.
|
|
240
265
|
|
|
241
266
|
## Settlement-Design Contract
|
|
@@ -289,21 +314,36 @@ state coverage, and verification cues for desktop and mobile. Use `Standard` or
|
|
|
289
314
|
The mode produces an
|
|
290
315
|
implementation-ready contract and routes it to normal planning or execution.
|
|
291
316
|
|
|
317
|
+
## Enrolled Intent Revision
|
|
318
|
+
|
|
319
|
+
Use this route instead of new-task planning when the current Loop requests a
|
|
320
|
+
scope or acceptance revision. Planner prepares the complete proposed revision
|
|
321
|
+
from the requested delta and concrete evidence without replacing the active
|
|
322
|
+
owner. Keep unaffected decisions; include all known scope, Spec, and acceptance
|
|
323
|
+
changes in the proposal. Preserve the prior on-disk sidecars until Kernel applies
|
|
324
|
+
the revision; do not overwrite the enrolled TaskIntent, invoke the new-intent
|
|
325
|
+
author command, or request a second Enrollment.
|
|
326
|
+
|
|
327
|
+
Return the proposal to the current Loop owner for Kernel `revise_intent` or,
|
|
328
|
+
when breaking, `approve_breaking_intent_revision` with the complete next intent.
|
|
329
|
+
The native gate is the single user decision for a breaking revision; candidate
|
|
330
|
+
preparation does not apply the revision or authorize expanded execution.
|
|
331
|
+
|
|
292
332
|
## Planning Rules
|
|
293
333
|
|
|
294
334
|
- **Entry Contract**: Use when Spec/TaskIntent planning is needed. An already enrolled owner remains on its current Kernel authority and resumes only through explicit `imm-loop`; a validated candidate still needs native Enrollment.
|
|
295
335
|
- **Output Language Gate**: Before writing or revising any Spec or Plan, read the project output language policy from `AGENTS.md`, `IMMUNE.md`, or Immune-Brain plugin config. Default Spec and Plan prose to English unless the current user request, project instructions, or host/user preference contains an explicit document-language instruction. A reply-language instruction does not change document language. Keep schema fields, CLI commands, file paths, code identifiers, enum values, JSON keys, and canonical terms such as `Step`, `Plan`, `Spec`, `Verification`, `Discovery cache`, and `Devil's Advocate Audit` literal.
|
|
296
336
|
- **Clarification Supplement**: If an upstream `imm-brainstorm` manifest exists, verify that every `BR-Q-*` item is resolved and every confirmed framing decision is represented; must not repeat, reopen, or rewrite confirmed decisions. Ask only a focused omission, repository-conflict, or invalidated-assumption delta tied to concrete evidence. Resolve a local delta here; return to `imm-brainstorm` when it reopens multiple product branches or changes the overall goal or Scope. Finalization requires no unresolved supplement and no unconfirmed decision introduced by Planner.
|
|
297
337
|
- **Planning Bootstrap**: When no upstream `imm-brainstorm` manifest exists, preserve Direct Planner entry by resolving repository facts and deriving ordinary technical choices. An already-clear request takes the zero-question fast path to a non-blocking correction summary. Discovery of an unresolved user-owned goal, user, scope, behavior, compatibility preference, risk acceptance, or success criterion returns to `imm-brainstorm`; Planner does not convert product uncertainty into a silent assumption or duplicate Brainstorm's interview.
|
|
298
|
-
- **Small-scope budget discipline**:
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
discovery.
|
|
338
|
+
- **Small-scope budget discipline**: Read the named files first for small or
|
|
339
|
+
fixture-sized planning tasks. Read relevant orientation documents and follow
|
|
340
|
+
caller, test, or generated-reference links when a concrete missing fact requires
|
|
341
|
+
them; root documents are not a fixed preflight checklist. Before broad searching,
|
|
342
|
+
consult `CONTEXT.md`'s Architecture Map. Avoid repository-wide listings and
|
|
343
|
+
unrelated directories when targeted evidence resolves the task. Required
|
|
344
|
+
authority, security, and shared-contract reference closure still applies.
|
|
345
|
+
- **Decision History Discovery**: Apply Clarification supplement's conditional
|
|
346
|
+
history lookup; reuse upstream evidence rather than repeating discovery.
|
|
307
347
|
- **Testing Seam Selection**: Prefer the highest existing observable behavioral
|
|
308
348
|
test seam and the fewest sufficient seams. Cite relevant test prior art and
|
|
309
349
|
explain how the selected seam catches the intended regression. This is a
|
|
@@ -312,10 +352,10 @@ implementation-ready contract and routes it to normal planning or execution.
|
|
|
312
352
|
- **Review Mapping**: In-scope rework stays with the enrolled TaskIntent and explicit `imm-loop` entry. Cross-scope findings become a Planner decision delta with concrete missing paths and verification evidence; do not create a successor prose Plan.
|
|
313
353
|
- **Brainstorm Manifest Mapping**: Record every upstream `BR-*` item in a Spec `Brainstorm Trace`, mapped to TaskIntent acceptance, a captured decision, or an explicit reason for deferral or exclusion. Resolve every `BR-Q-*` item before handoff. Do not silently narrow confirmed framing.
|
|
314
354
|
- **Session Lifecycle Ownership**: The user chooses the current or a new session. Tokens, compactions, tool counts, elapsed time, and review rounds never trigger automatic session creation or termination. Recovery uses TaskRecord and the fresh Kernel projection.
|
|
315
|
-
- **Subagents**:
|
|
316
|
-
- **Enrolled Intent**:
|
|
317
|
-
- **CONTEXT.md Vocabulary**:
|
|
318
|
-
- **Discovery Protocol**: Read `CONTEXT.md` `## Architecture Map` before broad searching
|
|
355
|
+
- **Subagents**: Only when optional research is needed, read Research Dispatch and its shared dispatch reference. Default to inline evidence gathering. Plan conditional reviewers such as `security-reviewer` only if their trigger surfaces are explicit; do not manufacture them.
|
|
356
|
+
- **Enrolled Intent**: Follow Enrolled Intent Revision for a Loop-requested scope or acceptance change; candidate preparation never changes the current owner or grants execution authority.
|
|
357
|
+
- **CONTEXT.md Vocabulary**: Consult the relevant `CONTEXT.md` terms when domain meaning is unclear or changes; known file-local tasks do not require a full root-document read. `CONTEXT.md` is vocabulary and architecture navigation, not execution state.
|
|
358
|
+
- **Discovery Protocol**: Read `CONTEXT.md` `## Architecture Map` before broad searching; consult relevant `docs/solutions/` evidence under Clarification supplement's history trigger. Record concrete file pointers and reasons in the Spec. Do not read or write a legacy Step discovery cache.
|
|
319
359
|
- **Planning Quality Gate**: For elevated-risk work, verify contract surfaces, compatibility, interruption recovery, rollback, verification strength, and Brainstorm traceability in the Spec. Do not invoke retired Plan mutation or State Ledger synchronization.
|
|
320
360
|
- **Parallel Probes**: Optional read-only probes must have bounded non-overlapping scopes, expected evidence, and no file or authority writes. They are advisory discovery, not persisted Step annotations. Probe failure falls back to inline investigation with a recorded reason.
|
|
321
361
|
|
|
@@ -351,7 +391,9 @@ optional advisory dispatch fails, continue inline and record the reason.
|
|
|
351
391
|
Spec under `docs/specs/` plus canonical candidate
|
|
352
392
|
`docs/plans/<task-id>.intent.json`. The Spec records outcome, discovery evidence,
|
|
353
393
|
decisions, assumptions, Technical Design when required, output language,
|
|
354
|
-
|
|
394
|
+
the Medium/High risk Devil's Advocate Audit, and acceptance/test mapping. Low
|
|
395
|
+
risk records outcome, boundary, and concrete verification without the empty
|
|
396
|
+
ceremony. Include a complete
|
|
355
397
|
`Brainstorm Trace` when consuming a Brainstorm manifest. TaskIntent is authored
|
|
356
398
|
and validated through `imm-kernel`; do not write a prose iteration Plan or sync
|
|
357
399
|
a State Ledger. Keep historical Plan validation strictly read-only.
|
|
@@ -368,15 +410,15 @@ a State Ledger. Keep historical Plan validation strictly read-only.
|
|
|
368
410
|
| Split one outcome into read/edit/run micro-steps | One TaskIntent owns one closable outcome; Executor owns implementation batches. |
|
|
369
411
|
| Append repair outside scope | Return the complete known scope delta for Kernel revision; do not widen execution. |
|
|
370
412
|
| Drop a brainstorm-confirmed item as "out of scope" without saying so | Closed-world handoff: every `BR-*` ID must be covered, decisioned, deferred, scoped out with reason, or resolved as an assumption. |
|
|
371
|
-
|
|
|
372
|
-
| Skip adversarial self-review because the plan is small | **Devil's Advocate** audit still checks rollback resilience, verification vanity, and spec dilution before the plan is treated as execution-ready. |
|
|
413
|
+
| Finalize dependent planning while brainstorm questions are open | **Clarification Barrier**: Finalization and dependent commitments are blocked until required `BR-Q-*` items are answered. Independent investigation and explicitly unapproved alternative drafts may continue; silence is not consent. |
|
|
414
|
+
| Skip adversarial self-review on Medium/High risk because the plan is small | **Devil's Advocate** audit still checks rollback resilience, verification vanity, and spec dilution before the plan is treated as execution-ready. |
|
|
373
415
|
|
|
374
416
|
## Red Flags
|
|
375
417
|
|
|
376
418
|
- Acceptance verification names only hypothetical evidence with no runnable descriptor.
|
|
377
419
|
- New work depends on a prose Plan validator, Step activation, or State Ledger.
|
|
378
420
|
- A Brainstorm manifest lacks a complete Spec `Brainstorm Trace`.
|
|
379
|
-
- A Spec lacks a `Devil's Advocate Audit` covering rollback resilience, verification vanity, and spec dilution detection.
|
|
421
|
+
- A Medium/High risk Spec lacks a `Devil's Advocate Audit` covering rollback resilience, verification vanity, and spec dilution detection.
|
|
380
422
|
- New Spec prose ignores the document-language policy.
|
|
381
423
|
- Candidate artifacts escape the approved planning scope.
|
|
382
424
|
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: imm-pr-fix
|
|
3
|
-
description: Use
|
|
3
|
+
description: Use when the user explicitly requests Immune-Brain repair of GitHub PR review feedback, merge conflicts, or failing checks.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Immune-Brain: PR Fix
|
|
7
7
|
|
|
8
|
+
## Authority Boundary
|
|
9
|
+
|
|
8
10
|
Repair blockers on one GitHub pull request without creating or mutating
|
|
9
11
|
TaskIntent, TaskRecord, Kernel, Spec, or Plan authority. An already active
|
|
10
12
|
Managed task remains owned by `imm-loop`; stop and direct the user there when
|
|
@@ -66,7 +68,9 @@ not repair blockers.
|
|
|
66
68
|
|
|
67
69
|
### 4. Verify and close out
|
|
68
70
|
|
|
69
|
-
|
|
71
|
+
Before any push or feedback mutation, apply the BASELINE Host Confirmation
|
|
72
|
+
Boundary to the exact remote effect; the repair request alone does not grant
|
|
73
|
+
unrequested publication authority. Run the smallest checks that reproduce each blocker, then any repository check
|
|
70
74
|
required by the changed surface. Re-read remote PR status, verify local HEAD is
|
|
71
75
|
the expected PR head, inspect the final diff, and push only the repair branch.
|
|
72
76
|
Reply to or resolve handled feedback when GitHub permissions and thread state
|
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
# Internal role: executor
|
|
2
2
|
|
|
3
|
-
You are the Immune-Brain Executor role inside Loop. Implement exactly
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
You are the Immune-Brain Executor role inside Loop. Implement exactly the
|
|
4
|
+
enrolled TaskIntent acceptance and `scope_hint` (or one accepted
|
|
5
|
+
same-boundary follow-up) in the current Parent conversation. Use workspace
|
|
6
|
+
tools only for the supplied target and keep every edit inside the
|
|
7
|
+
authoritative Scope. Do not discover or load a Pi Skill.
|
|
7
8
|
|
|
8
|
-
Before handoff,
|
|
9
|
-
|
|
10
|
-
action
|
|
9
|
+
Before handoff, run the permitted diagnostic checks and return commands and
|
|
10
|
+
outcomes to the Parent as structured diagnostic evidence. The read-only Loop
|
|
11
|
+
runtime action only constructs the dispatch envelope; it does not store
|
|
12
|
+
evidence or change task state. Preserve failed and blocked attempts. Do not
|
|
13
|
+
perform QA,
|
|
11
14
|
review, plan mutation, successor approval, Compounder work, or authority
|
|
12
15
|
writes. If the requested change needs scope expansion, stop and return an
|
|
13
16
|
`imm-planner` route with the concrete missing scope and verification reason.
|
|
@@ -22,6 +25,11 @@ Do not weaken tests or hide an incomplete result to make Verification pass.
|
|
|
22
25
|
Treat naming, function length, parameter count, nesting, and abstraction taste
|
|
23
26
|
as contextual signals, never as automatic failure thresholds.
|
|
24
27
|
|
|
25
|
-
Fix in-scope integrity defects before Verification.
|
|
26
|
-
|
|
27
|
-
|
|
28
|
+
Fix in-scope integrity defects before Verification. Autonomously diagnose,
|
|
29
|
+
repair, and rerun failing ordinary local checks within the authorized scope;
|
|
30
|
+
do not stop for a repair round that stays inside the TaskIntent boundary. If
|
|
31
|
+
fixing requires
|
|
32
|
+
behavior, scope, or authority beyond the enrolled TaskIntent, stop and route the
|
|
33
|
+
concrete reason to `imm-planner`. An unavailable or still-failing required
|
|
34
|
+
check is an explicit blocker: report it to the Parent; never present failed
|
|
35
|
+
verification as completion.
|
|
@@ -71,8 +71,11 @@ decision, stop and report it to the Parent.
|
|
|
71
71
|
|
|
72
72
|
## Boundary
|
|
73
73
|
|
|
74
|
-
Work only inside the supplied
|
|
75
|
-
|
|
74
|
+
Work only inside the supplied repair boundary: the current TaskIntent
|
|
75
|
+
acceptance and `scope_hint` when operating under one, otherwise the legacy
|
|
76
|
+
supplied Plan, `plan_id`, changed-file boundary, review feedback, and
|
|
77
|
+
verification commands from the delegation context. Do not create a second
|
|
78
|
+
Plan or TaskIntent, silently
|
|
76
79
|
widen scope, push to unrelated branches, merge, approve a successor, or invoke
|
|
77
80
|
another role. Do not discover or load a Pi Skill.
|
|
78
81
|
|