Chat with Wikipedia
Project description
RAG-demo
Chat with (a small portion of) Wikipedia
⚠️ RAG functionality is still under development. ⚠️
Requirements
- uv
- At least one of the following:
- A suitable terminal emulator. In particular, on macOS consider using iTerm2 instead of the default Terminal.app (explanation). On Linux, you might want to try kitty, wezterm, alacritty, or ghostty instead of the terminal that came with your DE (reason). Windows Terminal should be fine as far as I know.
- Any common web browser
Optional stuff that could make your experience better
- Hugging Face login
- API key for your favorite LLM provider (support coming soon)
- Ollama installed on your system if you have a GPU
- Run RAG-demo on a more capable (bigger GPU) machine over SSH if you can. It is a terminal app after all.
Run from the repository
First, clone this repository. Then, run one of the options below.
Run in a terminal:
uv run chat
Or run in a web browser:
uv run textual serve chat
Run from the latest version on PyPI
TODO: test uv automatic torch backend selection: https://docs.astral.sh/uv/guides/integration/pytorch/#automatic-backend-selection
Run in a terminal:
uvx --from=jehoctor-rag-demo chat
Or run in a web browser:
uvx --from=jehoctor-rag-demo textual serve chat
CUDA acceleration via Llama.cpp
If you have an NVIDIA GPU with CUDA and build tools installed, you might be able to get CUDA acceleration without installing Ollama.
CMAKE_ARGS="-DGGML_CUDA=on" uv run chat
Metal acceleration via Llama.cpp (on Apple Silicon)
On an Apple Silicon machine, make sure uv runs an ARM interpreter as this should cause it to install Llama.cpp with Metal support.
Ollama on Linux
Remember that you have to keep Ollama up-to-date manually on Linux. A recent version of Ollama (v0.11.10 or later) is required to run the embedding model we use. See this FAQ: https://docs.ollama.com/faq#how-can-i-upgrade-ollama.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file jehoctor_rag_demo-0.2.0.tar.gz.
File metadata
- Download URL: jehoctor_rag_demo-0.2.0.tar.gz
- Upload date:
- Size: 15.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fd8c4c9ace48478709eea38429de016fdea37400332b05b9c9d9b7fffa7efbe1
|
|
| MD5 |
a451fd5d67c4413a111bdf79bf994f0b
|
|
| BLAKE2b-256 |
d67a7e4d74ed3ba8bd4505517d10c60dd193b6cea07abf693c66bbb695879917
|
File details
Details for the file jehoctor_rag_demo-0.2.0-py3-none-any.whl.
File metadata
- Download URL: jehoctor_rag_demo-0.2.0-py3-none-any.whl
- Upload date:
- Size: 20.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d089d9ecf18faf0329f995530d1b4bae569f10b76da5b5a6598dbe049e06da66
|
|
| MD5 |
08201c8731db907450c9c7e388e67de9
|
|
| BLAKE2b-256 |
ad89d5384393e74b63f56bc3c3ab2bb3c60e309772abbdb32a976f2343d61410
|