pi-agent-codebase-workflows
Pi package with skills and prompt templates for documented-codebase workflows.
Credits: built for pi, created by Mario Zechner (GitHub: @badlogic, X: @badlogicgames) and the Earendil Works team (@earendil-works).
Included skills
codebase-recon — reconstruct durable project understanding into docs/agent/*.md plus project-root AGENTS.md.
arch-code-review — review current diffs against documented architecture, invariants, data model, dependency rules, risks, and tests.
safe-change — preflight, design/diagnosis, implementation, validation, and semantic docs update workflow for safe code changes.
Included prompt templates
Reconstruction:
/recon-all
/recon-01-inventory
/recon-02-architecture
/recon-03-data-invariants
/recon-04-dependency-rules
/recon-05-risk-register
/recon-06-agents
/recon-07-change-guide
/recon-08-consolidate
/recon-09-adr
/recon-10-risk-tests
Safe-change workflow:
/preflight
/bug-diagnose
/bug-implement
/feature-design
/feature-implement
/refactor-design
/refactor-implement
/risk-fix
/review-arch
Install
From git after repository is published:
pi install git:github.com/PriNova/pi-agent-codebase-workflows
From npm after package is published:
pi install npm:pi-agent-codebase-workflows
Local development/test:
pi install /absolute/path/to/pi-agent-codebase-workflows
pi -e /absolute/path/to/pi-agent-codebase-workflows
Focus/scoping arguments
Reconstruction prompts accept optional [focus] arguments. Use them to scope analysis to a module, package, app, service, directory, or bounded domain area, especially in monorepos.
Example:
/recon-01-inventory packages/api
/recon-02-architecture apps/mobile auth flow
/recon-all services/billing
Scoped passes should produce clearly labeled observations in docs/agent/*.md. Later /recon-08-consolidate can reconcile multiple scoped artifacts into repo-level guidance.
Review and risk-fix prompts also accept scope/focus arguments for targeted reviews or fixes.
Artifact locations
Skills write durable project-agent docs under:
docs/agent/
Project operating instructions stay at project root:
AGENTS.md
The workflows intentionally avoid docs/AGENTS.md and docs/agent/AGENTS.md.
Package structure
skills/
codebase-recon/SKILL.md
arch-code-review/SKILL.md
safe-change/SKILL.md
prompts/
*.md
Pi discovers these through the pi.skills and pi.prompts entries in package.json.