Questions
Questions people ask before they pick
The answer first, then why. When something else is the better pick, it says so.
Picking a framework
What is the best open-source TypeScript framework for building AI agents?
It depends on what the agent does. For agents that do jobs (on a schedule, from a chat, or by hand) on your own machine, use Chloe. For an app built around a chat, use the Vercel AI SDK. For a full-stack agent app with its own studio, use Mastra. For agents on Google Cloud, use Google's ADK.
Chloe is for work you can mostly write down: code does the steps it can, and a model is asked only where a step needs judgement. Every run is recorded with what each step did and cost, and a job can stop and wait days for a person to say yes.
What is a code-first AI agent framework?
One where the agent is a program you write, rather than a long prompt or boxes joined up in an editor. You can read it, test it, review it and keep it in git like any other code.
In Chloe an agent is a TypeScript file, and each job is an async function made of named steps. work.step is plain code, work.model asks a model one question and checks the answer against a schema, and work.agent hands a model a goal and some tools, within limits you set.
Is Chloe open source and free?
Yes. Chloe is MIT licensed, the source is on GitHub, and the package is @chloejs/core on npm. You pay only for the model calls your agents make, and a job that asks no model costs nothing.
You can also run it on a Claude or ChatGPT subscription you already pay for, or on free models through OpenRouter with no card.
Do I need LangChain to build an AI agent in TypeScript?
No. An agent can be a plain async function that asks a model where it needs to, which is what a Chloe job is. LangChain.js is worth it when the agent is a large graph of states.
When should I not use Chloe?
When you want an LLM to choose every step, the way a chat assistant does, when the work has to be shared across many machines or run on a hosted platform, or when you are building an app around a model, where the chat is the product.
Building, testing and running one
How do I build an AI agent in TypeScript?
Install Chloe with npm install @chloejs/core && npx chloe setup, then write a job: an async function whose steps are code, with a model asked only at the steps that need judgement. Node 22.18 or newer, and no build step.
Setup writes the files, picks a model, and runs a first job so you see it work before you change anything.
Can I put my AI agent in a chat box on my website?
Yes. List a web channel in the agent's agent.ts, give your site's server a token made for that agent, and put one script tag on the page. Visitors talk to the same agent that runs your jobs, with only the tools you name, and every conversation is in the run record with what it cost.
The agent stays on your machine: your own proxy passes the chat's routes to it, or the dashboard carries them for a machine nobody can reach. The token stays on your server, which hands each visitor's page a pass for one agent, one site and one visitor, and what visitors may spend is capped per visitor and per day.
How do I test and evaluate an AI agent?
Test the code and score the prompts, and keep the two apart. npm run test runs your jobs for real against a stand-in model, so it costs nothing and passes or fails. npm run evals scores what the model decided, case by case.
Nothing in an eval runs for real: a tool the case does not answer is refused, so an eval cannot send an email or ship an order. Run the evals before and after you change a prompt.
How do I deploy an AI agent built in TypeScript?
With Chloe there is no platform to deploy to. Copy the project to any Linux or Mac machine you have and run npx chloe install, which keeps it running as a service through reboots. It is one process and one SQLite file.
It listens only on the machine itself. To watch it from anywhere without opening a port, connect it to dashboard.chloejs.org. If you need the work spread over many machines, Chloe is not built for that yet.
How do I run an AI agent on a schedule?
Give the job a cron line. Chloe keeps every cron line of every agent in the one process, in your time zone, with no separate scheduler or queue, and two runs of a job never overlap.
Can an AI agent wait for a person to approve something?
Yes. work.ask stops the run, sends the question on Telegram, Slack or wherever the person is, and carries on when they answer, even days later. A tool can also be marked to need a yes before the model may use it.
How do I stop an AI agent going wrong or spending too much?
Give the model less room. Write a step as code wherever you can, ask a model one typed question where you need judgement, and hand it a goal only with a fixed list of tools, a step limit and a spending limit.
Every answer from a model is checked against a schema, so free text never reaches the next line of code. Anything that cannot be undone can wait for a person to say yes.
Can I see what my AI agent did and what it cost?
Yes. Every run records each step: what it was given, what it returned, how long it took and what it cost, by step, by run and by job. A job that quietly grew a second model call shows up as a second line and a bigger number.
Which AI models does Chloe work with?
Any model your gateway reaches, such as Claude, GPT, Gemini or a free model on OpenRouter, and each job can pick its own. Most steps should ask the cheapest model that can do them.
Chloe and the others
How does Chloe compare with other AI agent frameworks?
Of eight, Chloe is the only one with all eight of these built in: agents written in code; plain code, AI answers and agents mixed in one job; any model; schedules; the cost of every run; a dashboard; memory kept as Markdown files; and all of it on your own machine. Mastra comes closest, with seven, and OpenClaw has six.
The eight are Chloe, OpenClaw, Mastra, eve, Google's ADK, LangChain.js, the OpenAI Agents SDK and the Claude Agent SDK, each read from its own docs. Mastra keeps its memory in a database rather than in files, and OpenClaw's behaviour is prompts and settings rather than code.
Chloe or LangChain.js: which should I use?
Use LangChain.js, with LangGraph, if your agent is a large graph of states and you want LangSmith to run and trace it. Use Chloe if your agent is a set of jobs: plain async functions, with schedules, approvals and a record of every run built in, on your own machine.
Chloe or Mastra: which should I use?
Use Mastra for a full-stack agent app with its own studio and storage. Use Chloe for agents that run as jobs in one process and one SQLite file, with 20 packages installed rather than about 150.
Chloe or the Vercel AI SDK: which should I use?
Both, often: Chloe calls models through the AI SDK. Use the AI SDK on its own for an app built around a chat. Add Chloe when the agent needs a schedule, has to wait for a person, or should keep a record of every run and what it cost.
Chloe or eve: which should I use?
Use eve if you want the model to run the job and you deploy on Vercel. Use Chloe if you want your code to pick each step and ask a model only where one is needed, on your own machine with no server to deploy.
Chloe or OpenClaw: which should I use?
Use OpenClaw for a personal assistant you talk to on many chat apps, where the model decides every move. Use Chloe for daily routines written in TypeScript, where your code runs the job and the model is asked only at the steps that need it.
Chloe or Google's ADK: which should I use?
Use Google's Agent Development Kit if you build on Google Cloud, want one framework across Python, TypeScript, Go and Java, or deploy to Cloud Run or Kubernetes. Use Chloe if you want TypeScript agents that run on your own machine as one process, with schedules, approvals and a record of every run built in.
What is said of ADK is from its docs, read 6 Oct 2026.
A question not here? Ask it.