pi-pocket 0.29.0 → 0.30.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +58 -1
- package/SECURITY.md +1 -0
- package/docs/architecture.md +9 -4
- package/docs/desktop-app.md +54 -0
- package/docs/examples/approval-monitor.ts +82 -0
- package/docs/extensions/people-values.md +8 -0
- package/docs/extensions/policies/api-stability.md +1 -0
- package/docs/extensions/reference/api-versions.md +3 -0
- package/docs/extensions/reference/host.md +92 -1
- package/docs/extensions/tools.md +1 -0
- package/docs/features.md +4 -4
- package/docs/index.md +3 -0
- package/docs/macos.md +90 -0
- package/docs/map.md +9 -5
- package/docs/windows.md +73 -0
- package/npm-shrinkwrap.json +71 -67
- package/package.json +9 -9
- package/src/launcher/desktop.ts +45 -0
- package/src/launcher/main.ts +81 -17
- package/src/launcher/options.ts +59 -2
- package/src/server/alerts.ts +2 -2
- package/src/server/app.ts +2 -0
- package/src/server/auth.ts +40 -0
- package/src/server/background.ts +109 -241
- package/src/server/commands.ts +28 -17
- package/src/server/design/scan-fig-container.ts +3 -2
- package/src/server/design/scan-files.ts +3 -11
- package/src/server/design/system.ts +3 -4
- package/src/server/design/tokens-io.ts +2 -3
- package/src/server/docs.ts +9 -0
- package/src/server/errors.ts +12 -0
- package/src/server/extension-document-compat.ts +4 -0
- package/src/server/extensions/artifacts.ts +2 -6
- package/src/server/extensions/codemode.ts +27 -1
- package/src/server/extensions/guard.ts +9 -1
- package/src/server/extensions/pocket-relay/files.ts +10 -3
- package/src/server/extensions/pocket-relay/runtime.ts +6 -0
- package/src/server/extensions/pocket-relay.ts +31 -3
- package/src/server/extensions/schedules.ts +9 -2
- package/src/server/host.ts +25 -0
- package/src/server/http/api.ts +21 -4
- package/src/server/http/browser-routes.ts +5 -2
- package/src/server/http/conversation-routes.ts +4 -3
- package/src/server/http/events.ts +9 -4
- package/src/server/http/io.ts +5 -2
- package/src/server/http/sign-in.ts +9 -3
- package/src/server/limit-gate.ts +257 -65
- package/src/server/limits.ts +80 -4
- package/src/server/main.ts +71 -16
- package/src/server/no-follow.ts +67 -0
- package/src/server/pending-approvals.ts +174 -0
- package/src/server/processes.ts +1480 -0
- package/src/server/projection.ts +7 -6
- package/src/server/room.ts +2 -0
- package/src/server/schedules.ts +226 -4
- package/src/server/secrets.ts +6 -4
- package/src/server/socket-path.ts +167 -0
- package/src/server/themes.ts +2 -4
- package/src/server/worktrees.ts +16 -17
- package/types/pocket.d.ts +74 -0
- package/web/agent-now.js +2 -2
- package/web/notify.js +1 -5
- package/web/peeks.js +1 -1
- package/web/sessions.js +2 -3
- package/web/sheets/schedules.js +18 -0
- package/web/store.js +126 -13
- package/web/transcript.js +4 -30
package/docs/macos.md
ADDED
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
# The macOS package
|
|
2
|
+
|
|
3
|
+
Each release has `Pi-Pocket-<version>.pkg` on its [GitHub release page](https://github.com/TannerMidd/pi-pocket/releases), with a `.sha256` file beside it. It installs Pi Pocket for your macOS account, with no admin password and no Node.js of your own. macOS 13.5 (Ventura) or newer, on Apple silicon or Intel: one package fits both.
|
|
4
|
+
|
|
5
|
+
The package is thin: it puts Node.js and a small launcher on the disk, then installs the `pi-pocket` npm package. The installer needs the internet for that step.
|
|
6
|
+
|
|
7
|
+
## Gatekeeper
|
|
8
|
+
|
|
9
|
+
The package is not signed or notarized yet, so macOS does not open it with a double-click: it says that Apple could not check it for malicious software. To install it anyway:
|
|
10
|
+
|
|
11
|
+
1. Double-click the package, and select **Done** (or **OK**) in the warning.
|
|
12
|
+
2. Open **System Settings → Privacy & Security**. Near the bottom, it says that "Pi-Pocket-….pkg" was blocked. Select **Open Anyway**, and confirm with your password or Touch ID. This allows only this file; the install itself asks for no admin rights.
|
|
13
|
+
|
|
14
|
+
On macOS 14 and older, Control-click the package in Finder, select **Open**, then **Open** again. Download it only from the release page, and compare its SHA256 with the `.sha256` file if you want to be sure that it is the same file:
|
|
15
|
+
|
|
16
|
+
```sh
|
|
17
|
+
shasum -a 256 ~/Downloads/Pi-Pocket-0.29.0.pkg
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## What it installs, and where
|
|
21
|
+
|
|
22
|
+
The installer has one place to install: **Install for me only**. Everything goes in `~/Library/Application Support/Pi Pocket`:
|
|
23
|
+
|
|
24
|
+
| Folder or file | What it is |
|
|
25
|
+
| ---------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
26
|
+
| `node/` | Node.js, from the official `darwin-arm64` and `darwin-x64` tarballs. The build checks each against the SHA256 pinned in [`packaging/macos/build.sh`](../packaging/macos/build.sh), and joins their two `node` files into one universal file; each half is the official file, byte for byte, with its signature. |
|
|
27
|
+
| `app/` | A private npm prefix that holds the `pi-pocket` package. It is yours, so updates from the app work. |
|
|
28
|
+
| `pi-pocket` | Starts the launcher with that Node.js and prefix. Arguments go to `pi-pocket` (`pi-pocket --help`). |
|
|
29
|
+
| `Pi Pocket.command` | What Terminal runs for Pi Pocket (console). |
|
|
30
|
+
| `uninstall.sh`, `login-item.sh`, `stop-pi-pocket.sh` | The uninstaller, the switch of the sign-in item, and what stops a running Pi Pocket for the installer and the uninstaller. |
|
|
31
|
+
| `install-app.mjs` | Installs the `pi-pocket` npm package into `app/` during the install. |
|
|
32
|
+
| `npm-cache/`, `install.log` | npm's cache, and what npm printed during the install. |
|
|
33
|
+
|
|
34
|
+
The package always uses its own Node.js, also when you have one (from Homebrew, nvm, or nodejs.org): an update of your Node.js, or its removal, does not break Pi Pocket, and in-app updates always have a prefix that they can write. Your own Node.js and npm are not changed.
|
|
35
|
+
|
|
36
|
+
Your data (sessions, sign-ins, settings, extensions) stays in `~/.pi-pocket`, as with every other install.
|
|
37
|
+
|
|
38
|
+
The package also makes:
|
|
39
|
+
|
|
40
|
+
- **Pi Pocket.app** in the Applications folder of your home folder (`~/Applications`), the desktop app. It opens Pi Pocket in a window of its own, already signed in, with no Terminal window, and puts **π** in the menu bar with **Open Pi Pocket**, **Restart Server**, and **Quit Pi Pocket**. The server listens on this Mac only. To sign in your phone, use Menu → **Sign in another device** in the window. Close the window and Pi Pocket keeps running in the menu bar; open the app again to show it. A second server never starts. The window shows the Dock badge and notifications while the app runs. It starts the launcher in your login shell, so your `PATH` from `~/.zprofile` (Homebrew, for example) reaches the sessions. [desktop-app.md](desktop-app.md) says how it works.
|
|
41
|
+
- **Pi Pocket (console).app** beside it, which opens the launcher in a Terminal window, as Pi Pocket.app did before: there you choose how other devices reach Pi Pocket (the local network, a Cloudflare tunnel, Tailscale), and it shows the sign-in link and its QR code. Press **q** in the Terminal window, or close it, to stop it. When it runs, Pi Pocket.app uses its server instead of starting one.
|
|
42
|
+
- If another app of either name is in `~/Applications`, the installer leaves it, and Pi Pocket's app stays in the install folder. Spotlight and Launchpad find both. New sessions start in your home folder.
|
|
43
|
+
- with the choice **Start Pi Pocket when I sign in** (off by default, and on when an earlier install has it on; select **Customize** on the Installation Type page), a LaunchAgent, `~/Library/LaunchAgents/io.github.tannermidd.pi-pocket.plist`. From the next sign-in, it starts Pi Pocket.app in the menu bar, without a window. macOS lists it in System Settings → General → Login Items. To turn it on or off later:
|
|
44
|
+
|
|
45
|
+
```sh
|
|
46
|
+
"$HOME/Library/Application Support/Pi Pocket/login-item.sh" on # or off
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
**Quit Pi Pocket** (in the menu bar, or ⌘Q) stops the server, with each command that its agents run, and closes the window. A GUI install opens Pi Pocket.app at the end. The app's log is `~/Library/Logs/Pi Pocket/launcher.log`; it has no sign-in link.
|
|
50
|
+
|
|
51
|
+
Inside sessions, `node` and `npm` are the package's own, and a global npm install (`npm install -g …`) goes into Pi Pocket's prefix. Pi's tools work best with git: macOS asks to install the Xcode Command Line Tools the first time something runs `git`, or run `xcode-select --install`.
|
|
52
|
+
|
|
53
|
+
## Updates
|
|
54
|
+
|
|
55
|
+
Menu → **Update Pi Pocket** updates the package in `app/`, as for any global npm install, and restarts. The Node.js in `node/` stays the one that the package installed. A newer package brings a newer Node.js; install it over the old one. It stops a running Pi Pocket first (work in progress continues when Pi Pocket starts again), and it keeps a newer `pi-pocket` that the app already updated to.
|
|
56
|
+
|
|
57
|
+
## Uninstall
|
|
58
|
+
|
|
59
|
+
A macOS package has no uninstaller of its own. Run this in Terminal:
|
|
60
|
+
|
|
61
|
+
```sh
|
|
62
|
+
"$HOME/Library/Application Support/Pi Pocket/uninstall.sh"
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Run it in Terminal, not from a Pi Pocket session: it must stop Pi Pocket, so it refuses to run inside it. It asks first. It quits Pi Pocket.app, stops a running Pi Pocket, with each command that its agents run, and removes `~/Library/Application Support/Pi Pocket`, Pi Pocket.app, Pi Pocket (console).app, the sign-in item, and the package receipts. Then it asks whether to delete your data in `~/.pi-pocket`. The default is No: your sessions and settings stay for the next install. `--yes` skips the first question; without a terminal it asks nothing and keeps the data, unless you add `--delete-data`. Only the default data folder is offered: one chosen with `PI_POCKET_DIR` or `--data` stays. Another Pi Pocket install on the same account (npm, or a git checkout) uses the same `~/.pi-pocket`: the question says so, and a yes deletes it for that install too.
|
|
66
|
+
|
|
67
|
+
## Install from Terminal
|
|
68
|
+
|
|
69
|
+
```sh
|
|
70
|
+
installer -pkg Pi-Pocket-0.29.0.pkg -target CurrentUserHomeDirectory
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
No `sudo`: the package refuses to install as root. For the sign-in item too, pass `-applyChoiceChangesXML` with a file that selects the choice `login`, as [`.github/workflows/macos.yml`](../.github/workflows/macos.yml) does. The install fails when the npm step fails; `install.log` says why.
|
|
74
|
+
|
|
75
|
+
## How it is built
|
|
76
|
+
|
|
77
|
+
[`.github/workflows/macos-installer.yml`](../.github/workflows/macos-installer.yml) builds it on GitHub's macOS runner for each published release with `pkgbuild` and `productbuild`, and attaches it to the release. Pi Pocket.app is compiled there with `swiftc` for arm64 and x86_64, joined with `lipo`, and signed ad hoc, unless the `macos-signing` environment also has a "Developer ID Application" certificate (`MACOS_APPLICATION_CERTIFICATE` and `MACOS_APPLICATION_PASSWORD`): then it is signed with it and the hardened runtime. Without that certificate the package is not notarized, as notarization refuses code that is signed ad hoc. It runs beside the npm publish and does not wait for it. Only a release build is signed, and only when the `macos-signing` environment has the "Developer ID Installer" certificate that the workflow names; with the notary secrets too, it is notarized and stapled. Limit that environment to `v*` tags and give it a reviewer.
|
|
78
|
+
|
|
79
|
+
[`.github/workflows/macos.yml`](../.github/workflows/macos.yml) runs on each pull request, on Apple silicon and on Intel: it builds the package with a package packed from the pull request, installs it without `sudo`, starts the console launcher, checks that it answers HTTP and that the sign-in link works, and uninstalls it while it runs. Then it installs it again with the sign-in item and opens Pi Pocket.app: it checks that no Terminal opens, that the window signed in with a one-time link, that a second start opens the first, and that **Quit** stops everything. It starts the sign-in item, installs over the running Pi Pocket (which keeps the sign-in item), and uninstalls it with the data. It also runs `npm run check` and the test suite, without the tests that do not pass on macOS yet. The workflow skips them by name, and `test/pip-board-ui.test.ts` as a whole:
|
|
80
|
+
|
|
81
|
+
- Tests that press Ctrl or Alt for a shortcut. On a Mac the app takes ⌘ and Option instead (`APPLE` in `web/ui.js`), so the shortcut does not come. The PiP board tests stop at their first Alt+A, and each later test in that file needs the page that it left.
|
|
82
|
+
- Time limits and animations: the performance limits of the design lint and the RSS parser, the stall limits of helpers, and the glide of new rows. The macOS runner is slower than these limits allow.
|
|
83
|
+
- Some browser tests of the design workspace, drafts, linked sessions, and Markdown extension points, which time out on the runner. Nobody has looked into them yet.
|
|
84
|
+
- 4 tests that passed in one run on the runner and failed in the next (a deck's keys, design versions, the gallery scan's time limit, and the limit wait's Retry now): they are flaky there, not wrong on a Mac.
|
|
85
|
+
|
|
86
|
+
Tests that need Linux's `/proc` skip by themselves on macOS.
|
|
87
|
+
|
|
88
|
+
Background tasks work on macOS since 0.30.0: Pi Pocket reads the process table with `ps`, and the environment of your own processes with `ps -E`, to follow a task's processes.
|
|
89
|
+
|
|
90
|
+
The install through the Installer app (a double-click), the Gatekeeper steps, signing, and notarization are not tested in CI, and the app has been tried only on GitHub's runners, not yet on a Mac of its own.
|
package/docs/map.md
CHANGED
|
@@ -4,7 +4,7 @@ Where things are in Pi Pocket, for agents working on it. [index.md](index.md) li
|
|
|
4
4
|
|
|
5
5
|
## Processes
|
|
6
6
|
|
|
7
|
-
`bin/pi-pocket.js` checks Node, then runs `src/launcher/main.ts`. In an npm install, Node strips no types from files in `node_modules`: `bin/strip-types.js` does it for Pi Pocket's own files there, in the launcher and (with `--import`) in the server. The launcher reads its options (`options.ts`), asks how devices connect (`access.ts`: this device, LAN, Cloudflare quick tunnel, Tailscale, Tailscale Serve), runs the server (`src/server/main.ts`) as a child, restarts it on exit code 75 or a crash, and keeps the tunnel up. When a server stops before it is ready while an update from the app is under way, it goes back to the version before: the commit and packages of a git checkout, or the kept copy of a global npm install (`rollBackUpdate` in `src/server/update-state.ts`,
|
|
7
|
+
`bin/pi-pocket.js` checks Node, then runs `src/launcher/main.ts`. In an npm install, Node strips no types from files in `node_modules`: `bin/strip-types.js` does it for Pi Pocket's own files there, in the launcher and (with `--import`) in the server. The launcher reads its options (`options.ts`), asks how devices connect (`access.ts`: this device, LAN, Cloudflare quick tunnel, Tailscale, Tailscale Serve), runs the server (`src/server/main.ts`) as a child (on a Unix socket with `--socket`, for a reverse proxy, with no access mode), restarts it on exit code 75 or a crash, and keeps the tunnel up. When a server stops before it is ready while an update from the app is under way, it goes back to the version before: the commit and packages of a git checkout, or the kept copy of a global npm install (`rollBackUpdate` in `src/server/update-state.ts`; it also imports `lock.ts`, and `socket-path.ts` to check `--socket`). `term.ts` draws its menu, panel, and QR code in the terminal. `desktop.ts` writes `launcher-running.json`, which tells the desktop apps where its server answers; `--desktop` runs it for them, with no menu, keys, or sign-in link, until its input closes ([desktop-app.md](desktop-app.md)). `serve.ts` drives the Tailscale CLI for Serve mode: every call has a timeout, the mount is checked before it is made, and it is taken down when the launcher quits unless it found the mount already in place (an adopted mount may be the owner's own `tailscale serve`). A receipt in the data folder (`serve-mount.json`) names a mount the launcher made, so the next start clears one a killed run left behind; a start in another mode on that port stops when it cannot, and leaving the mode from the menu keeps the mode when the mount stays. The launcher takes `launcher.lock` for its whole life and the server takes `harness.lock`. The server then opens one `PocketApp` and serves it with `http.ts`.
|
|
8
8
|
|
|
9
9
|
## Data (`~/.pi-pocket/`, or `PI_POCKET_DIR`)
|
|
10
10
|
|
|
@@ -12,6 +12,7 @@ Where things are in Pi Pocket, for agents working on it. [index.md](index.md) li
|
|
|
12
12
|
- `config.json`: people, roles, hashed tokens, settings. `push.json`: VAPID keys and push subscriptions. `provider-limits.json`: the limits that runs wait for now, kept only as a hint (a missing or damaged file means no limit is known).
|
|
13
13
|
- `launcher.json`: the launcher's access choice. `serve-mount.json`: the Tailscale Serve mount the launcher made, named by port, so a later start can clear it.
|
|
14
14
|
- `launcher.lock` and `harness.lock` (each with a `.identity` file): one launcher per data folder, and one server per data folder.
|
|
15
|
+
- `launcher-running.json`: the launcher that runs, and its server's local address, for the desktop apps ([desktop-app.md](desktop-app.md)).
|
|
15
16
|
- `uploads/<conversation>/`, `worktrees/` (sessions' git worktrees), `extensions/` (the owner's drop-ins), `themes/` (the owner's theme folders, and `.removed/` for removed ones), `browser/profile/` (the built-in browser's profile; each session's cookies live in memory only).
|
|
16
17
|
|
|
17
18
|
## Server: `src/server/`
|
|
@@ -22,7 +23,7 @@ A module split into parts keeps its name for the part others import, with the re
|
|
|
22
23
|
|
|
23
24
|
| File | Owns |
|
|
24
25
|
| ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
25
|
-
| `main.ts` | The server process: options, the port, signals, then `PocketApp.open` and `createHandler`
|
|
26
|
+
| `main.ts` | The server process: options, the port (or the Unix socket), signals, then `PocketApp.open` and `createHandler` |
|
|
26
27
|
| `app.ts` | `PocketApp`: opening the harness, reading state back at startup (`#recover`), the commit coordinator (`#committed`), connected tabs and their peek tiles, access checks (`canSee`, `requireSteer`, `requireDriver`), the session list (each session's subagents counted by state; for Priority, the oldest waiting call and how many wait (`approval`), a failed run's reason (`failure`), and failed subagents nobody dealt with (`failedAgents`)), every subagent for the subagents board (`subagents`, `setBoard`), `hello`, model list with Pi’s enabledModels scope (`modelList`), extensions on and off Bundle readers for artifacts (`artifactBundle`: the page and its assets by hash, `artifactAsset`: one manifest asset), which callers must check access for. |
|
|
27
28
|
| `attribution.ts` | Who Pi works for: who wrote each message to Pi or whose work it is (authors documents, from request ids), who queued each submission; read back at startup |
|
|
28
29
|
| `room.ts` | One conversation's live view for its tabs: Pi Durable's view, with the active transcript from `Conversation.context()` in place of its window of entries, plus `ROOM_DOCS`, sent every 90 ms as changes; its peek tile (`peek`, at most once a second) for the tabs that show it (`PocketApp.setPeeks`) |
|
|
@@ -39,10 +40,12 @@ A module split into parts keeps its name for the part others import, with the re
|
|
|
39
40
|
| `host.ts`, `reload.ts` | `PocketHost` (what extensions get) and `Approvals`; the extension loader: built-ins in `ORDER`, drop-ins (never with a name Pi Pocket keeps, `BUILT_IN_TOOLS`), live reload |
|
|
40
41
|
| `extension-web.ts` | What extension modules add to the app (`web`, their default export's second argument): routes, the browser module and its files' versions, events to it, commands (`BUILT_IN_COMMANDS`), cleanups; who may use each (`mayUse`), `POCKET_API` |
|
|
41
42
|
| `lock.ts` | One process per data folder |
|
|
43
|
+
| `no-follow.ts` | Opens a file never through a link as its last part, also on Windows, which has no `O_NOFOLLOW` |
|
|
44
|
+
| `socket-path.ts` | `--socket`: the Unix socket's path checked, its folder and the folders above it checked before listening, a stale socket replaced (never anything else), the socket opened to the folder's group (0660), and removed on stop (by Node, as the server closes); the launcher imports `parseSocketPath` and `socketArgument` |
|
|
42
45
|
| `errors.ts`, `paths.ts` | `HttpError`, `describe`, and input checks; `~` paths |
|
|
43
46
|
| `zip.ts` | `zip(entries)`: a ZIP32 archive in memory with CRC32, UTF-8 names, and deflate, with no dependency; Design's PPTX and HTML exports use it |
|
|
44
47
|
|
|
45
|
-
`extension-request.ts` owns extension routes' request-lifetime document/context capabilities and fresh person/source authorization. `conversation-usage.ts` reads core usage ledgers and response counters for a conversation route, with visible descendant sums and fresh access checks. `http/extension-routes.ts` binds named source parameters and supplies human linked-session capabilities. `linked-sessions.ts` keeps the short final-admission lease; its child context watches policy publications and checks current config when Durable enters admission. `models.ts` supplies exact local `host.modelInfo` metadata. `versions.ts` supplies `host.pocketVersion` and `hello.server.pocketVersion`, read by browser `pocket.pocketVersion`; `pocket.openConversation` delegates to normal `store.navigate`.
|
|
48
|
+
`extension-request.ts` owns extension routes' request-lifetime document/context capabilities and fresh person/source authorization. `conversation-usage.ts` reads core usage ledgers and response counters for a conversation route, with visible descendant sums and fresh access checks. `http/extension-routes.ts` binds named source parameters and supplies human linked-session capabilities. `linked-sessions.ts` keeps the short final-admission lease; its child context watches policy publications and checks current config when Durable enters admission. `models.ts` supplies exact local `host.modelInfo` metadata. `versions.ts` supplies `host.pocketVersion` and `hello.server.pocketVersion`, read by browser `pocket.pocketVersion`; `pocket.openConversation` delegates to normal `store.navigate`. `pending-approvals.ts` supplies `host.pendingApprovals`: read-only approval snapshots and events, filtered for a source session and stripped of argument text.
|
|
46
49
|
|
|
47
50
|
### People
|
|
48
51
|
|
|
@@ -67,6 +70,7 @@ A module split into parts keeps its name for the part others import, with the re
|
|
|
67
70
|
| `deadline.ts` | The quiet limit of commands: an environment wrapper that stops a command with no output for too long, unless the call gives its own `timeout` |
|
|
68
71
|
| `stall-facts.ts` | Pure helpers of the stall watches (subagents, Agent Teams): what changes while a conversation makes progress, what it waits on, times in words |
|
|
69
72
|
| `background.ts` | Background tasks: commands Pi runs detached, each watched by a durable task until it ends, and their ends go to Pi as one message, steered into the run in flight |
|
|
73
|
+
| `processes.ts` | How background tasks find, follow, and stop their processes on Linux (`/proc`), macOS (`ps`), and Windows (a PowerShell helper with job objects), each process known by its pid and start time |
|
|
70
74
|
| `schedules.ts`, `when.ts` | Scheduled messages (a durable task) and their time grammar |
|
|
71
75
|
| `goals.ts` | "Done when" checks |
|
|
72
76
|
| `titles.ts` | A short title for a session with a long first message, or one that runs a skill or prompt template, from the session's own model |
|
|
@@ -205,7 +209,7 @@ The agent's side of Design mode. `extensions/design.ts` installs it (see Extensi
|
|
|
205
209
|
| `updates.ts`, `update-state.ts`, `npm-install.ts`, `npm-update.ts` | Updates of Pi Pocket itself (`app.updates`, `host.updates`): how the copy was installed (`installKind`), the newest version (the registry's `latest` for npm, and `beta` too with the beta channel on; GitHub for the notes and for a git checkout; `versions.ts`'s `compareReleases` orders pre-releases for it), what stands in the way, packages installed beside the checkout or a package staged beside a global npm install, the move forward or the swap, the restart, and `recover`; `update-state.ts` keeps `.pocket-update/` and the copy kept for a swap back, and the launcher imports it to go back; `npm-install.ts` tells how the copy was installed and whether npm's folders can be written, and `npm-update.ts` stages a version beside a global install |
|
|
206
210
|
| `versions.ts` | Pi Pocket's versions compared, for gallery entries' and themes' `minPocket` (a pre-release counts as its release), and `compareReleases`, which orders pre-releases for updates |
|
|
207
211
|
|
|
208
|
-
Outside `src/`: `flake.nix` and `nix/` build Pi Pocket with Nix (`nix/package.nix`) and run it as a NixOS service (`nix/module.nix`, with `nix/manage-extensions.sh` to copy declared drop-ins). `nix/tests/` runs only under Nix; `npm test` skips it. The container build is `docker/Dockerfile` and `docker/entrypoint.sh` (with `.dockerignore` for the build context), `docker-compose.yml` runs it, and `.env.example` lists the host-side variables for Compose; [docker.md](docker.md) explains them.
|
|
212
|
+
Outside `src/`: `flake.nix` and `nix/` build Pi Pocket with Nix (`nix/package.nix`) and run it as a NixOS service (`nix/module.nix`, with `nix/manage-extensions.sh` to copy declared drop-ins). `nix/tests/` runs only under Nix; `npm test` skips it. The container build is `docker/Dockerfile` and `docker/entrypoint.sh` (with `.dockerignore` for the build context), `docker-compose.yml` runs it, and `.env.example` lists the host-side variables for Compose; [docker.md](docker.md) explains them. `packaging/windows/` is the Windows installer (`pi-pocket.iss` for Inno Setup, `build.ps1`, the desktop app `PiPocket.cs` with its manifest, the `pi-pocket.cmd` start script, `stop-pi-pocket.ps1`, and `install-app.mjs`, which installs the npm package); `.github/workflows/windows-installer.yml` builds it for each release and `windows.yml` tests it, and [windows.md](windows.md) explains it. `packaging/macos/` is the macOS package (`build.sh` for `pkgbuild` and `productbuild`, `distribution.xml`, the package scripts in `scripts/`, the desktop app `app/main.swift`, the `pi-pocket` launcher and its `.command` file for Terminal, `install-app.mjs`, `uninstall.sh`, and `login-item.sh`); `.github/workflows/macos-installer.yml` builds it for each release and `macos.yml` tests it, and [macos.md](macos.md) explains it. [desktop-app.md](desktop-app.md) explains the two desktop apps.
|
|
209
213
|
|
|
210
214
|
## Extensions: `src/server/extensions/`
|
|
211
215
|
|
|
@@ -341,4 +345,4 @@ The maskable icon places the 352 × 352 artwork on a 512 × 512 page with 80-pix
|
|
|
341
345
|
|
|
342
346
|
## Tests: `test/`
|
|
343
347
|
|
|
344
|
-
`npm test` runs every `*.test.ts` with Node's test runner. `helpers.ts` provides a scripted model (`scriptedModel(route)`: `faux-1`, `faux-2`, `faux-vision`), `openApp` (the same data folder again is a restart; `now` moves the clock), `newSession`, `say`, `until`, and `fakeTab`. The scripted model costs nothing: spend tests write `pi.usage` themselves. `browser.test.ts` drives a real Chromium, where one is installed, for the built-in browser, and the `*-ui.test.ts` files load the whole web app in it. `docs-examples.test.ts` loads the example extensions in `docs/examples/` as drop-ins. `extension-web.test.ts` covers extension modules' routes, browser module files, and events, `extension-loader.test.ts` the loader with a real registry, and `extension-ui.test.ts` their browser modules in the app, in Chromium. `memory.test.ts` checks the pending-lesson queue's access and approval safety. `relay*.test.ts` cover the relay and its connectors. `linked-sessions.test.ts` checks linked sessions: a repeated start or send acts once, a hidden origin stays hidden, the checks of whom Pi works for come first, and an unavailable model makes nothing. `gallery.test.ts` checks what the gallery takes from its index: a file name that leaves the extensions folder, a file whose hash differs, an install under a name that was on before (it stays off), a revoked version, and a theme that installs only as pinned and only when its CSS passes the theme check. The notch test in `mobile-ui.test.ts` fakes a notch's safe-area insets in Chromium and checks that the rail, the top bar, and the message box clear it. `turns.test.ts` runs `web/turns.js` in Node: how the transcript groups Pi's answers, and which calls can still run. `voice.test.ts` runs `web/voice.js` in Node with a stand-in speech recognizer: where dictated words land as people type. `hooks.test.ts` covers webhooks and `fence.ts`. `hooks-ui.test.ts` checks prompt editing on desktop and mobile. It also checks that deliveries use the edited instructions and that the HTTP endpoint rejects edits without permission. The rest of the web app has no tests: check a change to it in a browser, on a copy (`node test/serve.ts`: this folder's code, its own temporary data, a scripted model).
|
|
348
|
+
`npm test` runs every `*.test.ts` with Node's test runner. `helpers.ts` provides a scripted model (`scriptedModel(route)`: `faux-1`, `faux-2`, `faux-vision`), `openApp` (the same data folder again is a restart; `now` moves the clock), `newSession`, `say`, `until`, and `fakeTab`. The scripted model costs nothing: spend tests write `pi.usage` themselves. `browser.test.ts` drives a real Chromium, where one is installed, for the built-in browser, and the `*-ui.test.ts` files load the whole web app in it. `docs-examples.test.ts` loads the example extensions in `docs/examples/` as drop-ins. `extension-web.test.ts` covers extension modules' routes, browser module files, and events, `extension-loader.test.ts` the loader with a real registry, and `extension-ui.test.ts` their browser modules in the app, in Chromium. `memory.test.ts` checks the pending-lesson queue's access and approval safety. `relay*.test.ts` cover the relay and its connectors. `linked-sessions.test.ts` checks linked sessions: a repeated start or send acts once, a hidden origin stays hidden, the checks of whom Pi works for come first, and an unavailable model makes nothing. `gallery.test.ts` checks what the gallery takes from its index: a file name that leaves the extensions folder, a file whose hash differs, an install under a name that was on before (it stays off), a revoked version, and a theme that installs only as pinned and only when its CSS passes the theme check. The notch test in `mobile-ui.test.ts` fakes a notch's safe-area insets in Chromium and checks that the rail, the top bar, and the message box clear it. `turns.test.ts` runs `web/turns.js` in Node: how the transcript groups Pi's answers, and which calls can still run. `voice.test.ts` runs `web/voice.js` in Node with a stand-in speech recognizer: where dictated words land as people type. `hooks.test.ts` covers webhooks and `fence.ts`. `hooks-ui.test.ts` checks prompt editing on desktop and mobile. It also checks that deliveries use the edited instructions and that the HTTP endpoint rejects edits without permission. `main.test.ts` also checks `--socket`: unsafe folders, what it never removes, no TCP port (an empty `--socket` too), and a stale socket; `launcher-serve.test.ts`, that the launcher runs no `tailscale` command on a socket. The rest of the web app has no tests: check a change to it in a browser, on a copy (`node test/serve.ts`: this folder's code, its own temporary data, a scripted model).
|
package/docs/windows.md
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# The Windows installer
|
|
2
|
+
|
|
3
|
+
Each release has `Pi-Pocket-Setup-<version>.exe` on its [GitHub release page](https://github.com/TannerMidd/pi-pocket/releases), with a `.sha256` file beside it. It installs Pi Pocket for your Windows account, with no admin rights and no Node.js of your own. Windows 10 (1809) or newer on x64, or Windows 11 on Arm through x64 emulation.
|
|
4
|
+
|
|
5
|
+
The installer is thin: it puts Node.js and a small start script on the disk, then installs the `pi-pocket` npm package. Setup needs the internet for that step.
|
|
6
|
+
|
|
7
|
+
## SmartScreen
|
|
8
|
+
|
|
9
|
+
The installer is not code-signed yet, so Windows SmartScreen says "Windows protected your PC" the first time. To run it, select **More info**, then **Run anyway**. Download it only from the release page, and compare its SHA256 with the `.sha256` file if you want to be sure that it is the same file:
|
|
10
|
+
|
|
11
|
+
```powershell
|
|
12
|
+
Get-FileHash .\Pi-Pocket-Setup-0.29.0.exe -Algorithm SHA256
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## What it installs, and where
|
|
16
|
+
|
|
17
|
+
Everything goes in `%LOCALAPPDATA%\Pi Pocket` (`C:\Users\<you>\AppData\Local\Pi Pocket`):
|
|
18
|
+
|
|
19
|
+
| Folder or file | What it is |
|
|
20
|
+
| --------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
21
|
+
| `node\` | A portable Node.js LTS, the official `win-x64` zip. The build checks its SHA256 against the value pinned in [`packaging/windows/build.ps1`](../packaging/windows/build.ps1). |
|
|
22
|
+
| `app\` | A private npm prefix that holds the `pi-pocket` package. It is yours, so updates from the app work. |
|
|
23
|
+
| `Pi Pocket.exe` | The desktop app ([desktop-app.md](desktop-app.md)): the icon in the notification area and the window. Setup's build compiles it from `PiPocket.cs`. |
|
|
24
|
+
| `pi-pocket.cmd` | Starts the launcher with that Node.js and prefix, in a console. Arguments go to `pi-pocket` (`pi-pocket.cmd --help`). |
|
|
25
|
+
| `stop-pi-pocket.ps1` | What stops a running Pi Pocket for Setup and the uninstaller: the app, its launcher and server with the agents' commands, the window's Edge, and the tunnel. |
|
|
26
|
+
| `Edge profile\` | The Edge profile of the app's window, with its sign-in cookie. |
|
|
27
|
+
| `launcher.log` | What the app's launcher and server print, and `launcher.old.log` from the run before. It has no sign-in link. |
|
|
28
|
+
| `npm-cache\`, `install.log` | npm's cache, and what npm printed during Setup. |
|
|
29
|
+
|
|
30
|
+
Setup always uses its own Node.js, also when you have one: an update of your Node.js, or its removal, does not break Pi Pocket, and in-app updates always have a prefix that they can write. Your own Node.js and npm are not changed.
|
|
31
|
+
|
|
32
|
+
Your data (sessions, sign-ins, settings, extensions) stays in `%USERPROFILE%\.pi-pocket`, as with every other install.
|
|
33
|
+
|
|
34
|
+
Setup also makes:
|
|
35
|
+
|
|
36
|
+
- a Start menu entry, **Pi Pocket**, the desktop app. It opens Pi Pocket in a window of its own, already signed in, with no console window, and puts Pi Pocket's icon in the notification area: click it to open the window, or right-click it for **Open Pi Pocket**, **Restart server**, and **Quit Pi Pocket**. The server listens on this PC only. To sign in your phone, use Menu → **Sign in another device** in the window. Opening Pi Pocket again shows the window that runs; a second server never starts. The window is Microsoft Edge in app mode, with a profile of its own; without Edge, your default browser opens Pi Pocket. [desktop-app.md](desktop-app.md) says how it works.
|
|
37
|
+
- a Start menu entry, **Pi Pocket (console)**, which opens the launcher in a console window, as before: there you choose how other devices reach Pi Pocket (the local network, a Cloudflare tunnel, Tailscale), and it shows the sign-in link and its QR code. Close the console window, or press **q** in it, to stop it. When it runs, the app uses its server instead of starting one.
|
|
38
|
+
- with the task **Start Pi Pocket when I sign in to Windows** (off by default), a shortcut in your Startup folder. It starts the app with its icon only, without a window.
|
|
39
|
+
|
|
40
|
+
New sessions start in your user folder. **Quit Pi Pocket** stops the server, with each command that its agents run, and closes the window.
|
|
41
|
+
|
|
42
|
+
Inside sessions, `node` and `npm` are the installer's own, and a global npm install (`npm install -g …`) goes into Pi Pocket's prefix. Pi's `bash` tool needs [Git for Windows](https://git-scm.com/download/win), or another `bash.exe` on `PATH` (Pi's own Windows guide is `docs/windows.md` in the `@earendil-works/pi-coding-agent` package). Setup says so at the end when it cannot find Git Bash.
|
|
43
|
+
|
|
44
|
+
Background tasks (Pi's `background` tool) work on Windows since 0.30.0, with Git Bash. Windows has no process groups or signals, so Pi Pocket follows a task's processes another way: a small Windows PowerShell helper (no admin rights) reads the process table, puts each task in a job object, and ends a process only after it checks the process's start time. What is weaker than on Linux and macOS:
|
|
45
|
+
|
|
46
|
+
- A stop ends the processes by force at once, with no polite stop first.
|
|
47
|
+
- A task's job does not let its processes leave it (Git Bash leaves a job that allows it), so a program in a task that asks to start a process outside its job gets "access denied". A process started outside the task (through a service or the Task Scheduler) is not followed, and a task does not say what it left running.
|
|
48
|
+
- The task's first process holds a handle to its job, so a restarted server finds the job again while that process runs. Once it ended, a restarted server knows the processes found before the restart, and what they start directly; a process started through Git Bash (which starts a program as a new process) is then not followed.
|
|
49
|
+
- A PowerShell in Constrained Language mode (a locked-down machine) cannot load the helper: then background tasks do not start, and say why.
|
|
50
|
+
|
|
51
|
+
## Updates
|
|
52
|
+
|
|
53
|
+
Menu → **Update Pi Pocket** updates the package in `app\`, as for any global npm install, and restarts. The Node.js in `node\` stays the one that Setup installed. A newer installer brings a newer Node.js; run it over the old install. It stops a running Pi Pocket first (it asks), and it keeps a newer package that the app already updated to.
|
|
54
|
+
|
|
55
|
+
## Uninstall
|
|
56
|
+
|
|
57
|
+
Settings → Apps → Installed apps → **Pi Pocket** → Uninstall. It quits the app, stops a running Pi Pocket, with each command that its agents run, and removes `%LOCALAPPDATA%\Pi Pocket` (with the window's Edge profile) and the shortcuts. Then it asks whether to delete your data in `%USERPROFILE%\.pi-pocket`. The default is No: your sessions and settings stay for the next install. A silent uninstall (`unins000.exe /VERYSILENT`) always keeps them. Only the default data folder is offered: one chosen with `PI_POCKET_DIR` or `--data` stays, and so does a `.pi-pocket` that another Pi Pocket install on the same account uses.
|
|
58
|
+
|
|
59
|
+
## Silent install
|
|
60
|
+
|
|
61
|
+
```powershell
|
|
62
|
+
.\Pi-Pocket-Setup-0.29.0.exe /VERYSILENT /SUPPRESSMSGBOXES /NORESTART /TASKS=startup
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Leave out `/TASKS=startup` for no sign-in shortcut. The exit code is 20 when the npm step fails; `install.log` says why.
|
|
66
|
+
|
|
67
|
+
## How it is built
|
|
68
|
+
|
|
69
|
+
[`.github/workflows/windows-installer.yml`](../.github/workflows/windows-installer.yml) builds it on GitHub's Windows runner for each published release, with Inno Setup (its installer checked against a pinned SHA256 too), and attaches it to the release. `Pi Pocket.exe` is compiled with the C# compiler of the .NET Framework 4.x in Windows itself (`csc.exe`), so it needs no download. It runs beside the npm publish and does not wait for it. Only a release build is signed, and only when the `windows-signing` environment has the signing secrets that the workflow names; limit that environment to `v*` tags and give it a reviewer.
|
|
70
|
+
|
|
71
|
+
[`.github/workflows/windows.yml`](../.github/workflows/windows.yml) runs on each pull request: it builds the installer with a package packed from the pull request, installs it silently, starts the console launcher, checks that it answers HTTP and that the sign-in link works, and stops it. Then it opens the app from its Start menu entry, and checks that no console window shows, that Edge's window signed in with a one-time link, that a second start opens the first, and that **Quit** stops everything; it starts the app as the Startup shortcut does, and uninstalls it while it runs. It also runs `npm run check` and the part of the test suite that passes on Windows.
|
|
72
|
+
|
|
73
|
+
Windows is still the least tested platform. The browser tests and most of the test suite do not run on Windows yet, and the app has been tried only on GitHub's runners, not yet on a PC of its own.
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-pocket",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.30.0-beta.2",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "pi-pocket",
|
|
9
|
-
"version": "0.
|
|
9
|
+
"version": "0.30.0-beta.2",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@earendil-works/chord": "1.
|
|
13
|
-
"@earendil-works/pi-ai": "1.
|
|
14
|
-
"@earendil-works/pi-codemode": "1.
|
|
15
|
-
"@earendil-works/pi-coding-agent": "1.
|
|
16
|
-
"@earendil-works/pi-durable": "1.
|
|
17
|
-
"@earendil-works/pi-mcp": "1.
|
|
18
|
-
"@earendil-works/pi-schema": "1.
|
|
12
|
+
"@earendil-works/chord": "1.6.0",
|
|
13
|
+
"@earendil-works/pi-ai": "1.6.0",
|
|
14
|
+
"@earendil-works/pi-codemode": "1.6.0",
|
|
15
|
+
"@earendil-works/pi-coding-agent": "1.6.0",
|
|
16
|
+
"@earendil-works/pi-durable": "1.6.0",
|
|
17
|
+
"@earendil-works/pi-mcp": "1.6.0",
|
|
18
|
+
"@earendil-works/pi-schema": "1.6.0",
|
|
19
19
|
"dompurify": "^3.4.17",
|
|
20
20
|
"heic-convert": "^2.1.0",
|
|
21
21
|
"htm": "^3.1.1",
|
|
@@ -442,21 +442,21 @@
|
|
|
442
442
|
}
|
|
443
443
|
},
|
|
444
444
|
"node_modules/@earendil-works/chord": {
|
|
445
|
-
"version": "1.
|
|
446
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/chord/-/chord-1.
|
|
447
|
-
"integrity": "sha512-
|
|
445
|
+
"version": "1.6.0",
|
|
446
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/chord/-/chord-1.6.0.tgz",
|
|
447
|
+
"integrity": "sha512-8dQXEKUR6qQPc4zNEblmv6hEfr2JAAU+nUprt+mhtdfRRZzl1At5ZhnJqTqesElAdR7RpAyaRIAilyteNHzyWA==",
|
|
448
448
|
"license": "MIT",
|
|
449
449
|
"dependencies": {
|
|
450
|
-
"@earendil-works/pi-schema": "1.
|
|
451
|
-
"@earendil-works/pi-telemetry": "1.
|
|
450
|
+
"@earendil-works/pi-schema": "1.6.0",
|
|
451
|
+
"@earendil-works/pi-telemetry": "1.6.0"
|
|
452
452
|
},
|
|
453
453
|
"engines": {
|
|
454
454
|
"node": ">=22.19.0"
|
|
455
455
|
},
|
|
456
456
|
"peerDependencies": {
|
|
457
|
-
"esbuild": "0.28.2",
|
|
458
|
-
"react": "19.3.0",
|
|
459
|
-
"ws": "8.21.0"
|
|
457
|
+
"esbuild": "^0.28.2",
|
|
458
|
+
"react": "^19.3.0",
|
|
459
|
+
"ws": "^8.21.0"
|
|
460
460
|
},
|
|
461
461
|
"peerDependenciesMeta": {
|
|
462
462
|
"esbuild": {
|
|
@@ -471,33 +471,33 @@
|
|
|
471
471
|
}
|
|
472
472
|
},
|
|
473
473
|
"node_modules/@earendil-works/pi-agent-core": {
|
|
474
|
-
"version": "1.
|
|
475
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-agent-core/-/pi-agent-core-1.
|
|
476
|
-
"integrity": "sha512-
|
|
474
|
+
"version": "1.6.0",
|
|
475
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-agent-core/-/pi-agent-core-1.6.0.tgz",
|
|
476
|
+
"integrity": "sha512-IU/x+2XtE4KIdIkEndZssdLPbIUR38Btj+Q7vjIIXIK7GSamLtDH5jOw/dzBWAvWFAgZ2dslF5sPc6GcGOnS+w==",
|
|
477
477
|
"license": "MIT",
|
|
478
478
|
"dependencies": {
|
|
479
|
-
"@earendil-works/pi-ai": "1.
|
|
480
|
-
"@earendil-works/pi-schema": "1.
|
|
479
|
+
"@earendil-works/pi-ai": "1.6.0",
|
|
480
|
+
"@earendil-works/pi-schema": "1.6.0"
|
|
481
481
|
},
|
|
482
482
|
"engines": {
|
|
483
483
|
"node": ">=22.19.0"
|
|
484
484
|
}
|
|
485
485
|
},
|
|
486
486
|
"node_modules/@earendil-works/pi-ai": {
|
|
487
|
-
"version": "1.
|
|
488
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-ai/-/pi-ai-1.
|
|
489
|
-
"integrity": "sha512-
|
|
487
|
+
"version": "1.6.0",
|
|
488
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-ai/-/pi-ai-1.6.0.tgz",
|
|
489
|
+
"integrity": "sha512-9hL+eygFDEiFp//cydeUfmFsKmEqpmvsNPb10Y1W8+m5K9O+sx1hMStfu6nukrBD5sl6mP4RykCYBBNEgsVLfw==",
|
|
490
490
|
"license": "MIT",
|
|
491
491
|
"dependencies": {
|
|
492
492
|
"@anthropic-ai/sdk": "0.129.0",
|
|
493
493
|
"@aws-sdk/client-bedrock-runtime": "3.1127.0",
|
|
494
|
-
"@earendil-works/pi-schema": "1.
|
|
495
|
-
"@earendil-works/pi-telemetry": "1.
|
|
496
|
-
"@google/genai": "2.
|
|
494
|
+
"@earendil-works/pi-schema": "1.6.0",
|
|
495
|
+
"@earendil-works/pi-telemetry": "1.6.0",
|
|
496
|
+
"@google/genai": "2.32.0",
|
|
497
497
|
"@smithy/node-http-handler": "4.12.1",
|
|
498
498
|
"http-proxy-agent": "9.1.0",
|
|
499
499
|
"https-proxy-agent": "9.1.0",
|
|
500
|
-
"openai": "7.
|
|
500
|
+
"openai": "7.59.0",
|
|
501
501
|
"partial-json": "0.1.7"
|
|
502
502
|
},
|
|
503
503
|
"bin": {
|
|
@@ -508,9 +508,9 @@
|
|
|
508
508
|
}
|
|
509
509
|
},
|
|
510
510
|
"node_modules/@earendil-works/pi-codemode": {
|
|
511
|
-
"version": "1.
|
|
512
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-codemode/-/pi-codemode-1.
|
|
513
|
-
"integrity": "sha512-
|
|
511
|
+
"version": "1.6.0",
|
|
512
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-codemode/-/pi-codemode-1.6.0.tgz",
|
|
513
|
+
"integrity": "sha512-GAgAy7iJCVbeiuqq2dTIuNj3aXTMUeTF8Nu8LZs72e8ueGGDU5L3/D8VxzTHALIpQ1/q8u1tfmB3iYS2Nopchw==",
|
|
514
514
|
"license": "MIT",
|
|
515
515
|
"dependencies": {
|
|
516
516
|
"quickjs-wasi": "3.6.2"
|
|
@@ -520,16 +520,16 @@
|
|
|
520
520
|
}
|
|
521
521
|
},
|
|
522
522
|
"node_modules/@earendil-works/pi-coding-agent": {
|
|
523
|
-
"version": "1.
|
|
524
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-coding-agent/-/pi-coding-agent-1.
|
|
525
|
-
"integrity": "sha512-
|
|
523
|
+
"version": "1.6.0",
|
|
524
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-coding-agent/-/pi-coding-agent-1.6.0.tgz",
|
|
525
|
+
"integrity": "sha512-zX1BVEsshx7A2MRuQ6jfr3RJGWw4Wn+vLq5ZfmlvS1RskhRmByaSZVXH/zcwRrWHO7qPgs98pNCbPOEti/t0fQ==",
|
|
526
526
|
"license": "MIT",
|
|
527
527
|
"dependencies": {
|
|
528
|
-
"@earendil-works/pi-agent-core": "1.
|
|
529
|
-
"@earendil-works/pi-ai": "1.
|
|
530
|
-
"@earendil-works/pi-codemode": "1.
|
|
531
|
-
"@earendil-works/pi-mcp": "1.
|
|
532
|
-
"@earendil-works/pi-tui": "1.
|
|
528
|
+
"@earendil-works/pi-agent-core": "1.6.0",
|
|
529
|
+
"@earendil-works/pi-ai": "1.6.0",
|
|
530
|
+
"@earendil-works/pi-codemode": "1.6.0",
|
|
531
|
+
"@earendil-works/pi-mcp": "1.6.0",
|
|
532
|
+
"@earendil-works/pi-tui": "1.6.0",
|
|
533
533
|
"@silvia-odwyer/photon-node": "0.3.4",
|
|
534
534
|
"brace-expansion": "5.0.12",
|
|
535
535
|
"chalk": "6.0.0",
|
|
@@ -545,7 +545,7 @@
|
|
|
545
545
|
"quickjs-wasi": "3.6.2",
|
|
546
546
|
"semver": "7.8.5",
|
|
547
547
|
"typebox": "1.3.27",
|
|
548
|
-
"undici": "8.12.
|
|
548
|
+
"undici": "8.12.4",
|
|
549
549
|
"yaml": "2.9.0"
|
|
550
550
|
},
|
|
551
551
|
"bin": {
|
|
@@ -572,16 +572,16 @@
|
|
|
572
572
|
}
|
|
573
573
|
},
|
|
574
574
|
"node_modules/@earendil-works/pi-durable": {
|
|
575
|
-
"version": "1.
|
|
576
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-durable/-/pi-durable-1.
|
|
577
|
-
"integrity": "sha512-
|
|
575
|
+
"version": "1.6.0",
|
|
576
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-durable/-/pi-durable-1.6.0.tgz",
|
|
577
|
+
"integrity": "sha512-nyPjInj/7ZjLEUCDMS7oNGRj1ynftOCVqXilWRBhIuT/xoRHrPy5yFNle/64hvs3F1rukMZ7Ar/4reA7auvUWQ==",
|
|
578
578
|
"license": "MIT",
|
|
579
579
|
"dependencies": {
|
|
580
|
-
"@earendil-works/chord": "1.
|
|
581
|
-
"@earendil-works/pi-ai": "1.
|
|
582
|
-
"@earendil-works/pi-codemode": "1.
|
|
583
|
-
"@earendil-works/pi-schema": "1.
|
|
584
|
-
"@earendil-works/pi-telemetry": "1.
|
|
580
|
+
"@earendil-works/chord": "1.6.0",
|
|
581
|
+
"@earendil-works/pi-ai": "1.6.0",
|
|
582
|
+
"@earendil-works/pi-codemode": "1.6.0",
|
|
583
|
+
"@earendil-works/pi-schema": "1.6.0",
|
|
584
|
+
"@earendil-works/pi-telemetry": "1.6.0",
|
|
585
585
|
"@silvia-odwyer/photon": "0.3.3",
|
|
586
586
|
"diff": "8.0.4"
|
|
587
587
|
},
|
|
@@ -590,9 +590,9 @@
|
|
|
590
590
|
}
|
|
591
591
|
},
|
|
592
592
|
"node_modules/@earendil-works/pi-mcp": {
|
|
593
|
-
"version": "1.
|
|
594
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-mcp/-/pi-mcp-1.
|
|
595
|
-
"integrity": "sha512-
|
|
593
|
+
"version": "1.6.0",
|
|
594
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-mcp/-/pi-mcp-1.6.0.tgz",
|
|
595
|
+
"integrity": "sha512-dhqAR6MP8Fp3b8LEcBFOyxMZpGSozUAdzF0Dbl7OvojsjZrQsDV3ZKn85WRbwjHb4WjQUCVBsIZXwoyQxXeunw==",
|
|
596
596
|
"license": "MIT",
|
|
597
597
|
"dependencies": {
|
|
598
598
|
"cross-spawn": "7.0.6"
|
|
@@ -602,27 +602,27 @@
|
|
|
602
602
|
}
|
|
603
603
|
},
|
|
604
604
|
"node_modules/@earendil-works/pi-schema": {
|
|
605
|
-
"version": "1.
|
|
606
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-schema/-/pi-schema-1.
|
|
607
|
-
"integrity": "sha512-
|
|
605
|
+
"version": "1.6.0",
|
|
606
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-schema/-/pi-schema-1.6.0.tgz",
|
|
607
|
+
"integrity": "sha512-jD0VRCUcFzWQ5zN82pOuoHNN42/3pu4E5krtpiKknvPq4g2m+fuO38lj+xnZhuVpYcd2G0qlmr8lE6ZMzkad7Q==",
|
|
608
608
|
"license": "MIT",
|
|
609
609
|
"engines": {
|
|
610
610
|
"node": ">=22.19.0"
|
|
611
611
|
}
|
|
612
612
|
},
|
|
613
613
|
"node_modules/@earendil-works/pi-telemetry": {
|
|
614
|
-
"version": "1.
|
|
615
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-telemetry/-/pi-telemetry-1.
|
|
616
|
-
"integrity": "sha512-
|
|
614
|
+
"version": "1.6.0",
|
|
615
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-telemetry/-/pi-telemetry-1.6.0.tgz",
|
|
616
|
+
"integrity": "sha512-MNL0TvtpgoSfX7mBLSVgzxTW6yvT8VLEpHvbWnZsIp92FtqVvx+4q9DxWZdX8KvcQqBs0GseAgVnLdVFinjN9Q==",
|
|
617
617
|
"license": "MIT",
|
|
618
618
|
"engines": {
|
|
619
619
|
"node": ">=22.19.0"
|
|
620
620
|
}
|
|
621
621
|
},
|
|
622
622
|
"node_modules/@earendil-works/pi-tui": {
|
|
623
|
-
"version": "1.
|
|
624
|
-
"resolved": "https://registry.npmjs.org/@earendil-works/pi-tui/-/pi-tui-1.
|
|
625
|
-
"integrity": "sha512-
|
|
623
|
+
"version": "1.6.0",
|
|
624
|
+
"resolved": "https://registry.npmjs.org/@earendil-works/pi-tui/-/pi-tui-1.6.0.tgz",
|
|
625
|
+
"integrity": "sha512-nVtWZ4rYr3KHDla3skGAWG5XoITEUJCoEx1AsWv1yKxV7+v86ulD2hxVn/P+COI6jsoeQmj3orqHbCHZwAUsUg==",
|
|
626
626
|
"license": "MIT",
|
|
627
627
|
"dependencies": {
|
|
628
628
|
"get-east-asian-width": "1.6.0",
|
|
@@ -753,9 +753,9 @@
|
|
|
753
753
|
}
|
|
754
754
|
},
|
|
755
755
|
"node_modules/@google/genai": {
|
|
756
|
-
"version": "2.
|
|
757
|
-
"resolved": "https://registry.npmjs.org/@google/genai/-/genai-2.
|
|
758
|
-
"integrity": "sha512
|
|
756
|
+
"version": "2.32.0",
|
|
757
|
+
"resolved": "https://registry.npmjs.org/@google/genai/-/genai-2.32.0.tgz",
|
|
758
|
+
"integrity": "sha512-60c79uXpR0a47bmGqDxbXEBuQUalNmwo5mx5kqb91jIW4FoqpsLSt86DeVhRhtH5+s/16Wqxt3sXzFQn2U1OHQ==",
|
|
759
759
|
"hasInstallScript": true,
|
|
760
760
|
"license": "Apache-2.0",
|
|
761
761
|
"dependencies": {
|
|
@@ -2587,9 +2587,9 @@
|
|
|
2587
2587
|
}
|
|
2588
2588
|
},
|
|
2589
2589
|
"node_modules/openai": {
|
|
2590
|
-
"version": "7.
|
|
2591
|
-
"resolved": "https://registry.npmjs.org/openai/-/openai-7.
|
|
2592
|
-
"integrity": "sha512-
|
|
2590
|
+
"version": "7.59.0",
|
|
2591
|
+
"resolved": "https://registry.npmjs.org/openai/-/openai-7.59.0.tgz",
|
|
2592
|
+
"integrity": "sha512-wPYKJkLPFEdNJ2tThSg4jE1Ptsv4X3u8g8LIvu0Qz/UIhsKeCzl73rl48PtQsDVrJL/ku0liXOsbyd2TsRsPJw==",
|
|
2593
2593
|
"license": "Apache-2.0",
|
|
2594
2594
|
"engines": {
|
|
2595
2595
|
"node": ">=22.0.0"
|
|
@@ -2598,6 +2598,7 @@
|
|
|
2598
2598
|
"@aws-sdk/credential-provider-node": ">=3.972.0 <4",
|
|
2599
2599
|
"@smithy/hash-node": ">=4.3.0 <5",
|
|
2600
2600
|
"@smithy/signature-v4": ">=5.4.0 <6",
|
|
2601
|
+
"google-auth-library": ">=9.15.1 <12",
|
|
2601
2602
|
"undici": ">=5 <9",
|
|
2602
2603
|
"ws": "^8.21.0",
|
|
2603
2604
|
"zod": "^3.25 || ^4.0"
|
|
@@ -2612,6 +2613,9 @@
|
|
|
2612
2613
|
"@smithy/signature-v4": {
|
|
2613
2614
|
"optional": true
|
|
2614
2615
|
},
|
|
2616
|
+
"google-auth-library": {
|
|
2617
|
+
"optional": true
|
|
2618
|
+
},
|
|
2615
2619
|
"undici": {
|
|
2616
2620
|
"optional": true
|
|
2617
2621
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pi-pocket",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.30.0-beta.2",
|
|
4
4
|
"description": "A durable, multiplayer, mobile-first web app for Pi agents, built on Pi Durable",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pi",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"start": "node bin/pi-pocket.js",
|
|
45
45
|
"dev": "node bin/pi-pocket.js --cwd .",
|
|
46
46
|
"check": "tsc --noEmit -p . && node test/types-file.ts && node docs-site/check-reference.mjs",
|
|
47
|
-
"test": "node --test --test-concurrency=4 test/*.test.ts",
|
|
47
|
+
"test": "node --test --test-concurrency=4 --test-timeout=600000 test/*.test.ts",
|
|
48
48
|
"site:publish": "gh workflow run pages.yml",
|
|
49
49
|
"format": "eslint --fix . && prettier --write .",
|
|
50
50
|
"format:check": "prettier --check . && eslint .",
|
|
@@ -54,13 +54,13 @@
|
|
|
54
54
|
"prepublishOnly": "npm run check && npm run lint && npm test"
|
|
55
55
|
},
|
|
56
56
|
"dependencies": {
|
|
57
|
-
"@earendil-works/chord": "1.
|
|
58
|
-
"@earendil-works/pi-ai": "1.
|
|
59
|
-
"@earendil-works/pi-codemode": "1.
|
|
60
|
-
"@earendil-works/pi-coding-agent": "1.
|
|
61
|
-
"@earendil-works/pi-durable": "1.
|
|
62
|
-
"@earendil-works/pi-mcp": "1.
|
|
63
|
-
"@earendil-works/pi-schema": "1.
|
|
57
|
+
"@earendil-works/chord": "1.6.0",
|
|
58
|
+
"@earendil-works/pi-ai": "1.6.0",
|
|
59
|
+
"@earendil-works/pi-codemode": "1.6.0",
|
|
60
|
+
"@earendil-works/pi-coding-agent": "1.6.0",
|
|
61
|
+
"@earendil-works/pi-durable": "1.6.0",
|
|
62
|
+
"@earendil-works/pi-mcp": "1.6.0",
|
|
63
|
+
"@earendil-works/pi-schema": "1.6.0",
|
|
64
64
|
"dompurify": "^3.4.17",
|
|
65
65
|
"heic-convert": "^2.1.0",
|
|
66
66
|
"htm": "^3.1.1",
|