Learning objectives
- Explain the ideas behind tokens and embeddings.
- Apply the ideas to the example and identify how you would check the result.
Concepts
A tokenizer turns text into units such as words, subwords or punctuation. An embedding represents an item as a vector. Cosine similarity compares the vectors' directions.
Practical example
Tokenize a Swahili greeting and compare illustrative vectors for payment, transfer and weather.
Try the exercise
- Define the task. Tokenize a Swahili greeting and compare illustrative vectors for payment, transfer and weather.
- Identify the key idea. A tokenizer turns text into units such as words, subwords or punctuation.
- Check your decision. Describe an alternative and how you would compare its results.