> For the complete documentation index, see [llms.txt](https://docs.lleverage.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.lleverage.ai/operator-agent/knowledge-bases.md).

# Knowledge Bases

Knowledge bases let the agent search through your uploaded documents and reference materials to find relevant information. Whether it's product catalogues, policy documents, technical manuals, or historical data — if it's in a knowledge base, the agent can find and use it.

### How the Agent Uses Knowledge Bases

When a knowledge base is available (either directly in the project or through a skill), the agent can query it using vector search. This means:

* The agent searches by **meaning**, not just keywords — asking about "delivery timelines" will find content about "shipping schedules" even if those exact words aren't used.
* Results are **ranked by relevance** and the agent uses the most relevant content to inform its response.
* The agent **cites its sources** so you can verify where information came from.

### Adding Knowledge to the Agent

There are a few ways to grow what the agent can look up:

* **Project knowledge bases** - Knowledge bases in your project are available to the agent in chat.
* **Through skills** - Add a knowledge base as a component of a skill, so the skill always has its reference material to hand.
* **From the agent's own output** - When the agent generates a useful file in a session, you can save it straight to a knowledge base so it's findable in future sessions.

For details on creating and managing knowledge bases themselves, see [Knowledge Bases](/platform/knowledge-bases.md) in the Platform section.

### What to Put in a Knowledge Base

Knowledge bases work best with:

* **Reference documents** — Product specs, pricing lists, policy documents, SOPs
* **Historical data** — Past orders, reports, templates
* **Domain knowledge** — Industry standards, regulatory requirements, technical manuals
* **FAQs and guides** — Common questions and their answers

#### Supported Document Types

* PDF (including scanned documents with OCR)
* Word documents (.docx)
* Spreadsheets (CSV, .xlsx)
* JSON, XML
* HTML
* Plain text

### Knowledge Bases in Skills

A skill can include one or more knowledge bases as components. This is useful because:

* The knowledge base is **scoped to the skill's purpose** — the agent queries it in the right context
* You can **version and manage** knowledge alongside the skill's instructions
* Different skills can use **different knowledge bases** for different tasks

For example, an order processing skill might include a product catalogue knowledge base, while a customer support skill might include a FAQ knowledge base.

### Tips

* **Keep knowledge bases focused.** A smaller, relevant knowledge base performs better than a large, general one.
* **Update regularly.** If your reference data changes (new pricing, updated policies), update the knowledge base so the agent has current information.
* **Use descriptive document names.** This helps both you and the agent understand what's in the knowledge base.
* **Feed good outputs back in.** Saving the agent's best reports and summaries to a knowledge base builds a growing library it can draw on.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.lleverage.ai/operator-agent/knowledge-bases.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
