A simple package for implementing RAG
Project description
GRAG - Good RAG
GRAG is a simple python package that provides an easy end-to-end solution for implementing Retrieval Augmented Generation (RAG).
The package offers an easy way for running various LLMs locally, Thanks to LlamaCpp and also supports vector stores like Chroma and DeepLake. It also makes it easy to integrage support to any vector stores easy.
Table of Content
Project Overview
- A ready to deploy RAG pipeline for document retrival.
- Basic GUI (Under Development)
- Evaluation Suite (Under Development)
- RAG enhancement using Graphs (Under Development)
Getting Started
To run the projects, make sure the instructions below are followed.
Further customization can be made on the config file, src/config.ini
.
git clone
the repositorypip install .
from the repository (note: add - then change directory to the cloned repo)- For Dev:
pip install -e .
Requirements
Required packages to install includes (refer to pyproject.toml):
- PyTorch
- LangChain
- Chroma
- Unstructured.io
- sentence-embedding
- instructor-embedding
LLM Models
To quantize model, run:
python -m grag.quantize.quantize
For more details, go to .\llm_quantize\readme.md Tested models:
- Llama-2 7B, 13B
- Mixtral 8x7B
- Gemma 7B
Model Compatibility
Refer to llama.cpp Supported Models (under Description) for list of compatible models.
Supported Vector Databases
1. Chroma
Since Chroma is a server-client based vector database, make sure to run the server.
- To run Chroma locally, move to
src/scripts
then runsource run_chroma.sh
. This by default runs on port 8000. - If Chroma is not run locally, change
host
andport
underchroma
insrc/config.ini
.
2. Deeplake
For more information refer to Documentation.
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
File details
Details for the file grag-0.0.1b0.tar.gz
.
File metadata
- Download URL: grag-0.0.1b0.tar.gz
- Upload date:
- Size: 29.6 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-httpx/0.27.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b4bffd9f02e2e6af16b91185dac29a0746112547c99b4cef039eef5c34a1c94b |
|
MD5 | e4f316a708384c3dcef3a510803a6897 |
|
BLAKE2b-256 | cdbc47d15e52084e60b5ba6d29d6815ae1aef78d626263c5ed73e4b81aec2b04 |
File details
Details for the file grag-0.0.1b0-py3-none-any.whl
.
File metadata
- Download URL: grag-0.0.1b0-py3-none-any.whl
- Upload date:
- Size: 51.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-httpx/0.27.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3e39865364c6a1afc2f184a34e29f9e055a34c7fb6b47ff75865c900fa5d34a7 |
|
MD5 | 254f299a17db1feb77fb37d4645b24cd |
|
BLAKE2b-256 | 1355c5fc4bc684d57b181298f4e33c3a0980e66a1b7a36e0626719a0e4256543 |