RAGdash is a Python-based RAG (Retrieval-Augmented Generation) system designed to seamlessly generate SQL queries and retrieve data through natural language prompts. By combining the power of natural language processing and data querying, RAGdash simplifies database interactions, making it easier for users to extract insights using conversational queries.
RAGdash allows users to interact with their MySQL databases using natural language prompts. The project leverages Retrieval-Augmented Generation (RAG) to map these prompts to SQL queries, offering a more intuitive interface for non-technical users to extract, analyze, and manipulate data from their databases. Users can ask questions about their data, and RAGdash will automatically generate and execute the SQL queries, returning relevant results.
Make sure your system has Python and pip installed. You can verify the installation by running:
python --version
pip --version
Clone the repository:
git clone https://github.com/techcodebhavesh/RAGdash.git
cd RAGdash
Install the required Python packages:
pip install -r requirements.txt
Install MySQL locally, or ensure you have access to a remote MySQL instance. If using a local MySQL instance, you can install it on Linux with:
sudo apt install mysql-server
Set up a MySQL database and create a table for the program to interact with.
Create a .env
file in the root directory with the following content:
GROQ_API_KEY=<groq_api_key>
DB_HOST="localhost"
DB_USER="root"
DB_PASSWORD="Password"
DB_NAME="sakila"
Replace DB_USER
, DB_PASSWORD
, and DB_NAME
with your actual MySQL credentials and database details.
Once the setup is complete, you can launch the RAGdash application by running the following command:
streamlit run app.py
This will launch the web interface for interacting with the database using natural language prompts.
Feel free to contribute to RAGdash by submitting pull requests. Any improvements in code structure, features, or documentation are welcome.
This project is licensed under the MIT License.