The two-step loop, concretely
When a visitor asks "do you offer refunds?", a RAG chatbot doesn't ask the model to remember anything. It (1) retrieves: searches an index of your pages and documents for the passages most relevant to refunds, and (2) generates: hands those passages to the model with strict instructions — answer from this context, cite it, and say so if it isn't enough. The model becomes a reader and summarizer of your content, not an author of plausible fiction.
How retrieval actually finds the right passages
Flocci Chat's retrieval is hybrid: vector search (embeddings in PostgreSQL's pgvector, matching by meaning, so "money back" finds your refund policy) combined with full-text search (matching exact words like product names and error codes), then diversity reranking (MMR) so the context isn't five copies of the same paragraph. Content enters that index automatically — an onboarding crawl plus passive learning of each page as real visitors open it, JavaScript-rendered pages included.
Why RAG alone isn't enough: the confidence gate
Retrieval can come back weak — the visitor's question may simply not be answered anywhere on your site. A trustworthy RAG chatbot must notice that. Flocci Chat scores retrieval confidence on every turn and routes low-confidence turns to a clarifying question ("are you asking about credit cards or bank transfers?") or a human handoff with a built-in support ticket — never to a confident guess. Answered turns stream with source citations a visitor can check. More on this in chatbots that cite their sources.
RAG chatbot vs "training a chatbot on your data"
Marketing pages say "train the AI on your website", but almost no product fine-tunes a model on your content — that would be slow, expensive and stale by tomorrow. What good products do is RAG: index your content and reference it at answer time. The practical questions to ask any vendor are: how does content get into the index (can it see JS-rendered pages? does it re-learn changes?), what happens on weak retrieval (clarify/handoff, or bluff?), and are sources shown. Those three questions are the whole trust story.