Older documentation. Start with the current guides.

Architecture

Go Micro began as a framework for service communication. RPC clients and servers, service discovery, codecs, transports, and pub/sub let applications communicate without tying their business logic to one infrastructure provider. Storage, configuration, and authentication support that same application boundary.

Agents extend this foundation: a service endpoint can also be a tool. The services → agents lifecycle describes how these components compose; it is not a requirement to adopt all of them or a replacement for RPC.

ComponentResponsibilityPublic entry point
ServiceImplement capabilities and own application datamicro.NewService
ModelAdapt model requests, responses, and tool calls to a providermodel.Model
AgentInterpret a request and use tools, memory, and execution controlsmicro.NewAgent
ApplicationCombine these components with users, interfaces, and usable outputsYour program or a runtime such as Mu

Service substrate

Services remain useful without a model or agent:

These are pluggable Go interfaces. Choosing a registry, broker, or store does not change a service’s business methods. Deployments still need to configure their backends, permissions, and persistence; the interfaces do not make a deployment secure or durable automatically.

Agent harness

The AI packages build on those service contracts:

A request arrives through Ask, RPC, or a gateway. The agent presents its tools to the model, executes requested calls, and returns a reply with tool-call and run metadata. The service owns the action and its data; the agent chooses when to use it. Tool selection is not a substitute for service-side authorization.

There is currently a split in execution responsibility: provider adapters can perform repeated tool calls inside Generate when a tool handler is supplied, while the agent adds guardrails, run tracking, and plan-completion logic around those calls. CLI development chat and multi-agent routing use this same agent harness, with memory and plans stored separately for each conversation. Provider-level tool iteration and agent-level execution control remain separate responsibilities.

See AI Integration, guardrails, and durability and recovery.

Interop gateways

Gateways derive their service and agent descriptions from registry metadata. An application can expose the same capabilities to Go clients, agents, and a UI.

Developer path

  1. Quick Start: develop services through conversation.
  2. Getting Started: create a Go agent and choose its tools.
  3. Your First Agent: run a complete service-backed agent.
  4. Debugging your agent: inspect tools and run history.

For a provider-free walkthrough, use the first-agent example. The 0→hero Reference contains the maintained lifecycle checks. See the API reference for individual interfaces and the CLI reference for project generation and development commands.