Add an Agent View for managing multiple Codex agents from the TUI
What variant of Codex are you using?
CLI
What feature would you like to see?
I would like Codex CLI/TUI to provide an Agent View for managing multiple active and historical agent sessions from one place.
When working with multiple agents in parallel, users currently need to keep track of several sessions manually. This becomes hard when agents are running in different worktrees, waiting for user input, or finishing at different times.
The proposed Agent View would let users:
- Open a unified agent/session list from the TUI, for example with
/agentsor an empty-prompt left-arrow shortcut. - See each agent's status, such as running, needs input, idle, done, or error.
- See the last response preview and recent activity time for each agent.
- Jump directly into an agent session from the list.
- Include agent sessions discovered from the current app-server and persisted subagent history, not only sessions spawned during the current TUI lifetime.
This would make parallel Codex workflows much easier to operate, especially when a user is delegating multiple independent implementation or investigation tasks.
Additional information
I have a local prototype branch implementing an initial version of this for the Rust TUI.
One limitation of the current prototype is that cross-process real-time status still depends on what the current app-server knows. A complete version may need a global session/agent registry so the Agent View can show all running Codex agents across projects and processes with live status.
14 Comments
I have a prototype branch here:
https://github.com/yuezhao238/codex/tree/feat/agent-view
It implements an initial TUI Agent View:
/agentopens anAgentsview./agentsis supported as an alias.thread/list.Local validation:
cargo test -p codex-tui agent_view -- --nocapturecargo test -p codex-tui agents_alias_opens_agent_command -- --nocapturecargo test -p codex-tui should_attach_live_thread_for_selection_includes_closed_metadata_only_threads -- --nocapture--nocapture`
just fix -p codex-tuigit diff --checkI have experienced the Agent View feature in Claude Code and found it to be truly excellent. I hope Codex might consider adding this functionality.
yes, this feature will be nice.
consider a different hotkey than just plain left, such as cmd+left
Love this idea
Yes, using Claude Agents feels extremely convenient.
I explored a narrower native implementation of this proposal that builds on the current app-server thread APIs and existing TUI thread-switch path:
https://github.com/pangpangDaddy/codex/tree/agent/native-agents-dashboard
Commit:
0ebff2a63bPreview
!Native Codex /agents dashboard snapshot
The prototype:
/agentsdashboard while leaving the existing/agentpicker unchanged;Needs input,Working,Completed, andFaileddirectly from app-serverThreadStatusand active flags;thread/listafter resume, with a loaded-thread fallback for older app servers;SelectAgentThreadflow, so it does not scan rollout files or depend on tmux;The current scope is intentionally the primary thread's known descendant tree, not a global cross-project/process registry. That keeps the first change within existing protocol and navigation boundaries while leaving room for the broader dashboard described here.
How to try it
In the TUI:
/agentsin the composer.Enterto open that agent's transcript; useEscto return. When the dashboard has more than eight agents, typing filters the list.Needs inputmeans the app-server reports an active thread waiting on approval or user input. Other active threads appear underWorking; idle or unloaded persisted threads appear underCompleted; app-server system errors appear underFailed.Local validation:
cargo check -p codex-tui --libRUST_MIN_STACK=16777216 cargo test -p codex-tui agents_dashboard --no-fail-fastRUST_MIN_STACK=16777216 cargo test -q -p codex-tui --no-fail-fast(3033 passed,0 failed,1 ignored)RUST_MIN_STACK=16777216 cargo clippy --fix --tests --allow-dirty -p codex-tuicargo fmt --allIf this narrower direction aligns with the maintainers' intended solution, would a maintainer be willing to invite a focused PR? I can submit the branch as a draft and adapt the UX or protocol approach before review.
👍 from my side aswell. Can't go back to regular interactive sessions. Claude Code's agent view and background agents is the superior user experience in the terminal.
+1 for this, I love GPT models but can't be as productive without the agents view
+1 for this.
The new agent should respect the existing concurrency limit, sandbox, permissions, and project instructions. This would make user-directed parallel workflows more deterministic and would complement the status and session-management capabilities proposed in this issue.
+1
One additional use case for a global Agent View is agent self-inspection before touching a shared working tree.
I run several independent Codex sessions in parallel on the same repo and branch. My global
AGENTS.mdtells each agent to:git statusfor dirty paths.This prevents conflicting edits, formatter/codegen races, index contention, and accidental commits or reverts of another agent's in-flight work.
For this workflow, a TUI view alone isn't enough. It needs a machine-readable, machine-wide interface—something like
codex agents --json—covering independent Codex processes, not only descendants known to the current app-server. A privacy-minimal result with session ID, cwd/worktree, and state such as working or waiting for input/approval would be sufficient. Idle persisted threads should be excluded; transcript recency isn't reliable evidence that a turn is still active.I currently maintain a small hook-backed registry solely to provide this liveness signal. An official interface would let agents perform this conflict check portably and remove that custom lifecycle tracking.
I tested a narrower implementation that extends the existing
/agentpicker rather than adding a second dashboard or command:The main evidence delta is hierarchical fidelity. The picker derives nesting from the authoritative
ThreadSpawn.parent_thread_idgraph, with the canonical V2agent_pathretained as a display/fallback signal. This lets the same UI distinguish siblings from nested subagents in V1 and V2 sessions. It also preserves the existingSelectAgentThreadflow and Alt-left/right switching, while addingworking/idle/closedstate, bounded recent activity, and the selected thread UUID.Human validation
Sibling agents created directly by Main render at the same depth:
!Main with sibling subagents Lagrange and Ampere
A subagent created by another subagent renders one level deeper:
!Main with nested subagents Mill and Nash
These screenshots are from real V1 thread-spawn sessions. The nested case used an isolated test configuration with
agents.max_depth = 2; the product default was not changed.Validation
codex-tuirun: 3333 passed; three pre-existing Windows permissions tests timed out with the same behavior as the baseline.just fix -p codex-tui,just fmt,cargo build --bin codex, andgit diff --checkpassed.Does extending the existing
/agentpicker in this direction align with the intended TUI UX, and if so, would a maintainer be willing to invite a focused PR?Hope we have this feature soon!
It looks like this dropped in today's release. This is a great leveler with Claude Code as
claude agentsis where I spend my entire day. And in fact, I can already see areas where it's better thanclaude agentswhich has lagged in improvements, such as a decent search or trying to give up on this foolish notion that people will just have five 'agents' named Alice, Bob, Charlie, Dave and Erica and are instead using it as a session manager - a way it's actually useful. Awesome stuff, temptation to switch to Codex has been increased!One thing's missing from my first inspection: The ability to run
codex agentsin one project directory. An agent view that lists all my projects and all my sessions from all my projects gets too crowded to be usable very quickly. With Claude Code I can pass in a--cwdand start one copy of agents per active project (i.e. per terminal tab)