specpi 0.23.0 → 0.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.24.0 - 2026-09-16
4
+
5
+ - Replace `pi-subagents@0.67.0` in the default base with first-party `specpi-delegation@0.2.0`, and add `specpi-experiments@0.1.0`. The base is now seven pinned packages; the other five are unchanged.
6
+ - Correct the delegation documentation: the package activates at Pi startup whenever a model is configured, and `/delegate off` turns it off. Earlier drafts of this entry and of the package's own README, security notes and guide described it as opt-in, which the extension, its tool description and its startup test all contradict.
7
+ - Publish SpecPi's own bounded delegation as an independent Pi package. Child sessions get three read-only tools over a source snapshot frozen when the batch starts — no shell, edits, network or nested delegation — under fixed ceilings that local settings may lower and never raise. Delegation activates at Pi startup whenever a model is configured, and `/delegate off` turns it off for the session. The extraction drops the Command Guard admission path, which SpecPi no longer ships, so the reported guard posture is `absent`.
8
+ - Publish the retired `/experiment` command as an independent Pi package. An experiment is a detached Git worktree created at `HEAD`, closed by exporting a patch or discarding it; the base worktree, its index and its uncommitted changes are never touched. `/experiment recover` reconciles records against what Git tracks and never deletes a directory Git still tracks.
9
+ - Both packages carry no production dependencies and were extracted under MIT from SpecPi 0.20.1, immediately before commit `4f5461d`.
10
+ - Add the HarnessTax study (Pan, Yang, Arabzadeh, Chiang, Stoica and Zaharia; UC Berkeley Sky Lab and Arena, 16 September 2026) to the research page, credited and linked, with all 21 model-harness pairs drawn as cost-success figures from the data published with the study.
11
+ - Measure what SpecPi adds to Pi's first model call rather than assuming Pi's economy survives configuration. `scripts/measure-context.mjs` reads the request a real Pi process sends and counts tool definitions, tool-schema characters and instruction characters the way the study defines them. The base sends 23,710 characters against stock Pi's 5,521, about 4.3x, still under half of Codex and about a quarter of Claude Code. The figure omits the four third-party pins, so it is a floor.
12
+ - Gate the two heaviest optional packages behind a saved preference that ships off. Pi sends every active tool's schema on every request of a session, so Browser QA's fourteen tools (about 8.7 KB) and delegation's one (about 4.4 KB) were charged to projects that never used them. `/browser on` and `/delegate on` enable them for a session; `/browser startup on` and `/delegate startup on` save that choice. A default session's first call falls from 23,710 characters to 10,536, from 4.3x stock Pi to 1.9x.
13
+ - Bump `specpi-browser-qa` to 0.2.0 and `specpi-delegation` to 0.2.0 for that change, and move the base pins to match. `specpi-experiments` is unchanged at 0.1.0.
14
+ - Measure Oh My Pi on the same terms and add it to the first-call chart. The fork sends 65,843 characters across 11 tools, about 11.9x stock Pi and six times a default SpecPi, which puts a configured Pi fork between Codex and Claude Code. `scripts/measure-context.mjs --omp=<path to its cli.js>` takes that row; it needs Bun and is skipped without the flag, so Oh My Pi is not a dependency of this repository.
15
+ - Remove Chat's `pi-subagents` frontend: the fleet adapter, its RPC bridge, its result cards and its configuration UI. Chat's existing delegation panel now covers the default base, including per-worker Stop. Package settings cover web access alone.
16
+
3
17
  ## 0.23.0 - 2026-09-14
4
18
 
5
19
  - Replace the BetterWright default with independently published `specpi-browser-qa@0.1.0`: 14 QA-focused interaction, accessibility, diagnostic, and visual-regression tools, not general-browser feature parity. The other five package pins and Chat 0.8.1 are unchanged.
package/NPM_RELEASE.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # npm release
2
2
 
3
- This guide covers the root `specpi` package. Browser QA has an independent [release process](packages/browser-qa/NPM_RELEASE.md), `browser-qa-v*` tags and `browser-qa-publish.yml` workflow. Package-only releases do not invoke the root publisher.
3
+ This guide covers the root `specpi` package. Each package under `packages/` releases independently, with its own release process, tag prefix and publish workflow: [Browser QA](packages/browser-qa/NPM_RELEASE.md) (`browser-qa-v*`), [Delegation](packages/delegation/NPM_RELEASE.md) (`delegation-v*`) and [Experiments](packages/experiments/NPM_RELEASE.md) (`experiments-v*`). Package-only releases do not invoke the root publisher.
4
4
 
5
5
  Publishing, tags, deprecation, ownership changes and GitHub Releases require explicit human approval. Publication is a post-merge operation: never publish from an unmerged commit. npm versions are immutable.
6
6
 
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  <h1 align="center">SpecPi</h1>
6
6
 
7
- <p align="center">Pi, beside your code.<br>Scope your work. Choose what improves. Keep your own Pi setup.</p>
7
+ <p align="center">A Pi harness setup, built to specification.</p>
8
8
 
9
9
  <p align="center">
10
10
  <a href="https://www.npmjs.com/package/specpi"><img src="https://img.shields.io/npm/v/specpi?style=flat-square&amp;color=084bdb" alt="npm version"></a>
@@ -13,135 +13,58 @@
13
13
  </p>
14
14
 
15
15
  <p align="center">
16
- <a href="#install">Install</a> · <a href="https://tannermidd.github.io/SpecPi/">Website</a> · <a href="https://tannermidd.github.io/SpecPi/wiki/">Documentation</a> · <a href="#vs-code">VS Code</a> · <a href="https://github.com/TannerMidd/SpecPi/releases">Releases</a>
16
+ <a href="https://tannermidd.github.io/SpecPi/">Website</a> · <a href="https://tannermidd.github.io/SpecPi/wiki/">Documentation</a> · <a href="https://github.com/TannerMidd/SpecPi/releases">Releases</a>
17
17
  </p>
18
18
 
19
19
  <p align="center">
20
20
  <a href="https://tannermidd.github.io/SpecPi/#vscode-chat">
21
21
  <picture>
22
- <source media="(prefers-color-scheme: dark)" srcset="https://tannermidd.github.io/SpecPi/media/specpi-chat.png">
23
- <img src="https://tannermidd.github.io/SpecPi/media/specpi-chat-light.png" width="1100" alt="SpecPi Chat beside a file in VS Code, discussing a focused code change with a file attached.">
22
+ <source media="(prefers-color-scheme: dark)" srcset="https://tannermidd.github.io/SpecPi/media/specpi-chat-showcase-dark.png">
23
+ <img src="https://tannermidd.github.io/SpecPi/media/specpi-chat-showcase-light.png" width="1100" alt="SpecPi Chat in VS Code: an open file beside the chat panel discussing a focused change.">
24
24
  </picture>
25
25
  </a>
26
26
  </p>
27
27
  <p align="center"><sub>SpecPi Chat · Example workspace</sub></p>
28
28
 
29
- SpecPi is a small base for the [Pi coding agent](https://pi.dev/). Its own extensions provide **scope control** and a **harness improvement loop**. Six pinned packages handle the supporting tools, and **SpecPi Chat 0.8.1** brings them into VS Code.
29
+ ---
30
30
 
31
- | Keep the work focused | Improve what gets in the way | Work beside your code |
32
- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------- |
33
- | Declare files and directories with `/scope`. Review drift as the task progresses. | Record recurring problems locally. Choose a change through `/harness-improvement` and verify it. | Chat, attach files, follow subagents, review approvals, and inspect changes in VS Code. |
31
+ SpecPi is a small base for the [Pi coding agent](https://pi.dev/), assembled from deliberate choices about how the agent should work not a curated marketplace.
34
32
 
35
- > **Moving from 0.20 or earlier?** The 0.21 base removes the old custom tools, extra commands, themes, and shell profiles. Read [updating and removal](#update-and-remove) before switching.
33
+ Two first-party extensions set the terms: **scope control**, which holds each task to the files it declared, and an **improvement loop**, which turns recurring friction into tested, evidence-backed harness changes instead of accumulated prompts and workarounds. Around them sit seven hand-picked packages, each pinned to an exact version and verified before any transaction completes, and **SpecPi Chat**, a VS Code frontend for working beside the agent.
36
34
 
37
- ## Install
38
-
39
- Requires Node.js 22.19+, Git, npm, and an existing Pi installation on PATH. The complete base is tested with Pi **0.84.4**; `pi-goal-x` currently declares Pi `>=0.83.0 <0.85.0` compatibility.
40
-
41
- ```sh
42
- npm install --global specpi@latest
43
- specpi plan
44
- specpi install
45
- specpi doctor
46
- ```
47
-
48
- Inspect the plan, confirm the install, then restart Pi. SpecPi installs two first-party extensions, the improvement skill, a marked working agreement, and the packages below using `pi install`. Provider and model settings are preserved. Confirmed install/update also runs the installed Browser QA package's Node setup to download Chromium and verify readiness. No Bun or OS libraries are installed. There are no additional harness extensions, themes, shell profiles, or tool wrappers.
49
-
50
- <details>
51
- <summary>Source checkouts, alternate Pi paths, and core-only installs</summary>
52
-
53
- For this checkout, run `node scripts/specpi.mjs` in place of `specpi`. `PI_CODING_AGENT_DIR` selects an alternate destination; `SPECPI_PI` selects a Pi CLI path. `specpi install --skip-package-install` installs only the first-party core for offline use and testing. `--skip-browser-install` skips Chromium setup while still acquiring all six packages; `doctor` still checks browser readiness. `--skip-package-install` skips both package acquisition and Chromium setup. A plain `pi install npm:specpi` loads only the packaged first-party resources; use the SpecPi installer above for the complete base, and avoid installing the same first-party resources both ways.
54
-
55
- </details>
56
-
57
- ## Default packages
58
-
59
- These are installed on every normal install and update. Exact versions live in [`templates/settings.json`](templates/settings.json); SpecPi merges only the package entries, preserving unrelated configuration and existing resource filters.
60
-
61
- | Package | Pinned version | Purpose |
62
- | ----------------------------------------------------------------------------------------------------------------- | -------------- | ------------------------------------------------------ |
63
- | [pi-web-access](https://github.com/nicobailon/pi-web-access) | 0.29.0 | Web search and page retrieval |
64
- | [specpi-browser-qa](https://www.npmjs.com/package/specpi-browser-qa) | 0.1.0 | Browser interaction, accessibility and visual QA |
65
- | [pi-subagents](https://github.com/nicobailon/pi-subagents) | 0.67.0 | Subagents and delegation |
66
- | [pi-goal-x](https://github.com/tmonk/pi-goal-x) | 0.31.2 | Persistent goals and progress |
67
- | [@sreetej510/pi-usage](https://github.com/Sreetej510/pi-extensions/tree/main/extensions/pi-usage) | 0.10.0 | Provider usage reporting |
68
- | [@gotgenes/pi-permission-system](https://github.com/gotgenes/pi-packages/tree/main/packages/pi-permission-system) | 32.0.2 | Tool permission policies |
69
-
70
- The effective commands are `pi install npm:<package>@<version>` for each row, including the scoped names. These packages supply their own extensions, tools, skills, and prompts according to their upstream defaults. SpecPi does not add a second implementation or configure their policies.
71
-
72
- SpecPi requests exact npm dependency saves for these installs and verifies installed versions before completing the transaction. This keeps later package installs from advancing an earlier pin through npm's default version ranges.
73
-
74
- Browser QA setup uses the installed package's pinned Playwright and the standard browser cache (or `PLAYWRIGHT_BROWSERS_PATH`). If setup fails, managed configuration rolls back; install missing OS libraries manually and retry `specpi install` (or `specpi update` for an existing installation). `specpi doctor` runs offline rendering, pixel-comparison, and accessibility checks without downloading anything. Provider credentials, web-service configuration, and permission rules remain governed by each package's documentation. Package installation and extension loading do not prove that every external service or tool is ready.
35
+ The setup optimizes for four things:
75
36
 
76
- ## Browser QA
37
+ - **Control** — declared scope, tool permissions, and confirmation-gated lifecycle commands
38
+ - **Accuracy** — exact pins, checksum-tracked state, rollback on failure, and evidence over claims
39
+ - **Improvement** — local observations become bounded, verified changes through `/harness-improvement`
40
+ - **Efficiency** — subagent delegation, persistent goals, and browser QA handled by the right tools
77
41
 
78
- [`specpi-browser-qa@0.1.0`](https://www.npmjs.com/package/specpi-browser-qa/v/0.1.0) is independently published and now included in the default base. Its 14 tools cover interactions, responsive screenshots, visual comparison, diagnostics, and accessibility checks in an ephemeral browser context. It is QA-focused, not general-browser feature parity with BetterWright. No personal browser, profile, cookie, or private Pi data is migrated.
42
+ Everything it manages is declared, versioned, and reversible.
79
43
 
80
- BetterWright remains an optional manual install, with its own [Bun-based setup](https://github.com/BetterWright/betterwright/blob/main/SETUP.md). SpecPi does not uninstall Bun or user-owned tools.
81
-
82
- ## VS Code
83
-
84
- [SpecPi Chat](https://github.com/TannerMidd/SpecPi/blob/main/vscode/README.md) provides the chat sidebar, file and image attachments, conversation history, tool output, package commands, and approval dialogs. Version **0.8.1** lets you edit global or project permission settings, confirm changes, and keep a backup. The VSIX remains separate from the npm harness package.
85
-
86
- Download the [0.8.1 VSIX](https://github.com/TannerMidd/SpecPi/releases/download/v0.23.0/specpi-chat-0.8.1.vsix), then run **Extensions: Install from VSIX…** in VS Code. Install/update SpecPi separately, then restart Pi in Chat to reload its extensions.
87
-
88
- [Download Chat](https://github.com/TannerMidd/SpecPi/releases/download/v0.23.0/specpi-chat-0.8.1.vsix) · [Chat guide](https://github.com/TannerMidd/SpecPi/blob/main/vscode/GUIDE.md) · [Build from source](https://github.com/TannerMidd/SpecPi/blob/main/vscode/DEVELOPMENT.md)
89
-
90
- ## Scope
91
-
92
- Declare the files and directories a task should touch with `/scope set`, then use `/scope status` to review drift.
93
-
94
- <details>
95
- <summary>Scope commands</summary>
96
-
97
- - `/scope set`: declare project-relative files or directories, one per line.
98
- - `/scope status`: review declared paths, pending drift, and snapshot uncertainty.
99
- - `/scope add <path>` or `/scope remove <path>`: change the declared scope.
100
- - `/scope accept <path>`: acknowledge a finding without adding that path to scope.
101
- - `/scope recheck`: deliberately refresh the baseline after an uncertain snapshot.
102
- - `/scope clear`: turn monitoring off.
103
- - `/scope task`: import the active improvement contract's paths explicitly.
104
-
105
- </details>
106
-
107
- Interactive writes and edits outside scope ask before proceeding. In headless mode they are recorded as pending. Other tools are checked afterward against bounded Git snapshots. Scope is a drift monitor, not a sandbox: shell commands and custom tools can already have changed files when drift is reported. State follows the current Pi session branch.
108
-
109
- ## Harness improvement loop
110
-
111
- <picture>
112
- <source media="(prefers-color-scheme: dark)" srcset="https://tannermidd.github.io/SpecPi/media/improvement-workflow-dark.svg">
113
- <img src="https://tannermidd.github.io/SpecPi/media/improvement-workflow.svg" width="1200" alt="Observe a recurring gap, select one change, modify the harness, test it, retire with evidence, and review later outcomes.">
114
- </picture>
115
-
116
- 1. Enable local observations with `/wishlist on`; collection is off by default. `/wishlist off` stops it.
117
- 2. Review recurring gaps with `/wishlist` and select one through `/harness-improvement` in a complete SpecPi source checkout.
118
- 3. Follow the `specpi-improve` skill: record a bounded contract, implement the smallest sufficient change, and gather direct acceptance evidence.
119
- 4. `finish_harness_improvement` verifies the selected contract, source changes, repository checks, and registered capability validators before retirement.
120
- 5. Review the journal with `/wishlist history <gap-id>`. A regression returns the item for human selection; it never authorizes an automatic fix.
121
-
122
- Observations are leads, not permission. Records stay local, use sanitized summaries and salted identifiers, and are never uploaded automatically. Pi still sends model requests to your selected provider. `/wishlist outcome <gap-id>` records the human's assessment of a local retirement.
44
+ ## Install
123
45
 
124
- ## Update and remove
46
+ Requires Node.js 22.19+, Git, npm, and an existing Pi installation on PATH.
125
47
 
126
48
  ```sh
127
49
  npm install --global specpi@latest
128
50
  specpi plan
129
- specpi update
51
+ specpi install
130
52
  specpi doctor
131
- specpi uninstall
132
53
  ```
133
54
 
134
- Install, update, and uninstall require confirmation; `--yes` supplies it for automation. Modified retained resources require `update --force`. Managed configuration and resources are backed up and checksum-tracked. `update --skip-package-install` preserves an existing base without invoking Pi's package installer. Normal updates reapply the reviewed pins and run Chromium setup unless `--skip-browser-install` is supplied.
135
-
136
- BetterWright is no longer a default package. Normal updates use recorded ownership to remove only unchanged SpecPi-added entries or restore pre-existing entries. User-modified entries and downloaded bytes survive; `--skip-package-install` preserves the old base. Restart Pi and each Chat connection to unload retired extensions. Independently retained BetterWright installs require separate user management.
55
+ `plan` shows what will change without modifying anything. Restart Pi after install.
137
56
 
138
- `pi-lens` is no longer included by default. A normal managed update removes unchanged Lens entries originally added by SpecPi; pre-existing or user-modified entries and downloaded files remain. `--skip-package-install` preserves the old base. Restart Pi and each Chat connection to unload Lens. Independently retained installations require separate user management (`pi remove npm:pi-lens` in their installation scope).
57
+ Full setup options, package details, and requirements: [website](https://tannermidd.github.io/SpecPi/#install).
139
58
 
140
- `pi-background-tasks` is no longer included by default because its Anthropic wrapper can reject changing message context. A normal update removes an unchanged package entry originally added by SpecPi; pre-existing or user-modified entries and downloaded files remain. `--skip-package-install` preserves the old base. To remove a separately retained installation, run `pi remove npm:pi-background-tasks` in its installation scope, then restart Pi.
59
+ ## Where things live
141
60
 
142
- Updating from the larger harness retires its recorded extra resources, restores legacy settings that still match ownership records, removes its shell marker block, and installs the new package base. Modified retired files and old runtime directories are preserved under `<agent-dir>/specpi/backups/`. Restart Pi to unload the old extensions. Unrelated configuration and local improvement evidence remain intact.
143
-
144
- Uninstall restores package entries that still match SpecPi's recorded changes and preserves subsequent user edits. Downloaded packages, browser caches, npm caches, upstream configuration, and private evidence remain on disk. A failed install rolls back SpecPi-managed files and configuration; package/browser downloads and upstream install-script effects cannot be rolled back. `doctor` checks the core, package settings, installed top-level versions, and actual Browser QA readiness. Core-only installations do not run browser checks.
61
+ | | |
62
+ | --- | --- |
63
+ | [Packages](https://tannermidd.github.io/SpecPi/#packages) | The seven pinned packages and what each provides |
64
+ | [Scope control](https://tannermidd.github.io/SpecPi/wiki/#scope) | `/scope` commands and drift monitoring |
65
+ | [Improvement loop](https://tannermidd.github.io/SpecPi/#loop) | Local wishlist, `/harness-improvement`, and retirement with evidence |
66
+ | [SpecPi Chat](https://tannermidd.github.io/SpecPi/#vscode-chat) | VS Code frontend and VSIX install · [Chat guide](https://github.com/TannerMidd/SpecPi/blob/main/vscode/README.md) |
67
+ | [Updating](https://tannermidd.github.io/SpecPi/#updating) | Update, uninstall, and migration notes |
145
68
 
146
69
  ## Development
147
70
 
@@ -149,12 +72,8 @@ Uninstall restores package entries that still match SpecPi's recorded changes an
149
72
  npm install --ignore-scripts --omit=peer --no-package-lock
150
73
  node --test tests/workflow-controls.test.mjs tests/workflow-controls-extension.test.mjs
151
74
  npm run check
152
- npm run check:pi-package
153
- npm run check:base
154
75
  ```
155
76
 
156
- Installer tests use disposable Pi directories. `check:base` requires network access, installs the real six packages in isolated state, loads them together through Pi 0.84.4, verifies Chat RPC startup and explicit permission replies, and checks removal. It also runs Chromium setup and offline Browser QA smoke checks, without sending model requests. Set `PLAYWRIGHT_BROWSERS_PATH` to a disposable test cache to avoid touching the normal browser cache. Never test against a live Pi installation. Publication remains explicit and uses the [release procedure](NPM_RELEASE.md).
157
-
158
- The website is static HTML and CSS in `site/`. After installing the pinned Playwright browser with `npx --no-install playwright install chromium`, run `npm run check:site` to check versions, links, and desktop, tablet, and mobile layouts. GitHub Pages deploys it from `main` after those checks pass.
77
+ Installer tests use disposable Pi directories never test against a live Pi installation. Publication follows the [release procedure](NPM_RELEASE.md).
159
78
 
160
79
  [Security model](SECURITY_MODEL.md) · [Third-party components](THIRD_PARTY.md) · [Release notes](CHANGELOG.md) · [MIT License](LICENSE)
package/SECURITY_MODEL.md CHANGED
@@ -28,17 +28,19 @@ Legacy migration restores only recorded settings ownership, preserves differing
28
28
 
29
29
  ## Browser QA package
30
30
 
31
- `packages/browser-qa` is an independently released Node-native Pi package extracted from the retired browser tools. The installer acquires the immutable `specpi-browser-qa@0.1.0` release through Pi; its source and dependencies are not bundled in SpecPi's npm artifact. Its explicit setup downloads Playwright Chromium, and its doctor performs offline rendering, image-comparison and accessibility smoke checks. It uses package-local dependency resolution and the standard Playwright browser cache rather than SpecPi's retired managed runtime. No Pi settings, credentials or personal profiles are migrated. The ephemeral context is not OS/network isolation; pages can reach localhost and private networks. See the package's [security documentation](packages/browser-qa/SECURITY.md) for artifact retention, best-effort redaction, permission and cleanup limits. This is QA tooling, not general-browser feature parity. BetterWright remains optional/manual. Normal updates restore recorded pre-existing entries and remove only unchanged SpecPi-added BetterWright entries; modified entries, personal browsers, profiles, cookies, and user-owned tools are not migrated or deleted.
31
+ `packages/browser-qa` is an independently released Node-native Pi package extracted from the retired browser tools. The installer acquires the immutable `specpi-browser-qa@0.2.0` release through Pi; its source and dependencies are not bundled in SpecPi's npm artifact. Its fourteen tools ship withdrawn: until a human runs `/browser on`, or saves `/browser startup on`, Pi is offered no browser tool and the model cannot launch a browser at all. Delegation ships off on the same basis, so neither package's tools reach a default session. Its explicit setup downloads Playwright Chromium, and its doctor performs offline rendering, image-comparison and accessibility smoke checks. It uses package-local dependency resolution and the standard Playwright browser cache rather than SpecPi's retired managed runtime. No Pi settings, credentials or personal profiles are migrated. The ephemeral context is not OS/network isolation; pages can reach localhost and private networks. See the package's [security documentation](packages/browser-qa/SECURITY.md) for artifact retention, best-effort redaction, permission and cleanup limits. This is QA tooling, not general-browser feature parity. BetterWright remains optional/manual. Normal updates restore recorded pre-existing entries and remove only unchanged SpecPi-added BetterWright entries; modified entries, personal browsers, profiles, cookies, and user-owned tools are not migrated or deleted.
32
32
 
33
33
  ## VS Code frontend
34
34
 
35
- SpecPi Chat is a separate VSIX, retained alongside the npm harness. It launches Pi only in a trusted filesystem workspace and communicates over local RPC. Provider credentials stay with Pi. The frontend manages only its own workspace-storage conversation catalog and sessions for user-directed history, branching, and export; it does not import unrelated Pi histories. Attachments, images, webview messages, and file navigation are validated and bounded. Rendered model and tool output is untrusted text, never executable HTML.
35
+ SpecPi Chat is a separate VSIX, retained alongside the npm harness. It launches Pi only in a trusted filesystem workspace and communicates over local RPC. Provider credentials stay with Pi. Sign-in is delegated rather than implemented: Chat can start the configured Pi executable in a user-visible VS Code terminal, without RPC flags or a session, and Pi alone prompts, runs any OAuth flow, and writes `auth.json`. Chat sends no input to that terminal, reads no credential store, runs no Pi auth subcommand, and accepts no credential over RPC; it observes only the terminal's closure, and restarts the connection so Pi re-resolves its catalogue. Its sign-in prompt is derived from Pi's own available-model list and missing-credential error text. The frontend manages only its own workspace-storage conversation catalog and sessions for user-directed history, branching, and export; it does not import unrelated Pi histories. Attachments, images, webview messages, and file navigation are validated and bounded. Rendered model and tool output is untrusted text, never executable HTML.
36
36
 
37
- Approval replies are tied to the current conversation, client, and request ID. Disconnect, cancellation, and expiry never grant permission. Multiline package approval context is shown in the dialog body; requests exceeding the display budget are cancelled rather than approved against incomplete context. The Permissions editor can change only the package's documented global/project `config.json`, with bounded UTF-8/schema validation, explicit native confirmation, connection/scope binding, stale-revision checks, private backups, and atomic replacement. It reads no permission logs, trust decisions, credentials, or agent frontmatter. Symlinks, hardlinks, and special files are refused. Backups remain local and may contain sensitive policy; another same-user process can still race filesystem operations. Saving does not claim runtime activation: the user can restart the selected chat and inspect `/permission-system show`. Global/project changes may affect other chats as upstream reloads them; session approvals are cleared by restart. pi-subagents activity comes from a read-only, connection-local public event adapter that registers no tools or commands. The VSIX does not install packages or duplicate their enforcement; only Permission System configuration has an explicit editing UI. TUI-only custom components are outside Pi's RPC rendering support.
37
+ Approval replies are tied to the current conversation, client, and request ID. Disconnect, cancellation, and expiry never grant permission. Multiline package approval context is shown in the dialog body; requests exceeding the display budget are cancelled rather than approved against incomplete context. The Permissions editor can change only the package's documented global/project `config.json`, with bounded UTF-8/schema validation, explicit native confirmation, connection/scope binding, stale-revision checks, private backups, and atomic replacement. It reads no permission logs, trust decisions, credentials, or agent frontmatter. Symlinks, hardlinks, and special files are refused. Backups remain local and may contain sensitive policy; another same-user process can still race filesystem operations. Saving does not claim runtime activation: the user can restart the selected chat and inspect `/permission-system show`. Global/project changes may affect other chats as upstream reloads them; session approvals are cleared by restart. Delegated agent activity comes from a read-only, connection-local widget the delegation package publishes; Chat registers no tools or commands of its own for it. The VSIX does not install packages or duplicate their enforcement; only Permission System configuration has an explicit editing UI. TUI-only custom components are outside Pi's RPC rendering support.
38
+
39
+ The optional **Destructive guard** preset replaces the complete global configuration draft; it never merges with the old global rules or options. The user can preview/edit the replacement or undo it without a write. Saving uses the same native confirmation, bound global destination, backup, and atomic replacement as ordinary settings edits. The preset asks by default, adds explicit destructive-command denials, disables YOLO and logging, and clears the authorizer chain. It performs no project-policy or agent-definition inspection and no additional directory enumeration. This is a configuration template, not independent enforcement or a claim that global settings override every runtime scope. Project/per-agent policies and session approvals remain upstream-controlled, including 32.0.2's ordered-map merging behavior. Case-sensitive patterns can block benign uses and miss scripts, alternative executable spellings, or unconfigured shell tools. Restart after saving and inspect effective policy; the template is not a sandbox.
38
40
 
39
41
  ## Upstream package boundary
40
42
 
41
- The six packages add their own extensions, tools, prompts, skills, network connections, filesystem operations, and subprocesses under their upstream defaults. They are not confined by the improvement loop's selection requirement. Permission System owns tool policies; SpecPi does not inject a duplicate guard or claim its coverage. Subagents can start other processes. `pi-lens` and `pi-background-tasks` (including its Anthropic provider wrapper) are no longer part of the default base. Normal updates remove only unchanged entries originally added by SpecPi; pre-existing or modified entries and downloaded bytes remain. `--skip-package-install` preserves the old base. Restart Pi and Chat connections to unload retired extensions. Independently retained installations remain trusted upstream code; retained Pi Lens can still apply configured formatting/autofixes. Web access and usage reporting can contact services and use credentials through their upstream implementations. SpecPi's local-only wishlist collection policy does not describe all activity of those packages.
43
+ The seven packages add their own extensions, tools, prompts, skills, network connections, filesystem operations, and subprocesses under their upstream defaults. They are not confined by the improvement loop's selection requirement. Permission System owns tool policies; SpecPi does not inject a duplicate guard or claim its coverage. Delegation starts real Pi child sessions in the same process tree, restricted to a frozen source snapshot and three read-only tools; experiments run the user's own `git` and create worktrees on disk. Neither is an OS sandbox. See [delegation](packages/delegation/SECURITY.md) and [experiments](packages/experiments/SECURITY.md). `pi-lens` and `pi-background-tasks` (including its Anthropic provider wrapper) are no longer part of the default base. Normal updates remove only unchanged entries originally added by SpecPi; pre-existing or modified entries and downloaded bytes remain. `--skip-package-install` preserves the old base. Restart Pi and Chat connections to unload retired extensions. Independently retained installations remain trusted upstream code; retained Pi Lens can still apply configured formatting/autofixes. Web access and usage reporting can contact services and use credentials through their upstream implementations. SpecPi's local-only wishlist collection policy does not describe all activity of those packages.
42
44
 
43
45
  Top-level versions are pinned; upstream transitive dependency ranges are not frozen by SpecPi. `doctor` reads configured pins and installed package metadata, then invokes the installed Browser QA bin for real offline rendering, pixel-comparison, and accessibility checks when the managed base includes it. Doctor never downloads a browser, and missing Chromium or OS libraries fail with recovery guidance. It does not validate provider access or browser readiness for independently retained BetterWright. Core-only installations do not run browser checks. `check:base` acquires the packages, checks combined resource loading and Chat RPC startup, and exercises upstream approval, denial, and cancellation with synthetic context. It uses temporary home/configuration directories and sends no model prompt. The base check also exercises Node-only Chromium setup and offline Browser QA readiness; authenticated services, OS isolation, and every upstream tool's behavior remain outside that check. See [THIRD_PARTY.md](THIRD_PARTY.md) for sources and compatibility limits.
44
46
 
package/THIRD_PARTY.md CHANGED
@@ -11,24 +11,29 @@ Development formatting uses Prettier **3.9.6** (MIT), ESLint **10.9.1** (MIT), `
11
11
 
12
12
  ## Default packages
13
13
 
14
- Reviewed on 2026-09-14 against published npm metadata and integrity-verified source archives. All six top-level packages declare the MIT license. Pins are authoritative in `templates/settings.json`.
14
+ Reviewed on 2026-09-16 against published npm metadata and integrity-verified source archives. All seven top-level packages declare the MIT license. Pins are authoritative in `templates/settings.json`.
15
15
 
16
16
  SpecPi requests exact npm dependency saves for these pins and checks installed top-level versions before completing installation. The override applies to package acquisition without changing the user's global npm configuration.
17
17
 
18
18
  | Package | Version | Upstream |
19
19
  | ------------------------------ | ------- | ------------------------------------------------------------------------- |
20
20
  | pi-web-access | 0.29.0 | [nicobailon/pi-web-access](https://github.com/nicobailon/pi-web-access) |
21
- | specpi-browser-qa | 0.1.0 | [TannerMidd/SpecPi](https://github.com/TannerMidd/SpecPi/tree/browser-qa-v0.1.0/packages/browser-qa) |
22
- | pi-subagents | 0.67.0 | [nicobailon/pi-subagents](https://github.com/nicobailon/pi-subagents) |
21
+ | specpi-browser-qa | 0.2.0 | [TannerMidd/SpecPi](https://github.com/TannerMidd/SpecPi/tree/browser-qa-v0.1.0/packages/browser-qa) |
22
+ | specpi-delegation | 0.2.0 | [TannerMidd/SpecPi](https://github.com/TannerMidd/SpecPi/tree/main/packages/delegation) |
23
+ | specpi-experiments | 0.1.0 | [TannerMidd/SpecPi](https://github.com/TannerMidd/SpecPi/tree/main/packages/experiments) |
23
24
  | pi-goal-x | 0.31.2 | [tmonk/pi-goal-x](https://github.com/tmonk/pi-goal-x) |
24
25
  | @sreetej510/pi-usage | 0.10.0 | [Sreetej510/pi-extensions](https://github.com/Sreetej510/pi-extensions) |
25
26
  | @gotgenes/pi-permission-system | 32.0.2 | [gotgenes/pi-packages](https://github.com/gotgenes/pi-packages) |
26
27
 
27
- Transitive dependencies and their notices remain in Pi's npm installation tree. Top-level pins do not freeze upstream dependency ranges or constitute a full transitive security audit. Pi invokes npm with its upstream package-management semantics, including dependency lifecycle scripts. Browser QA has no install hook: confirmed SpecPi install/update explicitly invokes its installed Node setup bin, unless acquisition or browser setup is skipped. It downloads package-pinned Chromium without installing OS libraries. BetterWright is optional/manual and retains its own Bun-based setup; SpecPi neither removes Bun nor deletes user-owned tools. Pi Subagents includes `@earendil-works/pi-server`. Usage reporting and web packages make their own provider/service connections. Consult upstream licenses and security policies before redistributing their components.
28
+ Transitive dependencies and their notices remain in Pi's npm installation tree. Top-level pins do not freeze upstream dependency ranges or constitute a full transitive security audit. Pi invokes npm with its upstream package-management semantics, including dependency lifecycle scripts. Browser QA has no install hook: confirmed SpecPi install/update explicitly invokes its installed Node setup bin, unless acquisition or browser setup is skipped. It downloads package-pinned Chromium without installing OS libraries. BetterWright is optional/manual and retains its own Bun-based setup; SpecPi neither removes Bun nor deletes user-owned tools. Usage reporting and web packages make their own provider/service connections. Consult upstream licenses and security policies before redistributing their components.
28
29
 
29
30
  Pi Lens is no longer a default package. Normal updates retire only unchanged entries added by SpecPi; independent or modified entries and downloaded bytes remain, with their upstream notices. Restart Pi to unload Lens.
30
31
 
31
- The combined base is tested with Pi 0.84.4. Pi Goal X declares Pi `>=0.83.0 <0.85.0`; compatibility with newer hosts is not assumed. SpecPi's former custom browser, structural-search, delegation, background-task, and command-guard implementations, DonSeTch, and Pi themes have been removed. Removal restores owned package settings but does not delete downloaded upstream packages or tools. Retired private runtimes remain in local backups with their notices.
32
+ The combined base is tested with Pi 0.84.4. Pi Goal X declares Pi `>=0.83.0 <0.85.0`; compatibility with newer hosts is not assumed. SpecPi's former custom browser, structural-search, background-task, and command-guard implementations, DonSeTch, and Pi themes have been removed. Its delegation and experiment implementations were not discarded: they now ship as the independent `specpi-delegation` and `specpi-experiments` packages described below. Removal restores owned package settings but does not delete downloaded upstream packages or tools. Retired private runtimes remain in local backups with their notices.
33
+
34
+ ## Standalone delegation and experiments
35
+
36
+ `packages/delegation` and `packages/experiments` are first-party packages extracted from SpecPi's own retired harness code under MIT. Neither bundles third-party runtime code or declares a production dependency; every runtime import is a Node builtin or a Pi-supplied optional peer. Experiments invokes the user's own `git` as an external program through Pi's `exec` seam; Git is not bundled, vendored or version-pinned. Delegation's extraction drops the Command Guard admission path, which SpecPi no longer ships, and reports its guard posture as `absent`. See their dependency notices and security boundaries: [delegation](packages/delegation/THIRD_PARTY.md) / [boundary](packages/delegation/SECURITY.md), [experiments](packages/experiments/THIRD_PARTY.md) / [boundary](packages/experiments/SECURITY.md).
32
37
 
33
38
  ## Standalone browser QA
34
39
 
@@ -38,4 +43,4 @@ The separately released `packages/browser-qa` source reuses the retired QA imple
38
43
 
39
44
  The website uses the bundled IBM Plex Sans and Plex Mono fonts under the SIL Open Font License 1.1; see [`site/fonts/LICENSE.txt`](https://github.com/TannerMidd/SpecPi/blob/main/site/fonts/LICENSE.txt). The website's scripts and diagrams are first-party code and assets. The README loads public package/license badges from Shields.io and build status from GitHub. Website fonts and media are not included in the npm package.
40
45
 
41
- SpecPi Chat 0.8.1 is a separately packaged VS Code extension with no bundled runtime dependencies. It uses VS Code's host APIs and Pi's RPC protocol. Its read-only pi-subagents adapter consumes the upstream `fleetStatus` v1 contract reviewed at 0.67.0. Generic tool output, visible custom messages, widgets, and dialogs stay owned by their upstream packages. Playwright **1.62.1** (Apache-2.0, [Microsoft Playwright](https://github.com/microsoft/playwright)) is a pinned development dependency for Chat's rendering tests; its browser is used for those checks and is not shipped in either artifact. The default Browser QA package independently uses the same pinned Playwright version for its runtime.
46
+ SpecPi Chat 0.8.3 is a separately packaged VS Code extension with no bundled runtime dependencies. It uses VS Code's host APIs and Pi's RPC protocol. Generic tool output, visible custom messages, widgets, and dialogs stay owned by their upstream packages. Playwright **1.62.1** (Apache-2.0, [Microsoft Playwright](https://github.com/microsoft/playwright)) is a pinned development dependency for Chat's rendering tests; its browser is used for those checks and is not shipped in either artifact. The default Browser QA package independently uses the same pinned Playwright version for its runtime. Chat's global Destructive guard preset is a full replacement configuration reviewed against Permission System 32.0.2's schema and native pattern semantics. No upstream patch, new dependency, policy-layer merger, or independent command evaluator is included. See [the security model](SECURITY_MODEL.md) for its limits.
@@ -48,6 +48,10 @@ export const SOURCE_ROOT_FILES = Object.freeze([
48
48
  const EXCLUDED_DIRECTORY_NAMES = new Set([
49
49
  ".git",
50
50
  ".next",
51
+ // Test and packaging scratch output. It lands at the repository root, and
52
+ // also under vscode/ whenever a check runs with that as its cwd, so it does
53
+ // fall inside the scanned SOURCE_DIRECTORIES.
54
+ ".specpi-test",
51
55
  "build",
52
56
  "coverage",
53
57
  "desktop",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "specpi",
3
- "version": "0.23.0",
3
+ "version": "0.24.0",
4
4
  "description": "Scope control and a human-selected harness improvement loop for Pi",
5
5
  "author": "Tanner Middleton",
6
6
  "repository": {
@@ -84,6 +84,8 @@
84
84
  "check:base": "node scripts/check-base-packages.mjs",
85
85
  "check:site": "node scripts/check-site.mjs",
86
86
  "check:browser-qa": "npm --prefix packages/browser-qa run check",
87
+ "check:delegation": "npm --prefix packages/delegation run check",
88
+ "check:experiments": "npm --prefix packages/experiments run check",
87
89
  "check:vscode": "npm --prefix vscode run check",
88
90
  "prepublishOnly": "npm run check",
89
91
  "check": "npm run format:check && npm run check:syntax && npm test && npm run check:package && npm run check:vscode"
@@ -19,7 +19,7 @@ export function runBrowserQA(agentDir, command) {
19
19
  const installed = JSON.parse(fs.readFileSync(path.join(root, "package.json"), "utf8"));
20
20
  if (
21
21
  installed.name !== "specpi-browser-qa" ||
22
- installed.version !== "0.1.0" ||
22
+ installed.version !== "0.2.0" ||
23
23
  installed.bin?.["specpi-browser-qa"] !== "./bin/browser-qa.mjs"
24
24
  ) {
25
25
  throw new Error("Missing or changed pinned Browser QA bin metadata");
@@ -469,7 +469,7 @@ async function doctor() {
469
469
  const errors = [];
470
470
  if (manifest.basePackages?.length) {
471
471
  errors.push(...checkBasePackages(agentDir, readJson(settingsPath, {})));
472
- if (manifest.basePackages.includes("npm:specpi-browser-qa@0.1.0")) {
472
+ if (manifest.basePackages.includes("npm:specpi-browser-qa@0.2.0")) {
473
473
  try {
474
474
  runBrowserQA(agentDir, "doctor");
475
475
  } catch (error) {
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "packages": [
3
3
  "npm:pi-web-access@0.29.0",
4
- "npm:specpi-browser-qa@0.1.0",
5
- "npm:pi-subagents@0.67.0",
4
+ "npm:specpi-browser-qa@0.2.0",
5
+ "npm:specpi-delegation@0.2.0",
6
+ "npm:specpi-experiments@0.1.0",
6
7
  "npm:pi-goal-x@0.31.2",
7
8
  "npm:@sreetej510/pi-usage@0.10.0",
8
9
  "npm:@gotgenes/pi-permission-system@32.0.2"