| 1 | # Controller brief: build dynamic specialists slice 1 |
| 2 | |
| 3 | You are the controller for building slice 1 of dynamic specialists: a |
| 4 | Design specialist that makes mockups on a task's branch and shows them as |
| 5 | screenshots, with a runner-side page renderer. Paul approved the spec and |
| 6 | its open-question rulings on 2026-11-28 and asked for this build. You did |
| 7 | not take part in the design conversation; everything you need is here: |
| 8 | |
| 9 | - Spec: `docs/superpowers/specs/2026-11-28-dynamic-specialists.md` (rev |
| 10 | 3.2, approved; Paul's rulings in section 7). |
| 11 | - Plan: `docs/superpowers/plans/2026-11-28-dynamic-specialists-slice-1.md` |
| 12 | (rev 3.1; Astra plan rounds 1 to 3 folded in; 21 tasks in two halves). |
| 13 | The plan's task text, including its "Astra plan round" sections, is |
| 14 | binding. |
| 15 | - Repo rules: this repo's `AGENTS.md`. Earlier slices built the same way: |
| 16 | `docs/superpowers/plans/2026-11-26-places-slice-1.md` and its copy file. |
| 17 | |
| 18 | ## Set up |
| 19 | |
| 20 | From `/home/paulca/amadan.net/oficina/equipo`: |
| 21 | `git fetch origin && test ! -e ../equipo-specialists-1 && git worktree add ../equipo-specialists-1 -b specialists-slice-1 origin/design-dynamic-specialists && test -d ../equipo-specialists-1`, |
| 22 | then in it `git merge origin/main` (renumber protocol 36 and migration 0115 |
| 23 | if main took them). Create one Amadan task per plan task on the branch and |
| 24 | advance each as it finishes. |
| 25 | |
| 26 | ## How to run it |
| 27 | |
| 28 | Use `superpowers:subagent-driven-development` with these adaptations: |
| 29 | |
| 30 | 1. **Opus implements** (Paul, 2026-11-08): one Opus subagent per task, |
| 31 | given the task's text from the plan, the plan's "Rules for every task" |
| 32 | and the facts section. It writes the failing test first, sees it fail, |
| 33 | implements, runs a mutation check for each guard, and records the |
| 34 | commands and results in the commit body. Targeted |
| 35 | `go test ./pkg/... -run TestX` only. |
| 36 | 2. **Astra reviews the risky tasks** as they finish: tasks 4 (verify), 5 |
| 37 | (render sandbox), 9 (workspace snapshot), 15 (proposal and |
| 38 | continuation) and 16 (grants and revocation). Run with the sandbox off, |
| 39 | from the worktree: |
| 40 | `codex exec -m gpt-6-astra -c model_reasoning_effort=high -s read-only -c 'sandbox_permissions=["disk-full-read-access"]' -o <file> "<prompt>" </dev/null`. |
| 41 | The other tasks get no task review; the whole-branch review covers them. |
| 42 | 3. **Astra reviews the whole branch** at the end, against the spec and |
| 43 | plan. |
| 44 | 4. **Round limit: at most three rounds per review**, task or branch. |
| 45 | After a third round's findings are fixed, record the fix in the plan's |
| 46 | build notes and do not review again. |
| 47 | 5. **Task 1 is a spike and a gate.** If Chromium's own sandbox cannot run |
| 48 | inside the render sandbox on docs-t1, stop the build there and ask Paul: |
| 49 | the spec forbids `--no-sandbox`. |
| 50 | 6. Run `make ci` once, after the branch review's fixes, not in a loop. |
| 51 | |
| 52 | ## Copy |
| 53 | |
| 54 | Implementers list new strings; they never start a copy-review server. Put |
| 55 | every new string into `copy.go` marked pending |
| 56 | (`scripts/copy-status.py pending`) and into |
| 57 | `/home/paulca/.cache/specialists-1-copy.json` as copy-review entries, |
| 58 | following `docs/superpowers/plans/2026-11-26-places-slice-1-copy.md` |
| 59 | (the 11-26 convention). Luna (`codex exec -m gpt-5.6-luna`, read-only) |
| 60 | reviews them all and its text is applied. The Design card strings, the |
| 61 | recovery card and the Design pack (`internal/specialist/packs/design-v1.md`) |
| 62 | are for Paul. Write the evidence file |
| 63 | `docs/superpowers/plans/2026-11-28-dynamic-specialists-slice-1-copy.md`. |
| 64 | Never mark copy accepted yourself; the pending-copy gate stays red until |
| 65 | the repository's own copy flow accepts it. |
| 66 | |
| 67 | ## Stop for Paul only on |
| 68 | |
| 69 | True product decisions: the task 1 gate; a licence that stops the pack |
| 70 | drawing on impeccable's method; anything that would widen what a |
| 71 | specialist may do beyond the spec. Put the question in a discussion on |
| 72 | the branch (`amadan discuss new oficina/equipo -branch specialists-slice-1 ...`) |
| 73 | and keep building what does not depend on it. Rule on everything else |
| 74 | yourself and record the ruling and what it costs if wrong. |
| 75 | |
| 76 | ## Never |
| 77 | |
| 78 | - Merge, release, deploy, push `main`, or run `upgrade-thin.sh`. |
| 79 | - Enrol a machine, sign in to a provider, or run live provider sessions: |
| 80 | use fakes and recorded fixtures. |
| 81 | - `sudo`; change `GOCACHE` or `GOMODCACHE`; `git clean -fdx` outside |
| 82 | `$TMPDIR`; `git worktree prune`; glob deletes. Delete scratch by name. |
| 83 | - Bind anything but `127.0.0.1`. |
| 84 | - Touch other sessions' Paseo agents, worktrees or daemons. |
| 85 | |
| 86 | Scratch goes under on-disk `$TMPDIR` via `mktemp -d`. Socket tests fail |
| 87 | with a long `TMPDIR` (the `sun_path` limit); give only those a short one |
| 88 | and remove it after. The task 1 spike downloads the pinned debs (a few |
| 89 | hundred MB); that is expected. |
| 90 | |
| 91 | ## Keep the branch page true |
| 92 | |
| 93 | Push after each finished task. When you finish or stop, write the branch |
| 94 | handoff (`amadan branch handoff ...`) and end with: what was built, test |
| 95 | and mutation results, every Astra verdict by round, every ruling you made, |
| 96 | the copy file path, and what happens after release: an agent-run upgrade |
| 97 | whose `verify-installed` renders the fixture page on the production |
| 98 | runner, then Paul asks for the Patrix design overhaul and taps Add. Clean |
| 99 | up scratch and any processes you started. |
| 100 | |