Content and knowledge
Products, the Knowledge pipeline from upload to searchable chunks, how search works and what changing the embedding model does, and templates with their variables.
The content module holds what the agent and campaigns write from: products, the Knowledge documents attached to them, and templates. It also lists CSV import jobs, which are described on CRM.
Products
A product is something the workspace sells. Knowledge documents, fit criteria, campaigns and deals hang off it. Its name and description are shown to the agent when it decides which product a conversation is about. A product can have its own AI account and model, and it lists the sending accounts that sell it.
- Creating a product also creates its default fit criteria (profile, BANT and engagement) in the same transaction.
- Deleting a product hides it and switches its fit criteria off, and deletes its documents, their chunks and their files for real.
- The products a conversation is about are those linked to the account that received the message (all products when none are linked), narrowed to the products of a campaign the person is in or entered in the last 30 days.
Knowledge pipeline
A Knowledge document is read once, when it is added, and split into chunks. Each chunk carries a vector from the workspace’s embedding model, and search compares the vector of a question with those.
The file is stored and the document is created as pending, then an event hands it to the pipeline. The upload answers at once, before the file is read. A document can also be created from pasted text.
A workspace without an embedding model cannot ingest anything; its documents fail at once.
Any error during reading, summarising or embedding marks the document as failed with the error message. The pipeline does not retry. A failed document stays failed until it is uploaded again or the workspace changes its embedding model.
The app shows the states as Reading…, Ready and Can’t read. A document still pending or processing after 10 minutes is shown as Waiting, and the app stops polling it.
Editing a document’s text or summary in the app saves the new text without splitting or embedding it again, so search keeps returning the old text.
Vectors and search
Vectors of any size are kept side by side, and each chunk records the model and the size that made it. Approximate nearest-neighbour indexes exist for 384, 768, 1,024 and 1,536 dimensions. Larger vectors (3,072) are searched without an index, because the index type stops at 2,000 dimensions. Lead memories have vectors too, with no index: recall reads the few memories of one person.
A search embeds the question, then reads the closest chunks that belong to the workspace, were made by the workspace’s current model and size, and belong to a product that has not been deleted, optionally limited to some products. It returns 5 chunks by default. Many workspaces share one index, so the index scan is allowed to keep going past chunks the filter drops, and a workspace still gets its 5 results.
Each result carries the document name, the product name and the page. The agent stores these as sources on its reply, which is how the Inbox can show “Deployment guide.pdf · p.4”. The Knowledge page’s search box uses the same search as the agent; see AI agent.
Changing the embedding model
Vectors from two models cannot be compared, and search reads only chunks made by the current model. When a workspace switches to another embedding model or another AI account for it, two things happen:
- Every document embedded with another model is set back to pending and sent through the pipeline again.
- The workspace’s lead memories are embedded again.
Until a document has been embedded again, search does not return it.
Downloads and deletion
The original file of a document can be downloaded and opens in the browser. Deleting a document deletes it, its chunks and the stored file.
Templates
A template is an email (subject and body), a plain text, or a prompt. A prompt has two parts: a fixed part the model provider can cache, and a part that changes on every request.
The prompts the product ships with live in code: the reply agent’s prompt, the queries it writes to search Knowledge, lead scoring, the campaign generator, the image description and document summary used by the Knowledge pipeline, and the attachment picker. A follow-up prompt for people who have not answered also ships, and no code uses it today.
The template list shows a workspace’s own templates and every shipped template it has not changed. Editing a shipped template creates a copy for that workspace, which takes over from the shipped one; deleting the copy brings the shipped version back. Code that needs a template takes the workspace’s copy first, then the shipped template, and fails when neither exists. A test send renders a template with sample values and sends it once through an email account.
Variables
One renderer fills every template, campaign step input, subject line, prompt and preview. A token looks like {{ customer.firstName | default: "there" }}: a namespace, a field, and optional filters.
| Namespace | Holds |
|---|---|
contact | The person’s email and phone, from the most recent channel that has not opted out |
customer | The person: first, last and full name, job title, industry, location, description, research, source |
company | Name, domain, industry, size, description |
org | The workspace name and booking link |
nodes | Outputs of earlier campaign steps |
runtime | Values passed in by the caller, such as prompt inputs |
The filters are default, upper, lower, capitalize, truncate, date and trim. Older single-word tokens such as {{firstName}} still work through an alias table. The campaign editor reads the list of fields, each with a sample value, from the backend.
A token that cannot be filled depends on why the text is rendered:
| Rendered for | An unfilled token becomes |
|---|---|
| Sending | Nothing |
| Preview | A visible placeholder, or nothing when the token has a filter |
| A prompt | Nothing for a bare word. A dotted or filtered token is never filled in a prompt and stays as written, so syntax examples inside a prompt reach the model. |
A token that is the whole text and has no filter keeps its type, so a number stays a number. Values are inserted without HTML escaping. The email client turns line breaks in the body into HTML line breaks and sends the body as HTML.
Email images
Images uploaded for emails (at most 5 MB; JPEG, PNG, GIF, WebP or SVG) get a public URL. They are served to anyone, with permanent caching and a content policy that keeps an SVG opened on its own from running script.