LightRAG Exploration
LightRAG Exploration is a Python FastAPI application for exploring Retrieval-Augmented Generation (RAG) workflows. It provides a modern web interface for chat, graph visualization, and RAG experimentation using local LLMs via Ollama. The app is designed for easy local use and sharing as a pipx CLI tool.
Features
- RAG Chat: Interact with a RAG pipeline using your own documents and local LLMs.
- Classic Chat: Simple chat interface with model selection and context summarization.
- Graph Viewer: Visualize the entity/relation graph extracted from your research data.
- Modern Web UI: Clean, responsive interface built with Tailwind CSS.
- Easy Setup: Installable as a pipx CLI for global use.
- Ollama Integration: Uses Ollama for local LLM inference and embeddings.
- Configurable: Uses
.envfor research output directory and Ollama host.
Prerequisites
- Python 3.9+
- pipx
- Ollama installed and running with required models (e.g.
gemma3:1b,nomic-embed-text:latest)
Install system dependencies (macOS example)
brew install pipx
pipx ensurepath
source ~/.zshrc # or restart your terminal
Install with pipx
pipx install lightrag-exploration
Usage
- The API will run on http://localhost:8080 by default.
- Open your browser and navigate to:
/frontend— Home page/frontend/chat— Classic chat interface/frontend/rag-chat— RAG chat interface/frontend/graph-viewer— Graph visualization/docs— FastAPI API docs
How It Works
- RAG Pipeline: Uses LightRAG and Ollama for retrieval, embedding, and LLM completion.
- Templates: Web UI is served from the
templates/directory. - Config: Set
research_output_dirandollama_hostin.envor.env.example.
Development
- All source code is in the root and
routers/directory. - The entrypoint is
main.py, which runs the FastAPI app. - You can run locally with:
python main.py - Or install and run globally with pipx as above.
Test your pipx build locally before uploading to PyPI!
You can install your built wheel or sdist with pipx to verify everything works as expected:
python -m build
pipx install --force dist/lightrag_exploration-0.1.0-py3-none-any.whl
# or
pipx install --force dist/lightrag_exploration-0.1.0.tar.gz
lightrag-exploration
pipx uninstall lightrag-exploration
Packaging & Distribution
To build and publish to PyPI:
- Upgrade build and twine:
python -m pip install --upgrade build twine
- Build your package:
python -m build
- (Optional) Check your package:
python -m twine check dist/*
- Upload to PyPI:
python -m twine upload dist/*
Troubleshooting
- If you see errors about missing templates, ensure you installed with pipx after running
pipx ensurepathand that your terminal session is up to date. - Make sure Ollama is running and the required models are pulled.
- If you see errors about missing research output, check your
.envand that the directory exists.
License
MIT
Metadata
Release files for lightrag-exploration 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| lightrag_exploration-0.1.1.tar.gz | 11.9 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| lightrag_exploration-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 28.5 kB
Release files / lightrag_exploration-0.1.1.tar.gz
| Download URL | lightrag_exploration-0.1.1.tar.gz |
|---|---|
| Size | 11.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
719e2953a8d55157669f3409e7bcd75e6b553a4bfa24a5dade1bec4681abb2a7
|
|
BLAKE2b-256 checksum How to use checksums |
a87bc796768cc6a694b210c2cf2f20c4ec6dfb57f5f436c6ab030da294d2c732
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.9
|
Release files / lightrag_exploration-0.1.1-py3-none-any.whl
| Download URL | lightrag_exploration-0.1.1-py3-none-any.whl |
|---|---|
| Size | 16.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9c4f1c299f6be1745ea4f4dba50268578994735b6c3404b893013646adb19d2f
|
|
BLAKE2b-256 checksum How to use checksums |
1358a16aa9c12e098f40a5d554095c1aff88ff7ab3efd89dc88e1370a9c9ddff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.9
|
Security for lightrag-exploration 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.