Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.agno.com/llms.txt

Use this file to discover all available pages before exploring further.

An agent that works in your filesystem, remembers you across sessions, and runs as a production API with persistent sessions and state management out of the box.

1. Define the Agent

Save the following code as workbench.py:
workbench.py
from agno.agent import Agent
from agno.db.sqlite import SqliteDb
from agno.os import AgentOS
from agno.tools.workspace import Workspace

workbench = Agent(
    name="Workbench",
    model="openai:gpt-5.4",
    tools=[Workspace(".",
        allowed=["read", "list", "search"],
        confirm=["write", "edit", "delete", "shell"],
    )],  # read/write/edit/shell in this directory
    enable_agentic_memory=True,  # remembers across sessions
    add_history_to_context=True,  # include past runs
    num_history_runs=3,  # last 3 conversations
)

# Serve via AgentOS → streaming, auth, session isolation, API endpoints
agent_os = AgentOS(agents=[workbench], tracing=True, db=SqliteDb(db_file="agno.db"))
app = agent_os.get_app()
Workspace(".") scopes the agent to the current directory. read, list, and search run freely; write, edit, move, delete, and shell require human approval.

2. Run Your AgentOS

1

Set up your virtual environment

uv venv --python 3.12
source .venv/bin/activate
2

Install dependencies

uv pip install -U 'agno[os]' openai
3

Export your OpenAI API key

Don’t have one? Get a key from platform.openai.com.
export OPENAI_API_KEY=sk-***
4

Run your AgentOS

fastapi dev workbench.py
Your AgentOS is now running at:http://localhost:8000API documentation is automatically available at:http://localhost:8000/docs
Now you have:
  • A stateful agent served as a production API.
  • Tracing and session monitoring enabled out of the box.
  • Per-session storage and isolation, with JWT-based RBAC available for multi-user isolation.
No third-party services required.

3. Chat with your Agent

The AgentOS UI connects your browser to your runtime. Use it to test, monitor, and manage your agents in real time.
  1. Open os.agno.com and sign in.
  2. Click “Connect OS”
  3. Select “Local”, enter your endpoint URL (default: http://localhost:8000), name it “Local AgentOS”, and click “Connect”.
Click on Chat, and ask:
List the files here and tell me what kind of project this is.
The agent reads your workspace and answers grounded in what it actually finds. Try a follow-up like “summarize the README” or “create a NOTES.md with three bullet takeaways”. The second one will pause for your approval before the file is written, since write_file is a confirm-required tool by default. Click Sessions or Traces in the sidebar to inspect stored conversations.
All session data is stored in your local database, no data leaves your system.

Next

Build a real product

Production templates (Scout, Dash, Coda) ready to clone and deploy.

Understand the runtime

Why AgentOS exists and the work it handles for you.