System Overview
High-level view of the Mosaic Stack architecture.
System Overview#
Mosaic Stack follows a modular, event-driven architecture. Each component is independently deployable and communicates over well-defined interfaces.
Core Components#
- Gateway: NestJS API server — agent routing, task dispatch, chat streaming, memory, and plugin hosting
- Web: Next.js dashboard — chat, tasks, projects, missions, settings, and user management
- Brain: PostgreSQL + pgvector data layer — tasks, projects, events, agents, memory, and skills
- Queue: Valkey-backed task queue with BullMQ — scheduling, dispatch, and health checks
- Observability: OpenTelemetry instrumentation with Jaeger tracing
Data Flow#
Requests enter through the Gateway, which evaluates routing policies, selects a provider, and forwards the request. Responses flow back through the same path, with telemetry events emitted at each step.