Search & query
How Vessios answers questions with a four-layer retrieval pipeline.
Every question you ask goes through a four-layer pipeline designed to answer fast when possible, and generate a grounded answer when needed.
Layer 0 — Query classification
Every query is classified first, so the system knows which retrieval strategy to use before doing any real work.
Semantic cache
If a semantically similar question has already been answered, the cached answer can be returned immediately.
Hybrid search
Vector search and keyword (BM25) search run together and are combined with Reciprocal Rank Fusion (RRF) to find the most relevant wiki pages.
RAG answer generation
The retrieved pages are assembled into context and an answer is generated. Good answers are written back into the wiki, compounding the knowledge base for future queries.
Streaming
Ask a question via the streaming endpoint (GET /query/stream) to receive the answer over Server-Sent Events as it’s generated, or use the synchronous endpoint (POST /query/sync) if you need the complete answer in a single response.
Answer quality safeguards
- Lost-in-the-middle mitigation — the most important evidence is placed at the start and end of the context window, where LLMs pay the most attention.
- Optional reranking — an additional reranking stage can be enabled to further improve result ordering before generation.
- Prompt caching — for context and hybrid query modes, the assembled context is cached to reduce latency and cost on related follow-up queries.
- Feedback loop — every answer can be rated via
POST /query/{query_id}/feedback, feeding back into wiki quality over time.
Wiki mode vs. RAG mode
Vessios automatically resolves whether to lean on the accumulated wiki or fall back to broader retrieval, based on how much your wiki has grown for a given topic. You can check the current mode for your tenant via GET /wiki/mode.
Search API
Besides conversational query, you can search wiki pages directly:
POST /pages/search— hybrid search over wiki pages.GET /pages— list pages.GET /pages/{page_id}/backlinks— see what links to a page.
See the API reference for full request/response schemas.