Keep work moving.
Maintain state across long sessions. Coordinate workers, pause for input, and recover from recorded evidence.
Sessions & recoveryCayu
Open source · Python · Apache 2.0
Cayu is an open-source Python framework for building and running domain-specific long-horizon agents. Compose a harness around your tools, knowledge, and business rules—with a durable runtime built in.
pip install cayu
How Cayu works
Cayu brings the building blocks, harness components, and runtime together in one Python framework. You supply the domain knowledge and define how the agent does its job.
| Concept | Its role in Cayu |
|---|---|
| Framework | The Python structure, APIs, defaults, and components you build with. |
| Harness | The system you assemble with Cayu: context, tools, memory, policies, domain logic, and verification. |
| Runtime | The integrated execution machinery: sessions, state, workers, recovery, approvals, and budgets. |
| Agent | The resulting product that performs work in your domain. |
An agent built with CayuA product that performs work in your domain
Cayu frameworkPython APIs, defaults, and components to build with
Your domain-specific harnessAssembled and customized with Cayu
Propose the next step
Your choice of providerCheck permission, then act
Your systems and functionsCollect and verify evidence
Context for what comes nextContinue toward the goal Wait for input Finish
Cayu runtimeIntegrated execution, built in
Durable sessions & stateWorkers & recoveryApprovals & budgetsReplay & observability
Long-horizon work
“Process these 5,000 documents” has a finish line. Getting there may involve thousands of calls, new evidence, a human decision, and a restart.
Hour 3
Review 5,000 documents, extract the required fields, and flag exceptions. Your harness defines the checks. Cayu records the execution.
The goal stays bounded as the execution grows.
Document review / Session 052Running
Documents reviewed1,240 / 5,000
Estimated model cost$18.60 / $100 budget
Document batch completed
Results and session progress recorded
Next
Continue reviewing the remaining documents.
This example shows the lifecycle you can build with Cayu. Your harness defines the business rules and completion checks.
Start building
Start with a project that has a place for your prompts, tools, policies, memory, and evals. Bring the libraries and domain code your team already uses.
Python 3.11+ · Run locally or on your infrastructure
Terminal
01 / Create your project
pip install cayu
cayu new support-agent
cd support-agent02 / Check and evaluate
cayu check --fail-on warning --json
pytest
cayu eval run03 / Run your agent
Configure your model provider in configuration/settings.py or CAYU_PROVIDER first.
python run.py --message "Review this change."Open the generated project in your development tool, or start with this prompt and build and refine your agent together.
Install cayu and create a document review agent. Use cayu new to scaffold the project. Define the required fields, flag exceptions for human review, and add completion checks and evals. Ask me about the document format and model provider before configuring them.
What Cayu handles
Maintain state across long sessions. Coordinate workers, pause for input, and recover from recorded evidence.
Sessions & recoveryDefine which tools an agent may use, when approval is required, and how much a run may spend.
Permissions & budgetsInspect the work, trace model costs, and evaluate behavior using the path the agent took and the result it produced.
Observability & evalsBuild, then operate
Build your agent and its domain-specific harness with Cayu. Run it on your own infrastructure, or use Cloud as your team’s shared workspace.
Cayu · Open source
Compose your harness in Python. Choose your models, stores, and execution environment. Inspect sessions, usage, and evals in the included runtime dashboard.
Explore deployment options Open source · Cayu Cloud is optionalCayu Cloud
Build in Console, deploy your agents, and manage their work in a shared workspace. Connect systems, set policies, and evaluate improvements with Compound.
Explore Cayu Cloud For teams managing the agent lifecycleWhy we built it
We kept rebuilding the same infrastructure around agents for finance, accounting, and enterprise operations. The complexity grew when the work had to continue across days, decisions, and failures.
We brought those building blocks and the runtime together in Cayu. Our background in ML and industrial systems shapes the approach: domain knowledge, verification, and the system around the model matter.
A few useful answers
Cayu is an open-source Python framework for building and running domain-specific long-horizon agents. It provides components and defaults to assemble your agent’s harness, with an integrated runtime for durable, controlled execution.
A harness is the system around the model: context, tools, policies, domain logic, memory, and verification. You assemble and customize it with Cayu to define how your agent does its job.
When work spans many decisions, interacts with real systems, waits for people, needs to survive interruptions, or operates under cost and permission constraints. The goal can be bounded even when execution takes hours or days.
Yes. Cayu provides defaults and replaceable Python contracts for models, context, tools, execution, and storage. Supported provider integrations include OpenAI, Anthropic, Amazon Bedrock, Google Vertex AI, and OpenAI-compatible APIs. You can implement your own provider contract.
No. Agents built with Cayu run on infrastructure you choose, with a packaged operator dashboard included. Cayu Cloud is an optional shared workspace for building, deploying, operating, and improving your agents.
Yes. Cayu is licensed under Apache 2.0. You can inspect, modify, and self-host it. We use Cayu in enterprise deployments; the open-source project is early, and we welcome feedback from teams building domain-specific long-horizon agents.
Build for the long run
What does your agent need to do?
Join the conversation ↗