Transparent harness
Every one of the 12 phases emits typed events with before / after / on-error hooks. System prompts are readable templates, not buried strings. Raw provider clients ship standalone — skip the harness entirely if you want.
Reactive Agents is a composable TypeScript framework for building reliable LLM agents on a harness you fully control. It’s built on Effect-TS, so the runtime is type-safe, observable, and composable end to end.
Building production AI agents is hard:
Reactive Agents solves each of these with a layered, composable architecture:
| Problem | Solution |
|---|---|
| No type safety | Effect-TS schemas validate every boundary |
| Monolithic | Layer system — enable only what you need |
| Opaque | 12-phase execution engine with lifecycle hooks |
| Unsafe | Built-in guardrails, verification, and cost controls |
Transparent harness
Every one of the 12 phases emits typed events with before / after / on-error hooks. System prompts are readable templates, not buried strings. Raw provider clients ship standalone — skip the harness entirely if you want.
Reliable on local models
A 4-stage healing pipeline repairs malformed tool calls on the fly — deterministic string/type fixes instead of an LLM reprompt — so local Ollama models can run the same tool-calling loop as frontier APIs.
Typed structured output
Attach a Zod / Valibot / ArkType / Effect schema and read a fully-typed result.object — streaming field-by-field if you want. No prompt engineering, no manual parsing. (New in v0.12)
Durable by design
Opt a run into a durable store and resume it from its last checkpoint after a crash, restart, or pause — across process boundaries. (New in v0.12)
Every capability is an independent Effect Layer. Compose them like building blocks:
const agent = await ReactiveAgents.create() .withMemory() // Default memory tier (see Memory guide for enhanced + embeddings) .withReasoning() // ReAct reasoning loop .withGuardrails() // Injection & PII detection .withCostTracking() // Budget enforcement .build();Every agent task flows through a deterministic lifecycle:
Each phase supports before, after, and on-error lifecycle hooks.
@reactive-agents/interaction is an opt-in, standalone package that models five autonomy levels — autonomous, supervised, collaborative, consultative, and interrogative — with mode switching, checkpoints, and notifications as composable Effect services.
It is used directly, not through createAgent or the builder: createInteractionLayer() provides the InteractionManager service as an Effect layer you compose into your own program. See the interaction modes example in the Examples Catalog for the working pattern.