A knowledge base is a set of documents an agent searches before it answers. It is the difference between an assistant that improvises your refund policy and one that quotes it.
When you'd use it #
Policies
Refunds, warranties, delivery terms — the answers that must be exactly right and never invented.
Product detail
Specifications and compatibility that are too long for a prompt and change too often to hard-code.
Internal procedure
The written-down version of what your best agent knows, made available to the AI.
Setting one up #
-
Register an embedding model first
Ingestion cannot start without one. You can add it from this page if the dropdown is empty — see Providers & models. -
Create the collection
Name and describe it. Keep separate subjects in separate collections so searches stay sharp. -
Upload documents
Each document is processed into a searchable index. Processing runs in the background; a document is not searchable until it completes. -
Retry anything that failed
Failed documents can be retried individually rather than re-uploading the batch. -
Attach the collection to an agent
In the builder, enable knowledge and pick the collection. You can also tune how many passages are retrieved and how close a match has to be.
Getting good answers out of it #
| Field | What it does |
|---|---|
| Match count | How many passages are pulled in. More context, more cost, and more chance of a distracting passage. |
| Match threshold | How close a passage must be to count. Raise it if the agent quotes irrelevant material; lower it if it says it does not know when the answer is clearly in there. |
| Document structure | Short, well-headed documents retrieve far better than one enormous PDF. Split by subject before uploading. |
| Say so in the prompt | Tell the agent to answer only from retrieved material and to say when it cannot. Retrieval supplies facts; the prompt decides whether it sticks to them. |