Architecture
The transport layer consists of these components:- AgentRegistry — Maps agent IDs to implementations (local classes or remote transports)
- AgentServer — Unified server that serves both local and remote agents
- HTTPTransport — Communicates with remote agents via HTTP
- RemoteAgent — Client-side proxy for remote agents
- Serverless Adapters — Deploy agents on FastAPI, Vercel, AWS Lambda
Why a Unified Transport Layer?
The architecture is designed around a few key principles: Location transparency — ARemoteAgent client talks to a local agent and a serverless Lambda function with the same API. The registry and transport abstract away whether an agent runs in-process or on another continent.
Pattern-based routing — The registry supports regex patterns (writer-.*, research-.*) so you can spin up multiple instances of the same agent type and address them dynamically.
Consistent wire protocol — All communication uses the same HTTP-based protocol regardless of platform. This is what lets serverless adapters on FastAPI, Vercel, and Lambda interoperate with a single AgentServer.
Pluggable transports — The transport interface is extensible. You can wrap HTTPTransport with retry logic, connection pooling, or custom load balancing without changing the registry or agents.
Quick Overview
Single Agent (Simplest Case)
Multi-Agent with Registry
How It Works
When a request arrives atAgentServer, the server:
- Extracts the agent ID from the URL path
- Looks it up in the registry (including regex pattern matching)
- If the target is a local class, instantiates and invokes it directly
- If the target is an
HTTPTransport, forwards the request to the remote endpoint - Returns the response through the same wire protocol
Related
- Deploying Agents — Step-by-step deployment guides
- Serverless Adapters Reference — FastAPI, Vercel, and Lambda adapters
- Tutorial: Complete Multi-Agent Setup — Build a system from scratch
- Advanced Transport Patterns — Load balancing, retry, orchestration