specpi 0.17.0 → 0.18.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 +14 -0
- package/NPM_RELEASE.md +23 -91
- package/README.md +4 -2
- package/SECURITY.md +6 -81
- package/SECURITY_MODEL.md +5 -1
- package/THIRD_PARTY.md +2 -2
- package/docs/browser-testing.md +3 -11
- package/docs/delegation/README.md +41 -322
- package/docs/delegation/protocol.md +24 -2
- package/extensions/command-guard/index.ts +3 -3
- package/extensions/delegation/core.mjs +26 -3
- package/extensions/delegation/extension.mjs +54 -3
- package/extensions/delegation/presentation.mjs +82 -0
- package/extensions/tool-wishlist/index.ts +3 -64
- package/package.json +4 -3
- package/scripts/specpi.mjs +6 -0
- package/docs/delegation/design-protocol.md +0 -382
- package/docs/delegation/design.md +0 -525
- package/docs/delegation/evaluation.md +0 -307
- package/docs/delegation/research.md +0 -216
- package/scripts/check-package.mjs +0 -528
- package/scripts/check-pi-package.mjs +0 -327
- package/scripts/check-release-order.mjs +0 -97
- package/scripts/check-syntax.mjs +0 -66
- package/scripts/pi-test-harness.mjs +0 -309
- package/scripts/run-browser-tests.mjs +0 -61
- package/scripts/setup-browser-tests.mjs +0 -38
- package/scripts/site-browser.mjs +0 -291
- package/scripts/verify-artifact.mjs +0 -21
- package/site/self-improvement-loop-v2.svg +0 -108
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.18.0 - 2026-09-07
|
|
4
|
+
|
|
5
|
+
- Start Command Guard off in RPC sessions, including new SpecPi Chat conversations. Explicit `/guard guard` and `/guard strict` still enable protection for the current session; the terminal startup chooser is unchanged.
|
|
6
|
+
|
|
7
|
+
- Let installer PATH discovery continue past inaccessible candidates while preserving permission errors for explicit executable paths. Use the pinned repository Pi for test fixtures and a temporary npm cache for package validation, so restricted test accounts do not require personal npm access.
|
|
8
|
+
|
|
9
|
+
- Publish bounded delegate lifecycle metadata through Pi's RPC widget protocol for SpecPi Chat's live panel. Add exact-attempt human cancellation, stop sampling on settlement/shutdown, and keep prior-generation task labels out of replacement sessions. Worker policy, model-facing operations, quotas and provider behavior are unchanged.
|
|
10
|
+
|
|
11
|
+
## 0.17.1 - 2026-09-07
|
|
12
|
+
|
|
13
|
+
- Reduce the npm package by shipping only runtime scripts; remove obsolete plans, research documents and unused assets, and shorten operational guides.
|
|
14
|
+
- Use structured wishlist candidates directly instead of parsing generated Markdown. Human selection and proof-gated retirement remain unchanged.
|
|
15
|
+
- Remove obsolete tests, editorial assertions and duplicate CI execution while retaining supported safety coverage. SpecPi Chat 0.3.7 separately removes unused standalone conversation paths.
|
|
16
|
+
|
|
3
17
|
## 0.17.0 - 2026-09-06
|
|
4
18
|
|
|
5
19
|
- Let delegation workers correct ordinary source-tool arguments and malformed/truncated reports in the same child session, preserving previously read passages and spending the original budgets. Keep source changes, revocations, unavailable tools, and exhausted budgets terminal. Remove the delegation-specific 8,192-token cap in favor of Pi's provider/model settings; scale SDK response acceptance with `/delegate budget` (1 MiB by default).
|
package/NPM_RELEASE.md
CHANGED
|
@@ -1,114 +1,46 @@
|
|
|
1
|
-
# npm
|
|
1
|
+
# npm release
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
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.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Prepare
|
|
6
6
|
|
|
7
|
-
1.
|
|
8
|
-
2.
|
|
9
|
-
3.
|
|
10
|
-
4. Configure npm trusted publishing for `TannerMidd/SpecPi` and `.github/workflows/npm-publish.yml`.
|
|
11
|
-
5. Do not configure a long-lived `NPM_TOKEN` when trusted publishing is available.
|
|
7
|
+
1. Choose an unused version; update `package.json`, dated `CHANGELOG.md` entry, README and site. Preserve historical changelog entries.
|
|
8
|
+
2. Chat has an independent version: if changed, align `vscode/package.json`, its changelog, guides and VSIX filenames. Run its check, render, isolated VSIX and package scripts. The VSIX is not in the npm tarball; building does not authorize Marketplace publication.
|
|
9
|
+
3. Validate:
|
|
12
10
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
```bash
|
|
16
|
-
npm publish --ignore-scripts --access public --provenance=false ./specpi-<version>.tgz
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
Verify the registry bytes and metadata immediately, then configure trusted publishing before any later release. Do not publish a GitHub Release for that same bootstrap version: the release workflow deliberately rejects versions that already exist. Keep the reviewed source tag as its immutable source reference. All later versions use the protected OIDC workflow and provenance.
|
|
20
|
-
|
|
21
|
-
## Prepare a release
|
|
22
|
-
|
|
23
|
-
1. Select a version that has never appeared on npm. npm versions are immutable.
|
|
24
|
-
2. Update `package.json`, `CHANGELOG.md`, `README.md`, `site/index.html`, `site/wiki/index.html`, `site/single-agent/index.html`, and the delegation guide to the same version. Keep historical changelog entries intact and remove stale unreleased-status wording.
|
|
25
|
-
If Chat changes are included, increment its independent version in `vscode/package.json` and `vscode/CHANGELOG.md`, and align the VSIX filenames and feature descriptions in the root README, extension README, and Pages guides. Build it with `npm --prefix vscode run package`, run `npm --prefix vscode run test:render` and the isolated `npm --prefix vscode run test:vsix`, and inspect the VSIX allowlist. The editor extension is not part of the npm tarball; creating this local artifact does not publish it or authorize a Marketplace release.
|
|
26
|
-
|
|
27
|
-
3. For a stable release, add a dated changelog heading. Use a prerelease version when the package should not receive the `latest` dist-tag.
|
|
28
|
-
4. Install the pinned development tools without lifecycle scripts or peers:
|
|
29
|
-
|
|
30
|
-
```bash
|
|
11
|
+
```sh
|
|
31
12
|
npm install --ignore-scripts --omit=peer --no-package-lock
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
5. Run the complete repository and package gates:
|
|
35
|
-
|
|
36
|
-
```bash
|
|
37
13
|
npm run check
|
|
38
14
|
npm run check:pi-package
|
|
39
15
|
npm publish --dry-run --ignore-scripts --provenance=false
|
|
16
|
+
npm pack --dry-run --json
|
|
40
17
|
git diff --check
|
|
41
18
|
```
|
|
42
19
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
7. Obtain fresh read-only review of package metadata, installer behavior, workflow permissions, and the packed artifact.
|
|
47
|
-
8. Commit the reviewed release, create the matching `v<version>` tag, and create a GitHub Release only after explicit approval.
|
|
48
|
-
|
|
49
|
-
## Documentation and publication order
|
|
50
|
-
|
|
51
|
-
Publication is a post-merge operation. npm versions are immutable, and the protected workflow must run from a reviewed release tag on `main`, so never publish from an unmerged commit: that would leave permanent public bytes whose source might never land.
|
|
52
|
-
|
|
53
|
-
`README.md`, `site/index.html`, and `site/wiki/index.html` document both the canonical `npm install --global specpi@latest` route and a version-pinned example, while `.github/workflows/pages.yml` deploys the site on any push to `main` that touches `site/**`. The release merge therefore deploys install instructions for a version that is not yet on the registry, and the site advertises a command that resolves to `E404` until publication completes.
|
|
54
|
-
|
|
55
|
-
Keep that window short and bounded:
|
|
20
|
+
Browser changes also require their opt-in browser gates. Installer/Pi lifecycle tests must use disposable state, never a live profile. Local dry runs disable provenance because they lack GitHub OIDC.
|
|
21
|
+
4. Review the diff, exact package manifest and artifact; obtain fresh read-only review for lifecycle, permissions and packaging changes.
|
|
22
|
+
5. After approval, merge to `main`, then create the matching `v<version>` tag and GitHub Release. Approve the protected `npm` environment promptly: Pages may already advertise the version. If publication cannot complete, revert the release merge and use a new version for the next attempt.
|
|
56
23
|
|
|
57
|
-
|
|
58
|
-
2. Create the `v<version>` tag and GitHub Release immediately, and approve the `npm` environment without delay. For the one bootstrap version described above, publish the reviewed tarball interactively instead and create no GitHub Release.
|
|
59
|
-
3. Wait for the publish job to verify registry version, integrity, dist-tag, and attestation state.
|
|
60
|
-
4. Complete the registry smoke check below, then confirm the deployed site and announce the release.
|
|
24
|
+
## Protected publication
|
|
61
25
|
|
|
62
|
-
|
|
26
|
+
`.github/workflows/npm-publish.yml` builds one immutable, checksummed candidate; validates that same tarball on Ubuntu, Windows and macOS; then publishes through approved GitHub OIDC with provenance. Stable releases use `latest`, prereleases `next`. Runs are serialized, existing versions are rejected and the candidate must advance its dist-tag. Registry readback must match version, integrity, dist-tag and attestation.
|
|
63
27
|
|
|
64
|
-
|
|
28
|
+
After publication, install the registry artifact into disposable state and exercise plan/install/doctor/uninstall. Check package-page links/images, license, provenance and dist-tag before announcing.
|
|
65
29
|
|
|
66
|
-
|
|
30
|
+
## First publication only
|
|
67
31
|
|
|
68
|
-
|
|
32
|
+
Enable npm 2FA/recovery, create a reviewer-protected GitHub `npm` environment and configure trusted publishing for `TannerMidd/SpecPi`, `.github/workflows/npm-publish.yml`. Do not add a long-lived npm token when OIDC is available.
|
|
69
33
|
|
|
70
|
-
|
|
34
|
+
If npm requires an initial interactive publication before attaching the trusted publisher, run every gate above, then publish the exact reviewed tarball with 2FA:
|
|
71
35
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
The publish job requires approval in the `npm` environment. Publication runs are serialized, and every candidate must advance its existing dist-tag. The job downloads and verifies the same immutable candidate, publishes through GitHub OIDC with npm provenance, uses `next` for prereleases and `latest` for stable versions, and reads the registry back until version, integrity, dist-tag, and attestation state match.
|
|
75
|
-
|
|
76
|
-
## Registry smoke check
|
|
77
|
-
|
|
78
|
-
After publication, install from the registry into disposable state rather than reusing the local tarball:
|
|
79
|
-
|
|
80
|
-
```bash
|
|
81
|
-
npm install --global specpi@<version>
|
|
82
|
-
specpi plan
|
|
83
|
-
```
|
|
84
|
-
|
|
85
|
-
Then complete one isolated install, doctor, and uninstall lifecycle before announcing the release. Verify the npm package page, README images, license, repository links, provenance, and dist-tag.
|
|
86
|
-
|
|
87
|
-
## Update and uninstall contract
|
|
88
|
-
|
|
89
|
-
Updating the npm CLI and managed SpecPi state are separate operations:
|
|
90
|
-
|
|
91
|
-
```bash
|
|
92
|
-
npm install --global specpi@latest
|
|
93
|
-
specpi update
|
|
94
|
-
specpi doctor
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
Restart Pi after updating managed resources so it loads the new delegation runtime.
|
|
98
|
-
|
|
99
|
-
Remove managed resources before removing the CLI:
|
|
100
|
-
|
|
101
|
-
```bash
|
|
102
|
-
specpi uninstall
|
|
103
|
-
npm uninstall --global specpi
|
|
36
|
+
```sh
|
|
37
|
+
npm publish --ignore-scripts --access public --provenance=false ./specpi-<version>.tgz
|
|
104
38
|
```
|
|
105
39
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
## Failure policy
|
|
40
|
+
This one bootstrap exception lacks GitHub provenance. Verify registry bytes/metadata immediately and configure trusted publishing before subsequent releases. Do not publish a GitHub Release for that same bootstrap version: the workflow rejects existing versions. Keep its reviewed source tag.
|
|
109
41
|
|
|
110
|
-
|
|
42
|
+
## Recovery
|
|
111
43
|
|
|
112
|
-
After publication, never
|
|
44
|
+
Stop before publication if any gate fails. After publication, never replace a version's bytes: verify the registry defect, deprecate when warranted, and ship a checked patch through an explicitly approved operation. Unpublish only when npm policy, legal requirements or credential exposure warrants it.
|
|
113
45
|
|
|
114
|
-
|
|
46
|
+
For exposed credentials, revoke them, stop workflows, inspect ownership/dist-tag history, use the [private reporting channel](SECURITY.md), and rotate related credentials before resuming.
|
package/README.md
CHANGED
|
@@ -48,7 +48,7 @@ specpi doctor
|
|
|
48
48
|
|
|
49
49
|
Preview the changes, confirm the install, then check the setup. Restart Pi when finished.
|
|
50
50
|
|
|
51
|
-
To pin this release, use `npm install --global specpi@0.
|
|
51
|
+
To pin this release, use `npm install --global specpi@0.18.0`.
|
|
52
52
|
|
|
53
53
|
Delegation is enabled at startup. Use `/delegate off` to turn it off.
|
|
54
54
|
|
|
@@ -58,10 +58,12 @@ Delegation is enabled at startup. Use `/delegate off` to turn it off.
|
|
|
58
58
|
|
|
59
59
|
Chat beside your code, attach files, and switch conversations.
|
|
60
60
|
|
|
61
|
-
[**Install from Marketplace**](https://marketplace.visualstudio.com/items?itemName=tannermidd.specpi-chat) · Requires
|
|
61
|
+
[**Install from Marketplace**](https://marketplace.visualstudio.com/items?itemName=tannermidd.specpi-chat) · Requires VS Code 1.96+, Node.js 22.19+, and Pi 0.84.4+. SpecPi is optional.
|
|
62
62
|
|
|
63
63
|
In VS Code, find **SpecPi Chat** by **tannermidd** in Extensions and install it. Open **SpecPi** in the Activity Bar, then **Connect Pi**.
|
|
64
64
|
|
|
65
|
+
Chat 0.4.0 adds live delegate progress and worker Stop controls, plus compact tags for attached files. With SpecPi 0.18.0, new Chat sessions start with Guard off; use `/guard guard` or `/guard strict` to enable it. Update the harness and use **Restart Pi** to load these changes.
|
|
66
|
+
|
|
65
67
|
## Go further
|
|
66
68
|
|
|
67
69
|
[Commands](https://tannermidd.github.io/SpecPi/wiki/#reference) · [Chat help](https://github.com/TannerMidd/SpecPi/blob/main/vscode/README.md) · [Development](https://tannermidd.github.io/SpecPi/wiki/#development) · [Security](SECURITY_MODEL.md) · [Release notes](CHANGELOG.md)
|
package/SECURITY.md
CHANGED
|
@@ -1,86 +1,11 @@
|
|
|
1
|
-
# Security
|
|
1
|
+
# Security policy
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Security fixes target the latest tagged SpecPi release. Older releases are unsupported unless an advisory says otherwise.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Report vulnerabilities privately through [GitHub Security Advisories](https://github.com/TannerMidd/SpecPi/security/advisories/new). Include the affected version, platform, impact, and a minimal reproduction using synthetic data. Do not post exploit details publicly or include real credentials. If private reporting is unavailable, open an issue requesting restoration of the channel without disclosing the vulnerability.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Responses and fixes are best-effort, without a guaranteed timeline or bug bounty. Coordinate disclosure with the maintainer. Updates appear in [advisories](https://github.com/TannerMidd/SpecPi/security/advisories) and [release notes](CHANGELOG.md).
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
| --- | --- |
|
|
11
|
-
| Latest tagged release | Supported |
|
|
12
|
-
| Older releases | Unsupported |
|
|
9
|
+
Reports covering SpecPi's installer, extensions, Chat, website, automation, or dependency integration are welcome. Upstream-only problems may be redirected to the responsible project.
|
|
13
10
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
Report suspected vulnerabilities through [GitHub private vulnerability reporting](https://github.com/TannerMidd/SpecPi/security/advisories/new). SpecPi currently accepts private reports only through GitHub.
|
|
17
|
-
|
|
18
|
-
Do not open a public issue, pull request, discussion, or other public report containing vulnerability or exploit details. A GitHub account is required. If private reporting is unexpectedly unavailable, open a public issue containing no vulnerability details and ask the maintainer to restore the private reporting channel before sharing the report.
|
|
19
|
-
|
|
20
|
-
Include as much of the following as is safe and practical:
|
|
21
|
-
|
|
22
|
-
- the affected SpecPi release or commit;
|
|
23
|
-
- the affected installer command, extension, tool, workflow, or website component;
|
|
24
|
-
- operating system and relevant configuration;
|
|
25
|
-
- expected and observed behavior;
|
|
26
|
-
- security impact and plausible attack scenario;
|
|
27
|
-
- minimal reproduction steps or proof of concept;
|
|
28
|
-
- known mitigations or workarounds;
|
|
29
|
-
- whether the issue is already public or actively exploited;
|
|
30
|
-
- preferred credit or anonymity.
|
|
31
|
-
|
|
32
|
-
Do not include real credentials, personal data, production secrets, or destructive payloads when a minimized demonstration is sufficient.
|
|
33
|
-
|
|
34
|
-
SpecPi handles reports on a best-effort basis. Maintainers will acknowledge, assess, and communicate as capacity permits, but the project does not promise fixed response or remediation times. Fix timing depends on impact, exploitability, complexity, upstream coordination, and release safety.
|
|
35
|
-
|
|
36
|
-
Please keep the report private while impact, mitigations, a fix, and an advisory are coordinated. Disclosure timing will be discussed with the reporter and may be accelerated when details are already public or exploitation is active. SpecPi does not currently operate a bug bounty program.
|
|
37
|
-
|
|
38
|
-
## Scope
|
|
39
|
-
|
|
40
|
-
Reports are in scope when they concern SpecPi-owned behavior, including:
|
|
41
|
-
|
|
42
|
-
- the plan, install, update, doctor, and uninstall lifecycle;
|
|
43
|
-
- managed configuration, backups, checksums, rollback, and shell integration;
|
|
44
|
-
- bundled extensions, skills, themes, browser integration, and local state;
|
|
45
|
-
- Command Guard classification, enforcement, approval, or bypass behavior;
|
|
46
|
-
- the GitHub Pages site and repository release or deployment workflows;
|
|
47
|
-
- an upstream dependency when SpecPi's integration, configuration, or selected version creates or exposes the vulnerability.
|
|
48
|
-
|
|
49
|
-
Pi, npm, Chromium, Playwright, DonSeTch, GitHub, and other third-party projects maintain their own security boundaries. Upstream-only vulnerabilities may be redirected to the responsible project. Reports remain relevant to SpecPi when its use of an upstream component creates a distinct risk or requires a SpecPi mitigation.
|
|
50
|
-
|
|
51
|
-
A disagreement with an intentional, documented limitation is not by itself a vulnerability. Reports that show the implementation violating its stated boundary, silently weakening a protection, exposing protected data, or enabling a practical bypass are welcome.
|
|
52
|
-
|
|
53
|
-
## Security updates
|
|
54
|
-
|
|
55
|
-
When appropriate, SpecPi publishes security information through [GitHub Security Advisories](https://github.com/TannerMidd/SpecPi/security/advisories), tagged releases, and [CHANGELOG.md](CHANGELOG.md). An advisory should identify affected and fixed releases, impact, mitigations or workarounds, and upgrade guidance. A CVE may be requested when appropriate.
|
|
56
|
-
|
|
57
|
-
## Secure installation and operation
|
|
58
|
-
|
|
59
|
-
- Install a version-pinned npm release or clone and review the matching source tag. Verify npm provenance when relying on the registry artifact. Do not pipe remote installer content directly into a shell.
|
|
60
|
-
- Installing the npm package adds the CLI only. Review `specpi plan` before installation or update, and use `--yes` only when every planned external installation is intended.
|
|
61
|
-
- Treat `pi install npm:specpi` as limited resource-only mode, not as the managed installer with browser runtime, supporting packages, instructions, backups, and rollback ownership.
|
|
62
|
-
- Run `specpi doctor` after installation and updates.
|
|
63
|
-
- Run Pi and SpecPi with the least operating-system privilege practical. Use a container or VM for hostile repositories, code, or web content.
|
|
64
|
-
- Protect Pi configuration and credentials with operating-system permissions. SpecPi is not a credential or process sandbox.
|
|
65
|
-
- Use dedicated test accounts rather than personal authenticated browser sessions.
|
|
66
|
-
- Inspect task cards, review packets, wishlist reports, issue drafts, screenshots, page text, downloads, console output, and visual baselines before sharing them.
|
|
67
|
-
- Review optional and global package installations. Some external state and package caches survive rollback or uninstall.
|
|
68
|
-
|
|
69
|
-
## Security boundaries at a glance
|
|
70
|
-
|
|
71
|
-
| Area | SpecPi provides | SpecPi does not provide |
|
|
72
|
-
| --- | --- | --- |
|
|
73
|
-
| npm distribution | Reviewed file allow-list, no install lifecycle script, protected publishing, and requested provenance | Automatic execution of the managed SpecPi installer or proof that packaged code is safe |
|
|
74
|
-
| Installer | Explicit plans and confirmation, bounded managed changes, backups, checksums, atomic promotion, and rollback | Rollback of every external package-manager side effect or cache |
|
|
75
|
-
| Command Guard | Pre-execution defense in depth for documented model-tool seams | A general sandbox for direct user commands, arbitrary tools, scripts, extensions, or running processes |
|
|
76
|
-
| Local improvement state | Explicit collection choice, bounded local records, sanitization, and no SpecPi upload | Guaranteed removal of every plain-language identity or automatic deletion on uninstall |
|
|
77
|
-
| Task and verification records | Fixed task requirements, source-bound gate observations, and explicit human outcome feedback | Independent model judgment, cryptographic attestation, or automatic authority to expand a task |
|
|
78
|
-
| Browser | A fresh Chromium context without the personal browser profile | Operating-system or network isolation from hostile web content |
|
|
79
|
-
|
|
80
|
-
The authoritative assumptions, enforcement seams, residual risks, and component details are in [SECURITY_MODEL.md](SECURITY_MODEL.md).
|
|
81
|
-
|
|
82
|
-
## Dependencies and supply chain
|
|
83
|
-
|
|
84
|
-
SpecPi pins reviewed executable dependencies and uses a reviewed lockfile for its managed browser runtime. The npm release workflow validates one tarball, publishes those same bytes from a protected environment with GitHub OIDC, and requests npm provenance. Provenance links an artifact to its build workflow but does not prove the source or dependencies are safe. Pinning, lockfiles, and provenance improve accountability but are not complete reproducible-build guarantees. Installation still trusts the configured package registries, upstream publishers, downloaded browser distribution, GitHub Actions, and the invoking host.
|
|
85
|
-
|
|
86
|
-
Some optional or bootstrap packages are installed globally and remain external system state. SpecPi uninstall does not remove them. See [THIRD_PARTY.md](THIRD_PARTY.md) for the canonical component and version inventory and [SECURITY_MODEL.md](SECURITY_MODEL.md) for acquisition and rollback boundaries.
|
|
11
|
+
See [SECURITY_MODEL.md](SECURITY_MODEL.md) for trust boundaries and [THIRD_PARTY.md](THIRD_PARTY.md) for dependencies and licenses. SpecPi is not an OS sandbox; use least privilege and containers or VMs for hostile code.
|
package/SECURITY_MODEL.md
CHANGED
|
@@ -95,6 +95,8 @@ SpecPi is not an operating-system sandbox and does not claim to contain a compro
|
|
|
95
95
|
|
|
96
96
|
## Installer and managed state
|
|
97
97
|
|
|
98
|
+
Installer executable discovery skips inaccessible candidates in an implicit PATH search; it neither changes their permissions nor executes them. Explicit executable paths and unexpected filesystem errors still fail. The existing Windows winget App Execution Alias handling is unchanged.
|
|
99
|
+
|
|
98
100
|
SpecPi is configuration and executable extension code for Pi and runs with the invoking user's permissions. Installing the public npm package adds the `specpi` CLI to npm-managed state but does not run SpecPi installation, download external tools, or mutate Pi state; the package defines no npm install lifecycle script. The installer prints a plan and requires confirmation unless `--yes` is supplied. `plan` is non-mutating. Installation and update merge documented settings leaves, preserve unrelated packages and configuration, and modify AGENTS and shell files only inside SpecPi marker blocks.
|
|
99
101
|
|
|
100
102
|
The canonical npm route is an installer-CLI distribution. Direct `pi install npm:specpi` loads packaged extensions, skills, and themes but bypasses the managed installer, so it does not provide managed instructions, supporting packages, browser runtime acquisition, optional tools, shell integration, backups, or ownership records. Pi-bundled runtime modules are optional peers and are not copied into the tarball. Release automation validates the packed artifact, requires a matching immutable version and release tag, publishes only from a protected environment, and requests npm provenance through short-lived GitHub OIDC credentials.
|
|
@@ -189,7 +191,7 @@ Repository checks, smoke tests, checksums, closed capability validators, and bro
|
|
|
189
191
|
|
|
190
192
|
The optional `vscode/` extension is distributed separately from the SpecPi npm installation. It runs in the VS Code workspace extension host and requires a trusted filesystem workspace before launching Pi or collecting file context. Only application-level settings choose executable paths; the launcher resolves native executables or known adjacent Pi JavaScript entry points and never executes a shell command string. Pi runs in the explicitly selected workspace with its normal installed extensions and provider configuration. VS Code trust does not replace Pi project trust, and the extension does not pass a flag to bypass Pi's trust decisions or Command Guard.
|
|
191
193
|
|
|
192
|
-
The sidebar uses Pi's documented JSONL RPC protocol. Pi owns provider authentication and tool execution; the extension does not read, copy, or manage authentication files. RPC model metadata is projected to display fields. Approvals and selection/input/editor requests are displayed as text and require an exact response for the requesting conversation's active request. Switching the displayed conversation preserves outstanding requests; background requests appear as needing input and never receive automatic approval. Stop, disconnect, runtime session transitions, and expiry cancel the affected conversation's requests. Expired or wrong-conversation responses cannot authorize later requests. In RPC, Command Guard starts
|
|
194
|
+
The sidebar uses Pi's documented JSONL RPC protocol. Pi owns provider authentication and tool execution; the extension does not read, copy, or manage authentication files. RPC model metadata is projected to display fields. Approvals and selection/input/editor requests are displayed as text and require an exact response for the requesting conversation's active request. Switching the displayed conversation preserves outstanding requests; background requests appear as needing input and never receive automatic approval. Stop, disconnect, runtime session transitions, and expiry cancel the affected conversation's requests. Expired or wrong-conversation responses cannot authorize later requests. In RPC, including SpecPi Chat, Command Guard starts off without an initial selection dialog because Pi cannot read dialog responses until its startup handlers return. Explicit `/guard guard` and `/guard strict` commands enable protection for the current session; new sessions start off again. The terminal startup chooser and initialization-failure handling are unchanged. Unsupported terminal-only components are disclosed rather than treated as functional editor controls.
|
|
193
195
|
|
|
194
196
|
Chat allows up to 90 seconds for an initial read-only RPC readiness probe before sending normal requests. This accommodates the 30-second startup fallback in older installed Guard versions without extending later request deadlines. Dialogs arriving before readiness receive cancellation only, never an approval or mode selection; the sidebar explains the limitation and retains a notice after connection. An extension with an unbounded startup dialog can still prevent readiness. Chat times out with recovery guidance instead of bypassing that extension or changing the user's installed harness.
|
|
195
197
|
|
|
@@ -207,6 +209,8 @@ Pi persists chats, including sent image blocks, in a workspace-specific director
|
|
|
207
209
|
|
|
208
210
|
Conversation edits select entries from the active Pi tree, revalidate the selection before mutation, and fork before the chosen user prompt. Exact original text and validated image blocks are captured before forking because Pi's fork response returns text only. The original conversation is retained, restored drafts require another send action, and conversation forks/clones do not restore or checkpoint workspace files. Actions are scoped to the active workspace, connection, and session revision. Export opens an unsaved Markdown document and Copy Conversation writes the visible Markdown to the OS clipboard only on explicit request. Both omit image bytes and represent images as placeholders; they do not reconstruct truncated or hidden history. Usage displays report Pi measurements, preserving unavailable values rather than inventing totals. The separate provider Limits row projects bounded strings from the known Codex Usage and pi-usage status keys, strips terminal/control sequences, and inserts text only. It does not parse numeric quotas, combine budgets with conversation cost, read provider credentials or usage-cache files, or add provider requests. Reports stay with their live connection and are cleared on disconnect, exit, and reconnect; refreshing and cache age remain upstream plugin responsibilities. Opening the details has no RPC or provider side effect. Existing `/usage` notifications and exact confirmation dialogs continue through the normal UI protocol; no automatic reset consumption or terminal-footer emulation is added.
|
|
209
211
|
|
|
212
|
+
The Delegates panel consumes the known `specpi-delegation-v1` RPC widget key, with one versioned JSON record of at most 32 KiB and eight projected worker rows. Public identities, shortened task labels, states, elapsed times, call counts and code-owned diagnostics are text-only; snapshots, full prompts, raw provider errors and child transcripts are not sent through the live widget. A single extension-side timer samples existing counters while slots are occupied; it makes no provider or source requests and is disposed on shutdown/rebinding. Invalidated-generation jobs contribute only to occupied-slot counts, not cross-session task labels; replaced same-generation stopping jobs remain visible until settlement. Chat clears live state on disconnect, exit and runtime session replacement and keeps at most 32 connection-local completion summaries for refresh; it adds no child journal or webview persistence. Existing delegate tool receipts are projected into readable advisory reports without changing their model/session content. Stop actions require a trusted workspace, foreground conversation, matching context and an observed running/queued batch/job/attempt. Pi rechecks that exact attempt before its human command cancels it. Worker Stop does not submit draft text/images, clear parent queues, approve tools, change quotas or claim remote termination. The widget is an integration contract with trusted installed extensions, not protection against a malicious extension in Pi's process.
|
|
213
|
+
|
|
210
214
|
Native change review reads VS Code's Git API, validates selected workspace paths, and opens the corresponding working-tree or staged view through the built-in diff/editor actions. It does not execute a shell command, stage, commit, discard, or restore files. Git integration availability and the filesystem race boundary still apply. The sidebar coordinator keeps independent Pi connections for explicitly opened conversations. Switching conversations or folders only changes the selected view. Stop and Disconnect target the selected process; extension-host shutdown stops all owned processes. User-initiated parallel conversations share their workspace files and are not isolated worktrees. Branching uses Pi's pre-runtime `--fork` to copy into a new owned session before extensions can write, then performs any active-branch or prompt selection there; the original process and session remain unchanged.
|
|
211
215
|
|
|
212
216
|
The extension introduces no network server, telemetry, runtime package dependency, or automatic model request when a view opens. Pi itself may contact its configured services when connected. Tests use synthetic homes, agent directories, providers, workspaces and profiles, plus an installed VS Code extension host; they do not access the user's live Pi credentials or conversations. Live provider availability and billing are outside the offline test evidence.
|
package/THIRD_PARTY.md
CHANGED
|
@@ -16,7 +16,7 @@ When Pi is absent, SpecPi can install the reviewed `@earendil-works/pi-coding-ag
|
|
|
16
16
|
|
|
17
17
|
The experimental delegation extension uses native discovery and public Pi SDK `createAgentSession`, in-memory sessions and a fresh `ModelRuntime`, with **public SDK capability checks instead of an exact-version allowlist**. Compatible Pi updates can activate without a SpecPi release. Missing APIs are named in the activation error; actual SDK/provider behavior remains subject to runtime checks and regression testing. The installer floor and pinned 0.84.4 bootstrap package are unchanged. Pi supplies the conversation/tool loop, standard configuration, authentication and OAuth. The child receives the parent model and thinking level with Pi clamping; unsupported runtime-only authentication, selected extension-provider overrides and safe descriptor mismatches fail preflight. Children load no ambient extensions, skills, AGENTS files or parent history. Parent hooks, ephemeral settings and session affinity are not inherited. Each SDK invocation is admitted before dispatch. SDK provider retries and compaction are disabled; ordinary tool-argument and report corrections use admitted calls in the same child session. Output length follows Pi's normal provider/model settings without a delegation-specific token cap, and SDK-visible streams are checked without claiming hard raw-transport, hidden-attempt, memory or invoice bounds. SpecPi does not install or vendor another runtime, add a launcher/service, or introduce a direct `pi-agent-core` dependency or additional runtime library. Parent Pi startup, resources and trust remain unchanged.
|
|
18
18
|
|
|
19
|
-
The [Pi 0.85.0 release](https://github.com/earendil-works/pi/releases/tag/v0.85.0), published 4 September 2026, prompted the additional compatibility review. It does not change the installer pin or imply that every provider/setup has passed.
|
|
19
|
+
The [Pi 0.85.0 release](https://github.com/earendil-works/pi/releases/tag/v0.85.0), published 4 September 2026, prompted the additional compatibility review. It does not change the installer pin or imply that every provider/setup has passed. Pi 0.85.1 also passes the isolated native/provider fixtures; its SDK session, agent-session and model-runtime modules match 0.85.0. Compatibility evidence is not an activation allowlist or proof of full parent inference parity.
|
|
20
20
|
|
|
21
21
|
The child uses configured global transport/thinking budgets without loading project settings. Startup proxy configuration and model-specific headers are unsupported and fail preflight; parent configuration stays unchanged. These limits are part of the experimental SDK integration, not claims about what Pi itself supports.
|
|
22
22
|
|
|
@@ -58,7 +58,7 @@ Repository development uses these exact, project-local formatting and linting pa
|
|
|
58
58
|
- `@typescript-eslint/parser@8.68.0` — MIT
|
|
59
59
|
- `typescript@6.0.3` — Apache-2.0
|
|
60
60
|
|
|
61
|
-
They are development-only dependencies, are not shipped by the SpecPi installer, and enforce the repository's JavaScript and TypeScript readability rules. TypeScript also runs strict no-emit checking for the browser extension
|
|
61
|
+
They are development-only dependencies, are not shipped by the SpecPi installer, and enforce the repository's JavaScript and TypeScript readability rules. TypeScript also runs strict no-emit checking for the browser extension.
|
|
62
62
|
|
|
63
63
|
Browser type checking and registered-tool tests additionally use exact project-local development dependencies: `@earendil-works/pi-coding-agent@0.84.4`, `@earendil-works/pi-ai@0.84.4`, `@earendil-works/pi-tui@0.84.4` (MIT), `typebox@1.3.7` (MIT), `@types/node@22.20.1` (MIT), and `playwright@1.62.1` (Apache-2.0). These reuse the reviewed Pi/runtime versions, do not alter the optional production-peer contract, and are not bundled or installed by SpecPi. Direct development dependencies are pinned; this is not a claim that the development transitive graph is locked. The browser executable test runtime still uses the separately reviewed lockfile. `setup:browser` provisions only `.specpi-test/browser-runtime/`; its explicit `--with-deps` option invokes Playwright OS dependency setup on disposable Linux CI runners. No language-server executable or additional automation framework was added.
|
|
64
64
|
|
package/docs/browser-testing.md
CHANGED
|
@@ -61,16 +61,8 @@ The shared browser workflow runs for CI and is a prerequisite of Pages deploymen
|
|
|
61
61
|
|
|
62
62
|
The existing `local-browser-automation` registry entry and `browser-runtime-smoke` prove their historical rendering/image-comparison contract only. They are not expanded into claims that diagnostics or keyboard behavior have passed that closed validator. Browser diagnostics and interactions in SpecPi 0.13.0 are evidenced by dedicated registered-tool/Chromium tests and CI; no wishlist item is automatically selected or retired and no invented shipped version is entered in the registry.
|
|
63
63
|
|
|
64
|
-
## Semantic navigation
|
|
64
|
+
## Semantic navigation decision
|
|
65
65
|
|
|
66
|
-
|
|
66
|
+
No agent-facing semantic-navigation tool is implemented. The original feasibility assessment found the existing TypeScript language service adequate for a small alias/reference/diagnostics example; that does not establish product coverage or a productivity improvement. Use project-native compiler/tooling and reassess only after concrete refactor friction.
|
|
67
67
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
| Approach | Assessment |
|
|
71
|
-
| --- | --- |
|
|
72
|
-
| Project-native compiler and shell tools | Adequate baseline for this TypeScript fixture and the browser refactor. Text search is easy but cannot distinguish aliases/shadowing; compiler APIs can, at the cost of writing a small explicit host. No measured productivity improvement is claimed. |
|
|
73
|
-
| Narrow TypeScript adapter | Could expose bounded path/line/column results and reuse this compiler if repeated refactor work justifies a maintained tool contract. Not justified by this small fixture alone. |
|
|
74
|
-
| Broad LSP integration | Adds server acquisition/trust, process cleanup, language-specific configuration, and protocol complexity without evidence of a current need. Deferred, not implemented. |
|
|
75
|
-
|
|
76
|
-
Any later adapter proposal must define supported languages/projects, on-disk versus unsaved buffers, canonical project-root and symlink boundaries, out-of-root declaration references, generated/vendor exclusions, result/time limits, cancellation/subprocess cleanup, and a no-auto-edit/no-auto-install policy. Definitions in dependencies may need an explicit read-only opt-in. Repository plugins/config scripts are executable trust boundaries, not automatically safe navigation inputs.
|
|
68
|
+
A later adapter would need explicit language/project support, on-disk versus unsaved-buffer semantics, path/link and dependency boundaries, bounded results and cancellation, and no automatic edits or server installation. Repository plugins and configuration scripts remain executable trust boundaries.
|