Dawn
Menu

Site

$ npm create dawn-ai-app@latest my-agent

TypeScript meta-framework · for LangGraph.js

Build LangGraph agents like Next.js apps.

Dawn adds file-system routing, shared and route-local tools, per-route scoping, generated types, and durable threads to your LangGraph.js stack. Keep the runtime. Drop the boilerplate.

$ npm create dawn-ai-app@latest my-agent
Read the docs
Author a file-system route, prove it with npm test, run it in the Dawn Workbench, then restore the same thread after a browser reload. Read the transcript.
Built onLangGraph.js
327stars4contributors

Why Dawn

LangGraph is powerful. Writing real agents in it is tedious.

LangGraph.js gives you a graph runtime, durable state, and a production-grade execution model — the right primitives. What it doesn't give you is structure. Real agents drift into a single file, hand-rolled tool plumbing, types that don't follow the data, and a dev loop that means restarting the graph every time you change a prompt.

Dawn is a meta-framework for LangGraph in the same shape Next.js is for React. File-system routes for agents, shared and route-local tools with inferred argument types, end-to-end generated types from your state schema, and a dev session that keeps the same URL while its child HTTP runtime restarts. With durable stores, persisted state remains available across those restarts.

Dawn includes Node and Hono HTTP runtimes, but it is not an LLM router or hosted cloud. The LangSmith target emits graph entries, and raw graph and chain exports stay portable. Your model calls and deployment target stay yours.

Route shapes

Two ways to drive the model.

Same routing, same types, same dev loop — you choose who's in charge. A route's index.ts exports exactly one shape.

agent

Let the model decide.

An LLM-driven route that picks tools at runtime and can pause for a human. Reach for it when you want the model to choose what to do.

workflow

You own the order.

A deterministic, typed async function. Reach for it when you control the sequence of operations and want predictable, step-by-step execution.

Need raw LangGraph? Export a graph or chain and instantiate anything you want.

Routing

Routes for agents, not just pages.

Every agent in your app is a directory. Drop in an index.ts, a state.ts, and a couple of tool files. Agent routes materialize as LangGraph graphs; workflow, raw graph, and chain routes keep their authored entry form. No registry or central switch statement grows with every capability.

  • File-system routing the way Next.js does it for pages
  • Route groups for organizing public vs. internal agents
  • Nested routes for multi-step workflows
  • Agent descriptors materialize with their eligible tools
See routing docs
Inspect the generated research route, co-located route files, shared searchCorpus tool, and offline test harness. Read the transcript.
tools/lookup-order.ts
// src/app/(public)/support/tools/lookup-order.ts
export const description = "Fetch order details by order ID."

export default async (input: { readonly orderId: string }) => {
  return await db.orders.find({ orderId: input.orderId })
}

Tools

Tools that live next to the route that uses them.

Tools live as files inside the route directory that consumes them. Their argument types are inferred from TypeScript source — no string-typed JSON blobs, no manual type wiring. Co-located tools mean each agent is a self-contained unit you can move, copy, or delete without hunting through a central registry.

  • Route-local tools — discovered automatically
  • TypeScript-inferred argument types with full IntelliSense
  • Tool handlers are plain typed functions
  • Easy to test in isolation
See tools docs

Types

Types that follow the data.

Define your agent state in one Zod schema. Dawn generates types that flow into route handlers, tool handlers, and your client code — so the editor catches an out-of-shape state mutation the moment you type it, not at 3am when the graph throws on a missing field.

  • Single Zod schema → typed agent state everywhere
  • Tool input/output types inferred and propagated
  • Generated types refresh on save (HMR)
  • Works with your existing tsconfig.json
See type generation docs
state.ts → tools/*.ts
import { z } from "zod"

// state.ts — single source of truth
export default z.object({
  tenant: z.string(),
  question: z.string(),
  history: z.array(z.object({
    role: z.enum(["user", "assistant"]),
    content: z.string(),
  })),
})

// inside a tool handler — state.history is inferred end-to-end
async function summarize({ state }) {
  return state.history.map((m) => `${m.role}: ${m.content}`).join("\n")
}
Run npm test and see the deterministic research scenario pass without a provider key. Read the transcript.

Dev loop

Edit, save, continue at the same URL.

Any meaningful route, tool, state, config, or middleware change restarts the child runtime. The child-owned HTTP listener restarts with it, while the parent watcher/session retains the same URL. With the default SQLite stores, or another durable configured store, thread/checkpoint state remains available when the fresh child is ready.

  • Fresh child runtime and listener after meaningful changes
  • Parent watcher/session retains the same URL
  • Durability follows the configured thread and checkpoint stores
  • Type errors surface in the terminal and in your editor
See dev server docs

Durability

Durable by default.

Every Dawn app ships a working checkpointer and thread store — no setup. Runs checkpoint to SQLite between turns, so threads survive a dawn dev restart and an agent that pauses for human input resumes exactly where it left off.

LangGraph defines the checkpoint interface; Dawn ships the default implementation. So durability is the path of least resistance — not a wiring task.

  • Threads survive a dawn dev restart — no lost state between edits.
  • Agents that pause for human input resume exactly where they left off.
  • A working SQLite checkpointer and thread store ship by default — zero setup.
Complete a fixture-backed Workbench run, then use a browser reload to reopen the same thread and restore its checkpoint-backed transcript. Read the transcript.

Compatibility

Your bet on LangGraph.js stays your bet.

Node and Hono targets are Dawn HTTP runtimes; the LangSmith target emits graph entries. Agent routes materialize LangGraph graphs, while workflows keep their authored function shape and raw graph and chain exports remain portable. You can still drop into raw StateGraph where you need direct control.

Your raw graphs stay valid LangGraph.js, and graph and chain routes keep the provider clients you instantiate. Dawn supplies the route and target boundaries around that code without replacing it.

What Dawn does not do

  • Dawn does not replace LangGraph.js — agent routes materialize LangGraph graphs.
  • Dawn does not proxy provider calls — raw graph and chain routes use the clients you instantiate.
  • Dawn does not host your agents — it emits artifacts for your deployment target.
  • Dawn does not wrap raw graph and chain exports in a proprietary runtime format.

Ecosystem

Plays well with your stack.

Dawn keeps the LangGraph.js ecosystem close: built-in agent providers where supported, bring-your-own providers in graph and chain routes, plus observability, vector storage, and deployment targets.

Models

Try it

Three steps to know if Dawn fits.

01

Scaffold research

Create the research starter: a typed agent route, shared tools, memory, skills, subagents, and a local corpus.

$ npm create dawn-ai-app@latest my-agent
02

Test offline

Run its deterministic agent harness tests and replay-backed quality eval without an API key.

03

Choose what’s next

Opt into live dev, adapt a route to your application, or build for your deployment target.

FAQ

Things people ask before adopting Dawn.

  • Dawn is pre-1.0. The framework's surface API is stabilizing, and the types and dev-loop layers are in active use on internal projects. Run replay evals and harness tests against a representative route before adopting Dawn for production work, and use live evals locally when you need real-model signal. The runtime — LangGraph.js — is production-grade today, and Dawn does not change its execution model.

Start building.

Scaffold a Dawn app, open the example, and see whether the shape fits your team in under five minutes.

$ npm create dawn-ai-app@latest my-agent
Star on GitHub