Skip to content

Getting started ​

Clanker is an embeddable TypeScript runtime for defining, running, and composing agents across provider backends. The quickest first run uses the local provider, so it needs no account, API key, or network access.

Run the repository ​

Clanker currently requires Node 24 and pnpm 10.

bash
git clone https://github.com/techsavvyash/clanker.git
cd clanker
pnpm install --frozen-lockfile
pnpm examples

That command builds and runs the five offline examples covering schemas, instruction files, child-agent calls, chains, routing, approvals, and cancellation.

A minimal agent ​

ts
import { AgentRuntime, defineAgent, local } from "@techsavvyash/clanker";

const agent = defineAgent({
  id: "hello",
  instructions: { type: "text", text: "Return a greeting." },
  provider: local()
});

const provider = local.provider();
provider.register("hello", async ({ input }) => ({
  greeting: `Hello, ${(input as { name: string }).name}`
}));

const runtime = new AgentRuntime({ providers: [provider] });
const result = await runtime.run(agent, { input: { name: "world" } });

console.log(result.output);

local is a real provider adapter with in-process handlers. It is useful for offline development and deterministic tests; moving to Codex or Claude changes the provider binding, not the runtime model.

Check the project ​

bash
pnpm lint
pnpm check
pnpm test
pnpm build
pnpm pack:smoke

The default test suite is offline. Live provider suites are opt-in through pnpm test:live and require the corresponding local provider authentication.

Next ​