Click any words you think contain an error. Click again to unmark.
Every line in this snippet trades pixel legibility for nothing: a square resize warps tall receipts, low JPEG quality smears glyphs without saving tokens, and low detail mode starves the model.
Imagine someone hands you a long shopping receipt and asks you to read every item. Now imagine they first photocopy it onto a small square card, smudge the ink with a wet thumb, then squint at it from across the room. You will miss numbers. The pipeline does all three of these things to the image before the model ever sees it. The square resize crushes a tall receipt into a stubby shape and makes the text tiny. The heavy compression blurs the edges of the characters. The low detail setting tells the model to glance, not read. Each step throws away the tiny pixels where the actual price digits live.
Detailed answer & concept explanation~7 min readEverything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example.
Everything important, quickly.
6 min: three bugs, why each kills OCR, vision token cost model, aspect-preserving resize math, detail mode tradeoff, validation gates after extraction.
Real products, models, and research that use this idea.
- Claude Opus 4.7 and Sonnet 4.6 vision both bill per pixel-derived tile; quality 20 JPEG costs the same as quality 95.
- GPT-5.5 exposes explicit low and high detail paths and OpenAI docs recommend high detail for any text-heavy extraction.
- Gemini 3.1 Pro tiles images at provider-side fixed dimensions; aspect-preserving resize avoids wasteful padding tokens.
- Open-source LLaVA-NeXT and Qwen2-VL stacks use SigLIP-family encoders that share the same small-text fragility under hard downscaling.
What an interviewer would ask next. Try answering before peeking at the approach.
QHow would you decide the right long-edge target without reading provider docs?
QWhen would you keep low detail mode despite OCR-heavy input?
Don't say thisRed flags and common mistakes that signal junior thinking. Click to expand.
Red flags and common mistakes that signal junior thinking. Click to expand.
Treating vision token cost like file size. JPEG quality and byte count do not move tokens; pixel dimensions and detail mode do. Compressing harder just adds artifacts for free.
The night-before-the-interview bullets. Scan these on the way to the call.
Primary sources. Skim if you want the original framing.
Same topic, related formats. Practice these next.