pi-crew 0.9.62 → 0.9.65

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 (60) hide show
  1. package/CHANGELOG.md +105 -0
  2. package/README.md +47 -1
  3. package/agents/critic.md +1 -1
  4. package/agents/explorer.md +1 -1
  5. package/agents/planner.md +1 -1
  6. package/agents/reviewer.md +1 -1
  7. package/agents/security-reviewer.md +1 -1
  8. package/agents/test-engineer.md +1 -1
  9. package/agents/writer.md +1 -1
  10. package/dist/index.mjs +478 -366
  11. package/package.json +7 -3
  12. package/scripts/analyze-run.mjs +1333 -0
  13. package/scripts/pty_probe.py +10 -8
  14. package/scripts/resource-sampler.mjs +482 -0
  15. package/skills/real-test-pi-crew/SKILL.md +6 -6
  16. package/src/agents/agent-config.ts +4 -0
  17. package/src/agents/agent-serializer.ts +1 -0
  18. package/src/agents/discover-agents.ts +8 -0
  19. package/src/config/role-tools.ts +49 -1
  20. package/src/observability/event-to-metric.ts +29 -0
  21. package/src/observability/metrics-primitives.ts +41 -3
  22. package/src/prompt/prompt-runtime.ts +6 -0
  23. package/src/prompt/scratchpad-lifecycle.ts +605 -0
  24. package/src/runtime/README.md +1 -1
  25. package/src/runtime/broker/crew-broker.ts +0 -16
  26. package/src/runtime/child-pi/child-pi-spawn.ts +42 -1
  27. package/src/runtime/child-pi/child-pi.ts +5 -0
  28. package/src/runtime/effectiveness.ts +23 -1
  29. package/src/runtime/merge-gate.ts +202 -0
  30. package/src/runtime/model/model-fallback.ts +11 -0
  31. package/src/runtime/model/pi-args.ts +1 -1
  32. package/src/runtime/model/provider-extensions.ts +31 -12
  33. package/src/runtime/output/progress-tracker.ts +3 -33
  34. package/src/runtime/recovery/crash-recovery.ts +1 -1
  35. package/src/runtime/scratchpad/README.md +184 -0
  36. package/src/runtime/scratchpad/engine.ts +648 -0
  37. package/src/runtime/scratchpad/guest.ts +360 -0
  38. package/src/runtime/scratchpad/index.ts +22 -0
  39. package/src/runtime/scratchpad/protocol.ts +88 -0
  40. package/src/runtime/scratchpad/snapshot-hmac.ts +161 -0
  41. package/src/runtime/scratchpad/snapshot-lookup.ts +74 -0
  42. package/src/runtime/scratchpad/transform.ts +363 -0
  43. package/src/runtime/task-runner/child-executor.ts +48 -31
  44. package/src/runtime/team-runner.ts +128 -203
  45. package/src/schema/team-tool-schema.ts +2 -0
  46. package/src/teams/discover-teams.ts +2 -0
  47. package/src/teams/team-config.ts +7 -0
  48. package/src/teams/team-serializer.ts +1 -0
  49. package/src/ui/mascot.ts +1 -14
  50. package/teams/default.team.md +1 -0
  51. package/teams/fast-fix.team.md +1 -0
  52. package/src/observability/event-bus.ts +0 -86
  53. package/src/plugins/plugin-define.ts +0 -6
  54. package/src/plugins/plugin-registry.ts +0 -32
  55. package/src/plugins/plugins/index.ts +0 -3
  56. package/src/plugins/plugins/nextjs.ts +0 -19
  57. package/src/plugins/plugins/vite.ts +0 -10
  58. package/src/plugins/plugins/vitest.ts +0 -9
  59. package/src/runtime/child-pi/child-pi-pool.ts +0 -68
  60. package/src/runtime/iteration-hooks.ts +0 -305
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-crew",
3
- "version": "0.9.62",
3
+ "version": "0.9.65",
4
4
  "description": "Pi extension for coordinated AI teams, workflows, worktrees, and async task orchestration",
5
5
  "author": "baphuongna",
6
6
  "license": "MIT",
@@ -61,15 +61,18 @@
61
61
  "types/",
62
62
  "CHANGELOG.md",
63
63
  "LICENSE",
64
- "NOTICE.md"
64
+ "NOTICE.md",
65
+ "scripts/resource-sampler.mjs",
66
+ "scripts/analyze-run.mjs"
65
67
  ],
66
68
  "scripts": {
67
69
  "check": "npm run ci",
68
- "ci": "npm run typecheck && npm run lint && npm run format:check && npm run check:conflict-markers && 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 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",
69
71
  "check:lazy-imports": "node scripts/check-lazy-imports.mjs",
70
72
  "check:bundle-staleness": "node scripts/check-bundle-staleness.mjs",
71
73
  "check:bundle-size": "node scripts/check-bundle-size.mjs",
72
74
  "check:conflict-markers": "node scripts/check-conflict-markers.mjs",
75
+ "check:decision-drift": "node scripts/check-decision-drift.mjs",
73
76
  "typecheck": "tsc --noEmit && node --experimental-strip-types -e \"await import('./index.ts'); console.log('strip-types import ok')\"",
74
77
  "lint": "biome check --linter-enabled=true --formatter-enabled=false --max-diagnostics=50 .",
75
78
  "format:check": "biome format .",
@@ -79,6 +82,7 @@
79
82
  "test:watch": "tsx --watch --test --test-concurrency=4 --test-timeout=30000 --test-force-exit 'test/unit/**/*.test.ts'",
80
83
  "test:integration": "node scripts/test-runner.mjs --test-concurrency=1 --test-timeout=300000 test/integration/*.test.ts",
81
84
  "test:smoke": "node scripts/test-runner.mjs --test-concurrency=1 --test-timeout=180000 test/smoke/*.smoke.ts",
85
+ "test:spike": "node scripts/test-runner.mjs --test-concurrency=2 --test-timeout=120000 --test-force-exit test/runtime/scratchpad/*.test.ts",
82
86
  "build:bundle": "node scripts/build-bundle.mjs",
83
87
  "test:bundle": "node --experimental-strip-types --test --test-force-exit test/unit/bundle-load.test.ts",
84
88
  "watch:bundle": "node scripts/watch-bundle.mjs",