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
 
fernandezbaptiste profile image
Bap

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

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

Thanks Bap ❀️

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
 
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
 
karadza profile image
Juraj

Nice! πŸ”₯

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

Thanks mate ❀️

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
 
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
 
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!