Skip to content

DO NOT MERGE feat(chat): bring back Crew Mode as one switch - #22876

Closed
bolichen97 wants to merge 2 commits into
mainfrom
feat/crew-mode
Closed

bolichen97 wants to merge 2 commits into
mainfrom
feat/crew-mode

Conversation

@bolichen97

@bolichen97 bolichen97 commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Supersedes #22842 (closed when its branch was renamed).

Problem / Motivation

Goal: A person finds and runs the conductor through one Crew Mode switch, and the sessions it dispatches stay out of their session lists and folders while they can still watch and steer each one.

The conductor is one entry in a long agent list, so most people never find it, and when they do its workers flood the session list and create folders the person did not ask for. There is no place that shows what each worker is doing, and no way to type into a worker without opening it as an unrelated chat.

Why it matters

Crew Mode is the way a person gets a goal split into parallel chats. Without a single, recognisable entry point it goes unused, and with workers mixed into the person's own list the list stops being theirs.

Not a goal

  • A Projects tab. The panel footer says it is coming; it needs its own design.
  • Narrowing the tools a worker runs with. Workers keep the default agent's tools.
  • Migrating folders or workers that older conductors already created.
  • Crew Mode for the pipeline, security and team-lead conductors. A normal chat's picker leaves them out like every conductor, but they are not Crew Mode: their sessions keep their folders and stay in the person's lists.
  • A timeline on phones. Phones show the worker list only.
  • A screen reader pass over the new surfaces (not done yet).

What changed (motivation → approach → change)

Goal: one switch, one conductor, a person's list that stays the person's, and the workers visible where the conductor is.

Approach: Crew Mode is an ordinary agent switch onto one configured conductor, so nothing new runs and memory and history stay. The rule for "which sessions are a Crew Mode root, and which are its workers" lives in one server module and is stamped on every slot row; every list, picker, folder tool and route reads that stamp instead of carrying its own copy. The board-in-chat rule follows the existing in-progress RFC docs/request-for-change/rfc-conductor-chat-board-on-tab.md (a conductor whose tab shows the board writes no board in the chat). Crew Mode itself, as a product shape, has no RFC on main yet; a maintainer decision is needed for the First Principles lane.

What was built:

  • One conductor. New config key agent.crew_mode_agent (default kirocrew-conductor). The Crew Mode chip on a new chat switches to it, and stamps that agent on the chat, so changing the key swaps the conductor for new chats while a chat already in Crew Mode keeps the one it started on. Only that agent (and its deprecated alias kirocrew-ledger-conductor) makes a chat a Crew Mode root. A normal chat's agent picker and the keyboard agent cycle list no conductor at all; a Crew Mode chat has no agent picker (another conductor's chat keeps its own). The name is read from the live config at the point of use, so a custom conductor applies from gateway start.
  • One way. Pressing the chip moves it into the composer's read-only Crew Mode mark, and nothing turns the mode off: the chat's workers and task board run through its conductor, so turning it off would leave them with nothing to report to.
  • Workers out of the person's lists. crew_mode.py stamps crew_mode_root / crew_root on slot rows. The sidebar, the Sessions page, command palette Recents and an artifact's Send to session all read one selector (selectPersonSlots). A Crew Mode root and its workers are never filed into the person's folders: session-control create drops folder_id and the MCP folder tools say why.
  • Workers panel. A Workers tab in the side panel, offered on every Crew Mode root and worker, and in the + menu. Cards are grouped Needs you / Working / Waiting / Done from real signals only (an open approval or question, a running turn, a closed tab or ledger item, a ledger report). A worker that has merely replied is not counted done. Each card has a one-line task. GET /api/chat/slots/{slot}/crew-workers, owner only.
  • Worker view. A card opens the worker in the main pane like any session, with a breadcrumb (root > worker), Back to conductor, and a steer box ringed in the crew purple that types into the worker as the person (POST .../crew-workers/{worker}/steer). It cuts into a running turn or queues for the next one, through the composer's own delivery helpers. The first delivered message reads "From conductor" instead of the raw envelope line. On desktop the panel stays beside the worker; on a phone the sheet closes so the chat shows.
  • Timeline. A List | Timeline switch in the Workers tab: one lane per session (conductor first), with turns, tool calls, waits on the person and hand-off arrows, all drawn from recorded transcript rows (GET .../crew-timeline). What is not recorded (for example a tool's end time, tokens) is listed behind an (i) and never drawn. Long stretches are drawn shorter so short bars stay readable; the header keeps the true elapsed time and credits. No playhead under reduced motion, and the view holds still while the person types.
  • Design B visuals. The root row is a gradient crew card with its workers' ghosts and "Needs you · N" / "Done x/y"; the sidebar filter has a Crew Mode chip. All colours come from theme tokens; status text reaches at least 4.5:1 in both themes on every row state.

Backwards compatibility

Compatible: the new config key defaults to the conductor the chip already used, the new routes are additive, and GET /api/chat/slots keeps every row for agents and for ?crew=all.

The diff takes rows away from some readers. Each one:

Reader: src/kiro_crew/dashboard/chat_api/slot_detail.py:api_chat_slots -- chat -- a person's read without ?crew=all leaves out Crew Mode workers; an agent's read (internal_auth) keeps every row, pinned by test_an_agents_read_keeps_the_workers_its_tools_resolve.
Reader: website/src/pages/ChatSidebar.tsx, pages/SessionsPage.tsx, components/commandPalette/providers/recentsProvider.ts, components/ArtifactSendToSession.tsx -- crew page -- workers are left out by selectPersonSlots; the Recents Older rows still dedupe against every live row, pinned by personSlots.crewWorkers.test.tsx.
Reader: the agent picker and the keyboard agent cycle -- chat -- conductors are left out of a normal chat's list (withoutConductors, agentCycleTarget); crewmates whatever their name stay, pinned by the crewMode tests.
Reader: src/kiro_crew/dashboard/session_control_parts/session_create.py:create_session -- subagent -- drops folder_id only for a Crew Mode root or its workers and answers folder_ignored: "crew_mode", pinned by test_session_control_create_filing.py.

Tests

  • test/test_crew_mode_workers.py: the stamp rule, list views, the worker list (groups from real signals, the one-line summary through the board's redactor, closed workers' saved titles), the steer route (owner-only, app tokens denied, scoped to the root's tree, steers or queues as the person, a held steer is persisted and shown), the live-config conductor name, and route registration.
  • test/test_crew_timeline.py: bars from recorded rows only, approval waits, hand-offs paired by target, only the genuine envelope on a row no person typed counts as a hand-off, labels redacted, and a 10,000-row window that is one pass (row reads counted).
  • test/test_session_control_create_filing.py, test/test_crew_mode_board.py, test/test_agent_execution_catalog.py: folder drop, the board line in the dashboard block, the catalog fields.
  • Frontend: CrewWorkerList, CrewTimeline (including the ticking and reduced-motion cases), crewTimeline scale, crewWorkers, crewSeed/UserMessage, CrewWorkerBreadcrumb (phone), the sidebar crew card, the Sessions page and Recents rule, the panel's Workers offer and + menu, and the phone sheet closing on a worker open.

Local gate: check_black_formatting.py, check_subprocess_encoding.py, isort, flake8, mypy src/kiro_crew, comment-history, brand, line cap, harness parity, i18n check, docs-lint, npm run build, and scripts/local-gate.py related tests on both surfaces.

Manual verification

On a local preview gateway with real data: a real conductor split a real goal into three workers. Checked the crew card and filter, no agent picker in the conductor chat, the Workers list and timeline, a worker in the main pane, a real steer landing, the breadcrumb back, the phone layout at 390 px (breadcrumb, 44 px Back target, 16 px steer input, sheet closes on open), light and dark themes, and status-text contrast measured on the rendered pixels (every label at or above 5.9:1). Two independent code-review rounds and two UI-review rounds were run before opening; every finding is fixed except the phone timeline, which is out of scope above.

Screenshots / video

Session list with the Crew Mode card

A running worker: its steer hint reads "Cuts into its current reply." Dark and light, from this head on a preview gateway:

Running worker with the steer composer, dark
Running worker with the steer composer, light

A done worker: its steer hint reads "Starts a new turn in ." Dark and light:

Done worker with the new-turn steer hint, dark
Done worker with the new-turn steer hint, light

Timeline header while a worker is still open ("Live"), dark and light:

Timeline while a worker runs, dark
Timeline while a worker runs, light

Timeline header once every worker is done ("Finished"), dark and light:

Timeline with every worker done, dark
Timeline with every worker done, light

crew-mode-v2-demo.webm
More screens

Light theme list

Crew Mode filter

Conductor composer without an agent picker

Workers panel

Worker before the steer

Related Issues

Restarts the closed #21889.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

Contribution License Agreement

Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.

Crew Mode chip and welcome page

Real UI on a preview gateway, English, real chats. The chip sits right of Choose memory mode on a new chat's welcome state. It reads "Crew Mode: split into tasks" (a phone shows "Crew Mode"), and its tooltip is "Turn on Crew Mode: each task runs in its own chat and reports back here."

Chip on a new chat, dark and light:

Crew Mode chip on a new chat, dark
Crew Mode chip on a new chat, light

Welcome page on an empty chat right after the chip is pressed: hero, slogan, the five-step flow and the Task board button. Dark and light:

Crew Mode welcome page, dark
Crew Mode welcome page, light

Where room is tight (a 390 px tall landscape screen), the slogan hides and Task board is its icon alone, named by aria-label and tooltip. Dark and light:

Crew Mode welcome page on a short screen, dark
Crew Mode welcome page on a short screen, light

Busy state ("Available after the reply."): not shown in a screenshot. The chip row only shows on the welcome state, and the welcome state ends the moment this tab sends. So the busy chip only appears when the server reports a run for an empty chat before its first message lands. CrewModeChip tests pin it (aria-disabled, the hint, no switch on click).

@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: e62c32a
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest test/test_security_posture.py test/test_crew_mode_workers.py and every test file this branch touches: 251 passed on this head.
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): flake8, mypy (3480 files), isort, black gate, line cap, docs lint, feature-map gate, frontend build, 69 frontend test files (1298 tests), and the backend tests above.
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Oct 21, 2026
@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Sensitive Change Review

Sensitive files changed:

  • src/kiro_crew/security_posture.py

  • @bolichen97 posted a complete reasoning template for 8f76a04.

@bolichen97
bolichen97 enabled auto-merge (squash) October 21, 2026 19:35
@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ human override accepted

@bolichen97 overrode this lane for 8f76a043470e0fc93912a4de9b35e785948bdd54 via /ai-review override (this commit only).

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of 8f76a043470e0fc93912a4de9b35e785948bdd54 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

No design-level blocker: one module decides who is a Crew Mode root or worker and stamps every row, and the readers that lose rows (app-sdk and Mochi self-lookups, MCP tools reading as an agent) still find their own rows.

Notes

  • "nothing turns the mode off" is a product decision with no record in docs/decisions/. A Crew Mode chat has no agent picker, so a person who turns it on by mistake can only get out by starting a new chat. Get the maintainer decision recorded before merge so it isn't reversed later as a "finding".
  • The PR bundles the switch, list filtering, the Workers panel, steering and the Timeline. The Timeline (crew_timeline.py, CrewTimeline.tsx) depends on nothing else and could ship as a follow-up PR, which would make a revert of the core switch smaller.
  • crew_mode._configured is a global fallback that the last config load overwrites. It holds no per-caller data, but only the live snapshot keeps it correct. If the watcher is not armed, a stale name decides which chats count as roots until the next agent switch.

[DESIGN-REVIEWED] 8f76a04

Description read

[DESCRIPTION-READ] 2a39d7551ea75de82ff68f600c5c62eef28558a50b6d31606872a9a0488dd0c1

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ✅ human override accepted

@bolichen97 overrode this lane for 8f76a043470e0fc93912a4de9b35e785948bdd54 via /ai-review override (this commit only).

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed 8f76a043470e0fc93912a4de9b35e785948bdd54 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 8f76a04

Verdict parsed from the review's SHA-scoped output markers for commit 8f76a043470e0fc93912a4de9b35e785948bdd54.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 8f76a043470e0fc93912a4de9b35e785948bdd54: <one-sentence reason>

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — 🔴 changes requested (blocking)

GPT 6.1 found at least one blocking issue that must be resolved before merging 8f76a043470e0fc93912a4de9b35e785948bdd54. Adjudication upheld 1 of 2 blocking finding(s); those must be resolved before merging.

This comment is updated in place on each push.

BLOCKING -- src/kiro_crew/crew_timeline.py:242 -- Interrupted turns use the narration timestamp as their completion time

start = ts - timedelta(milliseconds=elapsed)
Trigger: Stop a Crew Mode turn at +60s while a tool runs after narration was flushed at +2s. tool_rows saves that assistant row; _persist_partial_reply attaches the full elapsed time without changing its timestamp; api_crew_timeline passes it to derive_lane.
Outcome: The API reports a “recorded” turn from −58s to +2s. The displayed turn ends before the long tool execution, rather than when the person stopped it.
Anchor: defect
Fix: Use a recorded turn-end timestamp for this calculation; when none exists, represent the endpoint as unknown rather than treating the assistant segment’s timestamp as completion.

BLOCKING -- website/src/components/commandPalette/providers/recentsProvider.ts:265 -- Closed Crew Mode workers reappear in Older Sessions

const currentKeys = new Set(liveSlots.map((s) => normalizeKey(s.key)))
Trigger: Close a titled Crew Mode worker through session_close while its conductor remains open, then refresh Recents. close_target archives its transcript and removes its live slot; /api/sessions returns the archive, which passes shouldShowHistorySession and is absent from currentKeys.
Outcome: The worker hidden from Current reappears in the person’s Older Sessions, while the conductor’s Workers panel still lists it as a closed worker.
Anchor: defect
Fix: Exclude archived descendants of live Crew Mode roots using persisted lineage, rather than deduplicating Older only against live slots.

[BLOCK-MERGE] 8f76a04
[GPT-REVIEWED] 8f76a04

Adjudication (Opus 5.5) — is blocking on each finding proportionate?

F1 — UPHOLD. Harm is MEDIUM. The Crew timeline draws a wrong "recorded" turn bar on a common path: Stopping a turn while a tool runs after narration was flushed. Confirmed in the code:

  • turn_reply_seams.py:84 skips appending a new assistant row once _reply_flushed is set.
  • turn_stats.py:143-148 writes turn_stats onto the last assistant row and leaves that row's ts unchanged.
  • crew_timeline.py:242-243 then treats that ts as the turn's end and labels it END_RECORDED.

The bar is labelled authoritative, so the wrong timing doesn't show itself. The real fix is cheap: stamp an end time into turn_stats and read it at crew_timeline.py:242, or mark the end as unbounded when it is missing. No new mechanism is needed, so the harm justifies blocking.

F2 — DOWNGRADE. Harm is LOW. A closed worker's archived transcript shows up as an Older row in the command palette's Recents. Confirmed in the code:

  • recentsProvider.ts:265 builds the dedupe set from live slots only.
  • recentsProvider.ts:394 filters Older against that set.
  • recentsProvider.ts:108 admits any titled session.

Nothing is lost and the row opens a real archived conversation; a closed session showing under Older is the normal treatment for any closed session. The real fix costs more than that. History rows carry no lineage today: crew_root and parent exist only on live-slot types (types/index.chat.ts:251,291). So the fix needs persisted lineage in the backend's /api/sessions index, plus frontend filtering of archived descendants of live Crew Mode roots. That is cross-module work for a cosmetic list entry.

[ADJUDICATION] 8f76a043470e0fc93912a4de9b35e785948bdd54 total=2 uphold=1 downgrade=1
UPHOLD F1 src/kiro_crew/crew_timeline.py:242 reason=harm-warrants-remedy
DOWNGRADE F2 website/src/components/commandPalette/providers/recentsProvider.ts:265 reason=disproportionate-remedy
[GPT-ADJUDICATED] 8f76a043470e0fc93912a4de9b35e785948bdd54

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 8f76a043470e0fc93912a4de9b35e785948bdd54: <one-sentence reason>

@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: 95fc4c8
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest test/test_security_posture.py test/test_crew_mode_workers.py and every test file this branch touches: 251 passed on this head.
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): flake8, mypy (3480 files), isort, black gate, line cap, docs lint, feature-map gate, frontend build, 69 frontend test files (1298 tests), and the backend tests above.
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: f4c647d
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest test/test_security_posture.py test/test_crew_mode_workers.py and every test file this branch touches: 251 passed on this head.
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): flake8, mypy (3480 files), isort, black gate, line cap, docs lint, feature-map gate, frontend build, 69 frontend test files (1298 tests), and the backend tests above.
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Oct 21, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: 4b2cff9
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest test/test_security_posture.py test/test_crew_mode_workers.py and every test file this branch touches: 251 passed on this head.
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): flake8, mypy (3480 files), isort, black gate, line cap, docs lint, feature-map gate, frontend build, 69 frontend test files (1298 tests), and the backend tests above.
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Oct 21, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: 6d9ec48
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest on every test file this branch touches plus test_security_posture.py and the facade and config-baseline guards: 369 passed on this head (the one other failure is the boot-order pin, which reads a local frontend build; with that build moved aside its file passes 17/17).
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): isort, black gate, flake8, mypy (3484 files), line cap, eslint (73 changed files), tsc, and the branch's 23 frontend test files (564 tests).
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Oct 21, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: 2034a6c
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest on every test file this branch touches plus test_security_posture.py, the facade, config-baseline and boot-order guards: 440 passed on this head.
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): isort, black gate, flake8, mypy (3507 files), line cap, docs lint, feature-map gate, eslint and tsc on the changed frontend files, i18n checks, the frontend build, and 63 frontend test files (1385 tests).
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Oct 21, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: b5f731b
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest on every test file this branch touches plus test_security_posture.py, the facade, config-baseline and boot-order guards: 440 passed on this head.
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): isort, black gate, flake8, mypy (3507 files), line cap, docs lint, feature-map gate, eslint and tsc on the changed frontend files, i18n checks, the frontend build, and 63 frontend test files (1385 tests).
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@github-actions github-actions Bot removed the readiness: checking Automated validation is still running label Oct 22, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: e83dd12
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest on every test file this branch touches plus the security posture, facade, config-baseline, slot codec, persistence, agent switch and session-control suites: 632 passed on this head (Crew Mode, slot, codec, facade, persistence and create suites).
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): isort, black gate, flake8, mypy (3507 files), line cap, comment-history gate, brand gate, docs lint, feature-map gate, tsc, eslint, i18n checks, and 431 frontend test files (5790 tests) across components, chat pages and ChatPage.
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@bolichen97

Copy link
Copy Markdown
Contributor Author

/ai-review override first-principles e83dd12: Owner decision: Crew Mode returns as one opt-in switch. Conductors leave the normal agent picker and Crew Mode workers leave the person's lists, so the conductor can be swapped later without users noticing. The timeline view is in scope by owner request. Reviewed in two code and two UI rounds; a design doc and RFC follow.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Oct 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Human judgment recorded

@bolichen97 marked the first-principles AI finding as false positive, not applicable, or explicitly accepted for e83dd120042f81240e01b18bc53677df3e73a556.

Owner decision: Crew Mode returns as one opt-in switch. Conductors leave the normal agent picker and Crew Mode workers leave the person's lists, so the conductor can be swapped later without users noticing. The timeline view is in scope by owner request. Reviewed in two code and two UI rounds; a design doc and RFC follow.

This decision applies only to this commit. A new push requires a new judgment.

@bolichen97

Copy link
Copy Markdown
Contributor Author

/ai-review override ux e83dd12: Owner decision: keep the gradient on the Crew Mode card, chip and composer mark so a conductor chat stands out from normal chats. It is scoped to crew-mode.css, every status label passes 4.5:1 contrast in both themes, and the other UX findings are fixed in this head.

@github-actions

Copy link
Copy Markdown
Contributor

Human judgment recorded

@bolichen97 marked the ux AI finding as false positive, not applicable, or explicitly accepted for e83dd120042f81240e01b18bc53677df3e73a556.

Owner decision: keep the gradient on the Crew Mode card, chip and composer mark so a conductor chat stands out from normal chats. It is scoped to crew-mode.css, every status label passes 4.5:1 contrast in both themes, and the other UX findings are fixed in this head.

This decision applies only to this commit. A new push requires a new judgment.

@github-actions github-actions Bot added merge conflict Branch has merge conflicts with its base — author must resolve before merge readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Oct 22, 2026
…de panel

Crew Mode hands a chat to one conductor agent, set by the new config key
agent.crew_mode_agent (default kirocrew-conductor). The Crew Mode chip on a
new chat is the only way in: a normal chat's agent picker and the keyboard
cycle list no conductor, and a conductor chat has no agent picker.

Turning Crew Mode on stamps the conductor on the chat (crew_mode_agent,
persisted), so changing agent.crew_mode_agent swaps it for new chats while a
chat already in Crew Mode keeps its own. Only that agent and its deprecated
alias make a Crew Mode root: the pipeline, security and team-lead conductors
keep their folders and visible workers.

The sessions a Crew Mode chat dispatches stay out of the person's session
lists (sidebar, Sessions page, command palette Recents, Send to session) and
out of their folders, on the server and in the MCP folder tools. They are
listed in the side panel's Workers tab, grouped Needs you / Working /
Waiting / Done from real signals only, and open in the main pane like any
session, with a breadcrumb, Back to conductor and a steer box that types into
the worker as the person.

The root row is a gradient crew card with its workers' ghosts and a summary;
the sidebar filter has a Crew Mode chip. The Workers tab has a List |
Timeline switch: one lane per session drawn from recorded transcript rows
only, with turns, tool calls, waits and hand-off arrows, and what is not
recorded listed instead of drawn. Phones show the list.

New routes: GET /api/chat/slots?crew=roots|all,
GET /api/chat/slots/{slot}/crew-workers,
GET /api/chat/slots/{slot}/crew-timeline and
POST /api/chat/slots/{slot}/crew-workers/{worker}/steer, owner only.
… findings

- Only a Crew Mode chat (its family or its stamp) hides the agent picker,
  shows the Crew Mode label and skips the keyboard agent cycle; another
  conductor's chat keeps its picker. The stamp is honored in the split pane too.
- Crew Mode membership follows the current lineage: an adopted worker belongs
  to the root that adopted it, and with the lineage settled a released worker
  stands on its own; the birth stamp fills in only while lineage is unknown.
- A timeline hand-off pairs a send named by slot key, transcript stem or a
  unique title.
- A closed root's workers are restated on the removal patch even when a legacy
  client's push rebuilt the root cache first.
- A Crew Mode caller's session_create reply names the Workers panel, never a
  folder it was not filed in or the sidebar; the server reports crew_mode.
- The worker breadcrumb says a failed worker-list read with an error notice.
- The Crew Mode welcome tests use their own chat keys, and the slot row key
  pin lists crew_mode_agent.
- Chats created on the Crew Mode conductor are stamped too.
- The breadcrumb's root title is text, so its row holds two controls.
- Pressed, the Crew Mode chip moves into the composer's Crew Mode mark (a
  fade under reduced motion). The mark is a read-only status: no pill, no
  hover or pressed state, not focusable, named "Crew Mode is on for this chat".
- Worker cards show no raw ledger id.
- A worker the list marks done gets the new-turn steer hint, even with a stale
  turn flag.

- The timeline pairs hand-offs off the event loop.
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: 8f76a04
  • What rule changed: security_posture.py registers one new redaction sink, dashboard/handlers/crew_workers.py (the Crew Mode worker list and timeline), and lists crew_timeline.py as a non-egress module. No rule is removed or loosened.
  • Before -> after (what was allowed/blocked, now): Before, the two modules did not exist. After, the posture inventory names the new egress (worker cards and timeline labels), and the call-site scan sees it. crew_timeline.py only derives labels and gets the redactor passed in, so it emits nothing.
  • Worst case if wrong (breaks commands / leaks secret / locks user out): a worker title or timeline label shows an unredacted URL or credential in the owner's own side panel.
  • Evidence checked (which sandbox result proves it): N/A for the sandbox: this changes no sandbox or approval rule. Proof is in tests: test/test_crew_mode_workers.py feeds a fake AWS key id through the ledger line and checks the board redactor strips it; the timeline tests check labels pass the display battery.
  • No regression:
    • Tools still work (which tools/commands were run, result): python -m pytest on every test file this branch touches plus the security posture, facade, config-baseline, slot codec, persistence, agent switch and session-control suites: 5079 passed on this head (Crew Mode, crew log, slot, codec, facade, persistence, agent switch, create, feature-map and session-control suites).
    • Backward compatible (old config / old data / old callers still work, how checked): additive only. Existing sinks and allowlist entries are unchanged; test_security_posture.py (the inventory and call-site scan) passes.
    • Existing tests (which suites passed on this head): isort, black gate, flake8, mypy (3507 files), line cap, comment-history gate, brand gate, docs lint, feature-map gate, tsc, eslint, i18n checks, and 232 frontend test files (3402 tests) across components, chat pages and ChatPage.
  • How to undo: revert the security_posture.py hunks together with crew_workers.py and crew_timeline.py; nothing else reads the new rows.

@bolichen97

Copy link
Copy Markdown
Contributor Author

/ai-review override first-principles 8f76a04: Owner decision: Crew Mode returns as one opt-in switch. Conductors leave the normal agent picker and Crew Mode workers leave the person's lists, so the conductor can be swapped later without users noticing. The timeline view is in scope by owner request. Reviewed in two code and two UI rounds; a design doc and RFC follow.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Oct 22, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

/ai-review override ux 8f76a04: Owner decision: keep the gradient on the Crew Mode card, chip and composer mark so a conductor chat stands out from normal chats. It is scoped to crew-mode.css, every status label passes 4.5:1 contrast in both themes, and the other UX findings are fixed in this head.

@github-actions

Copy link
Copy Markdown
Contributor

Human judgment recorded

@bolichen97 marked the first-principles AI finding as false positive, not applicable, or explicitly accepted for 8f76a043470e0fc93912a4de9b35e785948bdd54.

Owner decision: Crew Mode returns as one opt-in switch. Conductors leave the normal agent picker and Crew Mode workers leave the person's lists, so the conductor can be swapped later without users noticing. The timeline view is in scope by owner request. Reviewed in two code and two UI rounds; a design doc and RFC follow.

This decision applies only to this commit. A new push requires a new judgment.

@github-actions github-actions Bot removed the merge conflict Branch has merge conflicts with its base — author must resolve before merge label Oct 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Human judgment recorded

@bolichen97 marked the ux AI finding as false positive, not applicable, or explicitly accepted for 8f76a043470e0fc93912a4de9b35e785948bdd54.

Owner decision: keep the gradient on the Crew Mode card, chip and composer mark so a conductor chat stands out from normal chats. It is scoped to crew-mode.css, every status label passes 4.5:1 contrast in both themes, and the other UX findings are fixed in this head.

This decision applies only to this commit. A new push requires a new judgment.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Oct 22, 2026
@bolichen97
bolichen97 disabled auto-merge October 22, 2026 14:19
@bolichen97 bolichen97 changed the title feat(chat): bring back Crew Mode as one switch DO NOT MERGE feat(chat): bring back Crew Mode as one switch Oct 22, 2026
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: passed Eligible automated validation passed for the current revision labels Oct 22, 2026
@bolichen97

Copy link
Copy Markdown
Contributor Author

Closing without merge by owner decision. The work stays on branch feat/crew-mode, which is now pushed to directly.

@bolichen97 bolichen97 closed this Oct 22, 2026
@github-actions github-actions Bot removed the readiness: checking Automated validation is still running label Oct 22, 2026
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