useAgentHeartbeat
stableAgent status polling hook — returns { agents, lastPing, stale, ping }. Marks agents stale after configurable staleness window. Used in multi-agent orchestration views.
import { useAgentHeartbeat } from "@nodus/design-system/patterns"Loading demo…
Props
| Prop | Type | Default | Description |
|---|---|---|---|
interval | number | — | Poll frequency in ms (default: 3000). |
staleAfterMs | number | — | Threshold before marking agent stale (default: 8000). |
intervalType
numberDefault —Poll frequency in ms (default: 3000).
staleAfterMsType
numberDefault —Threshold before marking agent stale (default: 8000).
Design Rationale
This component was designed to express:
Explore Related
useAgentStream→
SSE stream subscription hook — returns { chunks, status, latency, start, reset }. Simulates token-by-token delivery with configurable TTFT, chunkInterval, and chunkSize.
usePositionFeed→
Live FX position tick hook — returns { positions, lastUpdate, delta, running, pause, resume }. Configurable volatility and tick interval.
Was this helpful?