This article will show you how to make an RAG system that makes your data easily accessible via prompting.
A RAG system is an innovative approach to information retrieval. It utilizes traditional information retrieval approaches like vector similarity search combined with state-of-the-art large language model technology. Combined, these technologies make up a robust system that can access vast amounts of information from a simple prompt.
My motivation for this article is my frustration when trying to find an old mail. I typically have some information about the mail, like who the correspondent was or vaguely what the topic of the email was. Still, I must be more specific when doing a direct word search in Gmail, which makes finding the specific mail I am looking for challenging. I would like to have a RAG system that allows me to prompt my emails to search for them. So, if I needed an old email from my university about a subject, I could prompt something like “What technical course did I enroll in during my second year at NTNU?”. An equivalent direct word search to this prompt is challenging since I need more specific information in my prompt. Instead, a RAG system could find the mail, given it has all the required data.
· Motivation
· Retrieve the data
· Pre-process data
· Other options
· Implementing RAG
∘ Prepare the data
∘ Load the LLM
∘ Use the LLM
· Testing
∘ Test 1
∘ Test 2
· Future work
· Conclusion
The first step in making an RAG system is finding the data you want your RAG system to use. In my case, I want to search emails, though the…