This is an npm workspaces monorepo. All Pi extensions live under packages/. Each package has its own AGENTS.md with package-specific conventions and directory structure.
packages/
pi-continuous-learning/ # Pi extension: continuous learning via instincts
src/ # TypeScript source + tests (*.test.ts alongside source)
docs/ # Package documentation (internals.md, specification.md)
AGENTS.md # Package-level conventions, directory structure, testing
CHANGELOG.md # Release history (managed by release-please)
pi-red-green/ # Pi extension: TDD enforcement (red-green-refactor)
src/ # TypeScript source + tests (*.test.ts alongside source)
CHANGELOG.md # Release history (managed by release-please)
pi-compass/ # Pi extension: codebase navigation (codemap + code tours)
src/ # TypeScript source + tests (*.test.ts alongside source)
CHANGELOG.md # Release history (managed by release-please)
pi-simplify/ # Pi extension: code simplification (/simplify command)
src/ # TypeScript source + tests (*.test.ts alongside source)
CHANGELOG.md # Release history (managed by release-please)
pi-code-review/ # Pi extension: automated language-aware code review
src/ # TypeScript source + tests (*.test.ts alongside source)
CHANGELOG.md # Release history (managed by release-please)
pi-blueprint/ # Pi extension: multi-session planning with dependency tracking
src/ # TypeScript source + tests (*.test.ts alongside source)
CHANGELOG.md # Release history (managed by release-please)
After ANY code change, run the full check:
npm run checkIndividual commands:
npm test # run all package tests
npm test -w packages/pi-continuous-learning -- src/foo.test.ts # single file
npm test -w packages/pi-continuous-learning -- -t "pattern" # by name pattern
npm run typecheck # type-check all packages
npm run lint # ESLint on all packages
npm run build # compile all packages to dist/When working inside packages/pi-continuous-learning, refer to packages/pi-continuous-learning/AGENTS.md for:
- Code conventions specific to that package
- Full directory structure with file descriptions
- Testing approach
- Documentation update guidelines
- Installation instructions in package READMEs must use
pi install npm:<package-name>, notnpm install. These are Pi extensions installed via the Pi CLI.
- Create
packages/<name>/src/ - Add
packages/<name>/package.json(follow existing package as template) - Add
packages/<name>/tsconfig.jsonextending../../tsconfig.base.json - Add
{ "path": "packages/<name>" }to roottsconfig.jsonreferences - Add
"packages/<name>": {}torelease-please-config.json - Add
"packages/<name>": "0.1.0"to.release-please-manifest.json - Add the package to the Packages table in the root
README.md - Add the package to the Repository structure section in this file (
AGENTS.md) - No changes needed to
eslint.config.js,.mega-linter.yml,ci.yml, orpublish.yml