Lurker News
I am curious how people are doing RAG locally with minimal dependencies for internal code or complex documents?

Are you using a vector database, some type of semantic search, a knowledge graph, a hypergraph?

Comments (156) 83 threads

Earlier comments
mmargenot#
I made an obsidian extension that does semantic and hybrid (RRF with FTS) search with local models. I have done some knowledge graph and ontology experimentation around this, but nothing that I’d like to include yet.

This is specifically a “remembrance agent”, so it surfaces related atoms to what you’re writing rather than doing anything generative.
Extension: https://github.com/mmargenot/tezcat
Also available in community plugins.

IXCoach#
I have production agents which run vector search via FAISS locally ( in their env not 3rd party environments ), and for which I am creating embeddings for specific domains.

1 - agent memory ( its an ai coach so its the unique training methods that allow for instant adoption of new skills and distilling best fit skills for context )
2 - user memory ( the ai coaches memory of a user )
3 - session memory ( for long conversations, instead of compaction or truncation )
Then separately I have coding agents which I give semantic search, same system FAISS
- on command they create new memories from lessons ( consumes tokens * ) - they vector search FAISS when needing more context ( 2x greater agent alignment / outcomes this way )
And finally I forked openais codex terminal agent code to add - inbuilt vector search and injection
So I say "Find any uncovered TDD opportunity matching intent to actuality for auth on these 3 repos, write TDD coverage, and bring failures to my attention"
They set my message to {$query}
vector search on {$query}
embed results in their context window
programmatically - so no token consumption ( what a freaking dream )
thats open source if helpful
Its here
https://github.com/Next-AI-Labs-Inc/codex/tree/nextailabs
Im trying to determine where something like this fits in
https://huggingface.co/MongoDB/mdbr-leaf-ir
My gaps right now are ...
I am not training the agents yet, like fine tuning the underlying models.
Would love the simplest approach to test this, because at least with the codex clone I could easily swap out local models, but somehow doubting that they will be able to match performance of the outsourced models.
especially bc claude code just launched ahead of codex in the last week or so in quality, and they are closed source. Im seeing clear swarm agentic coding internally which is a dream for context window efficiency. ( in claude code as of today )

yakkomajuri#
I've written about this (and the post was even here on HN) but mostly from the perspective of running a RAG on your infra as an organization. But I cover the general components and alternatives to Cloud services.

Not sure how useful it is for what you need specifically: https://blog.yakkomajuri.com/blog/local-rag

Load more comments