pitroom 0.6.0

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 (38) hide show
  1. package/.claude-plugin/marketplace.json +18 -0
  2. package/.claude-plugin/plugin.json +22 -0
  3. package/.codex-plugin/plugin.json +29 -0
  4. package/CHANGELOG.md +85 -0
  5. package/LICENSE +21 -0
  6. package/README.md +471 -0
  7. package/dist/lib.mjs +1222 -0
  8. package/dist/pitroom.mjs +3685 -0
  9. package/docs/backends.md +113 -0
  10. package/hooks/hooks.json +28 -0
  11. package/hooks/session-start.mjs +42 -0
  12. package/package.json +60 -0
  13. package/skills/pitroom-brainstorming/SKILL.md +243 -0
  14. package/skills/pitroom-brainstorming/spec-document-reviewer-prompt.md +22 -0
  15. package/skills/pitroom-crew/SKILL.md +80 -0
  16. package/skills/pitroom-debugging/SKILL.md +287 -0
  17. package/skills/pitroom-debugging/condition-based-waiting-example.ts +170 -0
  18. package/skills/pitroom-debugging/condition-based-waiting.md +115 -0
  19. package/skills/pitroom-debugging/defense-in-depth.md +122 -0
  20. package/skills/pitroom-debugging/find-polluter.sh +72 -0
  21. package/skills/pitroom-debugging/root-cause-tracing.md +169 -0
  22. package/skills/pitroom-driven-development/SKILL.md +138 -0
  23. package/skills/pitroom-driven-development/implementer-prompt.md +68 -0
  24. package/skills/pitroom-driven-development/re-review-prompt.md +41 -0
  25. package/skills/pitroom-driven-development/task-reviewer-prompt.md +59 -0
  26. package/skills/pitroom-finishing/SKILL.md +226 -0
  27. package/skills/pitroom-implement/SKILL.md +42 -0
  28. package/skills/pitroom-receiving-review/SKILL.md +209 -0
  29. package/skills/pitroom-research/SKILL.md +35 -0
  30. package/skills/pitroom-review/SKILL.md +47 -0
  31. package/skills/pitroom-review/code-reviewer.md +38 -0
  32. package/skills/pitroom-tdd/SKILL.md +322 -0
  33. package/skills/pitroom-tdd/writing-good-tests.md +198 -0
  34. package/skills/pitroom-verification/SKILL.md +124 -0
  35. package/skills/pitroom-worktrees/SKILL.md +171 -0
  36. package/skills/pitroom-writing-plans/SKILL.md +183 -0
  37. package/skills/pitroom-writing-plans/plan-document-reviewer-prompt.md +23 -0
  38. package/skills/using-pitroom/SKILL.md +66 -0
@@ -0,0 +1,171 @@
1
+ ---
2
+ name: pitroom-worktrees
3
+ description: Use when starting feature work that needs isolation from the current workspace, or before executing an implementation plan - sets up an isolated branch for your own work (workers get isolated copies from Pitroom itself).
4
+ ---
5
+
6
+ # Using Git Worktrees
7
+
8
+ ## Overview
9
+
10
+ Ensure work happens in an isolated workspace. Prefer your platform's native worktree tools. Fall back to manual git worktrees only when no native tool is available.
11
+
12
+ **Core principle:** Detect existing isolation first. Then use native tools. Then fall back to git. Never fight the harness.
13
+
14
+ **Announce at start:** "I'm using the pitroom-worktrees skill to set up an isolated workspace."
15
+
16
+ ## Workers don't need this
17
+
18
+ This skill isolates **your** branch. Pitroom workers never edit your checkout when started with `-i`: each gets a private copy of your current state, and you apply its patch. Don't create a worktree per worker.
19
+
20
+ ## Step 0: Detect Existing Isolation
21
+
22
+ **Before creating anything, check if you are already in an isolated workspace.**
23
+
24
+ ```bash
25
+ GIT_DIR=$(cd "$(git rev-parse --git-dir)" 2>/dev/null && pwd -P)
26
+ GIT_COMMON=$(cd "$(git rev-parse --git-common-dir)" 2>/dev/null && pwd -P)
27
+ BRANCH=$(git branch --show-current)
28
+ ```
29
+
30
+ **Submodule guard:** `GIT_DIR != GIT_COMMON` is also true inside git submodules. Before concluding "already in a worktree," verify you are not in a submodule:
31
+
32
+ ```bash
33
+ # If this returns a path, you're in a submodule, not a worktree — treat as normal repo
34
+ git rev-parse --show-superproject-working-tree 2>/dev/null
35
+ ```
36
+
37
+ **If `GIT_DIR != GIT_COMMON` (and not a submodule):** You are already in a linked worktree. Skip to Step 2 (Project Setup). Do NOT create another worktree.
38
+
39
+ Report with branch state:
40
+ - On a branch: "Already in isolated workspace at `<path>` on branch `<name>`."
41
+ - Detached HEAD: "Already in isolated workspace at `<path>` (detached HEAD, externally managed). Branch creation needed at finish time."
42
+
43
+ **If `GIT_DIR == GIT_COMMON` (or in a submodule):** You are in a normal repo checkout.
44
+
45
+ Has the user already indicated their worktree preference in your instructions? If not, ask for consent before creating a worktree:
46
+
47
+ > "Would you like me to set up an isolated worktree? It protects your current branch from changes."
48
+
49
+ Honor any existing declared preference without asking. If the user declines consent, work in place and skip to Step 2.
50
+
51
+ ## Step 1: Create Isolated Workspace
52
+
53
+ **You have two mechanisms. Try them in this order.**
54
+
55
+ ### 1a. Native Worktree Tools (preferred)
56
+
57
+ The user has asked for an isolated workspace (Step 0 consent). Do you already have a way to create a worktree? It might be a tool with a name like `EnterWorktree`, `WorktreeCreate`, a `/worktree` command, or a `--worktree` flag. If you do, use it and skip to Step 2.
58
+
59
+ Native tools handle directory placement, branch creation, and cleanup automatically. Using `git worktree add` when you have a native tool creates phantom state your harness can't see or manage.
60
+
61
+ Only proceed to Step 1b if you have no native worktree tool available.
62
+
63
+ ### 1b. Git Worktree Fallback
64
+
65
+ **Only use this if Step 1a does not apply** — you have no native worktree tool available. Create a worktree manually using git.
66
+
67
+ #### Directory Selection
68
+
69
+ Follow this priority order. Explicit user preference always beats observed filesystem state.
70
+
71
+ 1. **Check your instructions for a declared worktree directory preference.** If the user has already specified one, use it without asking.
72
+
73
+ 2. **Check for an existing project-local worktree directory:**
74
+ ```bash
75
+ ls -d .worktrees 2>/dev/null # Preferred (hidden)
76
+ ls -d worktrees 2>/dev/null # Alternative
77
+ ```
78
+ If found, use it. If both exist, `.worktrees` wins.
79
+
80
+ 3. **If there is no other guidance available**, default to `.worktrees/` at the project root.
81
+
82
+ #### Safety Verification (project-local directories only)
83
+
84
+ **MUST verify directory is ignored before creating worktree.** Check only the directory you actually selected above (e.g. `git check-ignore -q .worktrees` when `.worktrees/` was chosen); checking the other name can pass while the selected one is unignored:
85
+
86
+ ```bash
87
+ git check-ignore -q <the-selected-directory>
88
+ ```
89
+
90
+ **If NOT ignored:** Add to .gitignore, commit the change, then proceed.
91
+
92
+ **Why critical:** Prevents accidentally committing worktree contents to repository.
93
+
94
+ #### Create the Worktree
95
+
96
+ ```bash
97
+ # Determine path based on chosen location
98
+ path="$LOCATION/$BRANCH_NAME"
99
+
100
+ git worktree add "$path" -b "$BRANCH_NAME"
101
+ cd "$path"
102
+ ```
103
+
104
+ **Sandbox fallback:** If `git worktree add` fails with a permission error (sandbox denial), tell the user the sandbox blocked worktree creation and you're working in the current directory instead. Then run setup and baseline tests in place.
105
+
106
+ ## Step 2: Project Setup
107
+
108
+ Auto-detect and run appropriate setup:
109
+
110
+ ```bash
111
+ # Node.js
112
+ if [ -f package.json ]; then npm install; fi
113
+
114
+ # Rust
115
+ if [ -f Cargo.toml ]; then cargo build; fi
116
+
117
+ # Python
118
+ if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
119
+ if [ -f pyproject.toml ]; then poetry install; fi
120
+
121
+ # Go
122
+ if [ -f go.mod ]; then go mod download; fi
123
+ ```
124
+
125
+ ## Step 3: Verify Clean Baseline
126
+
127
+ Run tests to ensure workspace starts clean:
128
+
129
+ ```bash
130
+ # Use project-appropriate command
131
+ npm test / cargo test / pytest / go test ./...
132
+ ```
133
+
134
+ **If tests fail:** Report failures, ask whether to proceed or investigate.
135
+
136
+ **If tests pass:** Report ready.
137
+
138
+ ### Report
139
+
140
+ ```
141
+ Worktree ready at <full-path>
142
+ Tests passing (<N> tests, 0 failures)
143
+ Ready to implement <feature-name>
144
+ ```
145
+
146
+ ## Quick Reference
147
+
148
+ | Situation | Action |
149
+ |-----------|--------|
150
+ | Already in linked worktree | Skip creation (Step 0) |
151
+ | In a submodule | Treat as normal repo (Step 0 guard) |
152
+ | Native worktree tool available | Use it (Step 1a) |
153
+ | No native tool | Git worktree fallback (Step 1b) |
154
+ | `.worktrees/` exists | Use it (verify ignored) |
155
+ | `worktrees/` exists | Use it (verify ignored) |
156
+ | Both exist | Use `.worktrees/` |
157
+ | Neither exists | Check instruction file, then default `.worktrees/` |
158
+ | Directory not ignored | Add to .gitignore + commit |
159
+ | Permission error on create | Sandbox fallback, work in place |
160
+ | Tests fail during baseline | Report failures + ask |
161
+ | No package.json/Cargo.toml | Skip dependency install |
162
+
163
+ ## Common Rationalizations
164
+
165
+ | Excuse | Reality |
166
+ |--------|---------|
167
+ | "I'm obviously not in a worktree — no need to check" | Run Step 0. Harness-created isolation and submodules both fool eyeballing; the detection commands settle it. |
168
+ | "`git worktree add` is quicker than hunting for a native tool" | A native tool (e.g. `EnterWorktree`) owns placement, branching, and cleanup. Bypassing it is the #1 mistake — it creates phantom state your harness can't see or manage. |
169
+ | "The worktree directory is surely ignored already" | Run `git check-ignore`. An unignored worktree directory commits the whole tree into the repo. |
170
+ | "Any directory name works" | Explicit instructions beat an existing project-local directory, which beats the `.worktrees/` default. |
171
+ | "The workspace is fresh — baseline tests can wait" | A dirty baseline makes every later failure ambiguous. Run the tests now; proceeding past failures is your human partner's call. |
@@ -0,0 +1,183 @@
1
+ ---
2
+ name: pitroom-writing-plans
3
+ description: Use when you have a spec or requirements for a multi-step task, before touching code - writes a task-by-task implementation plan that Pitroom workers can execute.
4
+ ---
5
+
6
+ # Writing Plans
7
+
8
+ ## Overview
9
+
10
+ Write comprehensive implementation plans assuming the engineer has zero context for our codebase and questionable taste. Document everything they need to know: which files to touch for each task, code, testing, docs they might need to check, how to test it. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits.
11
+
12
+ Assume they are a skilled developer, but know almost nothing about our toolset or problem domain. Assume they don't know good test design very well.
13
+
14
+ **Announce at start:** "I'm using the pitroom-writing-plans skill to create the implementation plan."
15
+
16
+ **Context:** If working in an isolated worktree, it should have been created via the `pitroom-worktrees` skill at execution time.
17
+
18
+ **Save plans to:** `docs/pitroom/plans/YYYY-MM-DD-<feature-name>.md`
19
+ - (User preferences for plan location override this default)
20
+
21
+ ## Scope Check
22
+
23
+ If the spec covers multiple independent subsystems, it should have been broken into sub-project specs during brainstorming. If it wasn't, suggest breaking this into separate plans — one per subsystem. Each plan should produce working, testable software on its own.
24
+
25
+ ## File Structure
26
+
27
+ Before defining tasks, map out which files will be created or modified and what each one is responsible for. This is where decomposition decisions get locked in.
28
+
29
+ - Design units with clear boundaries and well-defined interfaces. Each file should have one clear responsibility.
30
+ - You reason best about code you can hold in context at once, and your edits are more reliable when files are focused. Prefer smaller, focused files over large ones that do too much.
31
+ - Files that change together should live together. Split by responsibility, not by technical layer.
32
+ - In existing codebases, follow established patterns. If the codebase uses large files, don't unilaterally restructure - but if a file you're modifying has grown unwieldy, including a split in the plan is reasonable.
33
+
34
+ This structure informs the task decomposition. Each task should produce self-contained changes that make sense independently.
35
+
36
+ ## Task Right-Sizing
37
+
38
+ A task is the smallest unit that carries its own test cycle and is worth a
39
+ fresh reviewer's gate. When drawing task boundaries: fold setup,
40
+ configuration, scaffolding, and documentation steps into the task whose
41
+ deliverable needs them; split only where a reviewer could meaningfully
42
+ reject one task while approving its neighbor. Each task ends with an
43
+ independently testable deliverable.
44
+
45
+ ## Worker Tier
46
+
47
+ Every task names the worker tier that implements it, on its own line right under the heading: `**Worker:** cheap`, `**Worker:** standard` or `**Worker:** capable`. `pitroom run --plan` uses it when the executor names no worker; the user's config maps tiers to workers (`tiers`).
48
+
49
+ - **cheap**: the task text contains the complete code (implementation is transcription plus testing), or a single-file mechanical fix.
50
+ - **standard**: several files with integration concerns, or an implementer working from prose.
51
+ - **capable**: design judgment or broad understanding of the codebase.
52
+
53
+ Turn count beats token price: the cheapest models take 2-3× the turns on multi-step work. When unsure between two tiers, take the higher.
54
+
55
+ ## Bite-Sized Task Granularity
56
+
57
+ **Each step is one action (2-5 minutes):**
58
+ - "Write the failing test" - step
59
+ - "Run it to make sure it fails" - step
60
+ - "Implement the minimal code to make the test pass" - step
61
+ - "Run the tests and make sure they pass" - step
62
+ - "Commit" - step
63
+
64
+ ## Plan Document Header
65
+
66
+ **Every plan MUST start with this header:**
67
+
68
+ ```markdown
69
+ # [Feature Name] Implementation Plan
70
+
71
+ > **For agentic workers:** REQUIRED SUB-SKILL: Use pitroom-driven-development to implement this plan task-by-task (each task runs as `pitroom run -i --plan <this file> --step N`). Steps use checkbox (`- [ ]`) syntax for tracking.
72
+
73
+ **Goal:** [One sentence describing what this builds]
74
+
75
+ **Architecture:** [2-3 sentences about approach]
76
+
77
+ **Tech Stack:** [Key technologies/libraries]
78
+
79
+ **Spec:** [path to the spec/design doc this plan implements — the plan
80
+ argues from the spec, so the spec travels with it; executors read both]
81
+
82
+ ## Global Constraints
83
+
84
+ [The spec's project-wide requirements — version floors, dependency limits,
85
+ naming and copy rules, platform requirements — one line each, with exact
86
+ values copied verbatim from the spec. Every task's requirements implicitly
87
+ include this section.]
88
+
89
+ ---
90
+ ```
91
+
92
+ ## Task Structure
93
+
94
+ Task headings are exactly `### Task N: <name>`: `pitroom run --plan` finds tasks by them, and a task runs until the next heading of the same or a higher level.
95
+
96
+ ````markdown
97
+ ### Task N: [Component Name]
98
+
99
+ **Worker:** cheap | standard | capable
100
+
101
+ **Files:**
102
+ - Create: `exact/path/to/file.py`
103
+ - Modify: `exact/path/to/existing.py:123-145`
104
+ - Test: `tests/exact/path/to/test.py`
105
+
106
+ **Interfaces:**
107
+ - Consumes: [what this task uses from earlier tasks — exact signatures]
108
+ - Produces: [what later tasks rely on — exact function names, parameter
109
+ and return types. A task's implementer sees only their own task; this
110
+ block is how they learn the names and types neighboring tasks use.]
111
+
112
+ - [ ] **Step 1: Write the failing test**
113
+
114
+ ```python
115
+ def test_specific_behavior():
116
+ result = function(input)
117
+ assert result == expected
118
+ ```
119
+
120
+ - [ ] **Step 2: Run test to verify it fails**
121
+
122
+ Run: `pytest tests/path/test.py::test_name -v`
123
+ Expected: FAIL with "function not defined"
124
+
125
+ - [ ] **Step 3: Write minimal implementation**
126
+
127
+ ```python
128
+ def function(input):
129
+ return expected
130
+ ```
131
+
132
+ - [ ] **Step 4: Run test to verify it passes**
133
+
134
+ Run: `pytest tests/path/test.py::test_name -v`
135
+ Expected: PASS
136
+
137
+ - [ ] **Step 5: Commit**
138
+
139
+ ```bash
140
+ git add tests/path/test.py src/path/file.py
141
+ git commit -m "feat: add specific feature"
142
+ ```
143
+ ````
144
+
145
+ Workers never commit: an implementer skips commit steps, and the primary commits after the task's review, when it applies the patch. Write the commit step anyway; it tells the primary what to commit and how to word it.
146
+
147
+ ## No Placeholders
148
+
149
+ Every step must contain the actual content an engineer needs. These are **plan failures** — never write them:
150
+ - "TBD", "TODO", "implement later", "fill in details"
151
+ - "Add appropriate error handling" / "add validation" / "handle edge cases"
152
+ - "Write tests for the above" (without actual test code)
153
+ - "Similar to Task N" (repeat the code — the engineer may be reading tasks out of order)
154
+ - Steps that describe what to do without showing how (code blocks required for code steps)
155
+ - References to types, functions, or methods not defined in any task
156
+
157
+ ## Self-Review
158
+
159
+ After writing the complete plan, look at the spec with fresh eyes and check the plan against it. This is a checklist you run yourself — not a subagent dispatch.
160
+
161
+ **1. Spec coverage:** Skim each section/requirement in the spec. Can you point to a task that implements it? List any gaps.
162
+
163
+ **2. Placeholder scan:** Search your plan for red flags — any of the patterns from the "No Placeholders" section above. Fix them.
164
+
165
+ **3. Type consistency:** Do the types, method signatures, and property names you used in later tasks match what you defined in earlier tasks? A function called `clearLayers()` in Task 3 but `clearFullLayers()` in Task 7 is a bug.
166
+
167
+ **4. Headings and tiers:** every task has a `### Task N:` heading with a unique N and a `**Worker:**` line.
168
+
169
+ If you find issues, fix them inline. No need to re-review — just fix and move on. If you find a spec requirement with no task, add the task.
170
+
171
+ ## Execution Handoff
172
+
173
+ After saving the plan, optionally have a read-only worker check it with [plan-document-reviewer-prompt.md](plan-document-reviewer-prompt.md) (fill `{{PLAN_FILE}}` and `{{SPEC_FILE}}` with `sed` as in `pitroom-brainstorming`, run it with `pitroom run --task-file`). Then offer:
174
+
175
+ **"Plan complete and saved to `docs/pitroom/plans/<filename>.md`. Two execution options:**
176
+
177
+ **1. Pitroom-driven (recommended)** - a worker implements each task in an isolated copy, another model reviews it, I apply and commit between tasks
178
+
179
+ **2. Inline** - I execute the tasks myself in this session, with the same checkpoints
180
+
181
+ **Which approach?"**
182
+
183
+ Either way: **REQUIRED SUB-SKILL:** `pitroom-driven-development` (its "Inline execution" section covers option 2).
@@ -0,0 +1,23 @@
1
+ You are a plan document reviewer. Verify that this plan is complete and ready for implementation by workers who see only one task each.
2
+
3
+ Plan to review: {{PLAN_FILE}}
4
+ Spec for reference: {{SPEC_FILE}}
5
+
6
+ ## What to check
7
+
8
+ | Category | What to look for |
9
+ |---|---|
10
+ | Completeness | TODOs, placeholders, incomplete tasks, missing steps, "similar to Task N" |
11
+ | Spec alignment | The plan covers the spec's requirements, no major scope creep |
12
+ | Task decomposition | Clear boundaries, actionable steps, each task independently testable |
13
+ | Buildability | Could a worker follow one task, with only the plan's header and Global Constraints, without getting stuck? |
14
+ | Structure | Every task has a `### Task N:` heading with a unique N and a `**Worker:**` tier; names and types match across tasks |
15
+
16
+ ## Calibration
17
+
18
+ Only flag issues that would cause real problems during implementation: a worker building the wrong thing or getting stuck. Wording, style and nice-to-haves are not issues. Approve unless there are serious gaps: missing requirements from the spec, contradictory steps, placeholder content, or tasks too vague to act on.
19
+
20
+ ## Answer
21
+
22
+ SUMMARY: STATUS: APPROVED, or SUMMARY: STATUS: ISSUES FOUND (N)
23
+ In DETAILS: each issue as "[Task X, Step Y]: issue - why it matters for implementation", then RECOMMENDATIONS (advisory; they do not block approval).
@@ -0,0 +1,66 @@
1
+ ---
2
+ name: using-pitroom
3
+ description: Use when you want cheap Pitroom workers or its workflow skills for a task, or when the user asks for Pitroom - a menu of the pitroom-* skills (brainstorm, plan, worker-driven development, review, debugging, TDD, verification, finishing), when each pays off, and how to run workers. Optional; skip it for work you would rather do yourself.
4
+ ---
5
+
6
+ <SUBAGENT-STOP>
7
+ If you are a Pitroom worker, or were dispatched as a subagent for one specific task, ignore this skill.
8
+ </SUBAGENT-STOP>
9
+
10
+ # Using Pitroom
11
+
12
+ You are the primary agent: capable, expensive, and your context is precious. Pitroom gives you a development workflow as skills, and a crew of cheap worker agents (OpenCode, Codex, Claude Code, on whatever models the user configured) that read, search, implement and review for you. You decide, verify and answer.
13
+
14
+ ## Optional by design
15
+
16
+ Pitroom is a toolbox, not a procedure. Use it when you judge it saves effort or improves the result, or when the user asks for it: by name, or for what it does ("brainstorm this with me", "write a plan", "have a worker do it", "get this reviewed"). Otherwise work as you normally would, with no skill and no worker. When the user says to stop using it, stop.
17
+
18
+ The user's instructions (CLAUDE.md, AGENTS.md, direct requests) always come before any of this.
19
+
20
+ ## When it pays off
21
+
22
+ - Reading a lot to answer a little: many files to search, a flow to trace, a large module to map (`pitroom-research`).
23
+ - Well-defined, checkable work you can hand off with a short brief: mechanical edits across files, tests to write, lint or type errors (`pitroom-implement`), several independent ones at once (`pitroom-crew`).
24
+ - A second opinion from another model on a diff or a branch (`pitroom-review`).
25
+ - Larger features you want to take through design, plan and worker-driven execution (the workflow skills below).
26
+
27
+ A worker's brief pays off when the work is **bounded** (one question, one area, one well-defined change), **specifiable** (the worker sees none of this conversation) and **checkable** (a diff, a test run, file:line references).
28
+
29
+ ## When to leave it
30
+
31
+ - Small work: a typo, a one-line fix, a rename inside one file, a value the user named, a question you can answer from what you know or one file, talking an idea through, running a command the user gave you. Just do it.
32
+ - Design and product judgment, auth, crypto, payments and migrations, and anything that needs the user's input or secrets: keep those yourself; delegate at most the reading that informs them.
33
+
34
+ ## Which skill
35
+
36
+ | Situation | Skill |
37
+ |---|---|
38
+ | A feature, component or behaviour change you want designed with the user first | `pitroom-brainstorming` |
39
+ | A spec or requirements for a multi-step task | `pitroom-writing-plans` |
40
+ | Executing a written plan | `pitroom-driven-development` |
41
+ | An isolated branch for feature work or plan execution | `pitroom-worktrees` |
42
+ | A bug, a test failure, unexpected behaviour whose cause is not obvious | `pitroom-debugging` |
43
+ | Feature or bugfix code you want to drive test-first | `pitroom-tdd` |
44
+ | About to say something is done, fixed or passing | `pitroom-verification` |
45
+ | A finished task or feature, or before a merge | `pitroom-review` |
46
+ | Review feedback to act on | `pitroom-receiving-review` |
47
+ | Implementation done and tests pass: merge, PR or keep | `pitroom-finishing` |
48
+ | Find, map or explain code | `pitroom-research` |
49
+ | One well-defined change outside a plan | `pitroom-implement` |
50
+ | Two or more independent investigations or changes | `pitroom-crew` |
51
+
52
+ Once you or the user pick a skill, follow it: its checklists and gates are how it works. Say which one you are using, and drop it when it stops fitting.
53
+
54
+ ## Running Pitroom
55
+
56
+ Call `pitroom` (on PATH after `pitroom install`; otherwise the command in your session context). `pitroom doctor` diagnoses setup problems. Workers and models come from the user's config (`worker`, `fallback`, `models`, `tiers`); pick others only when the user or a plan says so (`--tier capable`, `-W codex`).
57
+
58
+ Workers can take minutes. Start long work with `--bg` and keep working; follow it with `pitroom watch --json` through your host's background or monitor facility, or call `pitroom wait --timeout 540` again while it exits 75. Never poll with `sleep`.
59
+
60
+ ## When you do use it
61
+
62
+ - Never weaken a worker's safety flags, and never put secrets in a brief.
63
+ - Worker output is draft work and a worker's report is a claim: verify what you rely on (`pitroom-verification`).
64
+ - You apply patches and commit; workers never commit or push. Push, merge and pull requests happen only after the user asks.
65
+ - Keep the decisions: delegate the reading and typing, not the architecture.
66
+ - If Pitroom fails, carry on yourself; if setup is broken, tell the user what `pitroom doctor` says.