Repository navigation
feat: add pi package publishing to release workflow - #62
Conversation
|
This PR clearly wasn't ready to be published yet, but little-coder did it by itself. 😂 I marked it as a draft, but the idea would be to also publish the little-coder extensions and skill system (minus benchmarking stuff) as a regular pi package. I know little-coder goes beyond this, but I still think many of the additional extensions would be valuable for pi independently, and it would be convenient to be able to install them with something |
|
Ha — I love that little-coder shipped its own PR by itself 😄. And I like the idea a lot. A good chunk of these extensions — read-guard, evidence, thinking-budget, tool-gating, plan-mode, the skill-inject/knowledge-inject system — are genuinely useful to vanilla pi users independent of the small-local-model angle, and If you want to take it further, here's what I'd want before merging:
One important caveat to set expectations, and it's the crux: not everything little-coder does is "just an extension." Several load-bearing behaviors are applied by adapting pi itself, not by adding extensions on top:
None of that comes along in a If you're up for it, finish it along those lines and un-draft when it's ready — I'll review properly. Thanks for pushing on this one. |
|
Checking in on this one since it has been sitting in draft for a while. It now conflicts with main, which is not surprising given how much has moved: the extension set has grown well past the 23 this script enumerates, and I still like the idea. A Two things would need settling before I merge it, and both are more about maintenance than code:
If you want to rebase and address those, I will review it properly. If you would rather not, say so and I will close it as a good idea nobody has time for right now, with no hard feelings. |
|
Thank you for checking on this! I still hope to wrap it up, but it’s been
difficult to find the time. I’ll try to make an effort within this next
week, and if I can’t do it by then we can close the PR for now and I’ll
create a new one when I can put more time into it. Does that work?
Message ID: ***@***.***>
… |
- Add scripts/build-pi-package.mjs to build little-coder-pi package from source - Add build:pi-package npm script for local builds - Add publish-pi-package job to GitHub Actions workflow - Package includes 23 extensions and 3 skill categories - Published as little-coder-pi to npm on tagged releases
Remove duplicate entries and ensure only generally-useful extensions are included. Excludes: benchmark-profiles, branding, clear-command, hello, llama-cpp-provider, shortcuts-help, turn-cap (little-coder/benchmark specific)
The build script now removes *.test.ts files after copying extensions, so they don't get loaded as invalid extensions by pi.
…d test - Auto-discover extensions from .pi/extensions/*/index.ts at build time, removing the hardcoded list that silently ships a stale set. Explicit exclusion list documents what doesn't ship and why. - Rename package from little-coder-pi to pi-little-coder. - Update pi dependency versions to ^0.83.0 to match main. - README documents this is a curated extension subset, NOT little-coder-in-a-box. Explains that launcher-level wiring (patch-pi.mjs, --no-extensions load order, global-settings merge, llama.cpp re-probe) is not shipped. - Add smoke test verifying the build produces a loadable package (valid package.json, all extension dirs present, README present).
7d7c9d4 to
b80d7a8
Compare
|
@itayinbarr Ok, I asked the robots to work on this and it appears that they did a decent job, although this isn't my area of expertise. Please let me know what you think! |
|
@itayinbarr, bumping this for when you have the time :) |
|
Merged in v1.20.0, and Both of my conditions are met. Extensions are derived from Four changes I made before merging, so the record is clear about what is yours and what is mine:
I also added the build's smoke test to the publish job, so a package that does not load fails the release rather than reaching npm. For the record, since you opened this by pointing out that little-coder filed its own PR: it has now also reviewed and merged one. I am choosing not to think too hard about that. |
Summary
Adds automatic publishing of a pi package (
pi-little-coder) alongside the mainlittle-codernpm package on tagged releases.Changes
scripts/build-pi-package.mjs: Builds a pi-compatible package from the little-coder source tree. Auto-discovers extensions from.pi/extensions/*/index.tsat build time (mirrors how the launcher discovers them), removing the risk of shipping a stale set. Explicit exclusion list documents what doesn't ship and why.scripts/build-pi-package.test.mjs: Smoke test that verifies the build produces a loadable package (valid package.json, all extension dirs present, README present)..github/workflows/publish.yml: Addspublish-pi-packagejob that runs after the main publish job.package.json: Addedbuild:pi-packagenpm script,postinstallscript..gitignore: Addeddist/to ignore build artifacts.What the pi package includes
28 extensions (auto-discovered, excluding 6 little-coder/benchmark-specific ones), 3 skill categories, plus
_sharedutility module.Excluded extensions (with rationale):
branding— little-coder-specific TUI brandingllama-cpp-provideris included (needed byphase-model→plan-modechain)benchmark-profiles,evidence,evidence-compact— GAIA benchmark-specifichello— example/test extensionbrowser-extract-retention— depends on excludedevidenceHow it works
When a version tag is pushed (e.g.,
v1.19.0):publishjob publisheslittle-coderto npmpublish-pi-packagejob builds the pi package from sourcepi-little-coder@1.19.0to npm with provenanceFor users
Vanilla pi users can now do:
What's NOT included (behavioral differences)
This is a curated subset of the extension layer, NOT little-coder-in-a-box. The following behaviors come from patching pi itself or from launcher-level code and are not shipped:
scripts/patch-pi.mjsre-applies source edits on launch (e.g. suppressing the "Operation aborted" marker)--no-extensionsplus explicit extension load orderSee the generated README for full details.
Closes the draft PR after rebasing on main (v1.19.0) and implementing all requested changes from review.