GUIDES
The knowledge base
Give the agent something to read. Upload your docs once, and every answer is grounded in them.
Upload docs in the console
Open your project, go to Knowledge, and drop files in. EERRAA splits each document into chunks, embeds them, and stores the vectors alongside the raw text. Indexing runs in the background. A doc goes live for retrieval the moment its job finishes, usually a few seconds after upload.
Everything you upload in the console lands in the shared project pool. Every visitor to your widget can be answered from it. Product docs, policies, FAQs, pricing, release notes, put whatever you want the agent to know here.
| Field | Type | Description |
|---|---|---|
Supported types | PDF / TXT / MD | Text is extracted, then chunked. Scanned image-only PDFs have no text to pull. |
File size | <= 50 MB | Per file. Larger files are rejected with FILE_TOO_LARGE. |
Per-user cap | 20 docs | Applies to private per-user uploads (below), not to the shared console pool. |
Languages | ar / en / mixed | Embeddings are multilingual, so an Arabic question can match English source text and back. |
How retrieval works
EERRAA does not just do a vector lookup. Every question runs through hybrid retrieval, so you get the recall of embeddings and the precision of keyword search at the same time.
| Field | Type | Description |
|---|---|---|
Vector search | pgvector | Cosine similarity over BAAI/bge-m3 embeddings (1024-d), top-K candidates. |
Keyword search | Postgres FTS | Full-text search over the same chunks, so exact terms and product names are not missed. |
Fusion | weighted | The two candidate sets are merged with a weighted score into one ranked list. |
Rerank | cross-encoder | A cross-encoder re-scores the merged list against the actual question. |
Threshold | 0.30 | Chunks below the relevance floor are dropped, so a weak match adds nothing. |
Injected | top 4 chunks | The best four surviving chunks are placed in context before the model answers. |
The upshot: when your docs contain the answer, it lands in context. When they do not, nothing crosses the 0.30 floor and the agent answers from the model instead of inventing a citation.
rag_retrieve event with the chunks it pulled and their scores, so you can see exactly what the agent read before it answered.Private per-user uploads
Retrieval runs against audiences. The shared project pool answers everyone. A privateuser:<id> pool answers only that one person. That is how you let a customer upload their own contract or spreadsheet and have the agent reason over it, without leaking it to the next visitor.
Private uploads go through the API, not the console, and they require signed identity so the file is bound to a real user you vouched for. Post the file and the signed user_context as multipart form data.
/v1/knowledgecurl -X POST https://eerraa.online/v1/knowledge \
-H "Authorization: Bearer era_your_project_key" \
-F "file=@contract.pdf" \
-F 'user_context={"id":"u_123","_ts":1735689600,"_sig":"<hmac>"}'The call returns immediately while indexing runs in the background:
{
"job_id": "kb_9f2c...",
"status": "processing",
"filename": "contract.pdf"
}List or delete a user's own docs with the same signed identity:
/v1/knowledge/v1/knowledgeSIGNED_IDENTITY_REQUIRED. Each user gets 20 docs; the 21st returns DOC_CAP_REACHED, and an unsupported file returns UNSUPPORTED_TYPE.