Skip to main content
The AgentOS control plane provides a simple way to manage your Knowledge bases. You can add, edit, and delete content from your Knowledge bases directly through the control plane. You can specify multiple Knowledge bases and reuse the same Knowledge instance across different Agents or Teams as needed.

Prerequisites

Before setting up Knowledge management in AgentOS, ensure you have: The example below uses PostgreSQL (with pgvector) and OpenAI embeddings. Swap in any supported vector database or embedder.

Example

The example below attaches multiple Knowledge bases to AgentOS and populates them with content from different sources.
agentos_knowledge.py

Screenshots

The screenshots below show how you can access and manage your different Knowledge bases through the AgentOS interface: llm-app-aidev-run

Knowledge ID

Each Knowledge instance registered with AgentOS gets a deterministic knowledge_id. It is a SHA256 hash of {db_id}:{knowledge_table}:{name} (contents-database id, knowledge_table name, instance name), formatted as a UUID-shaped string (8-4-4-4-12 hex). If the instance has no name, AgentOS substitutes knowledge_{db_id}. The same inputs always produce the same ID, so it is stable across restarts. Use knowledge_id in API calls to target a specific Knowledge instance:
For uploads from S3, GCS, SharePoint, GitHub, or Azure Blob (including source_params and S3 file browsing), see Remote Content.

Finding your Knowledge ID

The root /config endpoint returns the full AgentOS configuration, including a knowledge.knowledge_instances list with the ID, name, and database details for every registered Knowledge instance:

Backward compatibility

If you have a single Knowledge instance, you can omit knowledge_id from API calls. AgentOS will route to it automatically. For multiple instances, you can also use the db_id query parameter, but knowledge_id is preferred as it uniquely identifies the instance even when multiple instances share the same database.

Best Practices

  • Separate Knowledge by Domain: Create separate Knowledge bases for different topics (e.g., technical docs, FAQs, policies)
  • Consistent Naming: Use descriptive names for your Knowledge bases that reflect their content
  • Regular Updates: Keep your Knowledge bases current by regularly adding new content and removing outdated information
  • Monitor Performance: Use different table names for vector storage to avoid conflicts
  • Content Organization: Use the name parameter when adding content to make it easily identifiable
  • Use metadata for filtering and searching: Add metadata to your content to make it easier to find and filter

Troubleshooting

Ensure your knowledge base is properly added to the knowledge parameter when creating your AgentOS instance. Also make sure to attach a contents_db to your Knowledge instance.
Verify your PostgreSQL connection string and ensure the database is running and accessible.
Check that your content has been properly embedded by verifying entries in your vector database table.