RAG, Knowledge Bases and Vector Databases
RAG (verified, Bedrock Knowledge Bases docs)
Retrieval Augmented Generation (RAG) uses information from data sources to improve the relevancy and accuracy of responses. Flow:
- Ingest: convert documents to text, chunk them, create embeddings, store them in a vector index with a link back to the source.
- Retrieve: embed the user's query; find semantically similar chunks.
- Augment: add the chunks to the prompt.
- Generate: the FM answers from that context, optionally with citations.
Knowledge bases also remove the need to continually retrain a model to use your private data (verified).
Amazon Bedrock Knowledge Bases
- Managed Knowledge Base (AWS recommends it): Bedrock manages ingestion, indexing, storage and retrieval; connectors for Amazon S3, SharePoint, Confluence, Google Drive, OneDrive and a web crawler; document-level permission filtering; agentic retrieval for multi-hop questions; integrates with AgentCore Gateway as an MCP tool.
- Customer-managed Knowledge Base: you set up the vector store (such as Amazon OpenSearch Serverless, Amazon Aurora, Amazon Neptune) and control parsing and indexing.
- Features: citations for checking accuracy, reranking models, multimodal retrieval.
Business applications (design guidance)
Employee help desks over HR policies · customer support over product manuals · search across contracts · sales assistants over product catalogues.
AWS vector stores (guide list; verified as Bedrock options where noted)
| Service | Notes |
|---|---|
| Amazon OpenSearch Service (Serverless or managed cluster) | Search and vector engine; Bedrock KB option |
| Amazon Aurora (PostgreSQL) | Relational database with vector support; Bedrock KB option |
| Amazon Neptune (Neptune Analytics) | Graph database; graph-based RAG |
| Amazon RDS for PostgreSQL | Vector search with the pgvector extension (general background) |
| Also supported by Bedrock KBs | Amazon S3 Vectors, Pinecone, Redis Enterprise Cloud, MongoDB Atlas |
Exam traps
- Fine-tuning to teach the model this week's prices. Facts change; RAG retrieves current data.
- RAG removes the need for review. It reduces hallucinations; it doesn't eliminate them.
- Using DynamoDB as the "vector database" answer when OpenSearch, Aurora, Neptune or RDS for PostgreSQL is listed.
References
- Bedrock Knowledge Bases — checked Oct 19, 2026
- How knowledge bases work — checked Oct 19, 2026
- KB vector store setup — checked Oct 19, 2026
- AIF-C01 Domain 3 — checked Oct 19, 2026
Check your understanding
Policies change monthly; answers must cite the current policy. Approach?Show answerHide answer
Answer
RAG with Bedrock Knowledge Bases.What turns chunks into searchable vectors?Show answerHide answer
Answer
An embeddings model.Name two AWS services that store embeddings.Show answerHide answer
Answer
Amazon OpenSearch Service, Amazon Aurora (also Neptune, RDS for PostgreSQL).