$npx -y skills add scdenney/open-science-skills --skill diverge-codexDelegate creative divergence to a fresh Codex subagent before implementation. Use when the user explicitly asks Codex to delegate brainstorming, obtain an independent Codex context, or keep implementation separate from approach generation. Generate 3–5 conceptually distinct appro
| 1 | # Diverge with a fresh Codex context |
| 2 | |
| 3 | Use a fresh subagent to reduce anchoring from the lead agent's conversation history. Preserve the brainstorm-then-select discipline from `$diverge`; do not claim cross-model diversity because both contexts run Codex. |
| 4 | |
| 5 | Read [`../diverge/reference/creative-preference-optimization.md`](../diverge/reference/creative-preference-optimization.md) only when the user asks for the rationale or when refining the creativity criteria. |
| 6 | |
| 7 | ## Gate delegation |
| 8 | |
| 9 | Delegate only when the user explicitly invokes `$diverge-codex` or asks for a subagent, independent context, or delegated brainstorm. If the skill was loaded implicitly without such a request, run the ordinary `$diverge` workflow locally. |
| 10 | |
| 11 | ## Phase 1: brief the brainstormer |
| 12 | |
| 13 | Extract the task, hard constraints, existing artifacts, and acceptance criteria. Do not add an implementation preference. |
| 14 | |
| 15 | Spawn one fresh Codex subagent with only the task-local context it needs. Give it this contract: |
| 16 | |
| 17 | ```text |
| 18 | Generate 3–5 conceptually distinct approaches to TASK. Do not implement. |
| 19 | |
| 20 | Label every approach [Novel], [Surprising], [Diverse], or [Conventional]. |
| 21 | Include at least one [Novel] and one [Surprising] approach. For each, provide: |
| 22 | 1. Core mechanism — one sentence. |
| 23 | 2. How it works and why it differs — two or three sentences. |
| 24 | 3. Main tradeoff — one sentence. |
| 25 | |
| 26 | Do not restate one idea with different vocabulary. Return only the approaches. |
| 27 | ``` |
| 28 | |
| 29 | Do not reveal the lead agent's preferred solution or likely implementation. Consume the subagent's final answer, not its internal trace. |
| 30 | |
| 31 | ## Phase 2: present and pause |
| 32 | |
| 33 | Check that the response contains 3–5 mechanically distinct approaches and satisfies the required labels. If it does not, send one focused correction to the same subagent. |
| 34 | |
| 35 | Present the approaches without silently ranking, filtering, or rewriting them. Ask the user to select one approach or request a compatible synthesis. Stop before implementation. |
| 36 | |
| 37 | ## Phase 3: implement after selection |
| 38 | |
| 39 | Send the selected approach, original task, constraints, and acceptance checks back to the same subagent when possible. Require it to: |
| 40 | |
| 41 | - inspect current workspace state before editing; |
| 42 | - preserve unrelated user changes; |
| 43 | - implement the selected mechanism rather than substituting another; |
| 44 | - run proportionate checks; and |
| 45 | - return changed files, verification evidence, and any residual risk. |
| 46 | |
| 47 | The lead agent owns integration. Inspect the resulting diff and verification output, fix integration defects, and report the final outcome. |
| 48 | |
| 49 | ## Fallbacks |
| 50 | |
| 51 | - If subagents are unavailable, state that the independent-context path is unavailable and run `$diverge` locally. |
| 52 | - If the brainstorm subagent fails or returns empty output, retry once with a shorter brief, then fall back locally. |
| 53 | - If the selected approaches cannot be combined without changing the requested behavior, explain the incompatibility before proposing a hybrid. |
| 54 | |
| 55 | ## Constraints |
| 56 | |
| 57 | - Never implement during the divergence phase. |
| 58 | - Never describe same-model subagents as independent model families. |
| 59 | - Never break a user selection by replacing it with the lead agent's preferred approach. |
| 60 | - Never delegate without the explicit delegation gate above. |