Lightweight AI Agent Framework

Build tiny agents that do big things

A minimal, developer-friendly toolkit for building AI agents, automation scripts, and CLI tools. No bloat, no magic — just clean, composable primitives.

$npm install tinyagent

Everything you need. Nothing you don't.

Designed for developers who value simplicity and control.

Lightweight

Under 10KB gzipped. Zero dependencies by default. Ships only what you need.

CLI First

Built-in CLI scaffolding and commands. Perfect for terminal workflows.

Composable

Mix and match tools, prompts, and agents like LEGO blocks.

Plugin System

Extend functionality with community plugins or build your own.

TypeScript Native

Full type safety out of the box. IntelliSense for everything.

Multi-Provider

Works with OpenAI, Anthropic, local models, and more.

Simple by design

Get started in minutes with an intuitive API.

1import { Agent, tool } from 'tinyagent'
2
3const agent = new Agent({
4 name: 'assistant',
5 model: 'gpt-4o-mini',
6 tools: [searchTool, calculatorTool],
7})
8
9const response = await agent.run(
10 'What is the weather in Tokyo?'
11)