Orchard is a programming language for building LLM agents. It is not a library you add to an existing language. It is a small language with its own grammar, type system, and runtime, designed so that the awkward parts of agent work become ordinary language features instead of glue code you write by hand.
Most agents today are assembled from a general purpose language, a model SDK, a pile of string templates, a parser for whatever the model returned, and a framework that ties tools and retries together. That stack works, but the important behaviour lives in conventions rather than in the program. Orchard takes the parts that every serious agent needs and makes them first class: calling a model, getting back a typed value, using tools, running work in parallel, and keeping state between turns.
What Orchard is
An Orchard program describes one or more agents. An agent has a persona, a model it talks to, and handlers that respond to messages. Inside a handler you call the model, branch on the result, call tools, and return a value. The compiler checks all of this before anything runs, so a program that compiles will not fail because a field was missing or a branch was never handled.
The shape of a program
The defining feature is typed generation. A plain gen performs one model call and returns text. Writing gen as T instead returns a value of type T, and the runtime guarantees the value is valid. If you declare an enum, the result is one of its variants and nothing else. You then branch with a match that the checker proves exhaustive, so you cannot forget a case. The result is that model output enters your program as ordinary typed data, not as a string you hope to parse correctly.
What the language gives you
- Typed generation with validated results, so model output is checked against your types before your code ever sees it.
- Exhaustive
match, so every branch of a decision is handled and the compiler tells you when one is missing. - Tools as a built in idea. Native functions, the HTTP, web, and shell packs, and any server that speaks the Model Context Protocol can all be called from an agent.
- A real concurrency model. Use
spawn,await, andparallelto run several pieces of work at once and gather the results. - State that survives. Conversation memory and durable storage are part of the runtime, not something you bolt on later.
- Safety rails. Token and cost budgets, a circuit breaker, and limits on tool use are built into the loop that drives an agent.
Where Orchard runs
Orchard is a library first, and the orch command line tool is a thin layer over it. The core is written in Rust, and every boundary (the model provider, the store, the HTTP client, the set of tools) is a trait with a sensible default that a host can replace. The same core is wrapped for four targets: Rust, C through a stable header, Python through native bindings, and the browser through WebAssembly. A program you write on your laptop can run inside a server, a desktop app, or a web page without changing the agent itself.
It also runs without a network. A built in mock provider lets you develop and test an entire agent offline. When you are ready, you point the same program at a real provider such as Anthropic, an OpenAI compatible endpoint, or a local Ollama model, and nothing else has to change.
Who builds Orchard
Orchard is developed by Artemis Labs and released as open source under a permissive license. The goal is plain: make the reliable way to build an agent also the easy way. We would rather ship a language that catches mistakes at compile time than a framework that hides them until production.
Where to go next
- Read why we built a language instead of another framework.
- See what you can build with Orchard today.
- Follow the roadmap to see where the project is headed.
- Start writing code with the progressive guide, or read the source on GitHub.
