Context windows, tokens and what things cost
After this lesson you can: Estimate the cost and the context limit of a call before you make it.
First: Tokens and tokenization
Watch
- CAG vs Long Context: How AI Models Use and Remember Information - IBM Technology, 11 min. Directly compares long context with alternatives, useful for engineers estimating limits and cost tradeoffs.
- Is RAG Still Needed? Choosing the Best Approach for LLMs - IBM Technology, 11 min. RAG versus direct context is the practical decision behind paying for large prompts.
- What is a Context Window? Unlocking LLM Secrets - IBM Technology, 12 min. The title exactly targets context windows, but language is unknown so it cannot be first.
Notes
A context window is the maximum amount of text the model can consider in one call: your prompt, retrieved documents, chat history, tool results, and the model’s own response all share that same budget. Since you already know tokens are chunks of text, think of the context window as the size of the model’s working desk measured in tokens, not characters or words.
Unlock the full lesson notes, the exercises and the graded checkpoint - ₹5,000 once.