Knowledge collections
A prompt tells an agent how to behave. A collection tells it what is true about your business: the contracts, the product docs, the pricing page that changed last week. It searches them when it needs them, and pays nothing for them when it does not.
A named set of reference material
A collection groups documents an agent can search as one body. It carries a name, an optional description, its chunking settings, and a refresh schedule that decides how often URL-backed documents are re-indexed.
Manual is the default and means re-index only when asked. A file's content never changes, so the schedule only changes anything for URL-backed documents. Split collections by what an agent should be allowed to see rather than by topic: the collection is the unit you attach to an agent, so it is also the unit of access.
Three ways in, four states
A document arrives as an uploaded file, as a web URL, or captured from an email triage rule when an attachment lands in a watched mailbox. Whichever way it arrives, indexing runs in the background.
Each workspace's collections live on the Documents page in the superagnt app: create one there, then upload files or add URLs to it. A file can be a PDF, a DOCX, a CSV, or text such as Markdown or JSON. Mail is covered below.
| Status | Meaning |
|---|---|
pending | Queued. Nothing has been read yet. |
indexing | Being extracted, chunked and embedded. |
ready | Searchable. Only ready documents are returned by a search. |
error | The run failed. The document carries the reason. |
indexing is asynchronous
indexing and you poll until it reaches ready. Telling someone the knowledge base is live while it is still queued is how an agent ends up searching an empty collection.Individual documents can be re-synced or deleted without touching the rest of the collection.
The page is the source of truth
For a URL document, the indexed chunks are only a retrieval index. The document records where it came from and when it was last synced, and every search match from one is flagged live, with the instruction to re-read the source before relying on the detail. The agent then reads the live page rather than the stored copy, so a price that changed this morning is the price it quotes, even though the index was built last week.
Uploaded files are the opposite and are meant to be: a file is a snapshot, which is what you want for a signed contract.
The Documents card is the switch
Creating a collection does not give any agent access to it. The Documents card on an agent's Config tab is what puts a collection in that agent's search scope, and attaching one is what grants the agent its document tools. A search outside its bound collections is rejected.
From an MCP client the same binding is a config patch: agnt_agents_update_config with document_collection_ids. See building an agent.
The document tools are agnt_documents_search and agnt_documents_read, and only deployed agents have them; an MCP client searches with agnt_knowledge_search instead. Search is semantic, over one bound collection, and returns the best-matching chunks, each with its similarity score and the document it came from: id, name, kind, and the URL of a URL document. Read returns one document's current content by id, fetching a URL document's live page or extracting a file document's stored file, and refuses a document outside the agent's collections. It reads in three modes, so an agent loads only the lines it needs.
| Call | What comes back |
|---|---|
{ document_id } | A peek: the size in characters and lines, the page count of a PDF or the row count of a CSV, and the first 40 lines, up to 4,000 characters. |
{ document_id, query } | Only the lines that contain the query, matched on the server across the full text and ignoring case. Up to five lines of context each with context_lines, and 50 matches unless max_matches asks for up to 200. |
{ document_id, offset, limit } | A window of lines, 200 by default and up to 2,000, with the next_offset that starts the next window. |
Each fits a different question: search for what the documents say about something, grep for an exact figure, name or clause, and read a window only when a passage has to be read in order. The rest of a deployed agent's tools are on agent tools.
Filed, read in place, or sent
An email triage rule with the Save attachments action files a matching message's attachments into the collection the rule names. Each PDF, DOCX, CSV or text attachment, up to ten per message, is saved as a workspace file and added to the collection as a file document, then indexed like an upload. The email body is never saved. The action combines with the rule's others, which run in a fixed order: label, save attachments, archive, escalate.
Pick the collection in the rule editor on the Email page in the superagnt app. Over MCP, agnt_email_triage_create_rule (in the opt-in email family) takes save_to_documents among its actions with a document_collection_id, and agnt_email_triage_context lists the collections a rule can target. Attachments that would take the organization past a knowledge cap are skipped, and the rule's other actions still run.
Connecting a mailbox writes its starting triage rules, which take effect once you turn triage on for it. They include a rule that saves document attachments into a collection named Email Attachments, and your superagnt and the Inbox Manager are attached to that collection, so they can search whatever triage files. Retarget or delete that rule like any other.
An agent with a mailbox's tools can also read an attachment without filing it. connection_gmail_list_attachments and connection_outlook_list_attachments list a message's file attachments, and connection_gmail_read_attachment and connection_outlook_read_attachment read a PDF, DOCX, CSV or text attachment in the same three modes as agnt_documents_read.
Sending goes the other way. The save_draft, send_email, reply_all and forward_message tools of both mailboxes (connection_gmail_* and connection_outlook_*) take attachment_file_ids, the ids of workspace files: from agnt_files_upload for a new file, or from agnt_files_list for one already in the workspace, an attachment triage saved included. A message carries up to 20 files and 25 MB in all. A forward keeps the original's attachments and adds yours; on Gmail, when both together pass 25 MB, the original's are left off and listed in the result's omittedAttachments. On a deployed agent a send asks for approval by default, and the request names every attached file with its size.
The knowledge family
Six tools cover the whole loop: create a collection, add sources, wait for them to index, and check that the collection answers the questions the agent will be asked before you wire it on.
| Tool | What it does |
|---|---|
agnt_knowledge_list_collections | The workspace's collections with their chunking config and refresh schedule. Read-only. |
agnt_knowledge_create_collection | Creates a collection. Chunking defaults suit prose; raise the chunk size for reference tables and dense technical documents. |
agnt_knowledge_list_documents | The documents in a collection with their indexing status and last error. This is the poll target after adding one. |
agnt_knowledge_add_document | Adds a source and starts indexing it. Returns before indexing finishes. |
agnt_knowledge_ingest | Re-indexes a document that already exists, after its source changed or a previous run errored. |
agnt_knowledge_search | Semantic search over one collection, returning the best-matching chunks with their source document and similarity. |
- 01
Create, then add
Create the collection, then add each source to it by id. A URL document needs its URL; a file document needs a workspace file id from an upload. - 02
Poll before you trust it
List the documents until every one you added readsready. - 03
Search it yourself first
Run the questions your agent will be asked. If the chunks coming back are wrong, fix the chunking or the sources now, not after the agent has answered a customer with them.
What each plan holds
Knowledge is on every plan. The builder plans cap three things across the whole organization: how many collections exist, how many documents they hold, and the total size of the files behind those documents. The no-card trial runs on Growth limits.
| Plan | Collections | Documents | Storage |
|---|---|---|---|
| Starter | 3 | 500 | 2 GB |
| Growth | 15 | 5,000 | 20 GB |
| Scale | 50 | 25,000 | 100 GB |
hitting a cap
error with the plan limit as the reason. Everything already indexed stays searchable. Scheduled re-syncs pause while the organization is over its storage cap, and when a trial ends or a plan lapses; nothing is deleted, and they resume once the plan covers it.Indexing and search use no credits. See plans and limits and credits and wallets.