Exhaustively Explained

 Retrieval Augmented Generation — Intuitively and Exhaustively Explained

In this post we’ll explore “retrieval augmented generation” (RAG), a strategy which allows us to expose up to date and relevant information to a large language model. We’ll go over the theory, then imagine ourselves as resterauntours; we’ll implement a system allowing our customers to talk with AI about our menu, seasonal events, and general information.Who is this useful for? Anyone interested in natural language processing (NLP).

How advanced is this post? This is a very powerful, but very simple concept; great for beginners and experts alike.

Pre-requisites: Some cursory knowledge of large language models (LLMs) would be helpful, but is not required.

The Core of the Issue

LLMs are expensive to train; chat GPT-3 famously cost a cool $3.2M on compute resources alone. If we opened up a new restaurant, and wanted to use an LLM to answer questions about a menu, it’d be cool if we didn’t have to dish out millions of dollars every time we introduced a new seasonal salad. We could do a smaller training step (called fine tuning) to try to get the model to learn a small amount of highly specific information, but this process can still be hundreds to thousands of dollars.

Visit

Post a Comment

0 Comments