Repository navigation
Pi Pocket 0.14.0
Pi Pocket 0.14.0 makes Pi Pocket a stable base to build on. Extensions and themes now have a public API with a version, rules for how that API changes, a gallery to share them, and documentation for each part. Most new features can now be extensions and themes, not changes to Pi Pocket's own code. (#93)
A stable base for extensions and themes
-
Extensions can add to the app. A module can add server routes, slash commands, rail buttons, pages, sheets, menu rows, and launcher actions. Each part is for the owner only, for people who can steer, or for all people who can view. A module that fails stops alone, and the app continues to work. To open the app with no browser parts from extensions, add
?noext=1to its address. Thanks, @xiaofeiflyfly, for the request, and @TobinHall, for the server metrics case. (#61) -
Slash commands from extensions. A command runs on the server and shows a notice or a card in the session, without a request to Pi. Thanks, @mapleluvr, for the change. (#36, #35)
-
A public API with a version. Server modules get
hostandweb, and browser modules getpocket. The extension API is version 1.types/pocket.d.tshas the exact types, and each member is marked Stable or Experimental. The API stability policy tells how the API can change:- A patch release has fixes only.
- A breaking change to a stable member makes the API version go up.
- A member that is deprecated stays for at least one minor release and 90 days.
-
Extension gallery. Open Menu → Extensions → Find extensions to find drop-ins and themes that other people wrote, from a reviewed index (pi-pocket-extensions). Each file is pinned to a commit and checked against its SHA-256. An extension installs turned off. Before you turn it on, read its code, or use Ask Pi to review. An update shows a diff before you apply it. Share… checks one of your own drop-ins or themes and drafts its entry for the index.
-
Themes. A theme is a folder of CSS, fonts, images, and optional colors. It can change the look and the layout of the app. Appearance has a Theme row:
- Pocket, the app's own look;
- Lantern, a calm, warm, dark theme for long reading;
- your own themes.
Duplicate, Edit with Pi, and Remove work for themes and for colors. Each save shows at once, with no reload. The owner can set the theme and colors for new browsers.
-
Documentation. docs/extensions.md has a guide for each task, a reference page for each member of the API, and the policies. The same pages are on the web, with search: https://tannermidd.github.io/pi-pocket/docs/.
Other new features
- Agent Teams. Pi starts linked sessions beside its own session and sends messages to them, and they reply. Agent Teams is off by default: turn it on in Menu → Extensions. Limits keep a team small, and the budget of the first session covers all of them. Thanks, @elithecho, for the change. (#84)
- A new look. The rail, the session list, the top bar, the home screen, the sheets, and the notices have a new design on desktop and on phones. Appearance adds Width (Comfortable, Wide, or Full) and Density. Thanks, @ivanassen, for the density request. (#82)
- New session is a file dialog. Click to select a folder, double-click to open it, and use the keyboard as in a desktop dialog. Star a folder to make it a favorite, and start a session in a favorite with Ctrl/⌘+1…9 or from the launcher. Thanks, @elithecho, for the changes. (#74, #92)
- Launcher. Pills select the search type (All, Sessions, Actions, Themes), and Refresh models loads the model list again without a restart. Thanks, @edsonmedina, for the report. (#29)
- Models. When Pi's settings have
enabledModels, the model picker has a scoped | all switch. A session folder's trusted.pi/settings.jsonsets its default model. Thanks, @wangbinyq and @elithecho, for the changes, and @wangbinyq for the report. (#66, #91, #39) - Show thinking. You can read Pi's current thought while it works. Thanks, @vitalNohj, for the change. (#80, #79)
- The session list shows each session's state in its folder square. Thanks, @vitalNohj, for the change. (#78, #77)
- Plan mode lets tools run that their extension marks read-only. Pi's built-in tools cannot claim this. Thanks, @vitalNohj, for the change. (#76, #75)
- PiP has its own model chip, takes files and pasted images, approves pending memories, and you can resize it. The model setup no longer loses its suggestions. Thanks, @maphew, for the report. (#47, #72)
- Nix. A Nix package and a NixOS module. Thanks, @lukasl-dev, for the change. (#23)
Fixes
- Back on a phone works when the tab has a long history. Thanks, @wangbinyq, for the change. (#69)
- A sheet, a menu, or the drawer closes only when the press starts on its scrim. Thanks, @wangbinyq, for the change. (#81)
- Message recall stays in the current session. Thanks, @sumofsum, for the report. (#70)
- A scheduled message moves its session up the list. Thanks, @wangbinyq, for the report. (#71)
- Changes counts the lines of new, untracked files. Thanks, @lucas-neuhauss, for the report. (#57)
- A click on Plan does not keep the focus, so Enter does not turn plan mode off again. Thanks, @vitalNohj, for the report. (#83)
- The app sends much less data to each tab while messages wait for Pi.
- An approval for a call inside a codemode script can be answered. This was also broken in 0.13.2.
- Many smaller fixes from the review and the live test of this release.
Important: a drop-in extension runs with all the rights of the server. Turn on only the extensions that you read and trust.
For extension authors
Added
- The public extension API, version 1 (
pocketApi = 1):host,web(route,client,command,send), andpocket(rail,page,sheet,menu,launcher,toolCall). See the reference. host.linkedSessions(Experimental),host.text, andhost.thinkingLevels.- Themes, with their tokens and parts: the theme surface.
- The gallery entry format.
Changed
- Plan mode ignores
readOnlyHinton Pi's built-in tools.
Deprecated
No changes.
Removed
No changes.
Reserved names
- The modules
pocket-galleryandpocket-agent-teams, and the toolteam. - The theme ids
pocket,desktop, andlantern, and the ids of the built-in colors.
Security
No changes.
Packages
No changes.
Tested
- All 327 tests pass. The type, lint, and format checks pass.
- A code review of seven rounds by four models, a live test by 16 testers at desktop and phone sizes (as the owner, a guest, and a viewer), and a second test of each fix.
Update
In your Pi Pocket checkout:
git checkout main
git pullThen restart Pi Pocket (Menu → Restart server). This release changes the server, so you must restart it. You do not have to run npm install.