mirror of
https://github.com/teamchong/pxpipe.git
synced 2026-07-22 02:02:51 +02:00
8af9829872
Fable 5 / Opus 4.8 accept up to 2576px / 4784 visual tokens per image, but a request with >20 images (pxpipe always sends many) is held to the stricter <=2000px/side rule, so the real ceiling is ~1932x1932 (1928x1928 = 69x69 = 4761 tokens). MAX_HEIGHT_PX 1568->1932; dense tool/history pages now render at DENSE_CONTENT_COLS=384 / DENSE_CONTENT_CHARS_PER_IMAGE=92160 (1928x1928 full page) -- fewer image blocks at the same OCR-validated 5x8 cell. The static slab is unchanged (313 cols / 1573x1280). Also fixes a regression the code review caught: the break-even gate, truncateForBudget, and estimateImageCount predicted against the slab geometry (313 cols / 159 rows) while the dense renderer emits 384 cols / 240 rows, so large tool_results were truncated far earlier than the 10-image cap required -- silently dropping output that would have rendered. A per-page char budget is threaded through the prediction chain (defaults to READABLE so the slab and unit tests are byte-identical) plus a denseGateGeometry helper, so the gate prices the same page the renderer actually produces.