[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75C11VXVBT356RSPSYFHM2W":3,"skill-same:01M75C11VXVBT356RSPSYFHM2W":52},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":30,"updatedAt":31,"install":32,"resources":45},"01M75C11VXVBT356RSPSYFHM2W","test-pilot-init",null,"Internal helper reached from `superheroes:configure` to refresh test-pilot's profile, seeding blocks, and browser tooling layer. Not a front door; owners run `superheroes:configure` instead.","zwrose\u002Fsuperheroes","zwrose","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F4790575?v=4","01M75BY6XGBZAMPTCT9R25XXC6","Zach Rose","01M75BY6Y519H0CAD79EFWSW3N",1,"MIT","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Ftest-pilot-init\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: test-pilot-init\ndescription: \"Internal helper reached from `superheroes:configure` to refresh test-pilot's profile, seeding blocks, and browser tooling layer. Not a front door; owners run `superheroes:configure` instead.\"\n---\n\nThis skill speaks in host-neutral actions. Resolve them to your runtime's tools by reading the host tool map at `${CLAUDE_PLUGIN_ROOT}\u002Fhosts\u002F\u003Cyour-host>-tools.md` (the leading variable is this plugin's root directory) — `claude-tools.md` on Claude Code, `codex-tools.md` on Codex.\n\n# test-pilot-init\n\nCreate or reconcile a project's **test-pilot profile** plus its starter\nseeding blocks. Two modes: **create** (nothing resolves) and **reconcile**\n(profile exists → re-detect, diff, migrate; NEVER silently overwrite).\n\n## Step 1 — Resolve\n\n```bash\nROOT_DIR=\"${CLAUDE_PLUGIN_ROOT}\"\nRES=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fstore.py\" resolve) || RC=$?\nRC=${RC:-0}\nif printf '%s' \"$RES\" | jq -e '.refusal != null' >\u002Fdev\u002Fnull 2>&1; then\n  printf '%s' \"$RES\" | jq -r '\"\\(.refusal.reason): \\(.refusal.detail)\"' >&2\n  exit 1\nfi\nif [ \"$RC\" -ne 0 ]; then\n  echo \"store.py resolve exited non-zero (exit $RC)\" >&2\n  exit \"$RC\"\nfi\nLOCATION=$(printf '%s' \"$RES\" | jq -r .location)\n# FR-7\u002F8: surface the single coalesced storage-mode reconcile nudge (non-blocking, ack-gated).\nNUDGE_MSG=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fmode_reconcile.py\" signals 2>\u002Fdev\u002Fnull | jq -r 'if . == null then empty else .message end' 2>\u002Fdev\u002Fnull)\n[ -n \"$NUDGE_MSG\" ] && echo \"⚠ storage-mode: $NUDGE_MSG\"\n```\n\n`location: none` → create mode (Steps 2–6). Otherwise → reconcile (Step 7).\n\n## Step 2 — Detect (no questions the repo can answer)\n\nRead `CLAUDE.md` first — the profile is an ADDER over it. Then detect:\nstack\u002Fscripts (`package.json` scripts, `pyproject.toml`), dev command and\nport, DB env vars (`.env*` files — names only, never read values into the\nprofile), docker-compose services, existing seed scripts, `git remote\nget-url origin`.\n\n\u003C!-- decision-point: id=tp-init-uv mode=proceed kind=interview-step default=\"record uv absent; blocks limited to stdlib + run-command\" carrier=test-pilot-layer -->\nCheck `uv` availability (`command -v uv`). When absent, record `uv` absent in\n`## Setup disclosures` and state that blocks are limited to stdlib + run-command\ndesigns — do not offer to install. When present, record `uv` available. Continue\ndetection. Follow-up: `\u002Fsuperheroes:configure`.\n\u003C!-- \u002Fdecision-point: id=tp-init-uv -->\n\n## Step 3 — Browser tooling gate\n\nUse ToolSearch to check which browser MCPs are connected (search \"chrome-devtools\", \"Claude_in_Chrome\", \"playwright\").\nFor a Google sign-in or a pilot launched from a worktree, read `${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Fpilot-contract.md` § Browser launch recipes.\n\n\u003C!-- decision-point: id=tp-init-browser-tools mode=proceed kind=interview-step default=\"chrome-devtools, playwright, Claude_in_Chrome — detected subset in that order\" carrier=test-pilot-layer -->\n**`browserTools` provisional default.** When one or more tools are detected,\nwrite `browserTools` as the detected subset in fixed preference order:\n`chrome-devtools`, then `playwright`, then `Claude_in_Chrome` (omit undetected\nnames; never write an empty array). Record the chosen order in\n`## Setup disclosures`. Continue. Follow-up: `\u002Fsuperheroes:configure`.\n\u003C!-- \u002Fdecision-point: id=tp-init-browser-tools -->\n\n\u003C!-- decision-point: id=tp-init-browser-gate mode=gate kind=owner-gate default=\"hand back; no browser tool connected\" carrier=run-output -->\nWhen **no** browser MCP is connected, GATE: write the remediation down in the\nrun output (install chrome-devtools MCP, Playwright plugin, or Claude in Chrome\nextension), record that no browser tool is connected, leave `browserTools`\n**absent** (not an empty array), and **hand back** — do not continue init or\ndrive browser tooling. **No layer is written on this path** — init stops here\nbefore Step 6's writer runs. Follow-up: `\u002Fsuperheroes:configure`.\n\u003C!-- \u002Fdecision-point: id=tp-init-browser-gate -->\n\n## Step 4 — Decide location\n\n\u003C!-- decision-point: id=tp-init-storage mode=notify kind=storage-location default=\"returned .mode from store CLI\" carrier=test-pilot-layer -->\n```bash\nROOT_DIR=\"${CLAUDE_PLUGIN_ROOT}\"\nDEC=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fstore.py\" decide-location) || { echo \"decide-location exited non-zero (exit $?); halting rather than taking an undisclosed storage default\" >&2; exit 1; }\nLOC=$(printf '%s' \"$DEC\" | jq -r '.mode')            # \"in-repo\" | \"global\" — never \"ask\"\nSOURCE=$(printf '%s' \"$DEC\" | jq -r '.source')\nPROVISIONAL=$(printf '%s' \"$DEC\" | jq -r '.provisional')   # \"true\" | \"false\"\n[ -n \"$LOC\" ] && [ -n \"$PROVISIONAL\" ] && [ -n \"$SOURCE\" ] || { echo \"decide-location returned no usable decision; halting rather than taking an undisclosed storage default\" >&2; exit 1; }\nPATHS=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fstore.py\" create --location \"$LOC\") || RC=$?\nRC=${RC:-0}\nif [ \"$RC\" -ne 0 ]; then\n  printf '%s' \"$PATHS\" | jq -r 'if .reason then \"\\(.reason): \\(.detail)\" else \"store.py create exited non-zero (exit '\"$RC\"')\" end' >&2\n  exit \"$RC\"\nfi\n```\n\n**Storage location (`decide-location`).** `decide-location` returns JSON: `.mode` is `in-repo` or\n`global` (`ask` no longer exists); `.source` is where the decision came from: `env` (environment\noverride `TEST_PILOT_STORAGE` for this run only; never recorded), `registry` (a mode the owner\nrecorded; authoritative), `backfilled` (a mode inferred from consistent existing evidence and then\nrecorded), `provisional` (nothing recorded and no consistent evidence; the lib's default, re-taken\nnext run); `.provisional` is `true` when the mode was not owner-recorded. **Default:**\nthe returned `.mode` (recorded when configured, else the lib's provisional default). Bootstrap\nblocks never record — an unrecorded mode is re-taken next run. **Disclosure.** Write into the\n**test-pilot layer body** (the markdown piped to `core_md.py write-layer --hero test-pilot` in\nStep 6 — a `## Setup disclosures` section, not the generated provenance block): the storage mode\ntaken, its source, whether it is provisional, and that `\u002Fsuperheroes:configure` changes it. When\n`.provisional` is `true`, also state that it is a provisional default rather than an owner choice\nand will be re-taken on the next run when not recorded. **Follow-up:** `\u002Fsuperheroes:configure`.\nNOTIFY: the run continues after the disclosure lands in `## Setup disclosures`.\n\u003C!-- \u002Fdecision-point: id=tp-init-storage -->\n\n## Step 5 — Provisional defaults (no interview)\n\n\u003C!-- decision-point: id=tp-init-provisional-defaults mode=proceed kind=interview-step default=\"named provisional defaults per field list below\" carrier=test-pilot-layer -->\nDo not interview. Take named provisional defaults for every field detection + `CLAUDE.md` left\nopen. Write which fields were defaulted into `## Setup disclosures` of `$TEST_PILOT_LAYER_BODY`\n(the markdown piped to `core_md.py write-layer --hero test-pilot` in Step 6). Never guess a\nprotected target — when detection cannot name a production-shaped DB\u002Fsurface to refuse, state\nthat in `## Setup disclosures` and leave the gate **refusing** rather than inventing a target.\nContinue to Step 6. Follow-up: `\u002Fsuperheroes:configure`.\n\n**Provisional defaults** (when detection + `CLAUDE.md` did not answer):\n\n1. **Auth strategy** — `review-only` (provisional default): unattended execute cannot assume\n   credentials; the owner confirms via `\u002Fsuperheroes:configure`.\n2. **Protected targets** — only names detection actually found; if none, record `none detected —\n   gate refuses` and do not scaffold a target list.\n3. **Base URL \u002F readiness probe** — detected dev URL\u002Fport when present, else\n   `http:\u002F\u002Flocalhost:\u003Cdetected-port>` when a port was detected, else refuse to guess.\n4. **`dbEnvVar`** — first database-related env var **name** detected from `.env*` files (names\n   only, never values); if none, omit the field and record `none detected` in\n   `## Setup disclosures`.\n5. **`apiBase`** — `{baseUrl}\u002Fapi` when `baseUrl` is known; if `baseUrl` is unknown, omit the\n   field and record `none detected` in `## Setup disclosures`.\n6. **`allowedOrigins`** — `[]` (provisional default).\n7. **`devCommand`** — detected from `package.json` scripts (`dev`, then `start`) or\n   `pyproject.toml` `[project.scripts]`; if none detected, omit the field and record\n   `none detected` in `## Setup disclosures`.\n8. **`mayManageServer`** — `false` (provisional default): execute will not start the server\n   without owner confirmation via `\u002Fsuperheroes:configure`.\n9. **`browserTools`** — per Step 3 (`tp-init-browser-tools` \u002F `tp-init-browser-gate`); when none\n   detected, the field stays absent.\n\u003C!-- \u002Fdecision-point: id=tp-init-provisional-defaults -->\n\n## Step 6 — Scaffold\n\n1. Fill `${CLAUDE_PLUGIN_ROOT}\u002Ftemplates\u002Fprofile.md` (prose AND the\n   `json test-pilot-config` block — keep them consistent) and write it to\n   the resolved profile path. Set provenance `status=provisional` always on this create path —\n   only `\u002Fsuperheroes:configure` confirms with real answers.\n2. Write 1–2 starter blocks bespoke to this app into the resolved\n   `blocks_dir`, from `templates\u002Fstarter-block.py` — e.g. an HTTP seeder\n   against the detected API, or a `run-command` design wrapping an existing\n   seed script. Every block declares non-empty `targets` and pins PEP 723\n   dependency versions.\n3. Generate the catalog:\n   `python3 -B \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fcatalog.py\" --blocks-dir \u003Cblocks_dir>`\n4. CREATE path (fresh setup, FR-5): Fail-closed guard before the pipes below — not the\n   mechanical-carrier redesign: refuse when either the shared facts JSON (stack, verify command,\n   threat model) or `$TEST_PILOT_LAYER_BODY` (test-pilot's `json test-pilot-config` block + prose,\n   including the `## Setup disclosures` section assembled from Steps 4–5) is empty, because\n   `write-layer` replaces the entire layer file and an empty piped payload would silently blank it.\n   When either payload is empty, surface `assembly produced empty payloads; halting rather than\n   writing an empty layer` and **stop** — do not pipe into `write` or `write-layer`. When both\n   payloads are present, pipe the shared facts JSON into\n   `python3 -B \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fcore_md.py\" write\n   --status provisional` to write the band-wide `core.md`, and pipe `$TEST_PILOT_LAYER_BODY` into\n   `core_md.py write-layer --hero test-pilot --status \u003Cs>` so they land in the `test-pilot.md`\n   layer (FR-3). On reconcile of a pre-existing profile, the legacy `profile.md` is not adopted —\n   `resolve_shared` returns the `legacy-profile-unsupported` refusal pointing at\n   `superheroes:configure` — no shared facts to read yet; re-calibrate through configure first\n   (`core_md resolve` only after `core.md` exists; CONVENTIONS §2.1 \u002F §2.2). Never hand-format core.md — the lib owns\n   the format and the config lock. `write --status confirmed` is the CREATE path only; confirming\n   a pre-existing **provisional** core\u002Flayer goes through `core_md.py confirm` (reached from\n   `superheroes:configure`), which `write` cannot do on an existing file (it returns `reused`).\n   After `write`, check the result's `action`: `refused` (`fable-on-external-engine`,\n   `core-md-unreadable`, or `dispatch-gate-evaluation-failed`) means the core was **not** written —\n   surface the `violations` to the user and **stop**; do not run `write-layer` (`write` exits 0 either\n   way, so check `action`, not exit status).\n\nReport what was written and where; remind the user that `test-pilot-plan`\npicks it up from here.\n\n**iPhone check.** When the project's lanes will run the iPhone check, its app needs a\ndevelopment-only reporting script. Read `${CLAUDE_PLUGIN_ROOT}\u002Fskills\u002Ftest-pilot-init\u002Freference\u002Freporting-script.md`\nand tell the user the project adds the script itself.\n\n### Conformance run (when `pilot` block is declared)\n\nAfter calibration is written, and **only when** the profile declares a `pilot`\nblock, run the headless conformance pass (normative CLI in\n`reference\u002Fpilot-contract.md` §The conformance run):\n\n```bash\nROOT_DIR=\"${CLAUDE_PLUGIN_ROOT}\"\nREPORT_JSON=\"$(mktemp)\"\ntrap 'rm -f \"$REPORT_JSON\"' EXIT\nCONFORMANCE_ARGS=(run --cwd .)\nif [ -n \"${PILOT_REGISTRY:-}\" ]; then\n  CONFORMANCE_ARGS+=(--registry-path \"$PILOT_REGISTRY\")\nfi\npython3 -B \"$ROOT_DIR\u002Flib\u002Fpilot_conformance.py\" \"${CONFORMANCE_ARGS[@]}\" > \"$REPORT_JSON\"\npython3 -B \"$ROOT_DIR\u002Flib\u002Fpilot_acceptance.py\" matrix \\\n  --report-path \"$REPORT_JSON\" \\\n  --project \"$(basename \"$(pwd)\")\" \\\n  --commit \"$(git rev-parse HEAD)\" \\\n  --format markdown\n```\n\nWhen the project maintains a declare-and-exercise registry (see\n`reference\u002Fpilot-contract.md` §Declare and exercise), set `PILOT_REGISTRY` to\nthat JSON path before running the conformance step so `--registry-path` is passed\nand the report carries a `declarations` envelope. **Without a registry path** the\nconformance report's `declarations` key is `null` — the matrix CLI still\nrenders, but declaration-backed rows read `unexercised` with a stated reason;\nthat is the ordinary adopter case, not a refusal.\n\nStdout is the report JSON from the conformance run; the matrix step prints\nmarkdown on stdout. Stderr carries diagnostics. **Exit 1 is a real outcome to\nreport, not an error to swallow** — show the operator which surfaces came back\n`unexercised` and why, from the report's `resolution` list. The matrix's `ok`\nis **false** when any row is `unexercised`, when the reference worktree is\ndirty, or when the run itself left surfaces `unexercised` — that is the honest\noutcome for a project that has not exercised everything, **not a failure to\nwork around**. `--commit` must be a **full object id** (run `git rev-parse\nHEAD` in the reference project — not a branch name). **Dirty** is derived from\n`git status --porcelain` in the **CLI process's current working directory** when\nneither `--dirty` nor `--clean` is passed; pass `--dirty` or `--clean` to\noverride. The run **never** writes into the repository when `--allow-live-effects` is not passed. The\n`cleanup-end-to-end`, `mint-gate-off`, and `ownership-probe` exercises are\nreported as **unexercised** unless the operator explicitly passes\n`--allow-live-effects`; opting in runs the project's own destructive cleanup,\ngate-off, and ownership-probe commands against live datastore and checkout\nresources. A `mint-gate-off` exercise that does not produce a usable receipt is\nreported as **unexercised**, never recorded as exercised — configure refuses to\nclaim it. The matrix is **generated, not stored** by the plugin — where a\nproject keeps it is the project's own decision.\n\n### Pilot block (optional)\n\nThe nested `pilot` key inside `test-pilot-config` is **omitted entirely** unless the owner\nhas answered every one of its no-default fields. Do not scaffold it during init.\n\n- `effectsEscape`, the mint envelope, and expected pilot identities are **never synthesized,\n  defaulted, or placeholder-filled** — an unanswered declaration is absent and absent refuses.\n- Expected identity and the mintable-account allowlist are **policy**; they do not belong in\n  the `pilot` block at all (resolved via `policyRef.declaration` against an external policy\n  document).\n- Normative field table, refusal tokens, and probe vocabulary:\n  `${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Fpilot-contract.md`.\n\n## Step 7 — Reconcile mode\n\n\u003C!-- decision-point: id=tp-init-reconcile-drift mode=gate kind=owner-gate default=\"hand back; apply nothing\" carrier=run-output -->\nRe-run detection, then DIFF against the existing profile. GATE: write the drift diff down in the\nrun output (changed dev command, new env vars, vanished scripts, and any other detected deltas)\nand **hand back** — apply **no** profile changes and write **no** layer on this init path.\nHand-edits in the profile are preserved because nothing is written. Never regenerate from scratch\nover an existing profile. Follow-up: `\u002Fsuperheroes:configure` to apply, edit, or skip changes.\n\u003C!-- \u002Fdecision-point: id=tp-init-reconcile-drift -->\n","This skill speaks in host-neutral actions. Resolve them to your runtime's tools by reading the host tool map at `${CLAUDE_PLUGIN_ROOT}\u002Fhosts\u002F\u003Cyour-host>-tools.md` (the leading variable is this plugin's root directory) — `claude-tools.md` on Claude Code, `codex-tools.md` on Codex.\n\n# test-pilot-init\n\nCreate or reconcile a project's **test-pilot profile** plus its starter\nseeding blocks. Two modes: **create** (nothing resolves) and **reconcile**\n(profile exists → re-detect, diff, migrate; NEVER silently overwrite).\n\n## Step 1 — Resolve\n\n```bash\nROOT_DIR=\"${CLAUDE_PLUGIN_ROOT}\"\nRES=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fstore.py\" resolve) || RC=$?\nRC=${RC:-0}\nif printf '%s' \"$RES\" | jq -e '.refusal != null' >\u002Fdev\u002Fnull 2>&1; then\n  printf '%s' \"$RES\" | jq -r '\"\\(.refusal.reason): \\(.refusal.detail)\"' >&2\n  exit 1\nfi\nif [ \"$RC\" -ne 0 ]; then\n  echo \"store.py resolve exited non-zero (exit $RC)\" >&2\n  exit \"$RC\"\nfi\nLOCATION=$(printf '%s' \"$RES\" | jq -r .location)\n# FR-7\u002F8: surface the single coalesced storage-mode reconcile nudge (non-blocking, ack-gated).\nNUDGE_MSG=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fmode_reconcile.py\" signals 2>\u002Fdev\u002Fnull | jq -r 'if . == null then empty else .message end' 2>\u002Fdev\u002Fnull)\n[ -n \"$NUDGE_MSG\" ] && echo \"⚠ storage-mode: $NUDGE_MSG\"\n```\n\n`location: none` → create mode (Steps 2–6). Otherwise → reconcile (Step 7).\n\n## Step 2 — Detect (no questions the repo can answer)\n\nRead `CLAUDE.md` first — the profile is an ADDER over it. Then detect:\nstack\u002Fscripts (`package.json` scripts, `pyproject.toml`), dev command and\nport, DB env vars (`.env*` files — names only, never read values into the\nprofile), docker-compose services, existing seed scripts, `git remote\nget-url origin`.\n\n\u003C!-- decision-point: id=tp-init-uv mode=proceed kind=interview-step default=\"record uv absent; blocks limited to stdlib + run-command\" carrier=test-pilot-layer -->\nCheck `uv` availability (`command -v uv`). When absent, record `uv` absent in\n`## Setup disclosures` and state that blocks are limited to stdlib + run-command\ndesigns — do not offer to install. When present, record `uv` available. Continue\ndetection. Follow-up: `\u002Fsuperheroes:configure`.\n\u003C!-- \u002Fdecision-point: id=tp-init-uv -->\n\n## Step 3 — Browser tooling gate\n\nUse ToolSearch to check which browser MCPs are connected (search \"chrome-devtools\", \"Claude_in_Chrome\", \"playwright\").\nFor a Google sign-in or a pilot launched from a worktree, read `${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Fpilot-contract.md` § Browser launch recipes.\n\n\u003C!-- decision-point: id=tp-init-browser-tools mode=proceed kind=interview-step default=\"chrome-devtools, playwright, Claude_in_Chrome — detected subset in that order\" carrier=test-pilot-layer -->\n**`browserTools` provisional default.** When one or more tools are detected,\nwrite `browserTools` as the detected subset in fixed preference order:\n`chrome-devtools`, then `playwright`, then `Claude_in_Chrome` (omit undetected\nnames; never write an empty array). Record the chosen order in\n`## Setup disclosures`. Continue. Follow-up: `\u002Fsuperheroes:configure`.\n\u003C!-- \u002Fdecision-point: id=tp-init-browser-tools -->\n\n\u003C!-- decision-point: id=tp-init-browser-gate mode=gate kind=owner-gate default=\"hand back; no browser tool connected\" carrier=run-output -->\nWhen **no** browser MCP is connected, GATE: write the remediation down in the\nrun output (install chrome-devtools MCP, Playwright plugin, or Claude in Chrome\nextension), record that no browser tool is connected, leave `browserTools`\n**absent** (not an empty array), and **hand back** — do not continue init or\ndrive browser tooling. **No layer is written on this path** — init stops here\nbefore Step 6's writer runs. Follow-up: `\u002Fsuperheroes:configure`.\n\u003C!-- \u002Fdecision-point: id=tp-init-browser-gate -->\n\n## Step 4 — Decide location\n\n\u003C!-- decision-point: id=tp-init-storage mode=notify kind=storage-location default=\"returned .mode from store CLI\" carrier=test-pilot-layer -->\n```bash\nROOT_DIR=\"${CLAUDE_PLUGIN_ROOT}\"\nDEC=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fstore.py\" decide-location) || { echo \"decide-location exited non-zero (exit $?); halting rather than taking an undisclosed storage default\" >&2; exit 1; }\nLOC=$(printf '%s' \"$DEC\" | jq -r '.mode')            # \"in-repo\" | \"global\" — never \"ask\"\nSOURCE=$(printf '%s' \"$DEC\" | jq -r '.source')\nPROVISIONAL=$(printf '%s' \"$DEC\" | jq -r '.provisional')   # \"true\" | \"false\"\n[ -n \"$LOC\" ] && [ -n \"$PROVISIONAL\" ] && [ -n \"$SOURCE\" ] || { echo \"decide-location returned no usable decision; halting rather than taking an undisclosed storage default\" >&2; exit 1; }\nPATHS=$(python3 -B \"$ROOT_DIR\u002Flib\u002Fstore.py\" create --location \"$LOC\") || RC=$?\nRC=${RC:-0}\nif [ \"$RC\" -ne 0 ]; then\n  printf '%s' \"$PATHS\" | jq -r 'if .reason then \"\\(.reason): \\(.detail)\" else \"store.py create exited non-zero (exit '\"$RC\"')\" end' >&2\n  exit \"$RC\"\nfi\n```\n\n**Storage location (`decide-location`).** `decide-location` returns JSON: `.mode` is `in-repo` or\n`global` (`ask` no longer exists); `.source` is where the decision came from: `env` (environment\noverride `TEST_PILOT_STORAGE` for this run only; never recorded), `registry` (a mode the owner\nrecorded; authoritative), `backfilled` (a mode inferred from consistent existing evidence and then\nrecorded), `provisional` (nothing recorded and no consistent evidence; the lib's default, re-taken\nnext run); `.provisional` is `true` when the mode was not owner-recorded. **Default:**\nthe returned `.mode` (recorded when configured, else the lib's provisional default). Bootstrap\nblocks never record — an unrecorded mode is re-taken next run. **Disclosure.** Write into the\n**test-pilot layer body** (the markdown piped to `core_md.py write-layer --hero test-pilot` in\nStep 6 — a `## Setup disclosures` section, not the generated provenance block): the storage mode\ntaken, its source, whether it is provisional, and that `\u002Fsuperheroes:configure` changes it. When\n`.provisional` is `true`, also state that it is a provisional default rather than an owner choice\nand will be re-taken on the next run when not recorded. **Follow-up:** `\u002Fsuperheroes:configure`.\nNOTIFY: the run continues after the disclosure lands in `## Setup disclosures`.\n\u003C!-- \u002Fdecision-point: id=tp-init-storage -->\n\n## Step 5 — Provisional defaults (no interview)\n\n\u003C!-- decision-point: id=tp-init-provisional-defaults mode=proceed kind=interview-step default=\"named provisional defaults per field list below\" carrier=test-pilot-layer -->\nDo not interview. Take named provisional defaults for every field detection + `CLAUDE.md` left\nopen. Write which fields were defaulted into `## Setup disclosures` of `$TEST_PILOT_LAYER_BODY`\n(the markdown piped to `core_md.py write-layer --hero test-pilot` in Step 6). Never guess a\nprotected target — when detection cannot name a production-shaped DB\u002Fsurface to refuse, state\nthat in `## Setup disclosures` and leave the gate **refusing** rather than inventing a target.\nContinue to Step 6. Follow-up: `\u002Fsuperheroes:configure`.\n\n**Provisional defaults** (when detection + `CLAUDE.md` did not answer):\n\n1. **Auth strategy** — `review-only` (provisional default): unattended execute cannot assume\n   credentials; the owner confirms via `\u002Fsuperheroes:configure`.\n2. **Protected targets** — only names detection actually found; if none, record `none detected —\n   gate refuses` and do not scaffold a target list.\n3. **Base URL \u002F readiness probe** — detected dev URL\u002Fport when present, else\n   `http:\u002F\u002Flocalhost:\u003Cdetected-port>` when a port was detected, else refuse to guess.\n4. **`dbEnvVar`** — first database-related env var **name** detected from `.env*` files (names\n   only, never values); if none, omit the field and record `none detected` in\n   `## Setup disclosures`.\n5. **`apiBase`** — `{baseUrl}\u002Fapi` when `baseUrl` is known; if `baseUrl` is unknown, omit the\n   field and record `none detected` in `## Setup disclosures`.\n6. **`allowedOrigins`** — `[]` (provisional default).\n7. **`devCommand`** — detected from `package.json` scripts (`dev`, then `start`) or\n   `pyproject.toml` `[project.scripts]`; if none detected, omit the field and record\n   `none detected` in `## Setup disclosures`.\n8. **`mayManageServer`** — `false` (provisional default): execute will not start the server\n   without owner confirmation via `\u002Fsuperheroes:configure`.\n9. **`browserTools`** — per Step 3 (`tp-init-browser-tools` \u002F `tp-init-browser-gate`); when none\n   detected, the field stays absent.\n\u003C!-- \u002Fdecision-point: id=tp-init-provisional-defaults -->\n\n## Step 6 — Scaffold\n\n1. Fill `${CLAUDE_PLUGIN_ROOT}\u002Ftemplates\u002Fprofile.md` (prose AND the\n   `json test-pilot-config` block — keep them consistent) and write it to\n   the resolved profile path. Set provenance `status=provisional` always on this create path —\n   only `\u002Fsuperheroes:configure` confirms with real answers.\n2. Write 1–2 starter blocks bespoke to this app into the resolved\n   `blocks_dir`, from `templates\u002Fstarter-block.py` — e.g. an HTTP seeder\n   against the detected API, or a `run-command` design wrapping an existing\n   seed script. Every block declares non-empty `targets` and pins PEP 723\n   dependency versions.\n3. Generate the catalog:\n   `python3 -B \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fcatalog.py\" --blocks-dir \u003Cblocks_dir>`\n4. CREATE path (fresh setup, FR-5): Fail-closed guard before the pipes below — not the\n   mechanical-carrier redesign: refuse when either the shared facts JSON (stack, verify command,\n   threat model) or `$TEST_PILOT_LAYER_BODY` (test-pilot's `json test-pilot-config` block + prose,\n   including the `## Setup disclosures` section assembled from Steps 4–5) is empty, because\n   `write-layer` replaces the entire layer file and an empty piped payload would silently blank it.\n   When either payload is empty, surface `assembly produced empty payloads; halting rather than\n   writing an empty layer` and **stop** — do not pipe into `write` or `write-layer`. When both\n   payloads are present, pipe the shared facts JSON into\n   `python3 -B \"${CLAUDE_PLUGIN_ROOT}\u002Flib\u002Fcore_md.py\" write\n   --status provisional` to write the band-wide `core.md`, and pipe `$TEST_PILOT_LAYER_BODY` into\n   `core_md.py write-layer --hero test-pilot --status \u003Cs>` so they land in the `test-pilot.md`\n   layer (FR-3). On reconcile of a pre-existing profile, the legacy `profile.md` is not adopted —\n   `resolve_shared` returns the `legacy-profile-unsupported` refusal pointing at\n   `superheroes:configure` — no shared facts to read yet; re-calibrate through configure first\n   (`core_md resolve` only after `core.md` exists; CONVENTIONS §2.1 \u002F §2.2). Never hand-format core.md — the lib owns\n   the format and the config lock. `write --status confirmed` is the CREATE path only; confirming\n   a pre-existing **provisional** core\u002Flayer goes through `core_md.py confirm` (reached from\n   `superheroes:configure`), which `write` cannot do on an existing file (it returns `reused`).\n   After `write`, check the result's `action`: `refused` (`fable-on-external-engine`,\n   `core-md-unreadable`, or `dispatch-gate-evaluation-failed`) means the core was **not** written —\n   surface the `violations` to the user and **stop**; do not run `write-layer` (`write` exits 0 either\n   way, so check `action`, not exit status).\n\nReport what was written and where; remind the user that `test-pilot-plan`\npicks it up from here.\n\n**iPhone check.** When the project's lanes will run the iPhone check, its app needs a\ndevelopment-only reporting script. Read `${CLAUDE_PLUGIN_ROOT}\u002Fskills\u002Ftest-pilot-init\u002Freference\u002Freporting-script.md`\nand tell the user the project adds the script itself.\n\n### Conformance run (when `pilot` block is declared)\n\nAfter calibration is written, and **only when** the profile declares a `pilot`\nblock, run the headless conformance pass (normative CLI in\n`reference\u002Fpilot-contract.md` §The conformance run):\n\n```bash\nROOT_DIR=\"${CLAUDE_PLUGIN_ROOT}\"\nREPORT_JSON=\"$(mktemp)\"\ntrap 'rm -f \"$REPORT_JSON\"' EXIT\nCONFORMANCE_ARGS=(run --cwd .)\nif [ -n \"${PILOT_REGISTRY:-}\" ]; then\n  CONFORMANCE_ARGS+=(--registry-path \"$PILOT_REGISTRY\")\nfi\npython3 -B \"$ROOT_DIR\u002Flib\u002Fpilot_conformance.py\" \"${CONFORMANCE_ARGS[@]}\" > \"$REPORT_JSON\"\npython3 -B \"$ROOT_DIR\u002Flib\u002Fpilot_acceptance.py\" matrix \\\n  --report-path \"$REPORT_JSON\" \\\n  --project \"$(basename \"$(pwd)\")\" \\\n  --commit \"$(git rev-parse HEAD)\" \\\n  --format markdown\n```\n\nWhen the project maintains a declare-and-exercise registry (see\n`reference\u002Fpilot-contract.md` §Declare and exercise), set `PILOT_REGISTRY` to\nthat JSON path before running the conformance step so `--registry-path` is passed\nand the report carries a `declarations` envelope. **Without a registry path** the\nconformance report's `declarations` key is `null` — the matrix CLI still\nrenders, but declaration-backed rows read `unexercised` with a stated reason;\nthat is the ordinary adopter case, not a refusal.\n\nStdout is the report JSON from the conformance run; the matrix step prints\nmarkdown on stdout. Stderr carries diagnostics. **Exit 1 is a real outcome to\nreport, not an error to swallow** — show the operator which surfaces came back\n`unexercised` and why, from the report's `resolution` list. The matrix's `ok`\nis **false** when any row is `unexercised`, when the reference worktree is\ndirty, or when the run itself left surfaces `unexercised` — that is the honest\noutcome for a project that has not exercised everything, **not a failure to\nwork around**. `--commit` must be a **full object id** (run `git rev-parse\nHEAD` in the reference project — not a branch name). **Dirty** is derived from\n`git status --porcelain` in the **CLI process's current working directory** when\nneither `--dirty` nor `--clean` is passed; pass `--dirty` or `--clean` to\noverride. The run **never** writes into the repository when `--allow-live-effects` is not passed. The\n`cleanup-end-to-end`, `mint-gate-off`, and `ownership-probe` exercises are\nreported as **unexercised** unless the operator explicitly passes\n`--allow-live-effects`; opting in runs the project's own destructive cleanup,\ngate-off, and ownership-probe commands against live datastore and checkout\nresources. A `mint-gate-off` exercise that does not produce a usable receipt is\nreported as **unexercised**, never recorded as exercised — configure refuses to\nclaim it. The matrix is **generated, not stored** by the plugin — where a\nproject keeps it is the project's own decision.\n\n### Pilot block (optional)\n\nThe nested `pilot` key inside `test-pilot-config` is **omitted entirely** unless the owner\nhas answered every one of its no-default fields. Do not scaffold it during init.\n\n- `effectsEscape`, the mint envelope, and expected pilot identities are **never synthesized,\n  defaulted, or placeholder-filled** — an unanswered declaration is absent and absent refuses.\n- Expected identity and the mintable-account allowlist are **policy**; they do not belong in\n  the `pilot` block at all (resolved via `policyRef.declaration` against an external policy\n  document).\n- Normative field table, refusal tokens, and probe vocabulary:\n  `${CLAUDE_PLUGIN_ROOT}\u002Freference\u002Fpilot-contract.md`.\n\n## Step 7 — Reconcile mode\n\n\u003C!-- decision-point: id=tp-init-reconcile-drift mode=gate kind=owner-gate default=\"hand back; apply nothing\" carrier=run-output -->\nRe-run detection, then DIFF against the existing profile. GATE: write the drift diff down in the\nrun output (changed dev command, new env vars, vanished scripts, and any other detected deltas)\nand **hand back** — apply **no** profile changes and write **no** layer on this init path.\nHand-edits in the profile are preserved because nothing is written. Never regenerate from scratch\nover an existing profile. Follow-up: `\u002Fsuperheroes:configure` to apply, edit, or skip changes.\n\u003C!-- \u002Fdecision-point: id=tp-init-reconcile-drift -->\n",{"name":5,"description":7},"main","29c87a13937804687577d3b71e3005f63883f35c","plugins\u002Fsuperheroes\u002Fskills\u002Ftest-pilot-init",0,"https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes","https:\u002F\u002Fgithub.com\u002Fzwrose","Learning, tinkering, and other such stuff. ","2026-11-15 04:46:57",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add zwrose\u002Fsuperheroes --skill test-pilot-init",{"tool":38,"command":39},"bunx","bunx skills add zwrose\u002Fsuperheroes --skill test-pilot-init",{"tool":41,"command":42},"pnpm","pnpm dlx skills add zwrose\u002Fsuperheroes --skill test-pilot-init","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Ftest-pilot-init\u002FSKILL.md",true,[46],{"path":47,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":50,"sourceHtmlUrl":51},"reference\u002Freporting-script.md","REFERENCE","参考文档",5467,"https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Ftest-pilot-init\u002Freference\u002Freporting-script.md",[53,60,67,74,81,88],{"skillNo":54,"name":55,"nameZh":6,"description":56,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":57,"categories":58,"keywords":59,"publishedAt":19},"01M75C14YXJ1W26N03VHRDP38K","test-pilot-plan","Use when a PR\u002Fbranch needs a manual test plan with seeded data — \"write a test plan\", \"seed test data for this PR\", \"set up manual testing\". Seeds scenarios via the test-pilot engine and posts a checkbox plan to the PR. Does NOT execute the plan (that is test-pilot-execute).","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Ftest-pilot-plan\u002FSKILL.md",[],[],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":19},"01M75C0YKSEDN9TQCSA2MY01WQ","test-pilot-execute","Use when a test-pilot plan should be exercised before human spot-check — \"run the test plan\", \"pilot this PR\", \"verify the branch in the browser\". Drives the app via a browser MCP, or the lane's simulated iPhone, and posts a results comment. Observe-and-report only — a bug it finds is a finding, never an edit.","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Ftest-pilot-execute\u002FSKILL.md",[],[],{"skillNo":68,"name":69,"nameZh":6,"description":70,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":19},"01M75C0FC2AADQP6HR4XC94NV0","showrunner-handoff","Use in the showrunner advisor seat you are leaving while it is still alive — deliberate handover before the seat goes dark. Leaves durable state for the incoming seat. Emits no paste block. Not checkpoint (`\u002Fcompact`); not showrunner-resume (incoming seat).","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Fshowrunner-handoff\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":19},"01M75C0C5908SMD71067S8JJGR","review-init","Internal helper reached from `superheroes:configure` to refresh review-crew's calibration layer for a project. Not a front door; owners run `superheroes:configure` instead.","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Freview-init\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M75C08CZA02HRPRJ1TFJSS9H","review-code","Use when reviewing code changes on a local branch or an open pull request before merging — including when you want the review's findings auto-fixed locally. Gives a multi-specialist review with a fix-and-re-review loop. Not a whole-repo debt sweep (that is guardian).","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Freview-code\u002FSKILL.md",[],[],{"skillNo":89,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":19},"01M75C03Q2TVB7N66V95WXCHHR","guardian","Use to run the Guardian sweep — a periodic read-only sweep of repo health (duplication, complexity, coupling, dependency and doc freshness, dead code). Reports maintainability drift since the last sweep as plain-language consequences; it never edits code or files issues. Not code review of a change (that is review-code).","https:\u002F\u002Fgithub.com\u002Fzwrose\u002Fsuperheroes\u002Fblob\u002Fmain\u002Fplugins\u002Fsuperheroes\u002Fskills\u002Fguardian\u002FSKILL.md",[],[]]