Skip to content

Extract pi-kit into a standalone personal repo #54

Description

@ElbertePlinio

Extract packages/pi-kit into a standalone personal repo so personal Pi tooling stops depending on the product monorepo.

Why

  • pi-kit has zero imports from product packages and is excluded from the root build chain (package.json:11); it only borrows root tsconfig/Vitest/type-devDeps scaffolding.
  • The dotfiles bootstrap currently clones the entire platform repo just to provide pi-kit (run_after_clone_pickforge_platform.sh), which is an inverted dependency.
  • pi-kit already pins its own older toolchain (TS 5.6 / Vitest 2 vs root TS 5.9 / Vitest 4).

Audit evidence (2026-07-22, three-lane read-only audit): couplings and consumers are journaled in ~/.pickforge/pi-kit/raw/run-20260722T192014-bf30/.

Decisions (proposed defaults, veto in comments)

  • Destination: ~/Projects/Personal/pi-kitgithub.com/ElbertePlinio/pi-kit (private).
  • Package name: pi-kit (stays private: true).
  • Git history: plain copy; history remains in this repo.
  • Toolchain: keep pinned TS 5.6 / Vitest 2 initially; upgrade later separately.
  • Keep the pickforge-lanes-mcp launcher command name so Claude MCP registration is untouched.
  • No feature flag: infrastructure move, no product behavior change (workspace flag rule: N/A).

PR plan

  • PR 1 — new standalone repo (ElbertePlinio/pi-kit): copy extensions/ mcp/ src/ test/ themes/ README.md package.json; add local tsconfig.json (derived from platform tsconfig.base.json), explicit @types/node/@types/bun, local Vitest config with test/**/*.test.ts globs, own bun.lock, CI (frozen install, typecheck, tests, coverage, MCP stdin-close check per README); move pi-kit rules out of platform AGENTS.md:13-24.
    • Validation: bun install --frozen-lockfile && tsc --noEmit && vitest run green in new repo; bun mcp/server.ts stdin-close check.
  • PR 2 — dotfiles cutover (ElbertePlinio/dotfiles), single commit: ~/.pi/agent/settings.json package path, dot_pi/agent/extensions/btw.ts shim, dot_local/bin/executable_pickforge-lanes-mcp launcher, dot_agents/doctor-targets.json runtime root, path fixtures in scripts/check-agent-config-sync.sh; repoint/narrow the bootstrap clone script.
    • Validation: full check suite passes; Pi loads extensions; /btw works; pickforge-lanes-mcp starts; doctor green.
    • Watch: /btw is loaded externally but absent from pi.extensions — do not drop or double-register it.
  • PR 3 — this repo: remove packages/pi-kit, regenerate bun.lock, archive the three path-referencing docs under docs/superpowers/; confirm coverage config still valid. Closes this issue.
    • Validation: bun run check green at root.

Order: PR 1 → PR 2 → PR 3 (cutover must land before deletion; non-atomic cutover briefly breaks Pi loading, so PR 2 applies in one commit + immediate chezmoi apply).

Traceability

Acceptance criterion PR/slice Validation Status
pi-kit builds/tests standalone PR 1 CI green in new repo pending
Pi, /btw, lanes MCP, doctor all work from new path PR 2 check suite + doctor + manual Pi smoke pending
Platform no longer contains/needs pi-kit PR 3 bun run check green, no pi-kit refs pending

Current status: Planned
Next action: PR 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions