Repository navigation
Closed
Labels
size:M30-99 effective changed lines (test files excluded in mixed PRs).
Milestone
Description
This is the headline for the milestone. It is done when someone sends this in any thread and gets a playbook-shaped Crew:
ok, lets create a crew to implement what we have discussed. Please use @Playbook:[playbook name] for this work.
My rule: the agent that receives that message becomes the Captain and does, in order:
- Reads the named playbook with
playbook_read: every step's prompt and persona, and any warning. - Calls
list_personasand matches each step'spersonato an available saved persona. - Staffs one seat per distinct persona the playbook names. A seat owns every step that names its persona. Steps without a persona go to the seat that fits them best, or stay with the Captain.
- When a named persona is missing or disabled, proposes a custom seat in its place, with instructions drawn from the steps it will own, and says so in the seat's reason. The roster card flags the swap. It does not stop and ask.
- Writes the brief from "what we have discussed": the conversation so far, plus the playbook's title and description.
- Calls
propose_crewwithplaybookand per-seatsteps. - After approval, starts the run with
playbook_start, passing the Crew'screw_instance_idfrom the launch notice, and drives it as the Captain (The Captain runs a Crew's playbook and each seat receives its steps #322).
Where it stands today:
- None of this is instructed. The crew instructions (
T3OrchestrationInstructions.ts,J5_PROPOSE_CREW_DESCRIPTIONinapps/server/src/j5/a2a/mcp/tools.ts) never mention playbooks, andPLAYBOOK_INSTRUCTIONSsays steps "do not … spawn agents". Whether a Captain reads a mentioned playbook, or matches personas, is up to the model.
What should change:
- Instructions: add the steps above to
PLAYBOOK_INSTRUCTIONS(apps/server/src/j5/playbooks/instructions.ts) andJ5_PROPOSE_CREW_DESCRIPTION(apps/server/src/j5/a2a/mcp/tools.ts). My call is that this text stays in J5 files: do not edit the Crew bullet inside the upstreamapps/server/src/provider/T3OrchestrationInstructions.ts, which already interpolatesPLAYBOOK_INSTRUCTIONS. Replace the line saying steps "do not … spawn agents" with the Crew-shaped exception. Keep it short enough that both Claude and Codex follow it. - Refusals the Captain can act on: if the playbook is missing or invalid, the Captain says so in its own reply, naming the playbook and the error, and stops instead of proposing a Crew without it. No Inbox ask: the Captain is the thread the person watches (Jackson's ruling on feat(crews): a crew request that mentions @playbook: builds the playbook's Crew #387, 2026-09-30).
- Product docs:
docs/j5/product/features/crews.mdandplaybooks.mdget a scenario for this flow, with the AC links, and a History entry for my 1A/2A/3A rulings (Captain owns the run, persona per step, the Crew records its playbook). - User docs:
docs/user/playbooks.md"With a Crew" shows the example prompt.
Acceptance criteria:
- The headline prompt, with a playbook whose steps name two available personas and one step with no persona, produces a roster card with two persona seats, each owning its steps, the unassigned step placed, and "Follows playbook" shown.
- The same prompt, where one named persona is disabled, produces a custom seat for its steps, flagged as a swap.
- After approval, the Captain starts the run and the first step reaches its owning seat.
- The prompt works from a Claude Captain and a Codex Captain.
- A crew request that doesn't ask to use a playbook behaves exactly as today. Asking for one by name in plain words counts the same as
@playbook:; a playbook merely named in passing, or seen in quoted text, code, files, or tool results, doesn't (my ruling (a) on feat(crews): a crew request that mentions @playbook: builds the playbook's Crew #387, 2026-09-30).
Tests to ship:
- server test: given the tool calls above, a Captain's proposal decodes and launches with the right ownership (the model's choices are not what's under test)
- an integrated pass of the headline prompt in a real client against seeded personas and a seeded playbook, run once after the other issues land, with screenshots on the PR
Metadata
Metadata
Assignees
Labels
size:M30-99 effective changed lines (test files excluded in mixed PRs).
Activity
feat(crews): a crew request that mentions @Playbook: builds the playb…