Gradient

Courses

∇\nabla∇The maths behind AI0/72
π\piπMaths0/84
⋆\star⋆AI for everyone0/10
Γ\GammaΓGame theory0/49
py\texttt{py}pyPython for AI0/15
y^\hat{y}y^​Build your own AI0/15
All courses

Tuition

My tuitionOlympiad trackCompetitions

Practice

ProjectsAsk a questionTrain on a GPUExplorationsMaths StoriesUnsolved problemsPlaygroundScience labsMock testsOlympiad

Reference

GlossaryBlogDiscoveries
Glossary › Context window

What is context window?

All the text a model can see at once: instructions, the conversation so far and the reply in progress. Anything outside it cannot affect the output.

Where it is taught

Context, prompts and examples. A model's only working memory is the text in front of it. Understanding the context window explains what prompts do and why long conversations drift.

What the lesson leaves you with

  • The context window is everything the model can see, and all it can use.
  • A prompt changes the condition, not the weights.
  • Examples in the prompt steer the output without any training.
Open the lesson

Questions

What is context window?
All the text a model can see at once: instructions, the conversation so far and the reply in progress. Anything outside it cannot affect the output.
Where is context window used in AI?
A model's only working memory is the text in front of it. Understanding the context window explains what prompts do and why long conversations drift.
What is the key idea to remember about context window?
The context window is everything the model can see, and all it can use.
Where can I learn context window step by step?
In the lesson “Context, prompts and examples” in Gradient’s course on the maths behind AI, with interactive diagrams and questions.

Related terms

  • Fine-tuning
  • Hallucination
  • Pre-training
  • Prompt
  • Retrieval