WikiChat grounds large language model replies on retrieved Wikipedia and custom corpus text to reduce factual errors. It supports many LLM backends and optional web deployment.
Overview
WikiChat is a retrieval-augmented chatbot pipeline aimed at making LLM answers more factual by grounding them on external text, especially Wikipedia. It uses a multi-stage flow with several LLM calls to check, retrieve, and compose responses, and can add inline citations in the final answer.
By default it can query many Wikipedias through a rate-limited search API, or you can build and host your own vector index from Wikipedia dumps or custom documents. Retrieval can include structured blocks such as tables, infoboxes, and lists, not only plain article text.
You configure which LLM to use through a YAML file and API keys, with support for hosted APIs and local models. Redis Stack via Docker is used in the default setup. You can run conversations in the terminal or optionally deploy a Chainlit web front end with conversation storage.
The project also offers preprocessing scripts for Wikipedia, indexing with embedding models and Qdrant, distilled models for lower latency, and LangChain compatibility for integrators building their own interfaces.
Key features
- Multi-stage grounded generation
- Wikipedia and custom retrieval
- Many LLM provider options
- Multilingual Wikipedia search
- Structured data retrieval
- Inline response citations
- Terminal and Chainlit UI
- LangChain compatible
Use cases
- Factual question answering
- Research assistant prototypes
- Custom document Q&A
- Multi-user chat deployment
- RAG experimentation