clavia-labs/tardigrade
The TypeScript framework for building modular agents around an immutable event log.
What it solves
Tardigrade provides a structured, functional framework for building AI agents that need to maintain complex state and a reliable history of actions. It solves the problem of state management in agentic workflows by using an immutable event log, ensuring that an agent's current state is always derivable from its history of events.
How it works
The framework is built on Effect TS and uses a concept called "atoms" to manage state and logic:
- Atoms: Basic units of state storage.
- Durable Atoms: These reduce an immutable event log into a current state, allowing for state recovery and persistence.
- Effect Atoms: These derive views and propose actions (acts) based on the current state of other atoms.
Agents are composed of these atoms into an "actor" which can be deployed as a worker. The system supports hosting on Cloudflare (using Durable Objects) or self-hosted Celld fleets, where each actor instance is managed by a supervisor and separate threads with their own SQLite-backed journals.
Who it’s for
Developers building complex, composable AI agents in TypeScript who prefer a functional programming approach to state management and want durable, persistent state across sessions.
Highlights
- Immutable Event Log: State is derived from a history of events, ensuring consistency and correctness.
- Functional Composition: Built on Effect TS, drawing inspiration from Elm and Jotai.
- Durable State: Integrated support for SQLite-backed storage for agent threads.
- Cloudflare & Celld Support: First-class support for deployment to Cloudflare Workers and Celld fleets.
Related
- Project
- Project
- Project
- Project