Documentation
Concepts
Core Concepts
Core Concepts
Data sources
A datasource is a named Git repository and a path within that repo. The CLI syncs repositories and ingests markdown files from these paths.
Ingestion pipeline
Ingestion consists of:
- Sync: clone or update a Git repository.
- Parse: extract markdown sections and headings.
- Chunk: split content into overlapping text chunks.
- Embed: send chunks to the embedding provider.
- Upsert: store embeddings and metadata in Postgres.
Hybrid retrieval
Queries are executed using both:
- Vector similarity (
pgvectorHNSW index) - Full-text rank (
tsvectorwithzhparserandwebsearch_to_tsquery)
Scores are blended using retrieval.alpha.
Reranking (optional)
If a reranker endpoint is configured, the candidate list is re-scored before final results.
Ask AI
/api/askai calls a chat completion endpoint. If the RAG service is initialized, it attaches retrieved chunks alongside the answer.
Feedback