Code Atlas is an agentic engineering assistant designed to index your entire GitHub portfolio and answer natural-language questions about your codebase, complete with file and line-level citations.
Unlike typical "chat with your codebase" tools that focus on a single repository, Code Atlas is built to ingest and understand a portfolio of repositories at once. It automatically pulls your public repositories (specifically those tagged as a knowledge-base), parses the source code (starting with Python AST and Markdown), and indexes them into a vector database.
When you ask a natural-language question (e.g., "Which repo uses FastAPI?"), the system searches the index to retrieve the relevant code chunks and generates an answer that explicitly cites the source repository, file, and line numbers.
Code Atlas is designed to be highly resilient, efficient, and offline-friendly for indexing.
- Local Embeddings: Embeddings are generated using a local HuggingFace model (
all-MiniLM-L6-v2). This avoids rate limits and API costs during large ingestion runs, making the indexing process completely local and free. - Robust Incremental Syncing: Instead of relying purely on GitHub commit SHAs, Code Atlas maintains a file-by-file
index_queueinside a localmanifest.json. If indexing crashes midway, the next run will pick up exactly where it left off, giving you at-least-once execution guarantees. - Rigorous Evaluation Suite: Included is a domain-specific evaluation framework that calculates Hit Rate and MRR against a strict 52-question dataset spanning symbol lookups, multi-repo logic, configuration queries, and negative queries.
- AST Parsing: Smart chunking utilizing Python's AST to extract meaning natively, rather than blind string splitting.
- Clone/Sync: Fetch public repositories via the GitHub API that match the target topic (e.g.
knowledge-base). Usesgit pullfor incremental updates. - Parse: Extract and logically chunk the source code and documentation.
- Index: Embed the chunks and store them in ChromaDB for fast, context-aware retrieval.
- Chat: Run RAG pipelines across the whole database to answer arbitrary technical questions.
Make sure you have uv installed, then install dependencies:
uv syncConfigure your target GitHub username and topic via environment variables (default is mohakapoor and knowledge-base):
uv run python -m src.ingestThis will clone the repositories, download the local embedding weights, and build your ChromaDB index inside knowledge_base/chroma.
Test the RAG retrieval and question answering:
uv run python -m src.test_ragCode Atlas includes a rigorous evaluation suite for both retrieval and generation capabilities.
Latest Statistics:
- Retrieval: Precision: 0.78, Recall: 0.83
- Generation: Faithfulness: 0.88, Relevance: 0.91, Correctness: 0.82
Run the retrieval evaluation suite on the curated dataset:
uv run python -m src.eval.eval_retrieval