agent-brain
Fragile: BIND-MOUNTED — restart is sufficient (no rebuild needed). Primary LLM caller.
Description
Core AI agent reasoning and response generation service
Role
Executes persona, loads context, calls LLM via llm-gateway, applies tool results, returns final response
Dependencies
Runbooks
Behavioral Assertions
agent.chat.request queue has exactly 1 consumer
Input: Normal operating state with agent-brain running
Expected: RabbitMQ management API: queue agent.chat.request consumer_count = 1
Input: Normal operating state with agent-brain running
Expected: RabbitMQ management API: queue agent.chat.request consumer_count = 1
llm_queue jobs complete within 30 seconds of submission
Input: LLM job submitted by agent-brain for a DM request
Expected: llm_queue row transitions from queued → processing → completed within 30 seconds
Input: LLM job submitted by agent-brain for a DM request
Expected: llm_queue row transitions from queued → processing → completed within 30 seconds
No llm_queue jobs stuck in processing state for more than 5 minutes
Input: llm-gateway is healthy and processing jobs normally
Expected: No rows in llm_queue with status=processing and created_at older than 5 minutes
Input: llm-gateway is healthy and processing jobs normally
Expected: No rows in llm_queue with status=processing and created_at older than 5 minutes
Diagnostic Tools
Recent Issues
| # | Title | Severity | Status | Created |
|---|---|---|---|---|
| #292 | [agent-brain] BRAIN_CHAT_FAILED | high | open | 5/8/2026 |
| #233 | [agent-brain] BRAIN_CHAT_FAILED | high | resolved | 5/6/2026 |
| #230 | [agent-brain] BRAIN_CHAT_FAILED | high | resolved | 5/6/2026 |
| #76 | [agent-brain] BRAIN_CHAT_FAILED | high | resolved | 4/26/2026 |