THE LONG CONTEXT CARD · the long context seat · what fits, what goes where, what to cut
WAKES WHEN someone asks if contracts, papers, transcripts or a codebase fit in one request, what order a long report and the question go in, or why a long answer is cut off
THE METHOD
measure FOLDER --out parts.json — estimated parts from files.
plan parts.json --model … --max-tokens … --skeleton SKELETON.md — the verdict, the cuts, the order, the skeleton.
models — the windows and limits in use, with their date.
Count the real request with the token counting endpoint and plan again.
REFUSES
A fit called from a guess
An estimate presented as a measured count
Cutting the question or the instructions
Summarising a document the person said must stay whole
IT MAKES plan — does it fit, what to cut, the order, the skeleton; measure — estimate the tokens of files and write them as parts; models — the context windows and limits used, with sources and dates.
THE LAW The sums come from the machine; the window and limits are dated data from the docs. An estimate is labelled; a summary's size is an assumption until counted. The question goes last and is never cut; nor are the instructions. Room for the answer is part of the budget. It plans; the person chooses what to keep.
IN THE BOX scripts/longctx.py · assets/context-rules.json · the plan · the method by hand · the sources · ten tests.
PROOF selftest 18/18; a 40-contract review of 1.3 million tokens planned under a 1M window, and the trigger test, on the record (WITNESS.md) · witnessed 2026-10-13 · EDITION 1.
THE SEAL 96 of 100 · LEGENDARY · WITNESSED · Trigger 5 · Machinery 5 · Law 5 · Portability 5 · Proof 4
IT CAN BE WRONG an AI reading a text file: it can be wrong and can invent a number, a rule, a name or a date; check what matters against your own records and the source; the risk is yours. LICENSE-NOTE.md rides in the packet and is the licence.
THE PUNCH · SHA-256 OF SKILL.MD · 573B59DB9EE81D437C1C7CD9
CITE THIS CARDTHE LONG CONTEXT CARD, Edition 1. Lund Studio LLC, Westminster, Colorado. https://lundr.tech/?view=long-context-card. Punch 573B59DB9EE81D437C1C7CD9. Retrieved 2026-10-13.
What it is.
A plan for one big Claude request: a stack of contracts, a set of papers, a deposition, a codebase, a long conversation.
Use it whenever someone asks if contracts, papers, transcripts or a codebase fit in one request, what order a long report and the question go in, or why a long answer is cut off. Not for prompt caching (THE CACHE LAYOUT CARD), one big file in a session (THE CONTEXT BUDGET CARD), the context cost of skills (THE LOAD CARD).
It carries a machine that shows its working: plan — does it fit, what to cut, the order, the skeleton; measure — estimate the tokens of files and write them as parts; models — the context windows and limits used, with sources and dates — 18 checks in its selftest.
It answers requests such as “will 40 contracts fit in one request with a 1M window?”, “what order should the annual report, my instructions and my question go in?”, “our chat history is at 600k and growing: what do we summarise?”, “why is the answer cut off when I send the whole codebase?”.
Five laws, written into the card.
They are in the card itself, so the AI follows them.
THE SUMS COME FROM THE MACHINEThe sums come from the machine; the window and limits are dated data from the docs.
AN ESTIMATE IS LABELLEDAn estimate is labelled; a summary's size is an assumption until counted.
THE QUESTION GOES LAST AND IS NEVER CUTThe question goes last and is never cut; nor are the instructions.
ROOM FOR THE ANSWER IS PART OF THE BUDGETRoom for the answer is part of the budget.
IT PLANSIt plans; the person chooses what to keep.
The method.
measure FOLDER --out parts.json — estimated parts from files.
plan parts.json --model … --max-tokens … --skeleton SKELETON.md — the verdict, the cuts, the order, the skeleton.
models — the windows and limits in use, with their date.
Count the real request with the token counting endpoint and plan again.
What rides in the card.
In the card’s own voice, with a machine that shows its working.
THE REFERENCESreferences/SOURCES.md · THE-METHOD.md · THE-PLAN.md
THE MACHINEscripts/longctx.py · three commandsplan — does it fit, what to cut, the order, the skeleton; measure — estimate the tokens of files and write them as parts; models — the context windows and limits used, with sources and dates. 18 checks in its selftest. Needs: Python 3; the parts with their token counts (or the files, to estimate), and the model or the window.
What it does once your AI has it.
plan Does it fit, what to cut, the order, the skeleton
measure Estimate the tokens of files and write them as parts
models The context windows and limits used, with sources and dates
On the record Example Co's 40-contract review: 1.3 million tokens planned under a 1M window, six contracts cut to fit with 28,663 to spare, the skeleton written; 32 of 40 in the trigger test after the rewrite
What it refuses, and where it hands off.
It refuses a fit called from a guess; an estimate presented as a measured count; cutting the question or the instructions; summarising a document the person said must stay whole.
prompt caching → THE CACHE LAYOUT CARD
reading one big file or log in a session → THE CONTEXT BUDGET CARD
the context cost of skills → THE LOAD CARD
Plans from the counts given and does not read the documents; estimates are labelled; the windows were read 2026-10-12 and change. It is an AI reading a text file: it can be wrong, so check what matters against your own records and the source.
What’s in the buy.
CARD.md — the whole card: its boot, law, method, machine, seals, refusals and hand-offs, ledger, score and what it carries · SKILL.md — the door your AI reads first · START-HERE.md — the first five minutes, for you
SOURCES.md + THE-METHOD.md + THE-PLAN.md — in references/, in the card's own voice
scripts/longctx.py — the machine: plan · measure · models; see NEEDS below; selftest 18/18
WITNESS.md — the run on a realistic case as printed, and the trigger test on Haiku, Sonnet and Opus · SELFTEST.md — the machine's own test, as run at the cut · AUDIT.md, the twelve checks · MANIFEST.md, every file hashed
tests/evals.json — the cases it must take, hand off and refuse
MY-LEDGER.md — the card's memory, on your own machine · TIN.md, the nine lines on the tin · LICENSE-NOTE.md · HOSTS.md, where it runs
system/short-prompt.md and system/system-prompt.md — the doors for any AI without skills
PROOF · SELFTEST 18/18 · WITNESSED ON A RUN · TRIGGER TEST 28 OF 40 ON ITS OWN PROMPTS · HAIKU 9/16 · SONNET 12/16 · OPUS 7/8 · 0 WRONG PICKS · EDITION 1 · PUNCH 573B59DB9EE81D437C1C7CD9
ON EVERY DOOR · A CARD FOR YOUR AI, A FILE FOR YOUR COMPUTER
In Claude: turn on code execution under Settings › Capabilities, then Customize › Skills › + › Create skill, and upload the zip as it is — START-HERE.md in the box walks you through it, and tells you how to keep the ledger. In ChatGPT, Gemini and the rest: a Project, a GPT or a Gem with the card’s files attached and the short door in the box pasted as its instructions. The words run anywhere an AI reads Markdown; the machines run wherever the host runs Python. Witnessed in Claude only. The host marks →
Take it.
Nº 969 — LAUNCHING SOON
Sold as is under the term printed. A card instructs an AI you operate; results depend on your model, your files and your judgement. Not medical, legal, tax or financial advice, never the person’s boss, and not a licence to practise. The terms →
One payment. The file is yours to keep and keeps working at its edition; new editions issued in the year after you buy reach you by email as replacement files. Tax is added at checkout where it applies. Nothing auto-renews.
A TERM, NOT A SUBSCRIPTION: NOTHING RENEWS ITSELF AND NOBODY IS CHARGED AGAIN. WHEN A TERM ENDS THE FILES STAY ON YOUR COMPUTER AND STAY READABLE — FREEZE, NOT LOSS.
THE MACHINE · IN THE OPEN · FROM THE CARD’S OWN WITNESS.MD AND SELFTEST.MD
longctx.py, every command showing its working.
A small Python program. Your AI runs it; you can too. The blocks below are pasted from the card’s own record, as printed.
plan
does it fit, what to cut, the order, the skeleton
measure
estimate the tokens of files and write them as parts
models
the context windows and limits used, with sources and dates
selftest
18 checks that prove the machine; it must print 18/18
python3 scripts/longctx.py plan contracts-parts.json --model claude-opus-5-5 --max-tokens 32000 --skeleton SKELETON.md | sed -n '1,3p;45,70p'
LONG CONTEXT PLAN · contracts-parts.json · window 1,000,000 (Opus 5.5) · max_tokens 32,000 (the answer and any thinking) · facts as read 2026-10-12
part kind tokens count keep
the question question 240 measured must
input 1,302,020
+ max_tokens 32,000
= needed 1,334,020
headroom -334,020 (negative: over the window)
TO FIT · the largest parts that may be cut, to about 10% of their size (an assumption: set --summary-ratio)
RETRIEVE OR SUMMARISE supplier 14 master agreement 99,960 → 9,996 saves 89,964
RETRIEVE OR SUMMARISE supplier 27 master agreement 88,962 → 8,897 saves 80,065
RETRIEVE OR SUMMARISE supplier 39 master agreement 82,376 → 8,238 saves 74,138
RETRIEVE OR SUMMARISE supplier 25 master agreement 44,121 → 4,413 saves 39,708
RETRIEVE OR SUMMARISE supplier 40 master agreement 43,791 → 4,380 saves 39,411
RETRIEVE OR SUMMARISE supplier 36 master agreement 43,775 → 4,378 saves 39,397
input after the cuts 939,337 · headroom 28,663
ORDER · supplier 01 master agreement … supplier 40 master agreement (40 documents, in the order given) → review instructions → the question
long documents at the top, each tagged with its source; examples and instructions after them; the question last.
FINDINGS
ERROR the input alone (1,302,020) is over the window (1,000,000): the API returns a 400 invalid_request_error (prompt is too long) on every model
VERDICT · FITS AFTER CUTS
FORMULA · needed = the sum of the parts + max_tokens; it fits when needed is at most the window. Thinking tokens are part of max_tokens and count toward the window.
SOURCE · platform.claude.com/docs/en/build-with-claude/context-windows; platform.claude.com/docs/en/build-with-claude/prompt-engineering/claude-prompting-best-practices (Long context prompting) · read 2026-10-12.
LIMIT · it plans from the counts given; an estimate is about 4 characters a token. A summary's size is an assumption until it is written and counted. It does not read the documents' content.
wrote SKELETON.md · the prompt skeleton
# The prompt skeleton
Long material at the top, each document tagged with its source, the question last. Replace each {…} with the real text.
## the last user message
THE SELFTEST, AS PRINTED
PASS model ids map to the docs' names
PASS windows as read: Opus 5.5 1M with 128k output; Sonnet 4.5 is not in the 1M list
PASS 12 papers, history, system and question in 1M with 32k for the answer: FITS, headroom 454,500
PASS 1.3M tokens of contracts in a 1M window: the input alone is over (a 400), and the cut brings it under
PASS input under the window but input + max_tokens over it: the 4.5+ behaviour (accepted, may stop at model_context_window_exceeded) is named
PASS the cut stops as soon as it fits, largest first, and keeps what must be kept
PASS when nothing may be cut and it is still over: DOES NOT FIT, and it says to split the work
PASS the order: history first, then documents in their given order, examples, instructions, the question last
PASS the skeleton tags each document with its source, asks for quotes first, and ends on the question
PASS a CSV with thousands separators reads, and an unmeasured count is labelled estimated
PASS parts that cannot be read are refused, every bad field named
PASS a plan with no question is refused: the question must go last
PASS 140 PDF pages with a 200k window is over the 100 a request takes, as read
PASS max_tokens over the model's output limit (128k as read) is an ERROR
PASS measure reads a folder in a fixed order and writes estimated parts
PASS plan from an empty folder: FITS, exit 0, the same bytes twice, the skeleton written
PASS no window and no model exits 2 with a message; models prints the facts with their date
PASS assets/context-rules.json matches the rules built into this machine
selftest 18/18
THE TRIGGER TEST. The card's line was tried on Haiku, Sonnet and Opus beside 12 neighbouring skills, in a clean environment: 28/40 on its own prompts (Haiku 9/16 · Sonnet 12/16 · Opus 7/8), 0 wrong picks; no skill (answered directly) 11, claude-api 1.
THE RUNS ARE PASTED FROM THE CARD’S OWN RECORD AS PRINTED. THE CASES ARE THE STUDIO’S OWN EXAMPLES (EXAMPLE CO IS FICTION); NO PRIVATE PERSON IS NAMED.
QUESTIONS AT THE TABLE
Asked before the wire.
What does it need from me?
Python 3; the parts with their token counts (or the files, to estimate), and the model or the window.
Does it send anything anywhere?
Its machine reads what you point it at, and HOSTS.md says what it needs; python 3; the parts with their token counts (or the files, to estimate), and the model or the window. The words run wherever an AI reads Markdown.
What is on the record?
The selftest (18/18), a run on a realistic case with every command and verdict pasted into WITNESS.md as printed (Example Co's 40-contract review: 1.3 million tokens planned under a 1M window, six contracts cut to fit with 28,663 to spare, the skeleton written; 32 of 40 in the trigger test after the rewrite); and the trigger test, the card's line tried on Haiku, Sonnet and Opus beside 12 neighbouring skills: 28/40 on its own prompts, 0 wrong picks; the twelve-check audit (AUDIT.md). The punch on the face is the SHA-256 of SKILL.md, so a downloaded copy can be checked against this room.
Can it be wrong?
Yes — it is an AI reading a text file. Plans from the counts given and does not read the documents; estimates are labelled; the windows were read 2026-10-12 and change.
What will it never do?
It refuses a fit called from a guess; an estimate presented as a measured count; cutting the question or the instructions; summarising a document the person said must stay whole.
Who may use it?
One person, any number of their own AIs and computers; a team needs a company licence.