Skip to main content
Steps: 1. Run SurrealDB in a container: ./cookbook/scripts/run_surrealdb.sh 2. Run the demo: python cookbook/agent_os/dbs/surreal_db/run.py
"""SurrealDB + AgentOS demo

Steps:
    1. Run SurrealDB in a container: `./cookbook/scripts/run_surrealdb.sh`
    2. Run the demo: `python cookbook/agent_os/dbs/surreal_db/run.py`
"""

from agents import agno_assist
from agno.os import AgentOS
from teams import reasoning_finance_team
from workflows import research_workflow

# ---------------------------------------------------------------------------
# Create Example
# ---------------------------------------------------------------------------

# ************* Create the AgentOS *************
agent_os = AgentOS(
    description="SurrealDB AgentOS",
    agents=[agno_assist],
    teams=[reasoning_finance_team],
    workflows=[research_workflow],
)
# Get the FastAPI app for the AgentOS
app = agent_os.get_app()
# *******************************

# ************* Run the AgentOS *************
# ---------------------------------------------------------------------------
# Run Example
# ---------------------------------------------------------------------------

if __name__ == "__main__":
    agent_os.serve(app="run:app", reload=True)
# *******************************

Run the Example

# Clone and setup repo
git clone https://github.com/agno-agi/agno.git
cd agno/cookbook/05_agent_os/dbs/surreal_db

# Create and activate virtual environment
./scripts/demo_setup.sh
source .venvs/demo/bin/activate

python run.py