Bitzu

AIF-C01 ยท Designing foundation model applications

What is Retrieval Augmented Generation (RAG) and how do Amazon Bedrock Knowledge Bases implement it?

How RAG grounds a model in private data, its business applications and how Amazon Bedrock Knowledge Bases implements the flow.

Key points

  • RAG grounds a model in your own data without retraining it.
  • Ingestion: documents are split into chunks, turned into embeddings and stored in a vector store.
  • Question time: the query is embedded, similar chunks are retrieved and added to the prompt, and the model answers from that context.
  • Knowledge Bases: automates ingestion, embedding and retrieval; can return source citations.

Source: https://docs.aws.amazon.com/bedrock/latest/userguide/kb-how-it-works.html

Practice questions

Single choice

What is the main problem RAG solves?

  1. It permanently retrains the model on new documents
  2. It makes every response faster than a plain model call
  3. It lets the model answer using your own, up-to-date documents
  4. It removes the need for any embeddings
Show answer

Answer: C. It lets the model answer using your own, up-to-date documents

RAG supplies the model with relevant, current private content at query time, so answers reflect your data. It does not change model weights, make the model faster, or remove the need for a vector store.

Select all that apply

Which steps are part of how a knowledge base prepares and uses data in a RAG flow?

  1. Splitting source documents into chunks
  2. Converting chunks to embeddings stored in a vector index
  3. Updating the foundation model's weights with the documents
  4. Deleting the original documents after ingestion
  5. Adding the retrieved chunks to the prompt before generation
Show answer

Answer: A. Splitting source documents into chunks, B. Converting chunks to embeddings stored in a vector index, E. Adding the retrieved chunks to the prompt before generation

Documents are chunked and converted to embeddings stored in a vector index, and at runtime the user query is embedded and matched, then the retrieved text augments the prompt. The model's weights are not updated and documents are not deleted after ingestion.

True or false

Because RAG gives the model relevant documents, it guarantees the answer can never contain a hallucination.

Show answer

Answer: False

False. RAG reduces hallucinations by grounding the answer in retrieved text, but poor retrieval or a model that ignores the context can still produce wrong statements. Citations help users verify.

Practice 8 questions on this topic in Bitzu

Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.

Download on the App StoreGet it on Google Play

More AIF-C01 topics in this module