feat: unify team engineering on the session forest - #24
Merged
Merged
Conversation
Hire, chat, Discuss, and the conversation map now treat mounted child sessions as the only durable members. Drop parent-session team-agent shadows after migration, address Team* tools by session id, and align Web/TUI surfaces on the same forest. Co-authored-by: Suddenness <wangyuahn@users.noreply.github.com>
TeamCreate now parents nested members under the hiring session itself instead of always the root, and first-time mount writes a display name from the session title. Tests follow the session-id TeamStatus and prompt wording.
Add SessionSearch/Mount/Unmount/Graph to bundled profiles and tests. Drop the unused pendingAgentOpen path so approval and map opens stay on the Session itself.
Map cards, inspector chat/meeting, listAgents, and TUI /team now read mounted child Sessions only. Leftover parent-session team shadows are migrated or ignored, and ghost members inherit cwd from the parent, host, or home directory.
Annotate department/topology runtimes, pin map lookups and force pins, and align mount tests with the Session forest instead of parent team shadows.
TeamChat now delivers @mentions by sibling display name on the mounted forest path, work-edge identity uses the same Prompt / parent-fill / save remount as create, and TeamAssign no longer copies the parent lead tool set onto a durable child Session.
Each Team* and Session* tool now has its own mocked schema, execute wiring, and SessionSubagentHost path so hire, chat, Discuss, and topology contracts cannot hide behind a lumped smoke test.
/team and /map now merge the live forest instead of replacing it, Chat loads on the lead session, and opening a member only resumes that Session.
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.
Related Issue
Unify durable Team Engineering collaborators onto Session. Durable members were dual-written as an empty child Session (map card) plus a parent-session
kind:'team'Agent (work, chat, Discuss). The map, sidebar, inspector, and TUI then disagreed about who existed.Problem
Hiring created two identities. The GUI only painted Sessions, while work, sibling chat, and meetings stayed on the parent-session Team Agent. The result: fewer map cards than meeting participants, empty child workspaces, missing department chat,
/maprequiring a shadow agent, and models forbidden from changing Session topology.After the forest landed, the TUI still assembled department state three ways:
syncRuntimeStatemerged graph + metadata, but/teamand/mapreplacedteamAgentswith graph-only rows (dropping live Discuss and reports). Chat was wired to a same-session agent view that no longer exists, so Ctrl-Y on the lead was empty and opening a member switched Sessions without the department pane.What changed
Durable collaborators are Sessions only. Team Engineering is a capability on that Session (
parent_session_id+ identity + cwd +main).TeamCreate/ map create-child only create and resume a mounted child Session. Work and tools run onchild.main. Nested hire parents under the hiring Session.attachMountedTeamMemberis leftover-shadow cleanup, not the hire path.mounted_session_idteam agents copy transcript/chat into the child, then the parent-session shadow is dropped. True ghosts materialize as child Sessions first, inheriting cwd from the parent, host, leftover homedir, or the user home directory. Discuss participant ids are rewritten to the child Session./map//teamall read the same Session forest. Opening a card or a/teamrow opens that Session.listAgentsno longer synthesizes children as parent-session team nodes. The map no longer overlaysCachedMapAgent/agent:extras.SessionSearch/SessionMount/SessionUnmount/SessionGraph.@namementions to sibling session ids on the mounted forest (and leftover shadow) path. TeamAssign no longer copies the parent lead’s tool set onto a durable child Session. TeamStatus is auto-approved. System prompts inventory Session* topology tools./team,/map, andsyncRuntimeStatesharebuildDepartmentSnapshot(forest members + metadata Discuss + live reports). Opening a/teamrow onlyresumeSessions that child; a discussion row opens the pane. Ctrl-Y Chat reads this session’s lead (main). A mounted child without its own department points Chat back to the parent. Footer shows the mounted session title instead of a leftover same-session agent badge. TeamCreate snapshot ids prefersession_id.session.meta.updatedframe.The
Agentclass remains a standalone LLM runner (root AGENTS.md). One-shot Task sub-agents are still not map nodes./mapand/teamstay separate commands (topology vs department roster). Changeset is minor; protocol fields such asmounted_session_idremain during migration and are not bumped major without confirmation.Checklist
gen-changesetsskill, or this PR needs no changeset.gen-docsskill, or this PR needs no doc update.