DEV Community

Cover image for Build a Local RAG πŸ’» with Ollama, Huggingface, FAISS and Google Gemma 3 ✨

Build a Local RAG πŸ’» with Ollama, Huggingface, FAISS and Google Gemma 3 ✨

πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ on May 08, 2025

In the previous article, we learned about Retrieval-Augmented Generation (RAG). This has emerged as a powerful technique to enhance the capabilitie...
Collapse
Β 
nathan_tarbert profile image
Nathan Tarbert β€’

Been messing with this stuff myself lately and man, getting it running local really feels solid. You think most people will go for local setups or just stick with the easy cloud stuff?

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’

Cloud is easy and expensive. You pay for saving time and effort. Also, for completely private files and notes, better to setup locally. Should I create an app that works like that? For your local files?

Collapse
Β 
fernandezbaptiste profile image
Bap β€’

That is sooo useful! Saving it for future reference :D

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’

Thanks Bap ❀️

Collapse
Β 
karadza profile image
Juraj β€’

Nice! πŸ”₯

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’ β€’ Edited

Thanks mate ❀️

Collapse
Β 
nathan_tarbert profile image
Nathan Tarbert β€’

been diving into rag setups myself and honestly, getting all this working local is such a flex. love how clean the ui is too, makes me want to tweak my own setup asap

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’

Thanks Nathan. ❀️

Collapse
Β 
michael_liang_0208 profile image
Michael Liang β€’ β€’ Edited

Nice article!
when we are building local RAG, which is better to use for vector database, FAISS or pinecone?
What is pros and cons of using FIASS and pinecone?

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’

For local RAG, and your data is around 2-3 GB (PDFs, Txt, Excels ,etc) and mostly static like your notes or something. Then you can easily use FAISS and it works pretty fine.

If the data crosses that, then getting good results will becomes a challenge. So, dedicated vector database might be helpful in that case. Also, Pinecone is pretty good, there are other like Qdrant, Weaviate, etc. which have a generous free tier.

Collapse
Β 
michael_liang_0208 profile image
Michael Liang β€’

Thanks for your reply.

Collapse
Β 
dev_geos profile image
Dev Geos β€’

What is the minimal configuration machine for running in local ?

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’

Macbook M2 Pro Base model with 16 gb RAM.

Windows 11 + WSL with 16 GB RAM, i7 10th Gen, 2060.

Working fast in both the cases.

Collapse
Β 
anmolbaranwal profile image
Anmol Baranwal β€’

learning a bit about rag, will definitely come back to this later. awesome tutorial Saurabh.

Collapse
Β 
srbhr profile image
πš‚πšŠπšžπš›πšŠπš‹πš‘ πšπšŠπš’ Apideck β€’

Thank you buddy!