Quickstart
Get a working agent backend running in under 5 minutes. Agentend scaffolds the project, configures your fleet of model workers, and serves an AG-UI compatible streaming endpoint out of the box.
1. Install Agentend
Install the framework with all optional dependencies (Redis, pgvector, OpenTelemetry, Celery):
pip install agentend[all]Or install the minimal core:
pip install agentend2. Scaffold a project
The init command creates a project directory with an entry point, fleet config, Dockerfile, and dependency file:
agentend init myapp
cd myappThis generates:
- •
app.py— Application entry point - •
fleet.yaml— Fleet and memory configuration - •
Dockerfile— Container definition - •
requirements.txt— Python dependencies - •
.env.example— Environment variable template
3. Write a Capability
A Capability is the core abstraction in Agentend. It declares what intents the agent handles, which worker models it needs, and what tools are available. Open app.py and define your first capability:
from agentend import Agentend, Capability, tool
app = Agentend()
@app.capability(
name="invoice_processor",
intents=["process invoice", "extract invoice data"],
workers=["extract", "verify", "summarize"],
)
class InvoiceProcessor(Capability):
"""Extract, verify, and summarize invoice data."""
@tool
async def get_vendor_info(self, vendor_id: str) -> dict:
"""Look up vendor details from the database."""
return {"vendor_id": vendor_id, "name": "Acme Corp"}
def get_domain_context(self) -> str:
return "You are an invoice processing specialist."
app.run()4. Configure the fleet
The fleet.yaml file configures worker slots, memory tiers, and infrastructure. A minimal config:
fleet:
name: myapp
description: "My first agent fleet"
workers:
classify:
model: gpt-4o-mini
timeout: 30
extract:
model: claude-sonnet-4-6
timeout: 60
verify:
model: claude-opus-4-6
timeout: 45
summarize:
model: claude-sonnet-4-6
timeout: 60
generate:
model: claude-opus-4-6
timeout: 120
tool_call:
model: claude-sonnet-4-6
timeout: 90
memory:
session:
enabled: true
type: redis
ttl: 3600
semantic:
enabled: true
type: pgvector5. Serve
Start the server with auto-reload for development:
agentend serve --reloadYour agent backend is now running. The following endpoints are available:
| Method | Endpoint | Description |
|---|---|---|
| POST | /intent | Submit a natural language intent for processing |
| GET | /stream/{session_id} | SSE stream of AG-UI events for a session |
| GET | /health | Health check endpoint |
Next steps
- •Learn about Capabilities in depth
- •Configure your Fleet with benchmark-optimized models
- •Set up the Memory system for contextual conversations
- •Connect your frontend with AG-UI Events