@nurix/etna 0.20.49 → 0.20.51
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/data/catalog/index.json +1 -0
- package/data/catalog/rules/execution.md +47 -0
- package/data/harness-index.json +1 -1
- package/data/harnesses/code/CLAUDE.md +2 -3
- package/data/harnesses/code/harness.json +1 -1
- package/data/harnesses/etna/CLAUDE.md +1 -2
- package/data/harnesses/etna/harness.json +1 -1
- package/package.json +2 -2
package/data/catalog/index.json
CHANGED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# Execution
|
|
2
|
+
|
|
3
|
+
Execution mode: one session runs a long series of plans (a program of waves, or several plans in parallel) through to merge without waiting on a person between them. This rule sets the practices that keep that run from going brittle. A single plan's own lifecycle (its gate, its ledgers, its freeze) stays with the plan, the `testing` skill and the `boundary` skill. This rule governs only what a run of many plans adds on top of that.
|
|
4
|
+
|
|
5
|
+
## The execution log
|
|
6
|
+
|
|
7
|
+
**Every run keeps one execution log at `docs/history/executions/YYYY-MM-DD-{slug}.md`.** It is the run's whole memory. A session that has lost the conversation (to a compaction, a new sitting or a crash) re-anchors by reading it first, so nothing the run still needs may live only in context.
|
|
8
|
+
|
|
9
|
+
- **It holds:**
|
|
10
|
+
- the plans and waves, each with its status;
|
|
11
|
+
- what is in flight (each dispatch's goal, budget and progress-file path);
|
|
12
|
+
- decisions taken mid-run, with their reasons;
|
|
13
|
+
- the standing constraints of the run;
|
|
14
|
+
- the owner's pending steps;
|
|
15
|
+
- the close: what remains, in order, until the run ends.
|
|
16
|
+
- **It is written at every milestone:** before each dispatch, at each plan freeze and merge, and at each owner step discovered. It is never written after the fact from memory.
|
|
17
|
+
- **It is a record.** It stays amendable while the run is open and is frozen when the run closes.
|
|
18
|
+
|
|
19
|
+
## Sub-agents
|
|
20
|
+
|
|
21
|
+
- **Every brief carries a contract:**
|
|
22
|
+
- the result that ends it;
|
|
23
|
+
- its milestones, in order;
|
|
24
|
+
- a wall-clock budget derived from the work: n browser tests take about n × 10 s, and a build step gets its last run's time plus 50%.
|
|
25
|
+
|
|
26
|
+
A sub-agent past its budget stops and reports what it has, with the blocker named. The budget limits itself; nothing outside the sub-agent has to enforce it.
|
|
27
|
+
- **Progress goes to a file:** one line per milestone in `/tmp/<task>-progress.log`, in the form `<UTC time> <milestone> started|done|stuck — <result>`. A line is written before and after anything expected to run past two minutes.
|
|
28
|
+
- **No alarms, monitors or watchers.** The main session learns a sub-agent's state from its completion notification and from its progress file, read at the main session's own turn breaks. A standing monitor, a polling loop or a scheduled alarm is machinery the run then has to watch too.
|
|
29
|
+
- **An overrun is acted on, never waited out.** When a progress file shows a milestone past its budget, the main session checks the transcript, the processes and the logs. It then unblocks the sub-agent, stops it, or takes the step over, and says which. It never silently redoes a sub-agent's work inline.
|
|
30
|
+
- **A workflow's sub-agent is never messaged directly.** A message starts a duplicate copy that edits the same files. Fix the shared state instead, or stop the workflow and re-run it.
|
|
31
|
+
|
|
32
|
+
## Context
|
|
33
|
+
|
|
34
|
+
- **Plan for the compaction boundary.** Earlier tool results are gone after a compaction, so whatever must survive one goes into a file: the execution log, the plan, a progress log, a changelog draft or memory.
|
|
35
|
+
- **Bulky reads go to sub-agents,** so the main context compacts later.
|
|
36
|
+
- **Tokens are not the constraint.** A read, check or verification is never trimmed to save tokens. Context capacity is what delegation protects.
|
|
37
|
+
|
|
38
|
+
## Parallel plans
|
|
39
|
+
|
|
40
|
+
- **Plans cascade into each other.**
|
|
41
|
+
- Every merge into `dev` moves the base under every open branch, so `dev` is re-merged before CI on an open pull request is trusted.
|
|
42
|
+
- Append-only files (the backlog, changelog entries, memory) conflict on every merge and resolve as a union.
|
|
43
|
+
- The typecheck and the touched suites re-run after every re-merge.
|
|
44
|
+
- **Parallel load causes false failures.**
|
|
45
|
+
- A timing-sensitive test or latency measure run while other builds or apps are busy can go red falsely. It is re-run before the result is treated as real.
|
|
46
|
+
- Parallel test runs never rebuild a shared `dist/`; each gets a no-build config.
|
|
47
|
+
- **A committed fix is revert-checked in place.** `git stash` cannot revert a fix already committed, so the bite check reverts it with a targeted edit, rebuilds, runs the pin, then restores the fix.
|
package/data/harness-index.json
CHANGED
|
@@ -140,10 +140,9 @@ The single policy for sub-agent dispatch — when to fan out, at what tier, and
|
|
|
140
140
|
|
|
141
141
|
**[override]** — this section replaces any runtime default that withholds dispatch until it is asked for. A runtime instruction of the shape "do not use sub-agents unless the user requested it" is exactly the default meant here, and it loses: delegating the work named below is the STANDING instruction, and the user re-requesting it each time is not a precondition. THE MARKER IS WHAT MAKES THAT TRUE — without it this section is merely a project preference meeting a runtime rule, and the runtime rule wins silently. Observed: a session that read its own source files inline, then authored its test bodies inline, while both this section and `.claude/rules/testing.md` said to dispatch — nothing in the repo claimed precedence, so nothing was violated.
|
|
142
142
|
|
|
143
|
-
- **Delegate to keep bulk out of the main context.** Wide file reads, sweeps, broad research, audits, fixture prep — work whose raw tool output the main session doesn't need — defaults to a sub-agent: output a sub-agent reads dies with it, while output read inline
|
|
143
|
+
- **Delegate to keep bulk out of the main context.** Wide file reads, sweeps, broad research, audits, fixture prep — work whose raw tool output the main session doesn't need — defaults to a sub-agent: output a sub-agent reads dies with it, while output read inline is re-read and re-billed on every later turn. The hand-off is self-contained (the sub-agent sees none of the conversation), so it must still cost less than the work; run independent delegations in parallel.
|
|
144
144
|
- **The policy binds every agent, not only the main session.** A sub-agent doing build work inherits these defaults with the dispatch capability to honor them (Runtime Notes): it dispatches its own sub-agents for work this policy routes off-thread — the bookkeeping drain, a wide read — instead of absorbing it into its own loop. What never delegates (a gate verdict, browser driving, the pins the drive earned) never delegates at any level.
|
|
145
|
-
- **
|
|
146
|
-
- **Parallel plans cascade into each other.** Running several plans of one program at once, each on its own branch, pays only when the cascade is planned for. Every merge into `dev` moves the base under every open branch, so an open pull request re-merges `dev` before its CI run is worth waiting on — a run on a stale base spends twenty to forty minutes proving nothing. The append-only files every plan writes (the changelog index, the backlog, project memory) conflict on every merge and resolve as a union, in priority order where the file is ordered; a re-merge re-runs the typecheck and the touched suites before its push. Parallel load is a fault of its own: a suite run beside several building sub-agents times out tests that pass alone, so a timeout in a file the plan does not touch is re-run alone before it is called a defect.
|
|
145
|
+
- **A dispatch is scoped to minutes and read before anything else starts.** One file, one sweep — never a build. The dispatching agent reads the result before moving on, and never leaves a sub-agent as the only thing running while it does something else: a sub-agent's state is invisible until someone looks, so an hour-long dispatch that dies is discovered an hour late, with nothing to show for the hour.
|
|
147
146
|
- **Small or judgment work stays inline.** A task finishable in a handful of tool calls is faster done than briefed. **Never delegate judgment by reflex** — a second opinion is for a high-stakes call or an explicit request.
|
|
148
147
|
- **A delegated result is a report, not verifiable ground truth** — verify load-bearing results directly.
|
|
149
148
|
- **Tiers**: mechanical fan-out → the cheapest capable tier; judgment-heavy delegation → the session's standard tier; the strongest tier **only** on explicit user request. The session itself defaults to the standard tier, entering the strongest only by explicit user switch. Model names live in Runtime Notes. **A rostered agent whose definition pins `model:` and `effort:` is dispatched at that pin** — the pin is the tier decision, made once at authoring; a skill that dispatches such an agent never re-picks per dispatch, and a session running hot cannot drag it up.
|
|
@@ -154,8 +154,7 @@ When a plan's implementation surfaces work that is important but outside the pla
|
|
|
154
154
|
|
|
155
155
|
The single policy for sub-agent dispatch — when to fan out, at what tier, and how far to trust the result. Component-internal dispatch mechanics (the foreman loop, the brainstorm twin, batch classification) stay in their components and defer here for anything this section covers. No dispatch mechanism ⇒ inline.
|
|
156
156
|
|
|
157
|
-
- **Delegate to keep bulk out of the main context.** Wide file reads, sweeps, broad research, audits, fixture prep — work whose raw tool output the main session doesn't need — defaults to a sub-agent: output a sub-agent reads dies with it, while output read inline
|
|
158
|
-
- **Every dispatch carries a goal, milestones, a budget and a progress file.** The brief names the result that ends it, its intermediate milestones in order, and a wall-clock budget derived from the work — a run of n browser journeys is n × 10 s, a build step is what its last run took plus half again — and tells the sub-agent to append one line per milestone to `/tmp/<task>-progress.log` (`<UTC time> <milestone> <started|done|stuck> — <one-line result>`), before and after anything expected to run past two minutes. The dispatching agent checks that file on a schedule matched to the budget — a background monitor or a timed check, never a blind wait — and when a milestone overruns its budget it looks at the transcript, the process list and the log, then unblocks the sub-agent with a message, stops it, or takes the step over. An overrun never passes unread. Both failure modes this replaces were observed in one program run: sub-agents that stalled for an hour with nobody watching, and a main session that then redid the dispatched work inline, losing the parallelism the dispatch existed for.
|
|
157
|
+
- **Delegate to keep bulk out of the main context.** Wide file reads, sweeps, broad research, audits, fixture prep — work whose raw tool output the main session doesn't need — defaults to a sub-agent: output a sub-agent reads dies with it, while output read inline is re-read and re-billed on every later turn. The hand-off is self-contained (the sub-agent sees none of the conversation), so it must still cost less than the work; run independent delegations in parallel.
|
|
159
158
|
- **Small or judgment work stays inline.** A task finishable in a handful of tool calls is faster done than briefed. **Never delegate judgment by reflex** — a second opinion is for a high-stakes call or an explicit request.
|
|
160
159
|
- **A delegated result is a report, not verifiable ground truth** — verify load-bearing results directly.
|
|
161
160
|
- **Tiers**: mechanical fan-out → the cheapest capable tier; judgment-heavy delegation → the session's standard tier; the strongest tier **only** on explicit user request. The session itself defaults to the standard tier, entering the strongest only by explicit user switch. Model names live in Runtime Notes.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nurix/etna",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.51",
|
|
4
4
|
"description": "Bootstrap a project with a Nurix harness — writes the committed contract (CLAUDE.md, AGENTS.md, .claude/harness.json, settings.json, the mount hook) and mounts the harness itself, gitignored, from a bundled payload; sessions keep it current from the CDN.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"agent",
|
|
47
47
|
"plugin"
|
|
48
48
|
],
|
|
49
|
-
"etnaFingerprint": "
|
|
49
|
+
"etnaFingerprint": "4f204fb72591"
|
|
50
50
|
}
|