Repository navigation
feat(chat): pin the agent's todo list to the bottom of the chat - #43
Merged
Merged
Conversation
A todo list only showed inside its tool row, and only as the list an
omp/omo `init` started with (every item unchecked): the done, start,
drop and append operations that follow read as raw JSON, and gjc's
`todo_write` (operations wrapped in `ops`) and Codex's `update_plan` did
not render at all. Nothing said where the plan stood.
src/lib/todos.ts works the list out from every todo call in the loaded
turns: Claude Code's TodoWrite and Codex's update_plan replace it whole;
omp/omo `todo`, gjc `todo_write` and omo's `mcp__…__todo` are replayed
operation by operation (init, append into its phase, start, done, drop,
block with its reason, note, clear), and the whole-list answer those
tools print after every call ([X]/[ ] boxes, or gjc's ✓ → ○) wins over
the replay whenever it is complete, so a list started before the loaded
pages is right too. Checked on the 50 newest omp/omo/gjc sessions here:
the answer parses in all 50, and the replay alone agrees in 42.
The chat pins a TodoPanel to its bottom: the done count and the item in
progress (or blocked) on one line, opening to the list by phase with an
icon per state; whether it is open is remembered. In the work block a
todo call reads as one line ("done · Build", "plan · 7 items") and opens
to the list as it stood after it, instead of its JSON and answer text.
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
devswha
force-pushed
the
feat/chat-todo-panel
branch
from
September 25, 2026 18:17
c0bc931 to
5d2c833
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Before this change, a todo list only showed inside its tool row in the work block, and only partly:
todoinitlist, with every item unchecked. Thedone,start,dropandappendcalls that follow showed as raw JSONtodo_writeopsupdate_planTodoWriteNothing said where the plan stood.
How the state is worked out (
src/lib/todos.ts)TodoWriteand Codex'supdate_plansend the whole list every time, so the newest call wins.todo, gjctodo_writeand omo'smcp__…__todoare replayed one operation at a time:init,append(into its phase),start,done,drop,block(with its reason),noteandclear.[X]/[ ] … (in progress|dropped|blocked: …)for omp and omo, and✓ → ○for gjc. When that answer is complete, it replaces the replay. So a list started before the loaded pages is still right.Overall: n/N, or has no list at all.Checked against the 50 newest omp/omo/gjc sessions on this machine: the answer parses in all 50, and the replay alone matches it in 42. The rest come from the tool auto-correcting the agent's input, which the answer already reflects.
UI
3/6 · Now: Wire the panel into ChatView, or "Blocked: …" or "All done".plan · 7 items,done · Research,start · Fix, add · 1 to B). Opened, a row shows the list as it stood after that call, instead of its JSON and the answer text.Testing
src/lib/todos.test.ts):TodoWriteandupdate_plan.ops, and an answer that overrides the replay when the list began earlier.3/6 · Now: …closed, and opened it groups items by phase with the right states. The work rows readplan · 7 items,done · Researchand so on. No page errors.bun run typecheckpasses,bun testpasses 337/337,bun run test:uipasses 8/8, andscripts/chat-browser-qa.tspasses 5/5.🤖 Generated with Claude Code