This project is a simple GenAI LLM application that uses Retrieval-Augmented Generation (RAG) to help students answer questions based on stored study materials.
- The app retrieves relevant study materials from a vector database.
- It uses OpenAI's GPT-3 (or GPT-4) to generate responses based on these materials.
-
Clone the repository:
git clone <repo-link>
-
Install the required libraries:
pip install -r requirements.txt
-
Set your OpenAI API key:
- In
app.py
, replace'your-openai-api-key'
with your OpenAI API key.
- In
-
Run the application:
python app.py
-
You can send POST requests to
http://localhost:5000/ask
with a JSON body like:{ "question": "What is photosynthesis?" }
-
The app will return a generated answer based on the context it retrieves from stored materials.