Skip to content

RFC-001: Multi-Agent Visual Indicator for Active Sessions - #818

Open
vikramrajj wants to merge 1 commit into
CommandCodeAI:mainfrom
vikramrajj:feat/multi-agent-visual-indicator
Open

vikramrajj wants to merge 1 commit into
CommandCodeAI:mainfrom
vikramrajj:feat/multi-agent-visual-indicator

Conversation

@vikramrajj

Copy link
Copy Markdown

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

  • RFC document (rfcs/001-multi-agent-visual-indicator.md) with:
    • TypeScript interfaces for agent status tracking
    • Component designs (AgentBadge, AgentStatusBar)
    • Integration approach with existing session state
    • Settings schema for user configuration
    • Visual mockups for compact/detailed/minimal styles
    • Phased migration path (passive → interactive → advanced)

Key Design Decisions

  1. Three display styles: compact (default), detailed, minimal
  2. Status lifecycle: queued → running → completed/failed/killed
  3. Non-intrusive: Status bar sits above conversation, auto-hides when no agents active
  4. Configurable: Via agentIndicator settings object
  5. Phased rollout: Start with passive indicator, add interactivity later

Visual Inspiration

  • T3 Code (Theo) — agent badges with spinners
  • Codex — agent tiles with status indicators

Next Steps

If approved, implementation would proceed in three phases:

  1. Passive indicator (read-only display)
  2. Interactive controls (expand, kill, view output)
  3. Advanced features (timeline, metrics, streaming)

Related issue: #817

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>

@ahrazzle ahrazzle left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes: this RFC declares behaviour it does not implement, renders agent-produced text with no escape rules, diverges from the issue it cites, and creates a new repository convention without a recorded decision.

Checked against the live PR head (201b4a4) and its single added file. Checked the file against itself and against the repository governance records.
This repository has no source for the product internals the document specifies and no test suite or CI. Those internals could not be validated here.

Scope question for the maintainers. The PR creates a new top level rfcs/ directory and numbers the document RFC-001.
Code search finds no rfcs path anywhere else in the repository. The repository has no contributing guide and no pull request template.
Recent history offers no precedent for a design document PR either way. Do the maintainers want an rfcs/ convention at all?
If so, the convention needs a recorded approval in this thread.

Declared fields with no implementation. rfcs/001-multi-agent-visual-indicator.md:94 declares animate and no code reads it. rfcs/001-multi-agent-visual-indicator.md:92 declares showUsage and no code reads it.
rfcs/001-multi-agent-visual-indicator.md:58 declares color and no code reads it. rfcs/001-multi-agent-visual-indicator.md:67 declares progress and no code reads it.
The minimal style at rfcs/001-multi-agent-visual-indicator.md:88 has no branch. The only style branch is rfcs/001-multi-agent-visual-indicator.md:194 for detailed.
The compact prop at rfcs/001-multi-agent-visual-indicator.md:118 is never passed at rfcs/001-multi-agent-visual-indicator.md:197.
The typescript fence at rfcs/001-multi-agent-visual-indicator.md:110 holds JSX. It fails a .ts parse and only parses as tsx.

Undefined symbols. truncate is called at rfcs/001-multi-agent-visual-indicator.md:154 and never defined. generateId is called at rfcs/001-multi-agent-visual-indicator.md:220 and never defined.
renderAgentStatusBar is called at rfcs/001-multi-agent-visual-indicator.md:229 and rfcs/001-multi-agent-visual-indicator.md:240 and never defined. AgentStartParams at rfcs/001-multi-agent-visual-indicator.md:219 and AgentResult at rfcs/001-multi-agent-visual-indicator.md:234 have no definitions.
The session store at rfcs/001-multi-agent-visual-indicator.md:213 has no import and no initialization. The render trigger implies a re-render mechanism that the document never shows.

Unreachable states. rfcs/001-multi-agent-visual-indicator.md:225 always sets running. rfcs/001-multi-agent-visual-indicator.md:237 only produces completed or failed.
The queued and killed states have no production path. Session end cleanup at rfcs/001-multi-agent-visual-indicator.md:295 is prose with no handler.
The click interaction at rfcs/001-multi-agent-visual-indicator.md:305 assumes terminal capabilities the document never verifies.

Sanitisation is missing. Agent controlled name at rfcs/001-multi-agent-visual-indicator.md:56 and description at rfcs/001-multi-agent-visual-indicator.md:154 and error text at rfcs/001-multi-agent-visual-indicator.md:238 render into terminal output with no stated escape rules.
The color field at rfcs/001-multi-agent-visual-indicator.md:57 accepts hex or ansi color with no stated validation. A sanitisation subsection is needed before implementation.

Source alignment. Issue 817 specifies showAgentIndicator and agentIndicatorStyle with compact, detailed or none.
The document uses agentIndicator at rfcs/001-multi-agent-visual-indicator.md:249 with a different field set and minimal in place of none.
The recorded maintainer position on issue 817 describes a narrower explorer on the roadmap. The document proposes three broader phases without a recorded approval for the wider scope.

Requested changes. Define or remove each unused field. Define each undefined symbol or mark the mechanism explicitly out of scope.
Give queued and killed production paths or remove them. Add the sanitisation rules.
Align the settings keys with issue 817 or document the divergence with maintainer approval. Record the rfcs/ convention decision.

Automated posting by agentic team with human oversight.

@@ -0,0 +1,336 @@
# RFC-001: Multi-Agent Visual Indicator for Active Sessions

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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' && (

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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',

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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": {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants