RFC-001: Multi-Agent Visual Indicator for Active Sessions - #818
vikramrajj wants to merge 1 commit into
Conversation
Draft RFC for showing active agents in session with visual indicators. Includes TypeScript interfaces, component designs, and integration approach. Co-authored-by: CommandCodeBot <noreply@commandcode.ai>
There was a problem hiding this comment.
Requesting changes. This RFC declares behaviour it does not implement, renders agent-produced text with no escape rules, diverges from the cited issue, and creates a new repository convention with no recorded decision.
Scope
Reviewed head 201b4a4 with one added file, rfcs/001-multi-agent-visual-indicator.md, checked against itself and the repository governance records.
Blocking findings
-
Unrecorded
rfcs/convention. The PR creates a new top level rfcs/ directory and numbers this document RFC-001.
Code search finds no other rfcs/ path, and there is no contributing guide or pull request template.
No precedent for a design document PR in recent history either way.
Do the maintainers want an rfcs/ convention at all? If so, record approval in this thread. -
Unread declared fields.
animateatrfcs/001-multi-agent-visual-indicator.md:94andshowUsageatrfcs/001-multi-agent-visual-indicator.md:92are declared and never read.
coloratrfcs/001-multi-agent-visual-indicator.md:58andprogressatrfcs/001-multi-agent-visual-indicator.md:67are declared and never read.
The minimal style atrfcs/001-multi-agent-visual-indicator.md:88has no branch. Onlyrfcs/001-multi-agent-visual-indicator.md:194branches, for detailed.
The compact prop atrfcs/001-multi-agent-visual-indicator.md:118is never passed atrfcs/001-multi-agent-visual-indicator.md:197.
The typescript fence atrfcs/001-multi-agent-visual-indicator.md:110holds JSX, failing a .ts parse and parsing only as tsx. -
Undefined symbols.
truncateatrfcs/001-multi-agent-visual-indicator.md:154andgenerateIdatrfcs/001-multi-agent-visual-indicator.md:220are called and never defined.
renderAgentStatusBaratrfcs/001-multi-agent-visual-indicator.md:229andrfcs/001-multi-agent-visual-indicator.md:240is called and never defined.
AgentStartParamsatrfcs/001-multi-agent-visual-indicator.md:219andAgentResultatrfcs/001-multi-agent-visual-indicator.md:234have no definitions.
The session store atrfcs/001-multi-agent-visual-indicator.md:213has no import or initialization. The render trigger implies a re-render mechanism the document never shows. -
Unreachable states.
rfcs/001-multi-agent-visual-indicator.md:225always sets running.rfcs/001-multi-agent-visual-indicator.md:237produces only completed or failed.
The queued and killed states have no production path. Session end cleanup atrfcs/001-multi-agent-visual-indicator.md:295is prose with no handler.
The click interaction atrfcs/001-multi-agent-visual-indicator.md:305assumes terminal capabilities the document never verifies. -
Missing sanitisation. Agent controlled name at
rfcs/001-multi-agent-visual-indicator.md:56, description atrfcs/001-multi-agent-visual-indicator.md:154and error text atrfcs/001-multi-agent-visual-indicator.md:238render into terminal output with no stated escape rules.
The color field atrfcs/001-multi-agent-visual-indicator.md:57accepts hex or ansi color with no stated validation.
A sanitisation subsection is needed before implementation. -
Divergence from issue 817. Issue 817 specifies
showAgentIndicatorandagentIndicatorStylewith compact, detailed or none.
The document usesagentIndicatoratrfcs/001-multi-agent-visual-indicator.md:249with a different field set and minimal in place of none.
The recorded maintainer position on issue 817 describes a narrower explorer on the roadmap, while the document proposes three broader phases with no recorded approval for the wider scope.
Requested changes
- Define or remove unused fields.
- Define undefined symbols or mark them out of scope.
- Give queued and killed production paths or remove them.
- Add sanitisation rules.
- Align settings keys with issue 817 or record divergence with maintainer approval.
- Record the rfcs/ convention decision.
Limits
The repository has no source for the product internals this document specifies, and with no test suite or CI those internals were not validated here.
Automated posting by agentic team with human oversight.
| @@ -0,0 +1,336 @@ | |||
| # RFC-001: Multi-Agent Visual Indicator for Active Sessions | |||
There was a problem hiding this comment.
Creating a new top level rfcs/ directory and numbering this document RFC-001 is a convention decision. The repository has no contributing guide, no pull request template and no other rfcs path, so the maintainers may want to weigh in before this becomes the pattern for later documents.
| /** Show token usage on completion */ | ||
| showUsage: boolean; | ||
| /** Animation enabled for running state */ | ||
| animate: boolean; |
There was a problem hiding this comment.
This option is declared here, defaulted at line 104, and listed in the settings block at line 254, but no component in the document reads it. The same holds for showUsage (line 92), color (line 58) and progress (line 67). Implementing or removing them would keep the specification honest.
|
|
||
| ### Status Badge Component | ||
|
|
||
| ```typescript |
There was a problem hiding this comment.
This fence is labelled typescript but contains JSX, which does not parse as .ts (TS1005 errors start at line 33 of the block). It parses as .tsx, leaving only the unresolved module and cross-block names. Labelling the fence tsx would save an implementer the detour.
| <Box borderStyle="round" borderColor={color} paddingX={1} marginRight={1}> | ||
| <Text color={color}>{icon} </Text> | ||
| <Text bold>{agent.name}</Text> | ||
| <Text dimColor> — {truncate(agent.description, 40)}</Text> |
There was a problem hiding this comment.
agent.description here and agent.error at line 238 are agent-produced text rendered into the terminal. Truncating to 40 characters does not strip ANSI escape sequences or newlines, and the document states no sanitisation rule anywhere. Worth specifying before implementation.
| </Box> | ||
|
|
||
| {/* Detailed badges (if style is 'detailed') */} | ||
| {config.style === 'detailed' && ( |
There was a problem hiding this comment.
This is the only style branch in the component. The minimal style declared at line 88 therefore renders identically to compact, and the dots-only rendering shown in the mockup at line 285 is not produced by any code in the document.
| id: agentId, | ||
| name: params.agentName, | ||
| description: params.taskDescription, | ||
| status: 'running', |
There was a problem hiding this comment.
handleAgentStart always writes running, and handleAgentComplete at line 237 writes only completed or failed. The queued and killed members of AgentStatus (line 50) have no production path, although the summary line counts queued at line 190 and the mockups show both.
| startedAt: Date.now(), | ||
| }; | ||
| sessionState.activeAgents.set(agentId, activeAgent); | ||
| renderAgentStatusBar(); // Trigger re-render |
There was a problem hiding this comment.
renderAgentStatusBar is not defined anywhere in the document, and neither are truncate (line 154), generateId (line 220), AgentStartParams (line 219) or AgentResult (line 234). Mutating an entry of a Map does not by itself re-render an Ink tree, so the render trigger needs a defined mechanism.
|
|
||
| ```json | ||
| { | ||
| "agentIndicator": { |
There was a problem hiding this comment.
Issue #817 proposes showAgentIndicator and agentIndicatorStyle with the values compact, detailed or none. This block uses a different key and field set and uses minimal where the issue uses none. Aligning the two or recording the divergence would help whoever implements it.
Summary
This PR adds RFC-001 — a detailed design proposal for implementing a multi-agent visual indicator in the Command Code CLI, as requested in issue #817.
What's Included
rfcs/001-multi-agent-visual-indicator.md) with:AgentBadge,AgentStatusBar)Key Design Decisions
compact(default),detailed,minimalagentIndicatorsettings objectVisual Inspiration
Next Steps
If approved, implementation would proceed in three phases:
Related issue: #817