Real-World Use Case – Retrieval-Augmented Generation
In the previous chapter, we learned how to augment our kernel with memories, which enables our applications to be much more personalized. Cloud-based AI models, such as OpenAI’s GPT, usually have knowledge cut-offs that are a few months old. They also usually don’t have domain-specific knowledge, such as the user manuals of the products your company makes, and don’t know the preferences of your users, such as their favorite programming language or their favorite city. The previous chapter taught you ways to augment the knowledge of models by keeping small pieces of knowledge in memory and retrieving them as needed.
In this chapter, we’re going to show you how to expand the data that’s available to your AI application. Instead of using a small amount of data that fits in the prompt, we’re going to use a large amount of data with a retrieval-augmented generation (RAG) application...