Mozaik
Mozaik is an open-source TypeScript runtime for building autonomous, parallel AI agent teams that collaborate through a reactive, event-driven bus with shared environment awareness, tool use, and resilient coordination.
https://mozaik.jigjoy.ai/?ref=producthunt

Product Information
Updated:Jul 7, 2026
What is Mozaik
Mozaik is a TypeScript framework (runtime) designed to move multi-agent systems beyond rigid, sequential workflows into true team-style collaboration. Instead of orchestrating agents through predefined pipelines, Mozaik introduces an “agentic environment” where participants—agents, humans, observers, and tools—can join the same shared space, communicate, and coordinate in real time. It’s built to make agent collaboration a first-class concept: agents can stay aware of each other, exchange context intentionally, and work concurrently on the same goal.
Key Features of Mozaik
Mozaik is an open-source TypeScript agentic runtime for building autonomous teams of AI agents that collaborate in parallel through a shared, event-driven environment. Instead of hardcoding sequential workflows, Mozaik treats collaboration as a first-class concept: agents join an AgenticEnvironment (a broadcast bus), stay aware of other participants, exchange messages and context, react to tool calls and outputs as events, and recover from errors at runtime. The framework is designed for non-blocking “fire-and-forget” inference and reactive coordination, enabling multi-agent systems to communicate, coordinate, and ship work as a cohesive team.
Event-driven reactive core: Every message, tool call, reasoning step, and error is modeled as an event on a shared bus; agents subscribe to the events they care about and react immediately as they arrive.
Parallel by default (non-blocking inference): Agents can run inference and continue operating without waiting; results return as events, enabling multiple agents (and tools/observers) to work concurrently on the same goal.
Shared agentic environment (team awareness): Participants—humans, agents, observers, and tools—join the same AgenticEnvironment, allowing agents to detect who is “in the room,” respond to joins/leaves, and coordinate based on shared state.
Context as a first-class primitive: Mozaik provides structured context handling (via ModelContext and typed context items), making it easier to record, share, and route the right information to the right agent at the right time.
Tool/function-call integration via events: Function calls and tool outputs are handled as first-class events, enabling agents to execute tools and publish outputs back onto the bus for other participants to consume.
Runtime resilience and intelligent recovery: Agents can capture and handle failures with hooks like onError/onParticipantError, retry with backoff, or escalate to other participants instead of crashing the run.
Use Cases of Mozaik
Parallel AI coding and PR generation: Coordinate multiple specialized coding agents (planning, implementation, review, testing) to work concurrently and produce a pull request—exemplified by Mozaik-powered tools like baro.
Customer support and operations swarms: Run triage, knowledge-base retrieval, drafting, and QA agents in parallel on a shared bus so responses are faster, consistent, and auditable across a team of agents.
Research-to-writing pipelines without rigid workflows: Let researcher, writer, critic, and auditor agents collaborate adaptively at runtime—sharing only necessary context and reacting to each other’s findings as events.
Enterprise automation with tool-heavy processes: Build agent teams that call internal tools/APIs (tickets, CRM, databases) and coordinate across tool outputs and errors via event-driven communication.
Observability and evaluation for agentic systems: Attach observer participants to the environment to monitor messages, reasoning traces, tool calls, and failures in real time—supporting debugging, evaluation, and quality control.
Pros
Designed for true multi-agent collaboration: shared environment, awareness, and event-driven coordination rather than sequential orchestration.
Parallel, non-blocking execution improves throughput and responsiveness for complex goals.
Typed context/event model supports clearer structure, debugging, and extensibility in TypeScript ecosystems.
Cons
Event-driven, highly concurrent systems can be harder to reason about and debug than linear pipelines, especially as agent counts grow.
Requires TypeScript/Node adoption; teams outside that ecosystem may face higher integration costs.
Adaptive runtime coordination can be less predictable than predefined workflows, requiring careful testing and guardrails.
How to Use Mozaik
1) Create a new TypeScript project: Initialize a Node.js + TypeScript workspace (e.g., with npm init and tsc). Mozaik is a TypeScript runtime, so you’ll typically run it in a Node environment.
2) Install Mozaik core: Add the framework dependency: install @mozaik-ai/core (the starter template referenced in the sources is built against ^3.10.1).
3) Configure model provider credentials via environment variables: Mozaik selects a provider from the model name you pass to runInference, and each provider SDK reads credentials from the environment. Put the needed keys in your environment (commonly via a .env file), e.g., OPENAI_API_KEY if you use OpenAI.
4) Define participants (agents/observers/tools) as classes: Model each role as a participant (Mozaik calls agents 'participants'). Each participant has its own state and job; there is no inherited 'parent context'. Participants communicate by emitting/subscribing to typed events on a shared bus.
5) Add event handlers to make participants reactive: Implement reactive handlers such as onParticipantJoin / onParticipantLeft to give agents awareness of who is in the environment and to reassign work when someone leaves.
6) Use the event bus as the collaboration backbone: Treat every message, tool call, reasoning step, and error as an event on the bus. Participants subscribe to the events they care about and react immediately when those events fire.
7) Run inference in a non-blocking way ('fire and forget'): Start inference and continue other work without waiting. When results arrive, they come back as events; your participant reacts only to the relevant result events while everything else keeps running.
8) Implement tool calling as event-driven I/O: When the model requests a tool (e.g., via onFunctionCall), run the tool and emit a 'functionCallOutput' (or equivalent typed) event back onto the bus with the callId and result—so the run stays non-blocking.
9) Scope what each participant listens to (optional but recommended): To prevent unnecessary reactions, populate a participant’s listens list with the participant classes it should react to. When listens is non-empty, the environment only delivers external events whose source matches one of those classes.
10) Add runtime error recovery: Use onError and/or onParticipantError to catch tool failures or participant crashes. Implement retry with backoff (e.g., retry up to 3 attempts) and escalate by emitting a message event to another participant instead of crashing the whole run.
11) Enable parallelism by adding multiple participants: Create multiple specialized participants (e.g., Researcher, Writer, Critic, Auditor) and let them run concurrently. Mozaik is parallel-by-default: multiple agents can work at the same time while staying coordinated through shared events/context.
12) Let collaboration paths emerge at runtime: Avoid hardcoding rigid handoffs. Instead, design participants to decide when to communicate, who to involve, and what context to share based on the events they observe.
13) (Optional) Add observers for logging and UI: Attach observer-style participants that don’t drive decisions but record or render the run: e.g., an Auditor that writes a JSONL log, or a UI participant that emits frames for a terminal UI.
14) Run your agent team: Start the environment/bus, register participants, and trigger an initial event (e.g., a RunStart or goal message). The system proceeds as a reactive stream of events, with participants coordinating and recovering from errors in real time.
15) Use a starter template if you want a working CLI quickly: The sources reference a CLI starter template repo that wires an Ink terminal UI to @mozaik-ai/core and includes a typical split of agent/observer/tools. Clone a starter template to avoid boilerplate, then customize participants and tools for your use case.
Mozaik FAQs
Mozaik is an open-source, TypeScript-based agentic runtime/framework for building autonomous teams of AI agents that can communicate, coordinate, and act autonomously.
Mozaik Video
Popular Articles

Atoms: A Multi-Agent AI Platform That Transforms Ideas into Launch-Ready Products
May 22, 2026

Nano Banana SBTI: What It Is, How It Works, and How to Use It in 2026
Apr 15, 2026

Atoms Review — The AI Product Builder Redefining Digital Creation in 2026
Apr 10, 2026

Kilo Claw: How to Deploy and Use a True "Do‑It‑For‑You" AI Agent(2026 Update)
Apr 3, 2026







