Codebase RAG Sage is your AI-powered assistant for exploring and understanding codebases. It merges Retrieval-Augmented Generation (RAG) with Streamlit, Pinecone, and Groq’s LLaMA models to deliver contextual, code-aware answers to your queries.
- Conversational Code Exploration – Ask anything about your codebase in natural language and get informed responses grounded in actual source files.
- Semantic Search – Powered by embeddings (via
HuggingFaceEmbeddings
), for smarter, context-aware retrieval. - Namespace-Based Code Indexing – Handle multiple repositories, each with a distinct namespace in Pinecone.
- Streamlit Web Interface – Elegant and intuitive UI for all your codebase queries.
(Here you can show how the app looks—like the input field, cloned repo display, and Q&A section.)
git clone https://github.com/rahatmoktadir03/codebase-rag-sage.git
cd codebase-rag-sage
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -r requirements.txt
- Create a .env file or export these:
export PINECONE_API_KEY=your_pinecone_api_key export GROQ_API_KEY=your_groq_api_key
import pinecone
pinecone.init(api_key="YOUR_KEY")
pinecone.create_index("codebase-rag", dimension=768)