Agent infrastructure for Go

Build Go-native agents.

Models, memory, tools, guardrails, and workflows in one composable Go framework.

Charcoal modules linked to an illuminated amber core.

One runtime, five systems

Build the runtime your service needs.

Start with a small agent core. Add infrastructure as your application grows.

Agent core

A focused API for the full request cycle.

Generate, stream, attach files, call tools, and coordinate specialists from Go.

a, err := agent.New(agent.Options{
    Model: model,
    Memory: memory,
})

Providers

Change models without changing your agent.

Use hosted APIs, route across providers, or keep development local.

  • OpenAI
  • Gemini
  • Anthropic
  • OpenRouter
  • Ollama

Memory

Keep useful context close.

Combine short-term sessions with pluggable stores for durable, searchable history.

Session context Durable store

Tools and safety

Connect real systems with explicit boundaries.

Use structured tools, UTCP, CodeMode, checkpoints, and input or output guardrails.

tool call -> policy -> result

Model middleware

Put production policies around every call.

Compose runtime controls once, then apply them to any provider.

Timeout
Bound the complete operation.
Retry
Recover from transient setup failures.
Rate limit
Wait for capacity or reject early.
Token budget
Stop requests before spend runs away.
Amber routes converge through a set of dark workflow nodes.

Graph workflows

Make orchestration visible in code.

Route work between functions, tools, and agents without hiding control flow.

Route
Use emitted events to select the next node.
Join
Collect predecessor outputs before continuing.
Bound
Set step limits and timeouts for predictable runs.

Your first agent starts with one package.

The dummy model and in-memory store keep local setup safe and key-free.

go get github.com/Protocol-Lattice/go-agent

Install the package, choose a model, and create an agent.