miatz™
Verify a credentialLog inSit ChuunSit Chuun
  • Learners
  • Mentors
  • Business
CoursesApplied AIProgramResidencyPlaygroundsWar RoomsXookAtlasReadiness Check
miatz

The AI-era engineering institute. The machines got fast — we train the drivers. Real work, a daily loop that compounds, and a record that proves you can think.

Toggle theme
Explore
  • Courses
  • Applied AI
  • Program
  • Residency
  • Playgrounds
  • War Rooms
  • Xook
  • Atlas
  • Readiness Check
  • Tokenizer Lab
  • Chunking Lab
  • Prompt Anatomy
  • Calibration Lab
  • All playgrounds →
Learn
  • Courses
  • The Method
  • The Residency
  • Chuun · Entrance Examination
  • Manifesto
  • The Itz'at credential
  • Verified engineers
  • Playground Catalog
  • AI Use-Case Atlas
  • AI Readiness Check
  • Guides
  • Glossary
  • Compare approaches
  • Blog
  • What's New
For teams
  • For Students
  • For Mentors
  • For Business
  • Classroom migration
  • Miatz Index
  • API reference
  • Sit Chuun
  • Log in
Company
  • About
  • Experts
  • Why it's free
  • Pricing
  • FAQ
  • Contact
  • Privacy Policy
  • Terms of Service
  • Your data & privacy requests
  • Grievance redressal
  • Security & disclosure
  • Subprocessors
  • Data Processing Agreement
Take miatz with you

The Android app is live. iOS is on the way.

Available on AndroidGet it on Google Play
Not yet on iPhoneiOS — use the web app

Miatz Private Limited

Registered office:
C-101, Lotus Tower, Arge Urban Bloom, 30/A, 4th Main, 2nd Stage, Yeswanthpur, Bengaluru, Karnataka 560022, India
CIN:
U62013KA2026PTC226418
GSTIN:
29AAVCM3922D1Z6
Phone:
+91 82802 73456
Email:
hello@miatz.com
Website:
miatz.com
Grievance Officer:
Aishwarya · aishwarya@miatz.com · replies within 30 days
© 2026 miatz · Miatz Private Limited · Built in Bangalore·PrivacyTerms

miatz™, Itz'at™, Tuukul™, T'aan™, Kanan™, Xook™ and Chuun™ are trademarks of Miatz Private Limited (registrations in progress) · what the names mean

miatz
Glossary

Context Window

A context window is the maximum number of tokens a model can read and generate in one request — the hard ceiling on what it can attend to at once.

A context window is the maximum number of tokens a language model can hold in view for a single request — every system instruction, retrieved document, prior turn of conversation, and generated token all draw from one shared, finite budget.

Unlike a program that can request more memory mid-task, a context window is a hard architectural ceiling set at training and inference time. Feed the model one token past the limit and something has to give: most APIs simply reject the request, while some client libraries silently truncate the oldest messages, which is its own kind of bug. There is no "almost fits" — you are either inside the window or you are not.

How it works

Transformer models compute self-attention across every pair of tokens in the input, which is why context length was historically expensive to grow: naive attention cost grows quadratically with sequence length, so doubling the window roughly quadruples the compute for that layer. Techniques like sliding-window attention, grouped-query attention, and position-embedding schemes designed for length extrapolation are what let modern models offer windows of 128,000 tokens and beyond without the compute bill growing at the same rate.

Size is not the whole story. Research on long-context recall — often called "lost in the middle" — has repeatedly found that models are more reliable at using information near the start or end of the context than information buried in the middle, even when the window is nominally large enough to hold everything. A bigger window raises the ceiling; it does not guarantee the model will notice what you put in it.

Why it matters

Every architectural decision in an LLM application is really a context-window budgeting decision. A system prompt, retrieved chunks, tool definitions, conversation history, and the model's own output all compete for the same tokens. Run out of room and the cheapest fix — truncating old messages — is also the one most likely to silently drop the instruction or fact that mattered.

A worked example

Say your model's context window is 128,000 tokens. Your system prompt runs 800 tokens. A retrieval step pulls back three chunks at 1,200 tokens each — 3,600 tokens. The conversation has run long enough that history sits at 15,000 tokens. That is 19,400 tokens spent before the user's question or the model's answer exist at all — leaving roughly 108,600 tokens of headroom, comfortably above the 4,096-token output cap most APIs default to.

Let that same conversation run for another hour with no history management, and the math changes fast: history alone can eat 80,000 or 100,000 tokens, at which point the fixed 800-token system prompt is a rounding error competing against a wall of old messages for the model's attention — a "lost in the middle" setup even before the true ceiling is hit.

How miatz teaches it

Context-window math is a standing drill in the miatz prompting module: learners are handed a fixed token budget and a pile of candidate context — system rules, retrieved docs, history — and have to decide what stays, what gets summarized, and what gets cut, before ever touching a model. Running out of context in a War Room drill teaches the lesson faster than any diagram: the window is a budget, and budgets get spent.

Related terms

Token Context Engineering Retrieval-Augmented Generation (RAG)

Learn this in a course

AIE-103 · Context Engineering & Cost Basics

Learn it by doing it.

Miatz turns definitions into judgment — the free founding cohort trains you on exactly these concepts, hands-on.

Join free More definitions