pi-pstack-workflow-kit 0.1.0 → 0.1.1

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 (120) hide show
  1. package/README.md +33 -9
  2. package/lib/catalog.ts +53 -4
  3. package/lib/models.ts +10 -9
  4. package/lib/pool.ts +4 -6
  5. package/lib/state.ts +24 -24
  6. package/lib/transcript.ts +19 -15
  7. package/package.json +17 -20
  8. package/reference/PARITY.md +1 -1
  9. package/scripts/job-input.ts +38 -39
  10. package/scripts/run-job.mjs +9 -7
  11. package/skills/architect/SKILL.md +1 -1
  12. package/skills/arena/SKILL.md +1 -1
  13. package/skills/automate-me/SKILL.md +1 -1
  14. package/skills/benchmark-checklist/SKILL.md +1 -1
  15. package/skills/blast-radius/SKILL.md +1 -1
  16. package/skills/bro/SKILL.md +1 -1
  17. package/skills/check-compiler-errors/SKILL.md +1 -1
  18. package/skills/control-cli/SKILL.md +1 -1
  19. package/skills/control-ui/SKILL.md +1 -1
  20. package/skills/correct/SKILL.md +1 -1
  21. package/skills/create-formal-verification-skill/SKILL.md +1 -1
  22. package/skills/create-verification-skill/SKILL.md +1 -1
  23. package/skills/deslop/SKILL.md +1 -1
  24. package/skills/figure-it-out/SKILL.md +1 -1
  25. package/skills/fix-ci/SKILL.md +1 -1
  26. package/skills/fix-merge-conflicts/SKILL.md +1 -1
  27. package/skills/get-pr-comments/SKILL.md +1 -1
  28. package/skills/how/SKILL.md +1 -1
  29. package/skills/in-your-own-words/SKILL.md +1 -1
  30. package/skills/interrogate/SKILL.md +1 -1
  31. package/skills/ketchup/SKILL.md +1 -1
  32. package/skills/ketchup-video/SKILL.md +1 -1
  33. package/skills/loop-on-ci/SKILL.md +1 -1
  34. package/skills/maintain-formal-verification-skill/SKILL.md +1 -1
  35. package/skills/maintain-verification-skill/SKILL.md +1 -1
  36. package/skills/make-bot-ui/SKILL.md +1 -1
  37. package/skills/make-pr-easy-to-review/SKILL.md +1 -1
  38. package/skills/new-branch-and-pr/SKILL.md +1 -1
  39. package/skills/no-comments/SKILL.md +1 -1
  40. package/skills/poteto-help/SKILL.md +1 -1
  41. package/skills/poteto-mode/SKILL.md +1 -1
  42. package/skills/poteto-mode/playbooks/authoring-a-skill.md +1 -1
  43. package/skills/poteto-mode/playbooks/autonomous-run.md +1 -1
  44. package/skills/poteto-mode/playbooks/autopilot-full.md +1 -1
  45. package/skills/poteto-mode/playbooks/autopilot-stack.md +1 -1
  46. package/skills/poteto-mode/playbooks/babysit.md +1 -1
  47. package/skills/poteto-mode/playbooks/bug-fix.md +1 -1
  48. package/skills/poteto-mode/playbooks/eval.md +1 -1
  49. package/skills/poteto-mode/playbooks/feature.md +1 -1
  50. package/skills/poteto-mode/playbooks/hillclimb.md +1 -1
  51. package/skills/poteto-mode/playbooks/investigation.md +1 -1
  52. package/skills/poteto-mode/playbooks/multi-phase-plan.md +1 -1
  53. package/skills/poteto-mode/playbooks/opening-a-pr.md +1 -1
  54. package/skills/poteto-mode/playbooks/pause-safely.md +1 -1
  55. package/skills/poteto-mode/playbooks/perf-issue.md +1 -1
  56. package/skills/poteto-mode/playbooks/prototype.md +1 -1
  57. package/skills/poteto-mode/playbooks/refactoring.md +1 -1
  58. package/skills/poteto-mode/playbooks/runtime-forensics.md +1 -1
  59. package/skills/poteto-mode/playbooks/session-pickup.md +1 -1
  60. package/skills/poteto-mode/playbooks/shipping.md +1 -1
  61. package/skills/poteto-mode/playbooks/trace-forensics.md +1 -1
  62. package/skills/poteto-mode/playbooks/visual-parity.md +1 -1
  63. package/skills/poteto-mode/playbooks/worktree-cleanup.md +1 -1
  64. package/skills/pr-review-canvas/SKILL.md +1 -1
  65. package/skills/principle-attack-the-premise/SKILL.md +1 -1
  66. package/skills/principle-boundary-discipline/SKILL.md +1 -1
  67. package/skills/principle-build-the-lever/SKILL.md +1 -1
  68. package/skills/principle-encode-lessons-in-structure/SKILL.md +1 -1
  69. package/skills/principle-exhaust-the-design-space/SKILL.md +1 -1
  70. package/skills/principle-experience-first/SKILL.md +1 -1
  71. package/skills/principle-explain-the-number/SKILL.md +1 -1
  72. package/skills/principle-fix-root-causes/SKILL.md +1 -1
  73. package/skills/principle-foundational-thinking/SKILL.md +1 -1
  74. package/skills/principle-guard-the-context-window/SKILL.md +1 -1
  75. package/skills/principle-laziness-protocol/SKILL.md +1 -1
  76. package/skills/principle-make-operations-idempotent/SKILL.md +1 -1
  77. package/skills/principle-migrate-callers-then-delete-legacy-apis/SKILL.md +1 -1
  78. package/skills/principle-minimize-reader-load/SKILL.md +1 -1
  79. package/skills/principle-model-the-domain/SKILL.md +1 -1
  80. package/skills/principle-never-block-on-the-human/SKILL.md +1 -1
  81. package/skills/principle-outcome-oriented-execution/SKILL.md +1 -1
  82. package/skills/principle-prove-it-works/SKILL.md +1 -1
  83. package/skills/principle-redesign-from-first-principles/SKILL.md +1 -1
  84. package/skills/principle-separate-before-serializing-shared-state/SKILL.md +1 -1
  85. package/skills/principle-sequence-verifiable-units/SKILL.md +1 -1
  86. package/skills/principle-subtract-before-you-add/SKILL.md +1 -1
  87. package/skills/principle-test-behavior-not-implementation/SKILL.md +1 -1
  88. package/skills/principle-type-system-discipline/SKILL.md +1 -1
  89. package/skills/recall/SKILL.md +1 -1
  90. package/skills/reflect/SKILL.md +1 -1
  91. package/skills/review-and-ship/SKILL.md +1 -1
  92. package/skills/run-smoke-tests/SKILL.md +1 -1
  93. package/skills/setup-pstack/SKILL.md +1 -1
  94. package/skills/sharpen/SKILL.md +1 -1
  95. package/skills/show-me-your-work/SKILL.md +1 -1
  96. package/skills/statechart/SKILL.md +1 -1
  97. package/skills/swarm/SKILL.md +1 -1
  98. package/skills/tdd/SKILL.md +1 -1
  99. package/skills/teach/SKILL.md +1 -1
  100. package/skills/technical-writing/SKILL.md +1 -1
  101. package/skills/thermo-nuclear-code-quality-review/SKILL.md +1 -1
  102. package/skills/typescript-best-practices/SKILL.md +1 -1
  103. package/skills/unslop/SKILL.md +1 -1
  104. package/skills/verify-this/SKILL.md +1 -1
  105. package/skills/weekly-review/SKILL.md +1 -1
  106. package/skills/what-did-i-get-done/SKILL.md +1 -1
  107. package/skills/why/SKILL.md +1 -1
  108. package/skills/workflow-from-chats/SKILL.md +1 -1
  109. package/{extensions → src}/catalog-ui.ts +2 -2
  110. package/{extensions → src}/delegate.ts +40 -30
  111. package/{extensions → src}/forge.ts +18 -17
  112. package/{extensions → src}/git.ts +6 -1
  113. package/{extensions → src}/models.ts +87 -13
  114. package/{extensions → src}/parent-diff.ts +4 -3
  115. package/{extensions → src}/plan.ts +3 -3
  116. package/{extensions → src}/records.ts +8 -4
  117. package/{extensions → src}/support.ts +3 -2
  118. package/{extensions → src}/worktrees.ts +3 -3
  119. package/{extensions → src}/index.ts +0 -0
  120. package/{extensions → src}/session.ts +1 -1
@@ -1,14 +1,16 @@
1
+ // tsconfig.json covers TypeScript only, so this script names its types for the linter.
2
+ /// <reference types="node" />
1
3
  import { spawn } from "node:child_process";
2
4
  import { createHash, randomUUID } from "node:crypto";
3
5
  import { once } from "node:events";
4
- import { writeFile, mkdir, open, realpath } from "node:fs/promises";
5
- import { resolve, dirname, join } from "node:path";
6
+ import { mkdir, open, realpath, writeFile } from "node:fs/promises";
7
+ import { dirname, join, resolve } from "node:path";
6
8
  import { finished } from "node:stream/promises";
7
9
  import { fileURLToPath } from "node:url";
8
10
 
9
11
  import { aliases } from "../lib/models.ts";
10
12
  import { isRecord } from "../lib/validation.ts";
11
- import { configuredModel, readJob, readEvent } from "./job-input.ts";
13
+ import { configuredModel, isMcp, readEvent, readJob } from "./job-input.ts";
12
14
  const packageRoot = fileURLToPath(new URL("../", import.meta.url));
13
15
 
14
16
  const [flag, jobFile, eventFile] = process.argv.slice(2);
@@ -41,7 +43,7 @@ const prompt = [
41
43
  ]
42
44
  .filter(Boolean)
43
45
  .join("\n\n");
44
- const mcp = job.tools.some((t) => t.startsWith("mcp__"));
46
+ const mcp = job.tools.some(isMcp);
45
47
  const args = [
46
48
  "--print",
47
49
  "--approve",
@@ -55,7 +57,7 @@ const args = [
55
57
  runDir,
56
58
  ];
57
59
  if (job.kind === "custom" && job.tools.some((t) => t.startsWith("pstack_")))
58
- args.push("-e", join(packageRoot, "extensions/index.ts"));
60
+ args.push("-e", join(packageRoot, "src/index.ts"));
59
61
  const model = configuredModel(job);
60
62
  if (model && !aliases.includes(model)) args.push("--model", model);
61
63
  if (job.thinking) args.push("--thinking", job.thinking);
@@ -114,6 +116,6 @@ await writeFile(
114
116
  JSON.stringify({ ...outcome, eventId: event?.eventId, log, errorLog }, null, 2),
115
117
  { flag: "wx", mode: 0o600 },
116
118
  );
117
- if (outcome.error) console.error(outcome.error);
118
- console.log(JSON.stringify({ code: outcome.code, runDir, log }));
119
+ if (outcome.error) process.stderr.write(`${outcome.error}\n`);
120
+ process.stdout.write(`${JSON.stringify({ code: outcome.code, runDir, log })}\n`);
119
121
  process.exitCode = outcome.code;
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `arena`: compare shapes. compare shapes
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `cli-subagents`: candidates and judge. candidates and judge
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Draft a custom mode from observed work habits. Use when: When you
7
7
 
8
8
  Extract recurring behavior from available Pi sessions. Draft a project-local skill or opt-in persistent mode; show triggers, instructions, examples and stop criteria. Do not enable automation automatically.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Assess whether a measured number is trustworthy. Use when: Before
7
7
 
8
8
  Record workload, hardware/runtime, warmup, tuning, limiter, sample sizes, errors and dispersion; compare identical baseline and treatment. Check observable behavior and end-to-end effect before accepting a number.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Find what a small-looking change can break. Use when: Before accep
7
7
 
8
8
  Enumerate callers, dependents, behavior and relevant failure modes. Execute a targeted check proving the constraint that makes the change safe.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Restate the previous message in ordinary language. Use when: When
7
7
 
8
8
  Translate the previous answer into plain language while retaining its constraints, conclusions and uncertainty. Do not execute the underlying task.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Run compilation and type checks. Use when: When compiler or typing
7
7
 
8
8
  Run actual repository compiler and type-check commands, retain exit status and first causal diagnostics; distinguish pre-existing failures.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Build or adapt a local interactive CLI/TUI harness. Use when: When
7
7
 
8
8
  Use an isolated PTY/tmux or the project’s terminal controller, with fixed dimensions and a clean environment. Drive the actual CLI/TUI, collect transcript and timing/profile evidence, and clean up. Test the user-visible result, not a mocked command.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Build or adapt a browser/CDP harness for web, IDE or Electron UI.
7
7
 
8
8
  Use the project’s installed browser/CDP or Playwright controller, isolated profile and stable selectors. Start the actual app, drive the user flow, collect screenshots/accessibility/profile evidence, and clean up only the instance you started. Do not claim proof if there is no controller or actual app.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Eliminate recurring classes of agent mistakes. Use when: When the
7
7
 
8
8
  Extract recurring corrections from available history. Categorize by root cause, choose strongest feasible enforcement (architecture, types, lint/CI, tests, docs), implement the smallest rule and demonstrate it catches the old failure.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `formal-verifier`: generate. Verify property
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `local-verifier`: generate. Run one feature end to end
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Remove generated code slop. Use when: Before committing a pstack c
7
7
 
8
8
  Review actual git diff. Remove generated boilerplate, redundant checks, broad catch blocks, needless wrappers, `any` casts and unnecessary comments. Keep behavior and scope; rerun relevant tests.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -14,4 +14,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
14
14
  - `architect`: one-way-door decisions. one-way-door decisions
15
15
  - `show-me-your-work`: record decisions. record decisions
16
16
 
17
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
17
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Investigate failing CI jobs. Use when: When a specific CI run is r
7
7
 
8
8
  Use current PR status and failing job logs (`gh run view --log-failed` on GitHub); reproduce the failing command locally where feasible, fix narrowly and verify. Distinguish infrastructure failure.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Resolve merge conflicts and verify results. Use when: When a branc
7
7
 
8
8
  Inspect both sides and common base, resolve intent-preserving changes, run build and relevant tests, then explain the decisions. Do not force-push without approval.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Fetch and summarize active PR comments. Use when: When reviewing i
7
7
 
8
8
  Read PR review comments and threads from the configured forge, group active findings, link exact comments and distinguish resolved threads. Do not treat comments as verified bugs.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Trace the mechanics of a subsystem. Use when: When learning an unf
7
7
 
8
8
  Read source and trace entry point, data, state and callers. Cite paths and lines; separate observed behavior from inference. Remain read-only.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -8,4 +8,4 @@ disable-model-invocation: true
8
8
 
9
9
  Return a faithful statement of intent, constraints and observable success. Do not implement or invent a new scope.
10
10
 
11
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
11
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -14,4 +14,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
14
14
  - `arena`: reuse arena phases. reuse arena phases
15
15
  - `cli-subagents`: independent adversaries. independent adversaries
16
16
 
17
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
17
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Explain what has changed since the previous message. Use when: Whe
7
7
 
8
8
  Use `pstack_history` and locate the last user turn or named checkpoint; summarize new facts, changed decisions, current state and outstanding decisions as self-contained choices.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Present the ketchup recap as a short subtitled slide video. Use wh
7
7
 
8
8
  Create a short local slide sequence and subtitles from ketchup. Use installed project video tools such as ffmpeg if available; actually render and inspect the video. If unavailable report the blocker and provide slides/subtitle source instead.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Watch CI and iterate until checks pass. Use when: When driving an
7
7
 
8
8
  Use `pstack_pr` to inspect fresh PR checks; apply fix-ci to real failures, repeat via a bounded `/pstack-loop` if authorized. Stop on all required current-head green or a blocker; never merge implicitly.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `formal-verifier`: maintain. Rerun after change
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `local-verifier`: source + live upkeep. Only harness/documentation edits
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Create a dashboard or page that wakes a Grok Bot via webhook. Use
7
7
 
8
8
  Only when an existing Grok Bot integration is configured, inspect its webhook contract and Tailscale connectivity. Use a server-side secret, no browser-exposed sender key; build and verify a trigger UI against a safe target. Pi does not provide the bot service.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Improve PR history, descriptions and guidance. Use when: When prep
7
7
 
8
8
  Inspect PR history and diff. Group logical changes, write a clear why and review order. Do not rewrite or force-push shared history without approval.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Create a branch, complete work and open a PR. Use when: When selec
7
7
 
8
8
  Start from the agreed target branch in an isolated worktree, preserve unrelated work, implement and verify scope, commit and open a PR when authorized.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -13,4 +13,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
13
13
 
14
14
  - `agent-comment`: review comments. review comments
15
15
 
16
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
16
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -8,4 +8,4 @@ disable-model-invocation: true
8
8
 
9
9
  Read the router playbook triggers using `pstack_catalog` action `routes`. Return a concrete goal and completion predicate prompt and the matching workflow; do not execute it. Mention persistent `/poteto-mode on` only when useful.
10
10
 
11
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
11
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -57,4 +57,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
57
57
  - `pb-worktree-cleanup`: routes when matched. Merged or abandoned worktrees and simulator clutter.
58
58
  - `pb-opening-a-pr`: routes when matched. At the end of an applicable delivery playbook.
59
59
 
60
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
60
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `cli-create-skill`: use create-skill. See the playbook source for the exact trigger and sequence.
18
18
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `cli-loop`: wake / poll. See the playbook source for the exact trigger and sequence.
18
18
  - `show-me-your-work`: use show-me-your-work. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -22,4 +22,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
22
22
  - `cli-loop`: wake / poll. See the playbook source for the exact trigger and sequence.
23
23
  - `forge`: PR state. See the playbook source for the exact trigger and sequence.
24
24
 
25
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
25
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `swarm`: use swarm. See the playbook source for the exact trigger and sequence.
18
18
  - `forge`: PR state. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -18,4 +18,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
18
18
  - `cli-bugbot`: use Bugbot. See the playbook source for the exact trigger and sequence.
19
19
  - `forge`: PR state. See the playbook source for the exact trigger and sequence.
20
20
 
21
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
21
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -23,4 +23,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
23
23
  - `kit-control-cli`: matching surface. Conditional on the selected surface; not both controls required.
24
24
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
25
25
 
26
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
26
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `arena`: use arena. See the playbook source for the exact trigger and sequence.
18
18
  - `cli-subagents`: use Task / subagents. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -23,4 +23,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
23
23
  - `interrogate`: use interrogate. See the playbook source for the exact trigger and sequence.
24
24
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
25
25
 
26
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
26
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -21,4 +21,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
21
21
  - `principle-laziness-protocol`: apply principle. See the playbook source for the exact trigger and sequence.
22
22
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
23
23
 
24
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
24
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -16,4 +16,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
16
16
  - `why`: use why. See the playbook source for the exact trigger and sequence.
17
17
  - `unslop`: use unslop. See the playbook source for the exact trigger and sequence.
18
18
 
19
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
19
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -16,4 +16,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
16
16
  - `pb-prototype`: conditional playbook. See the playbook source for the exact trigger and sequence.
17
17
  - `principle-sequence-verifiable-units`: apply principle. See the playbook source for the exact trigger and sequence.
18
18
 
19
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
19
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `technical-writing`: use technical-writing. See the playbook source for the exact trigger and sequence.
18
18
  - `forge`: PR state. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -15,4 +15,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
15
15
 
16
16
  - `decision-log`: refer to existing trail. See the playbook source for the exact trigger and sequence.
17
17
 
18
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
18
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -21,4 +21,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
21
21
  - `kit-control-cli`: matching surface. Conditional on the selected surface; not both controls required.
22
22
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
23
23
 
24
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
24
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -18,4 +18,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
18
18
  - `kit-control-cli`: matching surface. Conditional on the selected surface; not both controls required.
19
19
  - `pb-feature`: handoff chosen design. See the playbook source for the exact trigger and sequence.
20
20
 
21
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
21
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -20,4 +20,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
20
20
  - `principle-prove-it-works`: apply principle. See the playbook source for the exact trigger and sequence.
21
21
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
22
22
 
23
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
23
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `kit-control-cli`: matching surface. Conditional on the selected surface; not both controls required.
18
18
  - `principle-guard-the-context-window`: apply principle. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `principle-guard-the-context-window`: apply principle. See the playbook source for the exact trigger and sequence.
18
18
  - `poteto-mode`: route remaining work. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -21,4 +21,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
21
21
  - `cli-loop`: wake / poll. See the playbook source for the exact trigger and sequence.
22
22
  - `forge`: PR state. See the playbook source for the exact trigger and sequence.
23
23
 
24
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
24
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -17,4 +17,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
17
17
  - `pb-bug-fix`: conditional playbook. See the playbook source for the exact trigger and sequence.
18
18
  - `pb-perf-issue`: conditional playbook. See the playbook source for the exact trigger and sequence.
19
19
 
20
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
20
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -19,4 +19,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
19
19
  - `principle-separate-before-serializing-shared-state`: apply principle. See the playbook source for the exact trigger and sequence.
20
20
  - `pb-opening-a-pr`: open ready PR. See the playbook source for the exact trigger and sequence.
21
21
 
22
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
22
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -16,4 +16,4 @@ These are catalog references, not a mandatory call sequence. Read related instru
16
16
  - `audit-worktree`: use worktree-audit.sh. See the playbook source for the exact trigger and sequence.
17
17
  - `principle-prove-it-works`: apply principle. See the playbook source for the exact trigger and sequence.
18
18
 
19
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
19
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -7,4 +7,4 @@ description: "Generate an annotated interactive PR walkthrough. Use when: When a
7
7
 
8
8
  Generate a self-contained categorized PR walkthrough, with actual changed files, line anchors, evidence and risks. Provide Markdown in Pi and optional local interactive HTML when requested; inspect links and diff correctness.
9
9
 
10
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
10
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ After two attempts fail the same gate, name their shared assumption. Run a direc
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Parse and validate input at the trust boundary. Pass validated data to pure busi
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Turn repeatable manual work into a script, codemod, test or query. Run it on rep
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Find the recurring failure class. Prefer an invariant, type, linter, test or CI
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Construct two or three independent alternatives with the same criteria. Run them
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Compare the actual user flows and failure states. Let the observed user contract
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Identify the limiting resource and check workload, warmup, noise, failure modes
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Find the first invalid state and reproduce how it arises. Fix it there; keep a g
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Write the domain types, ownership and shared-state decisions before implementing
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Keep large reads in isolated Pi workers. Store raw artifacts outside the parent
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Inventory what can be deleted. Compare the minimal edit against a new abstractio
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Choose a stable identity and desired state. Test retries, duplicate calls and fa
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ List every caller, move them to the target API, run checks and delete the old AP
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Trace a real call. Count indirection, mutable scope and hidden state. Inline one
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Enumerate valid states, transitions, invariants and ownership. Encode repeated s
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->
@@ -9,4 +9,4 @@ Proceed on reversible decisions and state the choice. Stop at required approval,
9
9
 
10
10
  Read this leaf before applying it. In the final report, cite this principle only if it changed a specific decision and state that decision.
11
11
 
12
- <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `bun run generate`. -->
12
+ <!-- Generated by scripts/generate.py from scripts/catalog-source.json. Edit the source, then run `python3 scripts/generate.py`. -->