Repository navigation
refactor(packs): consume acp-kernel 0.0.66 pack API - #403
Merged
Merged
Conversation
added 2 commits
September 12, 2026 22:18
…acks Fixes #401 - src/packs/* deleted (229 lines): types/sanitize/lean/builtin/dir all live in the kernel now (acp-kernel #259/#260, v0.0.66) - src/prompt-pack.ts rewritten on kernel exports; external surface (packResolver/resolveActivePack/mergeSurface/readToolSurfaceWithPacks) unchanged - pi-specific surface (PiPromptSections tri-state, tool extras, delegatePrompt) read from surface.adapters.pi and sanitized adapter-side; kernel treats it as opaque data - lean assertions moved to kernel leanPack.adapters.pi (aligned recall rules from #399/#400) - acp-kernel pinned 0.0.65 -> 0.0.66 (exact) - 792 tests: 789 pass / 0 fail / 3 skipped (pre-existing); typecheck+build green
…cedence test (USERPROFILE on Windows)
Contributor
📦 Built Extension ArtifactBranch: Option A — Install from npm PR tag (recommended)pi install npm:billion-context-pi@pr-403Each push to this PR publishes a new version under the Option B — Download artifact
tar xzf billion-context-pi-pr403.tgz
pi install ./packageThis comment is automatically updated on each push. |
ranxianglei
pushed a commit
that referenced
this pull request
Sep 12, 2026
…store PackSurface signature #403 landed the kernel-pack refactor but its mergeSurface built promptSections only from adapters.pi + inline, silently dropping the shared section keys the kernel sanitizer keeps at the generic top level (acpTags/tools/summariesInContext) — a behavior regression vs pre-refactor and vs the documented merge semantics. This aligns the implementation with the intended design: - promptSections merge: inline > adapters.pi > sanitized generic top level - mergeSurface(PackSurface | null) signature restored (pre-refactor contract; #403 had changed it to Pack) - re-export kernel defaultPackSources as-is instead of a local cwd wrapper - tests: port home/cwd acp.json precedence test (with USERPROFILE override) from #403; add pi-extras sanitization coverage lost when piAdapterSurface was removed; assert shared-key retention through mergeSurface
This was referenced Sep 12, 2026
HangxiangMa
pushed a commit
to HangxiangMa/billion-context-pi
that referenced
this pull request
Sep 21, 2026
…-packs refactor(packs): consume acp-kernel 0.0.66 pack API
ranxianglei
added a commit
that referenced
this pull request
Sep 25, 2026
… acp-kernel 0.0.90 (#540, #535 go-live) - #540: compress receipts and the tier3-only rewrite selected 'new' blocks with slice(-blocksCreated); an in-place refold keeps its original array position, so refolding b1 of [b1,b2,b3] presented b3's stale summary as the new one. Selection now diffs before/after runIds (every applyCompression assigns a fresh runId to created AND refolded blocks) — exact for both shapes. Regression test: two blocks, inline-restore the non-tail b1, re-compress its span, assert span clause + fingerprint line reference b1's NEW summary, b2 untouched, still exactly two persisted blocks. - pin acp-kernel 0.0.86 -> 0.0.90 (real install, overlay retired): ships refold-in-place (kernel #403) + full-log resolving (#400), making #535 P2 live end-to-end. - viable-ranges test now feeds well-formed CoreMessages: 0.0.90's syncBlocks (subid coverage, kernel #233) dereferences message.id via baseIdOf and throws on id-less host-shaped entries where 0.0.86 silently tolerated them (kernel-side guard filed separately). Gates: typecheck ✓ · 944 tests / 941 pass / 0 fail / 3 skipped · build ✓ Fixes #540
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #401 (supersedes closed #402 — that PR was closed by a branch rename; identical content plus a cross-platform test fix)
What
Migrates the adapter onto the kernel's pack layer so the mechanism has one source of truth (matching billion-context #729/#730, which already consumes the kernel API).
src/packs/{types,sanitize,lean,builtin,dir}.tsdeleted — replaced by acp-kernel 0.0.66 exports (Pack/PackSource/PackResolver,sanitizePackSurface, builtin registry withdefault+lean,createDirPackSource,defaultPackSources)src/prompt-pack.tsrewritten on kernel exports; consumers unchanged (mergeSurface/readToolSurfaceWithPacks/resolveActivePack;src/index.tscall sites passPackinstead ofpack.surface)surface.adapters.pi— opaque to the kernel, sanitized adapter-side (piAdapterSurface).pi/acp/packs> user~/.pi/acp/packs> builtin; filename-is-identity semantics from the kernelleanPack.adapters.pi, including the aligned recall rules (Post-compress search bounce: lean pack promotes search_context to routine recall #399/fix(packs): lean recall rules aligned with pre-lean semantics #400)acp-kernelexact pin bumped 0.0.65 → 0.0.66CI fixes vs #402
2026-09-13_kernel-packs(pr-validation requiresYYYY-MM-DD_short-title)readToolSurfaceWithPacksprecedence test now overrides bothHOMEandUSERPROFILE(os.homedir()resolvesUSERPROFILEon Windows — that was the windows-24 failure)Verification
npm run typecheckclean ·npm test789 pass / 0 fail / 3 skipped (skips pre-existing) ·npm run buildgreen