Local RAG Using Llama 3, Ollama, and PostgreSQL

Build a fully local, private RAG Application with Open Source Tools (Meta Llama 3, Ollama, PostgreSQL and pgai)

๐Ÿ›  ๐—ฅ๐—ฒ๐—น๐—ฒ๐˜ƒ๐—ฎ๐—ป๐˜ ๐—ฅ๐—ฒ๐˜€๐—ผ๐˜‚๐—ฟ๐—ฐ๐—ฒ๐˜€
๐Ÿ“Œ Try pgai PostgreSQL extension โ‡’ https://github.com/timescale/pgai
๐Ÿ“Œ Github repo with code used in the video: https://github.com/timescale/private-rag-example
๐Ÿ“Œ Use Open-source LLMs in PostgreSQL with Ollama and pgai โ‡’ https://www.timescale.com/blog/use-open-source-llms-in-postgresql-with-ollama-and-pgai/
๐Ÿ“Œ What is pgai? โ‡’ https://www.timescale.com/blog/pgai-giving-postgresql-developers-ai-engineering-superpowers/
๐Ÿ“Œ Install TimescaleDB / PostgreSQL using Docker โ‡’ https://docs.timescale.com/self-hosted/latest/install/installation-docker/
๐Ÿ“Œ Ollama โ‡’ https://ollama.com/
๐Ÿ“Œ Nomic Embed โ‡’ https://www.nomic.ai/blog/posts/nomic-embed-matryoshka
๐Ÿ“Œ Meta Llama 3 โ‡’ https://www.llama.com
๐Ÿ“Œ Try pgai on Timescale free for 30 days โ‡’ https://tsdb.co/ai-signup

Join Hervรฉ Ishimye, a Developer Advocate at Timescale, as he demonstrates how to create a private Retrieval Augmented Generation (RAG) application using open-source tools. Learn to integrate Meta Llama 3.2 as your language model, leverage Ollama for model execution, and employ PostgreSQL as your vector database. Ensure data privacy by running these elements locally and benefit from enhanced control, speed, and reduced costs. Hervรฉ walks through the process of setting up your RAG application using Docker, configuring Olama and PostgreSQL, and embedding models effectively. This tutorial emphasizes data safety and the integration of tools like pgai and pgvector in your local environment.

๐Ÿ“š ๐—–๐—ต๐—ฎ๐—ฝ๐˜๐—ฒ๐—ฟ๐˜€
00:00 Why private RAG?
02:28 Tools for Building a Private RAG Application
03:02 Deep Dive into Ollama and PostgreSQL
06:09 Setting Up Your Local Environment
10:38 Implementing the RAG Application
14:31 Conclusion and Final Thoughts

๐Ÿฏ ๐—”๐—ฏ๐—ผ๐˜‚๐˜ ๐—ง๐—ถ๐—บ๐—ฒ๐˜€๐—ฐ๐—ฎ๐—น๐—ฒ
At Timescale, we see a world made better via innovative technologies, and we are dedicated to serving software developers and businesses worldwide, enabling them to build the next wave of computing. Timescale is a remote-first company with a global workforce backed by top-tier investors with a track record of success in the industry.

๐Ÿ’ป ๐—™๐—ถ๐—ป๐—ฑ ๐—จ๐˜€ ๐—ข๐—ป๐—น๐—ถ๐—ป๐—ฒ!
๐Ÿ” Website โ‡’ https://tsdb.co/homepage-24
๐Ÿ” Slack โ‡’ https://slack.timescale.com
๐Ÿ” GitHub โ‡’ https://github.com/timescale
๐Ÿ” Twitter โ‡’ https://twitter.com/timescaledb
๐Ÿ” Twitch โ‡’ https://www.twitch.tv/timescaledb
๐Ÿ” LinkedIn โ‡’ https://www.linkedin.com/company/timescaledb
๐Ÿ” Timescale Blog โ‡’ https://tsdb.co/blog-24
๐Ÿ” Timescale Documentation โ‡’ https://tsdb.co/docs-24