TUI Surfaces
Three TUI components render Nity's presence in the terminal interface.
Components
Presence Indicator
presence-indicator.ts shows Nity's current state in the terminal.
interface PresenceIndicator {
render(state: BrandState): void
update(state: BrandState): void
clear(): void
}Visual states:
○ Nity — Standing by (idle, dim circle)
● Nity — Working (active, filled circle)
◐ Nity — Analyzing (thinking, half circle, pulse)
◉ Nity — Executing: iter 3/10 (executing, target, spin)
✕ Nity — Error: circuit open (error, cross, bold)
✓ Nity — Done (complete, check)Styling:
| State | Symbol | Color | Animation |
|---|---|---|---|
| idle | ○ | gray | none |
| active | ● | blue | none |
| thinking | ◐ | yellow | pulse |
| executing | ◉ | green | spin |
| error | ✕ | red | none |
| complete | ✓ | green | none |
Loop Status
loop-status.ts shows autonomous loop progress.
interface LoopStatus {
render(status: LoopStatusData): void
update(status: LoopStatusData): void
clear(): void
}
interface LoopStatusData {
currentIteration: number
maxIterations: number
circuitBreakerState: 'CLOSED' | 'HALF_OPEN' | 'OPEN'
lastAnalysis: {
confidence: number
shouldExit: boolean
} | null
}Display:
┌─ Loop ──────────────────────────────────┐
│ Iteration: 3/10 │
│ Circuit: CLOSED │
│ Confidence: 67% │
│ Progress: ██████░░░░ 60% │
└─────────────────────────────────────────┘Circuit breaker colors:
| State | Color | Visual |
|---|---|---|
| CLOSED | green | Solid bar |
| HALF_OPEN | yellow | Pulsing bar |
| OPEN | red | Stopped bar |
Memory Banner
memory-banner.ts shows memory and brain status.
interface MemoryBanner {
render(status: MemoryStatus): void
update(status: MemoryStatus): void
clear(): void
}
interface MemoryStatus {
brainLoaded: boolean
brainPath: string
episodeCount: number
memoryBackend: 'filesystem' | 'vector' | 'memory-fallback'
lastEpisode: Date | null
}Display:
┌─ Memory ─────────────────────────────────┐
│ Brain: ✓ Loaded (.voyager/brain.md) │
│ Episodes: 47 recorded │
│ Backend: filesystem │
│ Last episode: 2 min ago │
└──────────────────────────────────────────┘Fallback warning:
┌─ Memory ─────────────────────────────────┐
│ Brain: ✓ Loaded (.voyager/brain.md) │
│ Episodes: 47 recorded │
│ ⚠ Backend: memory-fallback (not saved) │
└──────────────────────────────────────────┘⚠️
When SimpleMem is unavailable, the memory banner shows a warning indicator. Episodes are still recorded in memory but will be lost when the session ends. The banner makes this visible so the human knows persistence is degraded.