Skip to content

fix: make base roles opt-in via --roles flag#412

Merged
bradygaster merged 1 commit intodevfrom
squad/379-base-roles-opt-in
Mar 15, 2026
Merged

fix: make base roles opt-in via --roles flag#412
bradygaster merged 1 commit intodevfrom
squad/379-base-roles-opt-in

Conversation

@bradygaster
Copy link
Copy Markdown
Owner

Summary

Makes the built-in base roles catalog opt-in instead of always-on, restoring the beloved fictional universe casting as the default experience.

Changes

File Change
\cli-entry.ts\ Parse --roles\ flag, pass to \
unInit()\
\init.ts\ \RunInitOptions.roles\ + .init-roles\ marker file
\commands.ts\ /init --roles\ REPL command support + help text
\coordinator.ts\ Split \�uildInitModePrompt()\ into default (universe) vs opt-in (catalog) paths
\index.ts\ Read .init-roles\ marker in \handleInitCast(), cleanup after casting
\ est/init-base-roles.test.ts\ 5 tests covering prompt behavior + marker lifecycle

How it works

  1. Default (\squad init): Fictional universe casting — LLM picks character names freely
  2. Opt-in (\squad init --roles): Includes the base roles catalog so LLM maps agents to curated role IDs
  3. Marker file .squad/.init-roles\ bridges CLI → REPL → coordinator (same pattern as .init-prompt)

Review notes

  • EECOM implemented, Flight coordinated + cross-reviewed, fixed ESM
    equire()\ → \import\ bug in commands.ts
  • All 5 new tests pass + 100 existing init/casting/repl tests pass
  • Upgrade impact: None — new flag, no behavioral change to existing users

Closes #379

cc @spboyer — this implements the base roles opt-in for your contribution. The role catalog is now available via \squad init --roles\ instead of being the default.

@bradygaster
Copy link
Copy Markdown
Owner Author

Hey @spboyer 👋 — Brady asked me to loop you in! Your base roles contribution (PR #369) is now opt-in via \squad init --roles. Default init still uses the fictional universe casting experience, and when users pass --roles, your curated role catalog powers the team setup. Let us know if you have any feedback on the implementation!

@bradygaster bradygaster force-pushed the squad/379-base-roles-opt-in branch from 0e55721 to c395c15 Compare March 15, 2026 13:47
@bradygaster bradygaster force-pushed the squad/379-base-roles-opt-in branch 2 times, most recently from ee43f08 to dbe9644 Compare March 15, 2026 14:23
Base roles were always included in the coordinator init prompt, overriding
the beloved fictional universe casting. This makes base roles opt-in:

- Add --roles flag to 'squad init' and '/init' REPL command
- Default init uses fictional universe casting (no role catalog)
- --roles writes .init-roles marker consumed by handleInitCast()
- Marker consumed immediately on read (prevents leak on rejection/error/cancel)
- Fix: use ESM fs import instead of require() in commands.ts
- Fix: remove dead useBaseRoles field from triggerInitCast type
- Fix: base roles example uses lowercase role IDs matching catalog

Closes #379

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@bradygaster bradygaster force-pushed the squad/379-base-roles-opt-in branch from dbe9644 to e2fd7de Compare March 15, 2026 14:25
@bradygaster bradygaster merged commit 705bfb8 into dev Mar 15, 2026
1 check passed
@bradygaster bradygaster deleted the squad/379-base-roles-opt-in branch March 15, 2026 14:29
tamirdresher pushed a commit to tamirdresher/squad that referenced this pull request Mar 16, 2026
* chore(squad): quality review findings — 7 issues filed

Quality audit complete: 5 agents assessed CLI across testing, coverage, stability, accessibility, UX.
Results: 4 P0 blockers (bradygaster#365bradygaster#368), 3 P1 items (bradygaster#369bradygaster#371).
Blocking: Waingro dead sessions, ErrorBoundary, dropped input; Marquez help text consistency.

Changes:
- Logged session summary to .squad/log/2026-02-24T0205-quality-review-complete.md
- Updated .squad/identity/now.md with quality review findings and new issue numbers

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* chore(squad): merge decision — Marquez UX audit findings

Quality assessment merged from inbox (Grade B): 11 improvements (3 P0, 4 P1, 4 P2). help text, stub commands, vocabulary, separators, roster.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* test: add speed gate tests for impatient user journey

18 speed gate tests enforcing time budgets across the user journey:
- Help scanability, init ceremony speed, welcome data loading
- Input parsing latency, ghost retry bounds, error actionability
- Version output speed and format

Filed issues: bradygaster#387, bradygaster#395, bradygaster#397, bradygaster#399, bradygaster#401, bradygaster#403

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
diberry pushed a commit to diberry/squad that referenced this pull request Mar 19, 2026
…er#429, bradygaster#424, bradygaster#417, bradygaster#415, bradygaster#412, bradygaster#411)

Documents features and changes from recent PRs that shipped without
corresponding docs updates:

- bradygaster#429: Update model catalog with Sonnet 4.6, Opus 4.6, GPT-5.4 defaults
- bradygaster#424: Document --sdk switch for TypeScript config generation
- bradygaster#412: Document --roles flag for opt-in base roles
- bradygaster#411: Note Ralph in init + @copilot routing template removal
- bradygaster#442: Add Session Recovery skill documentation
- bradygaster#417: Document CastingEngine character casting
- bradygaster#415: Add rework rate OTEL metrics reference

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
diberry pushed a commit to diberry/squad that referenced this pull request Mar 19, 2026
…er#429, bradygaster#424, bradygaster#417, bradygaster#415, bradygaster#412, bradygaster#411)

Documents features and changes from recent PRs that shipped without
corresponding docs updates:

- bradygaster#429: Update model catalog with Sonnet 4.6, Opus 4.6, GPT-5.4 defaults
- bradygaster#424: Document --sdk switch for TypeScript config generation
- bradygaster#412: Document --roles flag for opt-in base roles
- bradygaster#411: Note Ralph in init + @copilot routing template removal
- bradygaster#442: Add Session Recovery skill documentation
- bradygaster#417: Document CastingEngine character casting
- bradygaster#415: Add rework rate OTEL metrics reference

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
bradygaster pushed a commit that referenced this pull request Mar 20, 2026
* docs: fill content gaps from 7 recent PRs (#442, #429, #424, #417, #415, #412, #411)

Documents features and changes from recent PRs that shipped without
corresponding docs updates:

- #429: Update model catalog with Sonnet 4.6, Opus 4.6, GPT-5.4 defaults
- #424: Document --sdk switch for TypeScript config generation
- #412: Document --roles flag for opt-in base roles
- #411: Note Ralph in init + @copilot routing template removal
- #442: Add Session Recovery skill documentation
- #417: Document CastingEngine character casting
- #415: Add rework rate OTEL metrics reference

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix: remove duplicate gpt-5.1-codex-mini from Fast/Cheap tier

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant