# AgentOS Configuration (/agent-os/usage/extra-configuration)



You can pass extra configuration to your AgentOS with a YAML file. The example below sets quick prompts for an agent and a display name for the registered memory database.

## Configuration file [#configuration-file]

We will first create a YAML file with the extra configuration we want to pass to our AgentOS:

```yaml title="configuration.yaml"
chat:
  quick_prompts:
    basic-agent:
      - "What can you do?"
      - "How is our latest post working?"
      - "Tell me about our active marketing campaigns"
memory:
  dbs:
    - db_id: db-0001
      domain_config:
        display_name: Main app user memories
```

## Code [#code]

```python title="yaml_config.py"
"""Example showing how to pass extra configuration to your AgentOS."""

from pathlib import Path

from agno.agent import Agent
from agno.db.postgres import PostgresDb
from agno.knowledge.knowledge import Knowledge
from agno.models.openai import OpenAIResponses
from agno.os import AgentOS
from agno.team import Team
from agno.vectordb.pgvector import PgVector
from agno.workflow.step import Step
from agno.workflow.workflow import Workflow

# Get the path to our configuration file
cwd = Path(__file__).parent
config_file_path = str(cwd.joinpath("configuration.yaml"))

# Setup the database
db = PostgresDb(id="db-0001", db_url="postgresql+psycopg://ai:ai@localhost:5532/ai")

# Setup basic agents, teams and workflows
basic_agent = Agent(
    id="basic-agent",
    name="Basic Agent",
    db=db,
    enable_session_summaries=True,
    update_memory_on_run=True,
    add_history_to_context=True,
    num_history_runs=3,
    add_datetime_to_context=True,
    markdown=True,
)
basic_team = Team(
    id="basic-team",
    name="Basic Team",
    model=OpenAIResponses(id="gpt-5.2"),
    db=db,
    members=[basic_agent],
    update_memory_on_run=True,
)
basic_workflow = Workflow(
    id="basic-workflow",
    name="Basic Workflow",
    description="Just a simple workflow",
    db=db,
    steps=[
        Step(
            name="step1",
            description="Just a simple step",
            agent=basic_agent,
        )
    ],
)
basic_knowledge = Knowledge(
    name="Basic Knowledge",
    description="A basic knowledge base",
    contents_db=db,
    vector_db=PgVector(db_url="postgresql+psycopg://ai:ai@localhost:5532/ai", table_name="vectors"),
)

# Setup our AgentOS app
agent_os = AgentOS(
    description="Example AgentOS",
    agents=[basic_agent],
    teams=[basic_team],
    workflows=[basic_workflow],
    knowledge=[basic_knowledge],
    # We pass the configuration file to our AgentOS here
    config=config_file_path,
)
app = agent_os.get_app()


if __name__ == "__main__":
    """Run our AgentOS.

    You can see the configuration and available apps at:
    http://localhost:7777/config

    """
    agent_os.serve(app="yaml_config:app", reload=True)
```

<Note>
  Setting an `id` on the database, as the example above does, makes it easier to identify in the AgentOS interface.
</Note>

## Usage [#usage]

<Steps>
    <Step title="Set up your virtual environment">
      <CodeBlockTabs defaultValue="Mac">
        <CodeBlockTabsList>
          <CodeBlockTabsTrigger value="Mac">
            Mac
          </CodeBlockTabsTrigger>

          <CodeBlockTabsTrigger value="Windows">
            Windows
          </CodeBlockTabsTrigger>
        </CodeBlockTabsList>

        <CodeBlockTab value="Mac">
          ```bash
          uv venv --python 3.12
          source .venv/bin/activate
          ```
        </CodeBlockTab>

        <CodeBlockTab value="Windows">
          ```bash
          uv venv --python 3.12
          .venv\Scripts\activate
          ```
        </CodeBlockTab>
      </CodeBlockTabs>
    </Step>

  <Step title="Set Environment Variables">
    ```bash
    export OPENAI_API_KEY=your_openai_api_key
    ```
  </Step>

  <Step title="Install dependencies">
    ```bash
    uv pip install -U agno openai fastapi uvicorn python-multipart sqlalchemy pgvector "psycopg[binary]"
    ```
  </Step>

  <Step title="Setup PostgreSQL Database">
    ```bash
    # Using Docker
    docker run -d \
      --name agno-postgres \
      -e POSTGRES_DB=ai \
      -e POSTGRES_USER=ai \
      -e POSTGRES_PASSWORD=ai \
      -p 5532:5432 \
      pgvector/pgvector:pg17
    ```
  </Step>

  <Step title="Run Example">
    ```bash
    python yaml_config.py
    ```
  </Step>
</Steps>
