Spaces:
Runtime error
Runtime error
metadata
title: RAG-Document-System
sdk: docker
RAG Document System
A simple document interaction system using Retrieval-Augmented Generation (RAG) with Streamlit and Google's Gemini AI.
Features
- Upload text documents (.txt files)
- Ask questions about your documents
- Get AI-powered answers with source citations
- Persistent vector database storage
- Clean web interface
Setup
With Docker (Recommended)
- Clone the repository:
git clone https://github.com/tusiim3/RAG-Document-System.git
cd RAG-Document-System
- Copy
.env.example
to.env
and add your Google API key:
cp .env.example .env
- Run with Docker Compose:
docker-compose up --build
- Open http://localhost:8501 in your browser
Without Docker
- Clone the repository:
git clone https://github.com/tusiim3/RAG-Document-System.git
cd RAG-Document-System
- Install dependencies:
pip install -r requirements.txt
- Copy
.env.example
to.env
and add your Google API key:
cp .env.example .env
- Run the application:
streamlit run app.py
- Open http://localhost:8501 in your browser
Environment Variables
Required in .env
file:
GOOGLE_API_KEY
- Your Google API key for GeminiCHUNK_SIZE
- Text chunk size (default: 1000)CHUNK_OVERLAP
- Chunk overlap (default: 200)EMBEDDING_MODEL
- Embedding model nameLLM_TEMPERATURE
- AI response temperature (default: 0.3)
Usage
- Upload a text document using the file uploader
- Wait for document processing to complete
- Ask questions about the document in the chat interface
- View source documents for each answer
Technology Stack
- Streamlit for web interface
- LangChain for document processing
- ChromaDB for vector storage
- Google Gemini for AI responses
- Docker for containerization