GenAI Building Blocks: Tokens, Embeddings and Transformers
| Concept | Meaning | Why it matters |
|---|---|---|
| Token | The unit a model reads and writes: a word, part of a word or a symbol | Context limits and pricing are counted in tokens (12) |
| Chunking | Splitting documents into smaller pieces before embedding | Retrieval finds the relevant piece, not a whole manual |
| Embedding | A list of numbers (a vector) that represents the meaning of text, an image or audio | Similar meanings → nearby vectors, enabling semantic search |
| Vector | The array of numbers itself; stored in a vector database | Search by similarity, not keywords (20) |
| Prompt engineering | Designing the input to get the output you want | Cheapest way to improve results (23) |
| Transformer-based LLM | A neural network architecture using attention to weigh every token against every other; predicts the next token | The architecture behind modern LLMs |
| Foundation model (FM) | A large model pre-trained on broad data that can be adapted to many tasks | One model, many uses |
| Multi-modal model | Takes or produces more than one type (text, image, audio, video) | Describe an image, answer about a chart |
| Diffusion model | Generates images by learning to remove noise step by step | Image generation |
Verified (Amazon Bedrock Knowledge Bases docs)
- In RAG, documents are converted to text, split into chunks, the chunks are converted to embeddings and written to a vector index, keeping a mapping to the source document.
- At runtime the query is embedded too, and the index returns chunks with semantically similar vectors.
- Vectors can be floating-point (float32) or binary (1 bit per dimension): binary is cheaper to store but less precise.
Transformer, diffusion and token definitions are general background.
Exam traps
- Embeddings are encrypted text. They are numeric representations of meaning, used for similarity.
- Diffusion for text chat. Diffusion is the classic image-generation approach; chat uses transformer LLMs.
- Tokens = words. A token is often part of a word; counts differ by model.
References
- AIF-C01 exam guide, Domain 2 — checked Oct 19, 2026
- How Bedrock knowledge bases work — checked Oct 19, 2026
Check your understanding
What lets a system find "refund policy" when the user typed "money back"?Show answerHide answer
Answer
Embeddings and vector similarity search.Why chunk documents before embedding?Show answerHide answer
Answer
So retrieval returns focused, relevant passages that fit the context.Which model type usually generates images from noise?Show answerHide answer
Answer
A diffusion model.