Product
6 min read

Custom Knowledge Domains: A Complete Guide

Egret Team·

Knowledge domains are the foundation of Egret's RAG pipeline. Each domain represents a scoped collection of regulatory documents — think "HIPAA", "SOC 2", or "EU AI Act". By querying against a specific domain, you get precise, relevant answers rather than a generic response drawn from everything.

Creating a domain

Head to the Domains tab in your dashboard and click "Add Domain". Give it a name, an optional description, and choose a model tier (Standard or Advanced). The model tier determines which LLM is used for generation — Advanced uses a larger context window and more capable model at a higher credit cost.

Uploading documents

Each domain accepts PDF, DOCX, and plain text uploads. Egret automatically:

  • Extracts text and structure (headings, sections, tables)
  • Splits content into semantically meaningful chunks
  • Generates vector embeddings for similarity search
  • Indexes keywords for hybrid retrieval

Large documents are processed asynchronously. You'll see a progress indicator in the dashboard, and the domain status will change to "Ready" once indexing is complete.

Domain verification

For Enterprise plans, domains can be verified against a custom DNS record. This ensures that only authorised sources are used for retrieval. Add a TXT record to your DNS, and Egret will verify ownership within minutes.

Querying a domain

Every query in Egret is scoped to one or more domains. In the chat interface, select the domain from the dropdown. Via the API, pass the domain_id parameter to the /v1/query endpoint. The RAG pipeline will only retrieve passages from the selected domain's document collection.

Best practices

  • Keep domains focused — A domain scoped to "GDPR" will outperform a catch-all "All EU Regulations" domain.
  • Update regularly — Re-upload documents when regulations are amended to keep your index current.
  • Use descriptive names — Domain names appear in citations, so clarity helps your team trust the output.