Skip to content
AWS Certified AI Practitioner (AIF-C01) Exam Prep

Lesson 10 of 34 · 6 min

x
10/34

GenAI Building Blocks: Tokens, Embeddings and Transformers

Video lesson: AIF-C01 10/34: GenAI Building Blocks: Tokens, Embeddings and Transformers
ConceptMeaningWhy it matters
TokenThe unit a model reads and writes: a word, part of a word or a symbolContext limits and pricing are counted in tokens (12)
ChunkingSplitting documents into smaller pieces before embeddingRetrieval finds the relevant piece, not a whole manual
EmbeddingA list of numbers (a vector) that represents the meaning of text, an image or audioSimilar meanings → nearby vectors, enabling semantic search
VectorThe array of numbers itself; stored in a vector databaseSearch by similarity, not keywords (20)
Prompt engineeringDesigning the input to get the output you wantCheapest way to improve results (23)
Transformer-based LLMA neural network architecture using attention to weigh every token against every other; predicts the next tokenThe architecture behind modern LLMs
Foundation model (FM)A large model pre-trained on broad data that can be adapted to many tasksOne model, many uses
Multi-modal modelTakes or produces more than one type (text, image, audio, video)Describe an image, answer about a chart
Diffusion modelGenerates images by learning to remove noise step by stepImage 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

  1. AIF-C01 exam guide, Domain 2 — checked Oct 19, 2026
  2. 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 answer

    Answer

    Embeddings and vector similarity search.
  • Why chunk documents before embedding?Show answer

    Answer

    So retrieval returns focused, relevant passages that fit the context.
  • Which model type usually generates images from noise?Show answer

    Answer

    A diffusion model.
Previous

Progress is saved in this browser.

Next Lesson