open specs · typescript runtime · any library
Composable primitives for composable agents.
Tools, skills, agents, knowledge, workflows and policies: every part of an agent defined once, as a file with a declared contract. Use them with Mastra, the Vercel AI SDK, MCP, or your own stack. Open numbered specs; a TypeScript runtime that loads, runs, and projects them.
Apache-2.0 · running coding agents? → start here
one contract, many hosts
Define once. Run in any framework.
A tool declares its contract: schemas, side-effects, approval class. Implementations are drivers: in-process, CLI, HTTP, MCP. The same tool projects into whichever host you build with, so a new framework is a projection, not a rewrite.
import { defineTool } from "@agentproto/tool"
import { implementTool } from "@agentproto/driver"
import { z } from "zod"
const greet = defineTool({
id: "greet",
inputSchema: z.object({ name: z.string() }),
outputSchema: z.object({ greeting: z.string() }),
})
const impl = implementTool(greet, async ({ input }) => ({
greeting: `Hello ${input.name}`,
}))// Mastra
toMastraTool(impl)// Vercel AI SDK
toAiSdkTool(impl)// MCP / CLI / HTTP
serveTool(impl)the registry
Everything an agent is, as files with contracts
Every serious agent system converged on the same shape: a folder of markdown files the agent reads, writes, and runs from. The AIP specs give that shape a shared vocabulary: one numbered spec per primitive, aligned with the de-facto standards (SKILL.md as Anthropic shipped it, AGENTS.md, CLAUDE.md), not forks of them. Organised below by the question each layer answers; each spec links to its full text and lifecycle status.
Process: how does the standard itself evolve?
How AIPs are proposed, reviewed, and graduated. Read these first if you want to contribute a spec.
| # | Title | Status | Requires |
|---|---|---|---|
| AIP-1 | Purpose & Process | Final | · |
| AIP-2 | AIP Template | Final | · |
| AIP-40 | EXTENSION.md — agentextension/v1 (custom doctype declarations) | Review | · |
Primitives: what building blocks does everything else compose with?
Small, reusable pieces. Every other layer references at least one of these: collections, refs, IO blocks, secrets, process boundaries.
Identity: who acts?
How an agent describes itself: its profile, capabilities, persona. The shell that the rest of the layers attach to.
Memory: what does the agent remember between runs?
Knowledge an agent maintains, lessons it distils from experience, prompt overlays it carries forward. Memory turns one-shot agents into ones that compound.
Work, Org & Governance: what gets done, where, and under what rules?
Companies, agencies, work items, offices, assemblies, and the governance layer that records approvals and audit trails. The coordination substrate.
Capabilities: what can the agent do?
Skills, tools, workflows, intents: the declared surface of what an agent or its tools expose. Intent vs implementation: capabilities declare intent.
Drivers: how are capabilities actually implemented?
The DRIVER supertype and its concrete subtypes (CLI, HTTP, MCP, SDK). One tool, many drivers; the routing layer that connects intent to execution.
Surfaces: what does the agent produce or read?
Visual and code surfaces: design tokens, canvas templates, code workspaces. The artifacts agents author or consume on the human-facing edge.
why files, why contracts
Agents that improve their own components
Because every component is a file with a declared contract, an agent can extend itself with ordinary file operations, no research project, no plugin API. Self-modification becomes a write_file call the runtime can validate and you can gate.
Add a tool
Write a TOOL.md contract and a DRIVER.md implementation to disk. The runtime picks them up.
Swap a provider
One tool, many drivers: add a second driver and update policy. No caller changes.
Fix a bug in itself
Edit the driver body, rerun the contract's validators, ship it behind the same checks as any other change.
the human gateway
Primitives need a place to run. And someone needs to see them.
The agentproto CLI + daemon run your coding agents in the background: Claude Code, Codex and open models in one list, terminal or web. Check each one's work before it's committed. Built entirely on the primitives above.
npm i -g @agentproto/cli
agentproto serveGet started: run & supervise agents →errata, in advance
What's real vs. roadmap
The tool/driver primitives, the CLI, fifteen agent adapters, and the orchestration/supervision layer (nested orchestration, policy gates, fan-in monitoring, MCP composition) are live and used hands-on. The wider AIP spec family beyond that is an open roadmap. Most of those packages are early scaffolding, not finished implementations. We'd rather say that plainly than have you find out the hard way.
Full features breakdown →