ultimate-pi 0.6.1 → 0.8.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.
Files changed (117) hide show
  1. package/.agents/skills/harness-decisions/SKILL.md +20 -1
  2. package/.agents/skills/harness-eval/SKILL.md +11 -13
  3. package/.agents/skills/harness-orchestration/SKILL.md +36 -30
  4. package/.agents/skills/harness-plan/SKILL.md +13 -14
  5. package/.agents/skills/harness-sentrux-setup/SKILL.md +3 -4
  6. package/.pi/PACKAGING.md +1 -1
  7. package/.pi/agents/harness/adversary.md +20 -12
  8. package/.pi/agents/harness/evaluator.md +25 -14
  9. package/.pi/agents/harness/executor.md +27 -16
  10. package/.pi/agents/harness/incident-recorder.md +37 -0
  11. package/.pi/agents/harness/meta-optimizer.md +18 -15
  12. package/.pi/agents/harness/planner.md +27 -30
  13. package/.pi/agents/harness/tie-breaker.md +4 -2
  14. package/.pi/agents/harness/trace-librarian.md +18 -11
  15. package/.pi/agents/pi-pi/ext-expert.md +1 -1
  16. package/.pi/agents/pi-pi/keybinding-expert.md +1 -1
  17. package/.pi/agents/pi-pi/tui-expert.md +3 -3
  18. package/.pi/extensions/00-ultimate-pi-system-prompt.ts +194 -0
  19. package/.pi/extensions/budget-guard.ts +11 -3
  20. package/.pi/extensions/custom-footer.ts +8 -3
  21. package/.pi/extensions/custom-header.ts +2 -2
  22. package/.pi/extensions/debate-orchestrator.ts +11 -3
  23. package/.pi/extensions/dotenv-loader.ts +1 -1
  24. package/.pi/extensions/drift-monitor.ts +1 -1
  25. package/.pi/extensions/harness-ask-user.ts +1 -1
  26. package/.pi/extensions/harness-live-widget.ts +11 -4
  27. package/.pi/extensions/harness-run-context.ts +745 -0
  28. package/.pi/extensions/harness-telemetry.ts +1 -1
  29. package/.pi/extensions/harness-web-guard.ts +1 -1
  30. package/.pi/extensions/harness-web-tools.ts +1 -1
  31. package/.pi/extensions/lib/ask-user/dialog.ts +2 -2
  32. package/.pi/extensions/lib/ask-user/fallback.ts +1 -1
  33. package/.pi/extensions/lib/ask-user/render.ts +3 -3
  34. package/.pi/extensions/lib/harness-subagents/agent-loader.ts +1 -1
  35. package/.pi/extensions/lib/harness-subagents/agent-parser.ts +1 -1
  36. package/.pi/extensions/lib/harness-subagents/blackboard-tool.ts +1 -1
  37. package/.pi/extensions/lib/harness-subagents/harness-subagent-policy.ts +134 -0
  38. package/.pi/extensions/lib/harness-subagents/vendored/agent-manager.ts +2 -2
  39. package/.pi/extensions/lib/harness-subagents/vendored/agent-runner.ts +9 -5
  40. package/.pi/extensions/lib/harness-subagents/vendored/context.ts +1 -1
  41. package/.pi/extensions/lib/harness-subagents/vendored/env.ts +1 -1
  42. package/.pi/extensions/lib/harness-subagents/vendored/index.ts +2 -2
  43. package/.pi/extensions/lib/harness-subagents/vendored/output-file.ts +1 -1
  44. package/.pi/extensions/lib/harness-subagents/vendored/schedule.ts +1 -1
  45. package/.pi/extensions/lib/harness-subagents/vendored/settings.ts +1 -1
  46. package/.pi/extensions/lib/harness-subagents/vendored/skill-loader.ts +1 -1
  47. package/.pi/extensions/lib/harness-subagents/vendored/types.ts +2 -2
  48. package/.pi/extensions/lib/harness-subagents/vendored/ui/agent-widget.ts +1 -1
  49. package/.pi/extensions/lib/harness-subagents/vendored/ui/conversation-viewer.ts +2 -2
  50. package/.pi/extensions/lib/harness-subagents/vendored/ui/schedule-menu.ts +1 -1
  51. package/.pi/extensions/observation-bus.ts +8 -10
  52. package/.pi/extensions/pi-model-router-harness.ts +1 -1
  53. package/.pi/extensions/policy-gate.ts +136 -84
  54. package/.pi/extensions/provider-payload-sanitize.ts +1 -1
  55. package/.pi/extensions/review-integrity.ts +76 -22
  56. package/.pi/extensions/sentrux-rules-sync.ts +1 -1
  57. package/.pi/extensions/soundboard.ts +1 -1
  58. package/.pi/extensions/test-diff-integrity.ts +1 -1
  59. package/.pi/extensions/trace-recorder.ts +81 -21
  60. package/.pi/extensions/ultimate-pi-vcc.ts +1 -1
  61. package/.pi/harness/README.md +2 -0
  62. package/.pi/harness/agents.manifest.json +17 -13
  63. package/.pi/harness/docs/adrs/0009-sentrux-rules-lifecycle.md +1 -1
  64. package/.pi/harness/docs/adrs/0031-harness-run-context.md +41 -0
  65. package/.pi/harness/docs/adrs/0032-harness-command-orchestration.md +37 -0
  66. package/.pi/harness/docs/adrs/README.md +2 -0
  67. package/.pi/harness/evals/smoke/run-context.fixture.json +17 -0
  68. package/.pi/harness/specs/harness-run-context.schema.json +80 -0
  69. package/.pi/harness/specs/harness-spawn-context.schema.json +65 -0
  70. package/.pi/lib/harness-agent-output.ts +41 -0
  71. package/.pi/lib/harness-run-context.ts +1139 -0
  72. package/.pi/lib/harness-ui-state.ts +12 -1
  73. package/.pi/prompts/harness-abort.md +9 -6
  74. package/.pi/prompts/harness-auto.md +36 -61
  75. package/.pi/prompts/harness-critic.md +17 -32
  76. package/.pi/prompts/harness-eval.md +22 -30
  77. package/.pi/prompts/harness-incident.md +17 -34
  78. package/.pi/prompts/harness-plan.md +32 -36
  79. package/.pi/prompts/harness-review.md +18 -33
  80. package/.pi/prompts/harness-router-tune.md +16 -38
  81. package/.pi/prompts/harness-run.md +23 -40
  82. package/.pi/prompts/harness-setup.md +7 -27
  83. package/.pi/prompts/harness-trace.md +15 -34
  84. package/.pi/scripts/harness-generate-model-router.mjs +16 -13
  85. package/.pi/scripts/harness-verify.mjs +34 -0
  86. package/.pi/scripts/vendor-sync-pi-model-router.sh +10 -10
  87. package/CHANGELOG.md +34 -1
  88. package/README.md +31 -15
  89. package/THIRD_PARTY_NOTICES.md +1 -1
  90. package/package.json +14 -9
  91. package/vendor/pi-model-router/UPSTREAM_PIN.md +1 -1
  92. package/vendor/pi-model-router/extensions/commands.ts +2 -2
  93. package/vendor/pi-model-router/extensions/config.ts +2 -2
  94. package/vendor/pi-model-router/extensions/index.ts +1 -1
  95. package/vendor/pi-model-router/extensions/provider.ts +2 -2
  96. package/vendor/pi-model-router/extensions/routing.ts +2 -2
  97. package/vendor/pi-model-router/extensions/types.ts +1 -1
  98. package/vendor/pi-model-router/extensions/ui.ts +1 -1
  99. package/vendor/pi-model-router/package.json +4 -4
  100. package/vendor/pi-vcc/index.ts +1 -1
  101. package/vendor/pi-vcc/package.json +1 -1
  102. package/vendor/pi-vcc/src/commands/pi-vcc.ts +1 -1
  103. package/vendor/pi-vcc/src/commands/vcc-recall.ts +1 -1
  104. package/vendor/pi-vcc/src/core/content.ts +1 -1
  105. package/vendor/pi-vcc/src/core/load-messages.ts +1 -1
  106. package/vendor/pi-vcc/src/core/normalize.ts +1 -1
  107. package/vendor/pi-vcc/src/core/render-entries.ts +1 -1
  108. package/vendor/pi-vcc/src/core/report.ts +1 -1
  109. package/vendor/pi-vcc/src/core/search-entries.ts +1 -1
  110. package/vendor/pi-vcc/src/core/summarize.ts +1 -1
  111. package/vendor/pi-vcc/src/hooks/before-compact.ts +2 -2
  112. package/vendor/pi-vcc/src/tools/recall.ts +1 -1
  113. package/vendor/pi-vcc/src/types.ts +1 -1
  114. package/vendor/pi-vcc/tests/fixtures.ts +1 -1
  115. package/vendor/pi-vcc/tests/render-entries.test.ts +1 -1
  116. package/vendor/pi-vcc/tests/search-entries.test.ts +1 -1
  117. package/vendor/pi-vcc/tests/support/load-session.ts +2 -2
@@ -1,60 +1,43 @@
1
1
  ---
2
2
  description: Execute only against an approved PlanPacket with strict phase gates.
3
- argument-hint: "--plan <path-to-plan-packet.json> [--budget <amount>]"
3
+ argument-hint: "[--budget <amount>]"
4
4
  ---
5
5
 
6
6
  # harness-run
7
7
 
8
- Execute implementation only after an approved plan exists.
8
+ Orchestrator only spawn `harness/executor`. Do **not** implement inline.
9
9
 
10
10
  ## Step 0 — Parse arguments
11
11
 
12
- Read `$ARGUMENTS` and parse:
13
-
14
- - required: `--plan <path-to-plan-packet.json>`
15
12
  - optional: `--budget <amount>`
13
+ - Do **not** use `--plan` on happy path — load from `[HarnessActivePlan]` / `plan_packet_path`.
16
14
 
17
- If `--plan` is missing, stop and return:
18
-
19
- `Usage: /harness-run --plan <path-to-plan-packet.json> [--budget <amount>]`
20
-
21
- ## Process
22
-
23
- 1. Validate `--plan` input and confirm it is a valid approved `PlanPacket`.
24
- 2. Execute only within approved scope.
25
- 3. Run focused validations mapped to approved acceptance checks.
26
- 4. Produce rollback artifacts and handoff references for downstream gates.
27
-
28
- ## Required input
29
-
30
- - `--plan` must point to a valid `PlanPacket`.
15
+ If plan not ready:
31
16
 
32
- ## Gate behavior
17
+ `Run /harness-plan first — no approved plan in active run context.`
33
18
 
34
- - Refuse execution if no valid plan packet is provided.
35
- - Keep edits strictly within approved scope.
36
- - If scope drift appears, stop and return to `harness-plan`.
37
- - For **implementation forks** inside approved scope, call `ask_user` with 2–4 options. For plan-level ambiguity, stop and return to `harness-plan`.
38
- - Record evaluator/adversary prerequisites for downstream gates.
39
- - Always prepare rollback artifacts as part of execution output.
19
+ ## Orchestration (required)
40
20
 
41
- ## Guardrails
21
+ 1. Confirm `[HarnessActivePlan]` / extension reports plan ready.
22
+ 2. Build `HarnessSpawnContext` with `mode: execute`, `plan_packet_path`, `run_dir`, `acceptance_checks` from plan file.
23
+ 3. Spawn:
42
24
 
43
- - Do not overthink straightforward approved changes; execute the approved scope directly.
44
- - Only modify files and behaviors covered by the approved `PlanPacket`.
45
- - Never speculate about successful validation without runnable evidence.
25
+ ```
26
+ Agent({ subagent_type: "harness/executor", prompt: "<HarnessSpawnContext + handoff>" })
27
+ ```
46
28
 
47
- ## Output
29
+ 4. `get_subagent_result` — parse executor JSON (`execution_status`, validations, rollback refs).
30
+ 5. Parent persists trace/handoff artifacts under run dir if needed; do not self-review.
48
31
 
49
- - Implementation summary scoped to approved plan.
50
- - Files changed and why.
51
- - Targeted validations run.
52
- - Trace pointers and rollback references.
32
+ ## Parent rules
53
33
 
54
- ## Completion behavior
34
+ - Refuse if plan not approved.
35
+ - On `scope_drift`, stop and recommend `/harness-plan`.
36
+ - Do not call `ask_user` for plan-level ambiguity — return to plan command.
55
37
 
56
- End with:
38
+ ## Completion
57
39
 
58
- 1. `execution_status` (`completed`, `blocked`, or `scope_drift`).
59
- 2. `validation_summary` (pass/fail with command evidence).
60
- 3. `handoff_ready` booleans for evaluator/adversary prerequisites.
40
+ - `execution_status`: `completed`, `blocked`, or `scope_drift`
41
+ - `validation_summary` with command evidence
42
+ - `handoff_ready` for evaluator/adversary
43
+ - `next_command`: `/harness-eval` (same session — spawn isolated review agents; no new Pi session)
@@ -17,7 +17,7 @@ Bootstraps the complete ultimate-pi agentic harness: Graphify knowledge graph, C
17
17
  | Provider detection from `OPENAI_*` / `ANTHROPIC_*` env only | Wrong for pi users — keys live in `~/.pi/agent/auth.json`. Use `harness-generate-model-router.mjs` (Pi `ModelRegistry.getAvailable()`). |
18
18
  | Re-running 2.1–2.8 manually after CLI verify | Wasteful — trust `harness-cli-verify.sh` output; only fix reported ✗ lines. |
19
19
  | Overwriting `AGENTS.md` after graphify | Graphify appends a section — **merge**, do not replace (Step 4.3). |
20
- | `sentrux-rules-sync` without project manifest | Use **`harness-sentrux-bootstrap.mjs`** (Step 4.4) — seeds manifest + idempotent rules sync. |
20
+ | `sentrux-rules-sync` without project manifest | Use **`harness-sentrux-bootstrap.mjs`** (Step 4.2) — seeds manifest + idempotent rules sync. |
21
21
  | Re-running bootstrap with `--force` on unchanged manifest | Wasteful but safe — default bootstrap skips when hash unchanged; `--force` only after manifest edits. |
22
22
  | `graph.json` uses `links`, not `edges` | Step 6 stats: `g.get('edges', g.get('links', []))`. |
23
23
  | Guessing harness-web / `.env` defaults when `ask_user` is available | **Mandatory `ask_user`** at Step 4.0 unless `--non-interactive`. |
@@ -319,7 +319,7 @@ Install all 52 language plugins:
319
319
  sentrux plugin add-standard 2>/dev/null || echo "Plugins already installed or failed"
320
320
  ```
321
321
 
322
- Ensure the **sentrux** Pi skill is linked (see Step 4.2). **Rules.toml bootstrap runs in Step 4.3** (idempotent, merge-safe).
322
+ **Rules.toml bootstrap runs in Step 4.2** (idempotent, merge-safe). Sentrux CLI workflows use the package **`sentrux`** skill (`.agents/skills/sentrux`); no symlink into `.pi/skills/` required.
323
323
 
324
324
  ## Step 3 — Pi Extension Packages
325
325
 
@@ -385,6 +385,8 @@ Manual override: **`/router profile auto`** anytime after reload if they changed
385
385
 
386
386
  `harness-subagents` loads agents from the installed **`ultimate-pi`** package (`$UP_PKG/.pi/agents/**`) with namespaced ids (`harness/planner`, `pi-pi/agent-expert`). **Do not copy** agents into the project unless you want a deliberate override.
387
387
 
388
+ **Slash commands are orchestrators:** `/harness-plan`, `/harness-run`, etc. spawn `harness/*` agents via the `Agent` tool — bootstrap stays **script-first**; only optionally spawn `harness/sentrux-bootstrap` for Sentrux (see Step 4.2).
389
+
388
390
  Optional per-repo overrides: place `.md` files at the **same relative path** (e.g. `.pi/agents/harness/planner.md` overrides the package planner).
389
391
 
390
392
  Verify manifest drift after `pi update ultimate-pi`:
@@ -496,29 +498,7 @@ Ensure `.gitignore` contains:
496
498
  !.sentrux/rules.toml
497
499
  ```
498
500
 
499
- ### 4.2 — Sentrux Pi skill
500
-
501
- Pi does **not** load `.pi/mcp.json`. Agents use Sentrux via the **CLI** and the **`sentrux`** skill.
502
-
503
- From **project root**, ensure the skill is discoverable (idempotent):
504
-
505
- ```bash
506
- UP_PKG="$(node -p "require('path').dirname(require.resolve('ultimate-pi/package.json'))")"
507
- SKILL_SRC="$UP_PKG/.agents/skills/sentrux"
508
- SKILL_DST=".pi/skills/sentrux"
509
- if [ -d "$SKILL_SRC" ] && [ ! -e "$SKILL_DST" ]; then
510
- ln -s "../../.agents/skills/sentrux" "$SKILL_DST"
511
- echo "✓ linked $SKILL_DST → sentrux skill"
512
- elif [ -e "$SKILL_DST" ]; then
513
- echo "✓ sentrux skill already present at $SKILL_DST"
514
- else
515
- echo "✗ missing $SKILL_SRC — reinstall ultimate-pi"
516
- fi
517
- ```
518
-
519
- After `/reload`, agents can invoke **`/skill:sentrux`** for install paths, `sentrux check`, `sentrux gate --save` / `sentrux gate`, and harness integration. **context-mode** remains a separate `npm:context-mode` package in `.pi/settings.json` (its own MCP bridge inside that extension).
520
-
521
- ### 4.3 — Sentrux rules bootstrap (required)
501
+ ### 4.2 — Sentrux rules bootstrap (required)
522
502
 
523
503
  **Skill:** invoke **harness-sentrux-setup** before hand-editing rules or manifest.
524
504
 
@@ -552,7 +532,7 @@ Set up structural regression baseline (optional):
552
532
  sentrux gate --save . 2>/dev/null || echo "Baseline will be saved on first gate run"
553
533
  ```
554
534
 
555
- ### 4.4 — Project AGENTS.md
535
+ ### 4.3 — Project AGENTS.md
556
536
 
557
537
  **Do not overwrite** an existing `AGENTS.md` — graphify bootstrap may have appended a `## Graphify` section. If missing, create minimal onboarding content; if present, only add harness subsections that are absent.
558
538
 
@@ -681,7 +661,7 @@ Output summary table:
681
661
  | biome | ✓/✗ | Project config: found/default |
682
662
  | ast-grep | ✓/✗ | AST-aware code search (`sg`)
683
663
  | gh CLI | ✓/✗ | Auth: yes/no |
684
- | sentrux | ✓/✗ | CLI + plugins; rules via Step 4.3 bootstrap |
664
+ | sentrux | ✓/✗ | CLI + plugins; rules via Step 4.2 bootstrap |
685
665
  | Sentrux rules.toml | ✓/✗ | `.sentrux/rules.toml` synced from manifest |
686
666
  | pi extensions | ✓/✗ | 4 packages |
687
667
  | model router | ✓/✗ | Package + config verified, activation via `/router profile auto` |
@@ -1,51 +1,32 @@
1
1
  ---
2
2
  description: Query and summarize harness run traces for replay and forensics.
3
- argument-hint: "--run <run-id> [--phase plan|execute|evaluate|adversary|merge]"
3
+ argument-hint: "[--run <run-id>] [--phase plan|execute|evaluate|adversary|merge]"
4
4
  ---
5
5
 
6
6
  # harness-trace
7
7
 
8
- Retrieve and summarize trace artifacts for a run.
8
+ Orchestrator spawn `harness/trace-librarian`.
9
9
 
10
10
  ## Step 0 — Parse arguments
11
11
 
12
- Read `$ARGUMENTS` and parse:
13
-
14
- - required: `--run <run-id>`
12
+ - optional: `--run <run-id>` (recovery only)
15
13
  - optional: `--phase plan|execute|evaluate|adversary|merge`
16
14
 
17
- If `--run` is missing, stop and return:
18
-
19
- `Usage: /harness-trace --run <run-id> [--phase plan|execute|evaluate|adversary|merge]`
20
-
21
- ## Process
22
-
23
- 1. Collect run artifacts from canonical harness locations and provided trace refs.
24
- 2. Build phase timeline with policy and gate decision points.
25
- 3. Report completeness gaps against strict gate artifact requirements.
26
-
27
- ## Requirements
28
-
29
- - Use `.pi/harness/runs/` and external trace references as source of truth pointers.
30
- - Include phase timeline, artifact refs, and policy decisions.
31
- - Highlight missing artifacts that violate strict gate requirements.
32
-
33
- ## Guardrails
15
+ Happy path: omit `--run`.
34
16
 
35
- - Do not overthink simple trace lookups; prioritize completeness and stable references.
36
- - Only report artifacts for the requested run and optional phase filter.
37
- - Never infer artifact existence without verifying source pointers.
17
+ ## Orchestration (required)
38
18
 
39
- ## Output
19
+ 1. Build `HarnessSpawnContext` with `mode: trace`, `run_dir`, optional phase filter.
20
+ 2. Spawn:
40
21
 
41
- - Replay-ready timeline summary.
42
- - Artifact index (`plan`, `run`, `eval`, `adversary`, `consensus`, `incident`, `rollback`).
43
- - Any integrity or completeness gaps.
22
+ ```
23
+ Agent({ subagent_type: "harness/trace-librarian", prompt: "…" })
24
+ ```
44
25
 
45
- ## Completion behavior
26
+ 3. `get_subagent_result` — present timeline and artifact index to user.
46
27
 
47
- Always end with:
28
+ ## Completion
48
29
 
49
- - `trace_completeness` (`complete` or `incomplete`)
50
- - missing artifact checklist (if any)
51
- - most likely next command (`/harness-incident`, `/harness-review`, or `/harness-critic`)
30
+ - `trace_completeness`: `complete` or `incomplete`
31
+ - Missing artifact checklist
32
+ - `next_command` hint (`/harness-incident`, `/harness-review`, or `/harness-critic`)
@@ -3,13 +3,13 @@
3
3
  * Generate `.pi/model-router.json` from Pi's authenticated providers (auth.json + env),
4
4
  * not from raw env-var heuristics alone.
5
5
  *
6
- * Uses @mariozechner/pi-coding-agent ModelRegistry.getAvailable() — same source as /login.
6
+ * Uses @earendil-works/pi-coding-agent ModelRegistry.getAvailable() — same source as /login.
7
7
  *
8
8
  * Usage: node harness-generate-model-router.mjs [--force] [--dry-run]
9
9
  * --force overwrite existing .pi/model-router.json
10
10
  * --dry-run print JSON to stdout, do not write
11
11
  *
12
- * Requires @mariozechner/pi-coding-agent (peer of ultimate-pi; bundled with pi).
12
+ * Requires @earendil-works/pi-coding-agent (peer of ultimate-pi; bundled with pi).
13
13
  */
14
14
 
15
15
  import { existsSync, mkdirSync, writeFileSync } from "node:fs";
@@ -66,26 +66,29 @@ function fail(msg) {
66
66
  }
67
67
 
68
68
  async function loadPiCodingAgent() {
69
- const agentRoots = [
70
- join(UP_PKG, "node_modules", "@mariozechner", "pi-coding-agent"),
71
- join(UP_PKG, ".pi", "npm", "node_modules", "@mariozechner", "pi-coding-agent"),
72
- ];
69
+ const scopes = ["@earendil-works", "@mariozechner"];
70
+ const agentRoots = scopes.flatMap((scope) => [
71
+ join(UP_PKG, "node_modules", scope, "pi-coding-agent"),
72
+ join(UP_PKG, ".pi", "npm", "node_modules", scope, "pi-coding-agent"),
73
+ ]);
73
74
  for (const root of agentRoots) {
74
75
  const entry = join(root, "dist", "index.js");
75
76
  if (existsSync(entry)) {
76
77
  return import(pathToFileURL(entry).href);
77
78
  }
78
79
  }
79
- for (const base of [UP_PKG, process.cwd()]) {
80
- try {
81
- const req = createRequire(join(base, "package.json"));
82
- return req("@mariozechner/pi-coding-agent");
83
- } catch {
84
- /* try next */
80
+ for (const spec of ["@earendil-works/pi-coding-agent", "@mariozechner/pi-coding-agent"]) {
81
+ for (const base of [UP_PKG, process.cwd()]) {
82
+ try {
83
+ const req = createRequire(join(base, "package.json"));
84
+ return req(spec);
85
+ } catch {
86
+ /* try next */
87
+ }
85
88
  }
86
89
  }
87
90
  fail(
88
- "@mariozechner/pi-coding-agent not found (install pi or npm i in ultimate-pi). Peer: @mariozechner/pi-coding-agent",
91
+ "@earendil-works/pi-coding-agent not found (install pi or npm i in ultimate-pi). Peer: @earendil-works/pi-coding-agent",
89
92
  );
90
93
  }
91
94
 
@@ -16,10 +16,12 @@ const ADRS = join(ROOT, ".pi", "harness", "docs", "adrs");
16
16
 
17
17
  const REQUIRED_SCHEMAS = [
18
18
  "harness-run-record.schema.json",
19
+ "harness-run-context.schema.json",
19
20
  "harness-posthog-event.schema.json",
20
21
  "observation.schema.json",
21
22
  "run-trace.schema.json",
22
23
  "eval-verdict.schema.json",
24
+ "harness-spawn-context.schema.json",
23
25
  ];
24
26
 
25
27
  const REQUIRED_ADRS = [
@@ -32,10 +34,13 @@ const REQUIRED_ADRS = [
32
34
  "0007-interactive-drift-monitor.md",
33
35
  "0008-harness-posthog-telemetry.md",
34
36
  "0009-sentrux-rules-lifecycle.md",
37
+ "0031-harness-run-context.md",
38
+ "0032-harness-command-orchestration.md",
35
39
  ];
36
40
 
37
41
  const REQUIRED_EXTENSIONS = [
38
42
  "harness-telemetry.ts",
43
+ "harness-run-context.ts",
39
44
  "trace-recorder.ts",
40
45
  "observation-bus.ts",
41
46
  "drift-monitor.ts",
@@ -192,6 +197,35 @@ async function main() {
192
197
  if (!(await fileExists(libPath))) fail("missing lib/harness-posthog.ts");
193
198
  ok("lib/harness-posthog.ts");
194
199
 
200
+ const runCtxLib = join(ROOT, ".pi", "lib", "harness-run-context.ts");
201
+ if (!(await fileExists(runCtxLib))) fail("missing lib/harness-run-context.ts");
202
+ ok("lib/harness-run-context.ts");
203
+
204
+ const policyGateSrc = await readFile(
205
+ join(ROOT, ".pi", "extensions", "policy-gate.ts"),
206
+ "utf-8",
207
+ );
208
+ if (!policyGateSrc.includes("isPlanPhaseAllowedMutation")) {
209
+ fail(
210
+ "policy-gate.ts must use isPlanPhaseAllowedMutation (plan-phase scoped writes)",
211
+ );
212
+ }
213
+ if (!policyGateSrc.includes('pi.on("tool_call", async (event, ctx)')) {
214
+ fail("policy-gate tool_call must receive ctx for run context");
215
+ }
216
+ ok("policy-gate plan-phase writes");
217
+
218
+ const runCtxFixture = join(SMOKE, "run-context.fixture.json");
219
+ if (!(await fileExists(runCtxFixture))) {
220
+ fail("missing run-context.fixture.json");
221
+ }
222
+ const runCtxData = JSON.parse(await readFile(runCtxFixture, "utf-8"));
223
+ if (runCtxData.schema_version !== "1.0.0") {
224
+ fail("run-context fixture schema_version must be 1.0.0");
225
+ }
226
+ if (!runCtxData.run_id) fail("run-context fixture missing run_id");
227
+ ok("run-context.fixture.json");
228
+
195
229
  const fixture = JSON.parse(
196
230
  await readFile(join(SMOKE, "run-record.fixture.json"), "utf-8"),
197
231
  );
@@ -11,19 +11,19 @@ rm -rf "$VEND/.git"
11
11
 
12
12
  for f in "$VEND"/extensions/*.ts; do
13
13
  sed -i \
14
- -e "s|'@earendil-works/pi-agent-core'|'@mariozechner/pi-agent-core'|g" \
15
- -e "s|'@earendil-works/pi-ai'|'@mariozechner/pi-ai'|g" \
16
- -e "s|'@earendil-works/pi-coding-agent'|'@mariozechner/pi-coding-agent'|g" \
17
- -e "s|'@earendil-works/pi-tui'|'@mariozechner/pi-tui'|g" \
14
+ -e "s|'@earendil-works/pi-agent-core'|'@earendil-works/pi-agent-core'|g" \
15
+ -e "s|'@earendil-works/pi-ai'|'@earendil-works/pi-ai'|g" \
16
+ -e "s|'@earendil-works/pi-coding-agent'|'@earendil-works/pi-coding-agent'|g" \
17
+ -e "s|'@earendil-works/pi-tui'|'@earendil-works/pi-tui'|g" \
18
18
  "$f"
19
19
  done
20
20
 
21
- # Align package.json peers with @mariozechner (upstream lists @earendil-works)
21
+ # Align package.json peers with @earendil-works (upstream lists @earendil-works)
22
22
  sed -i \
23
- -e 's|"@earendil-works/pi-agent-core"|"@mariozechner/pi-agent-core"|g' \
24
- -e 's|"@earendil-works/pi-ai"|"@mariozechner/pi-ai"|g' \
25
- -e 's|"@earendil-works/pi-coding-agent"|"@mariozechner/pi-coding-agent"|g' \
26
- -e 's|"@earendil-works/pi-tui"|"@mariozechner/pi-tui"|g' \
23
+ -e 's|"@earendil-works/pi-agent-core"|"@earendil-works/pi-agent-core"|g' \
24
+ -e 's|"@earendil-works/pi-ai"|"@earendil-works/pi-ai"|g' \
25
+ -e 's|"@earendil-works/pi-coding-agent"|"@earendil-works/pi-coding-agent"|g' \
26
+ -e 's|"@earendil-works/pi-tui"|"@earendil-works/pi-tui"|g' \
27
27
  "$VEND/package.json"
28
28
 
29
29
  python3 -c "
@@ -40,7 +40,7 @@ cat >"$VEND/UPSTREAM_PIN.md" <<EOF
40
40
  - **Repository:** https://github.com/yeliu84/pi-model-router
41
41
  - **License:** MIT (\`LICENSE\` in this tree)
42
42
  - **Pinned upstream commit:** \`$COMMIT\`
43
- - **Local changes:** \`extensions/*.ts\` imports use \`@mariozechner/*\` and relative paths end in \`.js\` for TypeScript nodenext.
43
+ - **Local changes:** \`extensions/*.ts\` imports use \`@earendil-works/*\` and relative paths end in \`.js\` for TypeScript nodenext.
44
44
  EOF
45
45
 
46
46
  rm -f "$VEND/package-lock.json"
package/CHANGELOG.md CHANGED
@@ -4,6 +4,39 @@ All notable changes to this project are documented in this file.
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [v0.8.0] — 2026-05-17
8
+
9
+ ### ✨ Features
10
+
11
+ - **Harness command orchestration:** slash prompts spawn `harness/*` agents with required `HarnessSpawnContext`; subagent tool policy; L4 review via isolated subagents (not session fork); ADR 0032.
12
+
13
+ ### 🐛 Fixes
14
+
15
+ - **Policy gate / harness-plan:** allow scoped writes to `plan-packet.json` in plan phase after `ask_user` approval; block project source edits until execute; promote `/harness-auto` to execute phase mid-turn after approved plan write.
16
+
17
+ ### 📖 Documentation
18
+
19
+ - **Harness plan workflow:** present full plan → Approve via `ask_user` → persist packet; `--quick` does not skip approval (ADR 0031).
20
+
21
+ ### 🔧 Chores
22
+
23
+ - **pi-coding-agent:** migrate peer/dev deps to `@earendil-works/pi-coding-agent` 0.74.1.
24
+
25
+ ## [v0.7.0] — 2026-05-17
26
+
27
+ ### ✨ Features
28
+
29
+ - **Harness run context:** track active run and canonical plan path in session; short slash commands without `--run` or `--plan`; project `active-run.json` for forked eval sessions; ADR 0031.
30
+ - **System prompt extension:** load packaged `.pi/SYSTEM.md` by default with optional workspace `.pi/system.md` override.
31
+
32
+ ### 📖 Documentation
33
+
34
+ - **README and harness prompts:** manual workflow without run IDs; `harness-run-status`, `harness-new-run`, `harness-use-run` helpers.
35
+
36
+ ### 🔧 Chores
37
+
38
+ - **harness-setup:** remove Sentrux skill symlink step; rules bootstrap only.
39
+
7
40
  ## [v0.6.1] — 2026-05-17
8
41
 
9
42
  ### 🐛 Fixes
@@ -95,7 +128,7 @@ All notable changes to this project are documented in this file.
95
128
 
96
129
  - Remove `npm:@yeliu84/pi-model-router` from package dependencies; add `THIRD_PARTY_NOTICES.md`
97
130
  - `harness-sync-model-router.mjs` adjusts Pi defaults only (no package toggling)
98
- - `check:ts` uses ES2023; devDependency on `@mariozechner/pi-ai`, `pi-tui`, `pi-agent-core` for vendored typecheck
131
+ - `check:ts` uses ES2023; devDependency on `@earendil-works/pi-ai`, `pi-tui`, `pi-agent-core` for vendored typecheck
99
132
 
100
133
  ### 🐛 Fixes
101
134
 
package/README.md CHANGED
@@ -29,11 +29,12 @@ pi install npm:ultimate-pi
29
29
 
30
30
  That runs: plan → execute → evaluate → adversary → policy decision. It does **not** auto-merge.
31
31
 
32
- If something blocks, inspect the last run:
32
+ If something blocks, inspect status (no run id needed):
33
33
 
34
34
  ```text
35
- /harness-trace-last
35
+ /harness-run-status
36
36
  /harness-policy-status
37
+ /harness-trace-last
37
38
  ```
38
39
 
39
40
  ## Commands
@@ -42,15 +43,18 @@ If something blocks, inspect the last run:
42
43
  |---------|----------------|
43
44
  | `/harness-setup` | One-time project bootstrap (tools, harness dirs, extensions) |
44
45
  | `/harness-auto "<task>"` | End-to-end pipeline (recommended) |
45
- | `/harness-plan "<task>"` | Plan only (no code changes) |
46
- | `/harness-run --plan <file>` | Execute an approved plan |
47
- | `/harness-eval --run <run-id>` | Evaluation summary |
48
- | `/harness-review --run <run-id>` | Independent review verdict |
49
- | `/harness-critic --run <run-id>` | Adversarial review |
50
- | `/harness-trace --run <run-id>` | Full trace for a run |
51
- | `/harness-trace-last` | Summary of the most recent run |
46
+ | `/harness-plan "<task>"` | Create or **revise** the active plan in context (no plan path to copy) |
47
+ | `/harness-run` | Execute the active plan from context (**no `--plan`** on happy path) |
48
+ | `/harness-eval` | Eval for active run (optional `--run`; spawns isolated `harness/evaluator`) |
49
+ | `/harness-review` | Independent review (optional `--run`) |
50
+ | `/harness-critic` | Adversarial review (optional `--run`) |
51
+ | `/harness-trace` | Trace summary (optional `--run`) |
52
+ | `/harness-run-status` | Where you are + what to run next (no run id shown) |
53
+ | `/harness-new-run` | Abandon current run and start fresh |
54
+ | `/harness-use-run <id>` | Advanced recovery only |
55
+ | `/harness-trace-last` | Last phase / handoff (no run id) |
52
56
  | `/harness-policy-status` | Current policy / block reasons |
53
- | `/harness-abort [reason]` | Stop and return to plan-only mode |
57
+ | `/harness-abort [reason]` | Stop and replan path |
54
58
 
55
59
  ## Manual workflow
56
60
 
@@ -58,15 +62,23 @@ Use this when you want each step separate:
58
62
 
59
63
  ```text
60
64
  /harness-plan "your task"
61
- /harness-run --plan .pi/harness/runs/<run-id>/plan-packet.json
62
- /harness-eval --run <run-id>
63
- /harness-review --run <run-id>
64
- /harness-critic --run <run-id>
65
+ /harness-run
66
+ /harness-eval
67
+ /harness-review
68
+ /harness-critic
65
69
  ```
66
70
 
71
+ The harness **remembers the active run and plan** per project — you do not pass `plan-packet.json` paths or run ids between steps. The live widget shows phase/policy; after each step the agent (and UI notify) suggests the next command.
72
+
73
+ Recovery: `--run` and `--plan` remain for scripts; `/harness-use-run` and `/harness-run-status` for operators.
74
+
67
75
  ## Defaults you should know
68
76
 
77
+ - **System prompt** — [`.pi/extensions/00-ultimate-pi-system-prompt.ts`](.pi/extensions/00-ultimate-pi-system-prompt.ts) sets the base prompt from packaged [`.pi/SYSTEM.md`](.pi/SYSTEM.md), or from your workspace override **`.pi/system.md`** (lowercase) if you create one. Nothing is copied into your project by default. After upgrading the package or editing either file, run **`/reload`**.
69
78
  - **Model routing (vendored + gated)** — [`pi-model-router`](https://github.com/yeliu84/pi-model-router) ships inside this package (`vendor/pi-model-router/`). [`.pi/extensions/pi-model-router-harness.ts`](.pi/extensions/pi-model-router-harness.ts) activates it **only after** `.pi/model-router.json` exists (generation: `/harness-setup` Step 3.5), so **`router/auto` does not appear** beforehand. See [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md). [`.pi/scripts/harness-sync-model-router.mjs`](.pi/scripts/harness-sync-model-router.mjs) may set **`defaultProvider`/`defaultModel`** to **`router`/`auto`** when the project sets no default — run **`/reload`** afterward. Do **not** add `npm:@yeliu84/pi-model-router` to `.pi/settings.json`; it duplicates the fork. Maintainer refresh: **`npm run vendor:sync-router`**.
79
+ - **Active run + plan context** — PlanPacket lives at a fixed path per run; the extension injects it for `/harness-plan` (revise) and `/harness-run` (execute). Session state plus `.pi/harness/active-run.json`; no run ids or plan paths to copy.
80
+ - **Review isolation** — `/harness-eval`, `/harness-review`, and `/harness-critic` spawn isolated subagents (`inherit_context: false`); stay in the same session (see ADR 0032).
81
+ - **Concurrent plans** — a second `/harness-plan` while a run is active is blocked until `/harness-abort` or `/harness-new-run` (except drift replan / amend after `needs_clarification`).
70
82
  - **Plan before mutate** — write/edit/shell that changes the repo is blocked until execute phase.
71
83
  - **No auto-merge** — you decide when to open or merge a PR.
72
84
  - **Structured runs** — each run writes artifacts under `.pi/harness/runs/` for replay and audit.
@@ -78,7 +90,11 @@ Optional: copy [`.env.example`](.env.example) to `.env` if you use PostHog or ot
78
90
  | Problem | Try |
79
91
  |---------|-----|
80
92
  | Setup fails | `node --version` (need 18+), rerun `/harness-setup` |
81
- | Blocked in evaluate/review | Run review in a fresh session (isolation from execute) |
93
+ | "No active run" on eval | Finish plan+run first, or `/harness-run-status` |
94
+ | Forgot where you left off | `/harness-run-status` |
95
+ | Second plan rejected | `/harness-abort` or `/harness-new-run` |
96
+ | Blocked in evaluate/review | Spawn review via Agent (`harness/evaluator` / `harness/adversary`); do not run review tools inline in execute phase |
97
+ | High plan drift | `harness-drift-replan` or abort then replan (ADR 0007) |
82
98
  | Budget / scope stop | `/harness-budget-status`, narrow the task or split the plan |
83
99
  | Test integrity warning | `/harness-test-integrity-last`, fix or justify test changes |
84
100
 
@@ -5,7 +5,7 @@
5
5
  - **Project:** https://github.com/yeliu84/pi-model-router
6
6
  - **License:** MIT ([vendor/pi-model-router/LICENSE](vendor/pi-model-router/LICENSE))
7
7
  - **Pinned revision:** See [vendor/pi-model-router/UPSTREAM_PIN.md](vendor/pi-model-router/UPSTREAM_PIN.md)
8
- - ultimate-pi loads it from [`vendor/pi-model-router`](vendor/pi-model-router); import specifiers were adapted for `@mariozechner/pi-coding-agent` and related Pi packages.
8
+ - ultimate-pi loads it from [`vendor/pi-model-router`](vendor/pi-model-router); import specifiers were adapted for `@earendil-works/pi-coding-agent` and related Pi packages.
9
9
 
10
10
  ## pi-vcc (vendored)
11
11
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ultimate-pi",
3
- "version": "0.6.1",
3
+ "version": "0.8.0",
4
4
  "description": "Ultimate AI coding harness for pi.dev — extensible skills, Obsidian wiki knowledge layer, compressed context, deterministic output",
5
5
  "keywords": [
6
6
  "pi-package",
@@ -70,10 +70,10 @@
70
70
  "vendor/pi-vcc"
71
71
  ],
72
72
  "peerDependencies": {
73
- "@mariozechner/pi-coding-agent": "*"
73
+ "@earendil-works/pi-coding-agent": "*"
74
74
  },
75
75
  "scripts": {
76
- "check:ts": "tsc --noEmit --target ES2023 --lib ES2023 --moduleResolution nodenext --module nodenext --skipLibCheck .pi/extensions/lib/harness-vcc-settings.ts .pi/extensions/dotenv-loader.ts .pi/extensions/lib/posthog-node.d.ts .pi/extensions/lib/harness-posthog.ts .pi/extensions/lib/harness-paths.ts .pi/extensions/pi-model-router-harness.ts .pi/extensions/provider-payload-sanitize.ts .pi/extensions/harness-telemetry.ts .pi/extensions/harness-ask-user.ts .pi/extensions/lib/ask-user/schema.ts .pi/extensions/lib/ask-user/types.ts .pi/extensions/lib/ask-user/validate.ts .pi/extensions/lib/ask-user/dialog.ts .pi/extensions/lib/ask-user/fallback.ts .pi/extensions/lib/ask-user/render.ts .pi/extensions/trace-recorder.ts .pi/extensions/observation-bus.ts .pi/extensions/drift-monitor.ts .pi/extensions/sentrux-rules-sync.ts .pi/extensions/custom-header.ts .pi/extensions/lib/harness-subagents/agent-loader.ts .pi/extensions/lib/harness-subagents/agent-parser.ts .pi/extensions/lib/harness-subagents/agent-manifest.ts .pi/extensions/lib/harness-subagents/blackboard.ts .pi/extensions/lib/harness-subagents/blackboard-tool.ts .pi/extensions/lib/harness-subagents/spawn-policy.ts .pi/extensions/lib/harness-subagents/types-blackboard.ts .pi/extensions/harness-web-tools.ts .pi/extensions/harness-web-guard.ts .pi/extensions/lib/harness-web/run-cli.ts",
76
+ "check:ts": "tsc --noEmit --target ES2023 --lib ES2023 --moduleResolution nodenext --module nodenext --skipLibCheck .pi/extensions/00-ultimate-pi-system-prompt.ts .pi/lib/harness-run-context.ts .pi/lib/harness-ui-state.ts .pi/extensions/harness-run-context.ts .pi/extensions/lib/harness-vcc-settings.ts .pi/extensions/dotenv-loader.ts .pi/extensions/lib/posthog-node.d.ts .pi/extensions/lib/harness-posthog.ts .pi/extensions/lib/harness-paths.ts .pi/extensions/pi-model-router-harness.ts .pi/extensions/provider-payload-sanitize.ts .pi/extensions/harness-telemetry.ts .pi/extensions/harness-ask-user.ts .pi/extensions/lib/ask-user/schema.ts .pi/extensions/lib/ask-user/types.ts .pi/extensions/lib/ask-user/validate.ts .pi/extensions/lib/ask-user/dialog.ts .pi/extensions/lib/ask-user/fallback.ts .pi/extensions/lib/ask-user/render.ts .pi/extensions/trace-recorder.ts .pi/extensions/observation-bus.ts .pi/extensions/drift-monitor.ts .pi/extensions/policy-gate.ts .pi/extensions/budget-guard.ts .pi/extensions/debate-orchestrator.ts .pi/extensions/harness-live-widget.ts .pi/extensions/sentrux-rules-sync.ts .pi/extensions/custom-header.ts .pi/extensions/lib/harness-subagents/agent-loader.ts .pi/extensions/lib/harness-subagents/agent-parser.ts .pi/extensions/lib/harness-subagents/agent-manifest.ts .pi/extensions/lib/harness-subagents/blackboard.ts .pi/extensions/lib/harness-subagents/blackboard-tool.ts .pi/extensions/lib/harness-subagents/spawn-policy.ts .pi/extensions/lib/harness-subagents/types-blackboard.ts .pi/extensions/harness-web-tools.ts .pi/extensions/harness-web-guard.ts .pi/extensions/lib/harness-web/run-cli.ts",
77
77
  "vendor:sync-router": "bash .pi/scripts/vendor-sync-pi-model-router.sh",
78
78
  "vendor:sync-vcc": "bash .pi/scripts/vendor-sync-pi-vcc.sh",
79
79
  "release": "bash .pi/scripts/release.sh",
@@ -82,7 +82,7 @@
82
82
  "format": "biome format --write",
83
83
  "format:check": "biome format",
84
84
  "prepare": "lefthook install",
85
- "test": "node --test test/harness-verify.test.mjs test/harness-ask-user.test.mjs test/harness-subagents-loader.test.mjs test/sentrux-rules-sync.test.mjs && npx -y tsx --test test/harness-vcc-settings.test.ts",
85
+ "test": "node --test test/harness-verify.test.mjs test/harness-ask-user.test.mjs test/harness-subagents-loader.test.mjs test/sentrux-rules-sync.test.mjs && npx -y tsx --test test/harness-vcc-settings.test.ts test/harness-plan-phase-policy.test.mjs test/harness-subagent-policy.test.mjs",
86
86
  "test:vcc": "npx -y tsx --test vendor/pi-vcc/tests/*.test.ts",
87
87
  "harness:sentrux-bootstrap": "node .pi/scripts/harness-sentrux-bootstrap.mjs",
88
88
  "harness:sentrux-sync": "node .pi/scripts/sentrux-rules-sync.mjs --force",
@@ -90,20 +90,25 @@
90
90
  },
91
91
  "devDependencies": {
92
92
  "@biomejs/biome": "2.4.14",
93
- "@mariozechner/pi-agent-core": "0.73.0",
94
- "@mariozechner/pi-ai": "0.73.0",
95
- "@mariozechner/pi-coding-agent": "0.73.0",
96
- "@mariozechner/pi-tui": "0.73.0",
93
+ "@earendil-works/pi-agent-core": "0.74.1",
94
+ "@earendil-works/pi-ai": "0.74.1",
95
+ "@earendil-works/pi-coding-agent": "0.74.1",
96
+ "@earendil-works/pi-tui": "0.74.1",
97
97
  "@sinclair/typebox": "^0.34.49",
98
98
  "lefthook": "2.1.6",
99
99
  "typescript": "^6.0.3"
100
100
  },
101
101
  "dependencies": {
102
102
  "@posthog/pi": "latest",
103
- "asciify-image": "^0.1.10",
104
103
  "croner": "^9.0.0",
105
104
  "jimp": "^1.6.1",
106
105
  "nanoid": "^5.1.5",
107
106
  "posthog-node": "^5.30.6"
107
+ },
108
+ "overrides": {
109
+ "@mariozechner/pi-agent-core": "npm:@earendil-works/pi-agent-core@0.74.1",
110
+ "@mariozechner/pi-ai": "npm:@earendil-works/pi-ai@0.74.1",
111
+ "@mariozechner/pi-coding-agent": "npm:@earendil-works/pi-coding-agent@0.74.1",
112
+ "@mariozechner/pi-tui": "npm:@earendil-works/pi-tui@0.74.1"
108
113
  }
109
114
  }
@@ -3,6 +3,6 @@
3
3
  - **Repository:** https://github.com/yeliu84/pi-model-router
4
4
  - **License:** MIT (`LICENSE` in this tree)
5
5
  - **Pinned upstream commit:** `8c60095da0e753c242c4be9bb617b85f4dd3255c`
6
- - **Local changes:** TypeScript imports in `extensions/*.ts` use `@mariozechner/*`; relative imports end in `.js` for NodeNext; `package.json` peerDependencies list `@mariozechner/*`.
6
+ - **Local changes:** TypeScript imports in `extensions/*.ts` use `@earendil-works/*`; relative imports end in `.js` for NodeNext; `package.json` peerDependencies list `@earendil-works/*`.
7
7
 
8
8
  **Refresh upstream:** run `npm run vendor:sync-router` from ultimate-pi root (updates this file with the latest commit SHA).
@@ -1,8 +1,8 @@
1
1
  import type {
2
2
  ExtensionAPI,
3
3
  ExtensionContext,
4
- } from '@mariozechner/pi-coding-agent';
5
- import type { AutocompleteItem } from '@mariozechner/pi-tui';
4
+ } from '@earendil-works/pi-coding-agent';
5
+ import type { AutocompleteItem } from '@earendil-works/pi-tui';
6
6
  import type {
7
7
  RouterConfig,
8
8
  RouterPinByProfile,
@@ -1,7 +1,7 @@
1
1
  import { existsSync, readFileSync } from 'node:fs';
2
2
  import { join } from 'node:path';
3
- import { getAgentDir } from '@mariozechner/pi-coding-agent';
4
- import type { ThinkingLevel } from '@mariozechner/pi-agent-core';
3
+ import { getAgentDir } from '@earendil-works/pi-coding-agent';
4
+ import type { ThinkingLevel } from '@earendil-works/pi-agent-core';
5
5
  import type {
6
6
  RouterConfig,
7
7
  RouterProfile,
@@ -1,7 +1,7 @@
1
1
  import type {
2
2
  ExtensionAPI,
3
3
  ExtensionContext,
4
- } from '@mariozechner/pi-coding-agent';
4
+ } from '@earendil-works/pi-coding-agent';
5
5
  import {
6
6
  type RouterConfig,
7
7
  type RouterPersistedState,