pi-crew 0.9.66 → 0.9.68

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/CHANGELOG.md +109 -0
  2. package/README.md +2 -3
  3. package/agents/executor.md +1 -1
  4. package/agents/test-engineer.md +1 -1
  5. package/agents/verifier.md +1 -1
  6. package/dist/index.mjs +4451 -4092
  7. package/package.json +12 -8
  8. package/scripts/analyze-run.mjs +1333 -0
  9. package/scripts/resource-sampler.mjs +482 -0
  10. package/skills/real-test-pi-crew/SKILL.md +10 -9
  11. package/src/agents/agent-config.ts +35 -14
  12. package/src/config/role-tools.ts +2 -2
  13. package/src/extension/knowledge-injection.ts +17 -0
  14. package/src/extension/pi-api.ts +0 -16
  15. package/src/extension/team-tool/api/agent-control.ts +358 -0
  16. package/src/extension/team-tool/api/handler-context.ts +57 -0
  17. package/src/extension/team-tool/api/heartbeat.ts +75 -0
  18. package/src/extension/team-tool/api/mailbox.ts +242 -0
  19. package/src/extension/team-tool/api/plan-approval.ts +190 -0
  20. package/src/extension/team-tool/api/read.ts +443 -0
  21. package/src/extension/team-tool/api/task-claims.ts +207 -0
  22. package/src/extension/team-tool/api.ts +56 -1301
  23. package/src/extension/team-tool/cancel.ts +15 -4
  24. package/src/extension/team-tool/goal-wrap.ts +2 -2
  25. package/src/extension/team-tool/goal.ts +4 -4
  26. package/src/extension/team-tool/lifecycle-actions.ts +5 -5
  27. package/src/extension/team-tool/parallel-dispatch.ts +2 -2
  28. package/src/extension/team-tool/respond.ts +11 -3
  29. package/src/extension/team-tool/run-intent.ts +357 -0
  30. package/src/extension/team-tool/run.ts +8 -285
  31. package/src/extension/team-tool/status.ts +56 -21
  32. package/src/extension/team-tool.ts +10 -8
  33. package/src/prompt/scratchpad-lifecycle.ts +80 -5
  34. package/src/runtime/child-pi/child-pi-spawn.ts +13 -7
  35. package/src/runtime/child-pi/child-pi.ts +22 -144
  36. package/src/runtime/child-pi/mock-fixtures.ts +171 -0
  37. package/src/runtime/crew-agent-records.ts +18 -1
  38. package/src/runtime/scratchpad/README.md +11 -0
  39. package/src/runtime/scratchpad/guest.ts +157 -7
  40. package/src/runtime/scratchpad/protocol.ts +13 -1
  41. package/src/runtime/scratchpad/transform.ts +206 -12
  42. package/src/runtime/supervisor-contact.ts +0 -16
  43. package/src/runtime/task-runner/child-executor.ts +1 -0
  44. package/src/runtime/task-runner/state-helpers.ts +9 -1
  45. package/src/runtime/team-runner.ts +39 -2
  46. package/src/state/contracts.ts +3 -0
  47. package/src/state/event-log/event-log.ts +19 -27
  48. package/src/state/gitignore-manager.ts +61 -7
  49. package/src/utils/glob-match.ts +29 -0
  50. package/types/dwf.d.ts +1 -1
  51. package/src/runtime/scratchpad/snapshot-hmac.ts +0 -161
  52. package/src/types/new-api-types.ts +0 -35
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-crew",
3
- "version": "0.9.66",
3
+ "version": "0.9.68",
4
4
  "description": "Pi extension for coordinated AI teams, workflows, worktrees, and async task orchestration",
5
5
  "author": "baphuongna",
6
6
  "license": "MIT",
@@ -67,22 +67,26 @@
67
67
  ],
68
68
  "scripts": {
69
69
  "check": "npm run ci",
70
- "ci": "npm run typecheck && npm run lint && npm run format:check && npm run check:conflict-markers && npm run check:decision-drift && npm run check:lazy-imports && npm run check:bundle-staleness && npm run build:bundle && npm run check:bundle-size && npm run test:bundle && npm test && npm pack --dry-run",
70
+ "ci": "npm run check:lockfile-sync && npm run typecheck && npm run lint && npm run format:check && npm run check:conflict-markers && npm run check:decision-drift && npm run check:event-types && npm run check:lazy-imports && npm run check:bundle-staleness && npm run build:bundle && npm run check:bundle-size && npm run test:bundle && npm test && npm pack --dry-run",
71
+ "check:lockfile-sync": "node scripts/check-lockfile-sync.mjs",
71
72
  "check:lazy-imports": "node scripts/check-lazy-imports.mjs",
72
73
  "check:bundle-staleness": "node scripts/check-bundle-staleness.mjs",
73
74
  "check:bundle-size": "node scripts/check-bundle-size.mjs",
74
75
  "check:conflict-markers": "node scripts/check-conflict-markers.mjs",
75
76
  "check:decision-drift": "node scripts/check-decision-drift.mjs",
77
+ "check:event-types": "node scripts/check-event-types-registry.mjs",
76
78
  "typecheck": "tsc --noEmit && node --experimental-strip-types -e \"await import('./index.ts'); console.log('strip-types import ok')\"",
77
79
  "lint": "biome check --linter-enabled=true --formatter-enabled=false --max-diagnostics=50 .",
78
80
  "format:check": "biome format .",
79
81
  "test": "npm run test:unit && npm run test:integration",
80
82
  "test:unit": "node scripts/test-runner.mjs --test-concurrency=4 --test-timeout=180000 --test-force-exit 'test/unit/**/*.test.ts'",
81
83
  "test:critical": "node scripts/test-runner.mjs --test-concurrency=4 --test-timeout=30000 --test-force-exit test/unit/runtime/broker/crew-broker-handshake.test.ts test/unit/runtime/broker/crew-broker-stale-socket.test.ts test/unit/runtime/broker/crew-broker-feature-flag.test.ts test/unit/runtime/broker/crew-broker-server-gate.test.ts test/unit/runtime/broker/crew-broker-client-fallback.test.ts test/unit/runtime/broker/crew-broker-mailbox-observer.test.ts test/unit/runtime/broker/crew-broker-close-during-reconnect.test.ts test/unit/runtime/broker/crew-broker-steer-dedup.test.ts test/unit/runtime/broker/crew-broker-symlink-steering.test.ts test/unit/ui/keybinding-map.parity.test.ts test/unit/ui/pi-tui-dispatch-probe.test.ts test/unit/utils/session-utils-extract.test.ts test/unit/config/config-schema-sync.test.ts test/unit/runtime/child-pi/child-pi-env-spread.test.ts",
82
- "test:watch": "tsx --watch --test --test-concurrency=4 --test-timeout=30000 --test-force-exit 'test/unit/**/*.test.ts'",
84
+ "test:watch": "node scripts/test-runner.mjs --watch --test-concurrency=4 --test-timeout=30000 'test/unit/**/*.test.ts'",
83
85
  "test:integration": "node scripts/test-runner.mjs --test-concurrency=1 --test-timeout=300000 test/integration/*.test.ts",
84
86
  "test:smoke": "node scripts/test-runner.mjs --test-concurrency=1 --test-timeout=180000 test/smoke/*.smoke.ts",
85
87
  "test:spike": "node scripts/test-runner.mjs --test-concurrency=2 --test-timeout=120000 --test-force-exit test/runtime/scratchpad/*.test.ts",
88
+ "test:functional": "node scripts/test-runner.mjs --test-concurrency=1 --test-timeout=120000 test/functional/pi-crew-functional.test.ts",
89
+ "test:platform": "node scripts/test-runner.mjs --test-concurrency=1 --test-timeout=60000 test/platform/*.test.ts",
86
90
  "build:bundle": "node scripts/build-bundle.mjs",
87
91
  "test:bundle": "node --experimental-strip-types --test --test-force-exit test/unit/bundle-load.test.ts",
88
92
  "watch:bundle": "node scripts/watch-bundle.mjs",
@@ -93,7 +97,7 @@
93
97
  "build:crew-font": "python scripts/build-crew-vibes-font.py",
94
98
  "bench": "node scripts/run-bench.mjs",
95
99
  "bench:check": "node scripts/bench-check.mjs",
96
- "test:new": "tsx --test --test-concurrency=4 --test-timeout=30000 --test-force-exit 'test/unit/**/*.test.ts'",
100
+ "test:new": "node scripts/test-runner.mjs --test-concurrency=4 --test-timeout=30000 'test/unit/**/*.test.ts'",
97
101
  "test:changed": "node scripts/test-changed.mjs",
98
102
  "bench:capture": "node scripts/run-bench.mjs && node -e \"require('node:fs').copyFileSync('test/bench/results.json','test/bench/baseline.json')\"",
99
103
  "profile:startup": "node scripts/profile-startup.mjs",
@@ -133,10 +137,10 @@
133
137
  },
134
138
  "devDependencies": {
135
139
  "@biomejs/biome": "^2.5.3",
136
- "@earendil-works/pi-agent-core": "^0.83.0",
137
- "@earendil-works/pi-ai": "^0.83.0",
138
- "@earendil-works/pi-coding-agent": "^0.83.0",
139
- "@earendil-works/pi-tui": "^0.83.0",
140
+ "@earendil-works/pi-agent-core": "^0.84.0",
141
+ "@earendil-works/pi-ai": "^0.84.0",
142
+ "@earendil-works/pi-coding-agent": "^0.84.0",
143
+ "@earendil-works/pi-tui": "^0.84.0",
140
144
  "@types/node": "^25.9.5",
141
145
  "tsx": "^4.23.0",
142
146
  "typescript": "^7.0.2"