Implementation

Agent behavior is built with AutoGen-style patterns under src/core/autogen/: dynamic NPCs, routing, tools, and hooks into messaging and tasks.

Character specifications

YAML files (for example under src/core/specs/) define persona and behavior inputs. At runtime the system merges those specs with simulation settings loaded from MongoDB.

Core services

DynamicAgentService, DynamicAgentRouter, and related modules coordinate multi-agent turns and tool calls. Unless a flow is explicitly cross-tenant, treat all orchestration as organization-scoped.

Reliability

Agents depend on LLM providers and optional memory backends. When you add flows, document timeouts, fallbacks, and what the learner sees on failure. See Orchestration for routing and lifecycle interaction.