Repository navigation
feat(FIX-2154): coder and a project per worker in the Grok Bot-style lab, on fixtures - #3811
Conversation
…lab, on fixtures The front end for the spec's amendment (D3, D4, step 5). coder joins the roster as a worker that takes tasks only and runs Claude Code; its pane shows its runs read only, with no composer. Asking lead for a code change files a task: with no project picked, the run is refused before any file and the card asks for one; the pick sticks to lead, is said to lead as your line, and lead files the task again. The result lands as a line from coder. Talking to a worker never needs a project. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0147y64Do6d4RkSqzyXhUyKg
|
The latest updates on your projects. Learn more about Vercel for GitHub. 3 Skipped Deployments
|
|
@codex review Please look closely at three areas:
Generated by Claude Code |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Second look + architecture pass (read from the diff only; not run)The approach is right for a fixtures lab: the adapter stays the one seam, and each new call names the package call it stands for. Findings, most important first. Should fix in this PR
Simplification opportunities (this PR is the natural moment)
Architecture note for the wiring step (not this PR)
Minor / fixtures only
No blocker on the fixture design itself; items 1–3 are the ones I'd want changed before merge. Generated by Claude Code |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Simplify review (FIX-2154 · coder + project on fixtures)
Scope on current main: this PR is one commit (~13 files, all labs/teammates/). Earlier stack (full lab shell, durable-by-default, FIX-2158 spec) is already merged; that keeps this delta appropriately small.
Is this the right approach?
Yes. The spec’s fixture-first bar (D3/D4) maps cleanly to:
- Extend
LabAdapterwith project + task + run watches (same shape as existingwatchTalk/watchConversation), with the wiring table inadapter.tsas the single contract. - Keep task UI in React (
TaskCardshared by conversation +Runs) instead of growingConversationEntryrendering insideEntry. - Prove coder-as-task-only with a separate center pane (
Runs) rather than bolting harness UI onto talk workers.
A simpler alternative would have been to defer D3/D4 until workforce wiring (2161 / real listTasks). That would shrink this PR but would delay evidence for “talk-first + refused no-project + harness delegate” — the decisions you already locked in DECISIONS.md. For ER-1, the adapter boundary + delete-at-wiring fixtures is the established lab pattern; pulling in Shift Manager lib/* now would cross the “app adds only UI + config” line (and the spec explicitly copies patterns, not imports).
Not worth adding: a third-party pub/sub or state library for fixtures — global notify() is fine at lab scale; at wiring you’ll replace it with client subscriptions anyway.
What went farther than necessary (actionable, not blocking)
| Area | Note |
|---|---|
| Two project-pick paths | Header <select> only calls setWorkProject; card ProjectPrompt calls pick() (set + send to refile). README says header pick “works too,” but after header-only pick the card can show “refused · no project” until the next user line triggers fixture refile. Consider one applyProject(project, { refile }) used by both, or narrow README to “sets default before jobs.” |
Entry + task |
task entries render in Conversation while Entry’s task case is null — workable but confusing; either narrow before Entry or drop task from the union for conversation feed items. |
TaskCard type name |
Interface TaskCard vs component TaskCard — rename row type (BoardTask / TaskRow) before wiring. |
fixtures.ts script() |
Order-sensitive branches (/coder/, refiled, refused refile) are the real complexity hotspot; a small scenario table or leadScriptForUserText would help maintain step 5 without changing behavior. |
| Fixture perf | Global fan-out + Runs mounting watchTasks per filer is OK for the lab; when wiring, batch subscriptions (roster/session scope) to avoid N+1 streams. |
Skipped (larger than this PR)
- Shared
getAssetPathwith shift-manager (only two apps today). - Extracting Shift Manager conversation helpers into a package (intentionally deferred to wiring).
- Fixing
fsdev chat--store/dataLine(not in this diff; still a good follow-up when the lab goes durable).
Verdict
Approve. Direction and decomposition match the spec; complexity tracks real decisions (project gate, coder harness, dual center panes), not accidental abstraction. Inline nits below are polish before or during wiring — none change the architectural call.
Sent by Cursor Automation: Review For Best Approach
Picking lead's project from the header while a job waits on one now takes the card's path: store the project, then say it to lead, so lead files the task again. Codex review on #3811. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0147y64Do6d4RkSqzyXhUyKg
There was a problem hiding this comment.
Code Snob — already tight. No POC.
Read labs/teammates/src/adapter.ts, App.tsx, fixtures.ts, components/Conversation.tsx, Entry.tsx, Runs.tsx, TaskCard.tsx, WorkersList.tsx (the status line), lib/use-watch.ts, and test/screen.test.tsx.
A rewrite leaves this contract the same size.
FiledByis the subscription.watchTaskstakes a conversation id, and a hook cannot live inside the.map, so one child per filer is the loop. Keying that watch by the runner would be a different adapter than the one this PR names (the conversation board's rows).- The card prints
needs a projectorrefused · no projectfromneeds-projecttogether with whether the filer has a project now. The screen test reads both strings. Storing the phrase on the row moves the same branch.`${task.status} in ${task.project}`only folds the running/done half. Entry'staskarm returns null becauseConversationdraws the card from the board row. ExcludingtaskfromEntry's argument deletes that arm. The branch inConversationstays: the card needs the row, the project, andpick. Handing those toEntryadds them on every entry.taskTilehas one caller. The body is thefind.ConversationandRunsshare the main/header/scroll classes.Conversationstill carries the project select, the working chip, Talk, and the composer;Runscarries the harness chip. A pane with those slots is longer than the two headers.receivedandresultshare a frame. The accent classes and the note (reply,task done) are the whole difference, and the classes have to be written in full, so a shared card ties.- The run's steps use their own timers so the filing turn can end. The result then waits on lead the same way a received message does. One
play()over both loops is about a line. refiledis the set of refused tasks already filed again. A flag written back onto the row is a longer update.- The comments that restate the next line are the takes-tasks activity note and the step labels in the new screen test. The pick comment is why
sendfollowssetWorkProject. Removing the labels leaves the asserts.
Sent by Cursor Automation: Code Snob
…ne Runs Cursor review on #3811: the row type no longer shares the card component's name, the task-only pane has its own landmark label, and Entry's switch is formatted. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0147y64Do6d4RkSqzyXhUyKg


What this does
This adds the front end for the FIX-2154 spec amendment (#3804: D3, D4 and step 5) to
labs/teammates. Like #3798, it runs on fixtures, and wiring comes later.tasks · Claude Code. Its pane shows its runs read only, with no composer, because it takes no messages.coder/WORKER.mdwithharness: claude-code, anddelegates: [teammates.coder]on lead.New adapter functions, each naming the call it stands for:
listProjects,watchWorkProjectandsetWorkProject(FIX-2161),watchTasks(listTasks_tasks), andwatchRun(the row'srunlink, followed). The README's fixtures table lists each one.Evidence
pnpm --filter @flow-state-dev/teammates test: 12 pass. There are two new screen tests:relayand the result line.node scripts/inventory.mjs: PASS, 34 files, no other row.tscandeslinton the lab are clean, and fallow reports nothing for the lab.No changeset: the lab is private.
Generated by Claude Code