Skip to content

An AI-powered Q&A assistant for developers that answers natural language queries about a codebase by combining large language models, vector search, and GitHub integration.

Notifications You must be signed in to change notification settings

kruth-s/AI-Code-Navigator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 

Repository files navigation

AI-Code-Navigator

An AI-powered Q&A assistant for developers that answers natural language queries about a codebase by combining large language models, vector search, and GitHub integration.

Overview

This Q&A Bot is an AI-powered assistant designed to help developers query large codebases efficiently. By combining large language models (LLMs) with vector search technologies, the system provides precise answers to natural language questions about repository contents. It integrates directly with GitHub Issues and Pull Requests, enabling context-aware discussions and automated responses.


Features

  • Natural Language Querying
    Ask questions such as "Where is the login function implemented?" or "Which files handle database connections?"

  • Semantic Code Search
    Uses vector embeddings (via FAISS or Pinecone) to retrieve relevant code snippets.

  • LLM-Powered Responses
    Generates context-aware explanations and summaries of relevant code sections.

  • GitHub Integration
    Responds directly to questions in Issues and Pull Requests through the GitHub API.

  • Scalable Architecture
    Designed to work with both small projects and enterprise-scale repositories.


Architecture

  1. Code Embedding

    • Repository files are parsed and converted into embeddings using a pre-trained model.
    • Embeddings are stored in a vector database (FAISS or Pinecone).
  2. Query Processing

    • Developer submits a natural language query.
    • The query is embedded and matched against the code embeddings.
  3. Answer Generation

    • Relevant code snippets are retrieved.
    • An LLM processes the context and generates a natural language answer.
  4. GitHub Integration

    • Bot listens to Issues and PR comments.
    • Answers are posted automatically to the relevant discussion thread.

Tech Stack

  • Backend: Python (FastAPI or Flask)
  • Vector Database: FAISS (local) or Pinecone (cloud)
  • LLM: OpenAI API or Hugging Face Transformers
  • GitHub Integration: GitHub REST/GraphQL API
  • Task Queue (Optional): Celery / Redis for background jobs

Installation

Prerequisites

  • Python 3.9+
  • Access to an LLM API key (OpenAI / Hugging Face)
  • GitHub personal access token
  • FAISS or Pinecone account

Setup

# Clone repository
git clone https://github.com/your-username/codebase-qa-bot.git
cd codebase-qa-bot

# Create virtual environment
python -m venv venv
source venv/bin/activate   # Linux/Mac
venv\Scripts\activate      # Windows

# Install dependencies
pip install -r requirements.txt

About

An AI-powered Q&A assistant for developers that answers natural language queries about a codebase by combining large language models, vector search, and GitHub integration.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages