Visual primitives vs. think-with-images in multimodal agents
Multimodal models can still miscount and fail spatial plans because of a perception gap and a referring gap. This article explains visual primitives versus think-with-images, how Agent harness configuration—not just model weights—decides which path runs, and how to close both gaps with structured IDs, coordinates, and aligned evaluation.
Why “seeing the image” can still yield wrong counts and broken paths
Multimodal large models already offer usable capabilities for recognition, localization, counting, and spatial planning. In production, two problems still recur. On the input side, resolution, cropping, and attention coverage can be insufficient, so the model cannot “see” dense objects clearly. On the reasoning side, the scene is still described in natural language, so references stay ambiguous and later steps collapse. The first issue is often called the perception gap; the second is the referring gap. When they stack, paper settings and live results can diverge: crowd counts off by a few people, or maze paths that fail completely in an interactive client, are not rare.
To understand this, separate how images are encoded from how the Agent is orchestrated. Encoding decides how visual information enters reasoning. Orchestration decides tool calls, whether intermediate results are written back, and whether multi-turn correction happens. Experimental builds that look different in a web demo versus a paper usually fail not because a capability is “missing,” but because the default pipeline never enables unambiguous pointers in continuous visual space, or because prompts, resolution, and tooling do not match the paper.
Two technical paths: visual primitives and think-with-images
Industry practice roughly splits into two ways of handling images.
The first is visual primitives. Object position, extent, and relations in continuous visual space are expressed as operable structured marks—boxes, points, trajectories, region indices—rather than phrases such as “the red one on the left” or “the crowd in the middle.” Primitives act as unambiguous pointers: later reasoning cites coordinates or region IDs instead of descriptions that drift. For dense counting, overlapping targets, and fine-grained localization, the referring gap is substantially reduced.
The second is think-with-images. The model repeatedly consults the image in the chain of thought and, if needed, crops or zooms a region before reasoning further—closer to classic multi-step visual QA. It alternates natural language and image features, is simple to implement, and fits existing conversational Agents. On extremely dense counting and complex geometric planning, one bad referring step can throw the entire plan off.
If an experimental multimodal build leans toward the second path in Agent settings, that does not reject primitives. It usually means the harness (orchestration layer) is cheaper: tool protocols, intermediate image return, and session state can reuse existing conventions. The practical question for developers is whether the current deployment writes primitives into tool results, or whether they exist only in the paper setup. Verify with matched tasks (a crowd photo with a fixed headcount, a maze with fixed topology), not slogans.
Closing the perception gap and the referring gap separately
The perception gap mainly comes from resolution, tiling, and attention coverage. In practice: raise effective input resolution or recrop regions of interest; for very large images, use a sliding window and record the mapping from window to global coordinates; for small objects, run detection or segmentation first to produce candidates, then let the language model judge semantics. These steps should emit structured boxes, not prose.
The referring gap must be removed from the “language of thought.” Useful conventions:
- Give every discussed object a stable ID; later steps cite only ID and coordinates.
- For counting, force enumerate–deduplicate–verify; do not emit a single integer directly.
- For planning, write the path as an ordered coordinate sequence and re-read the image at each step to check reachability.
Illustrative pseudocode (generic convention, not a vendor API):
objects = detect_and_assign_id(image) # id, bbox, scorecount = unique(objects)path = plan(objects, start, goal) # list of (x,y)for step in path:assert visible_and_reachable(image, step)
If a live product disagrees with paper results, check first whether secondary zoom is enabled, whether detections are written back into context, and whether evaluation prompts allow “box first, then count.” Web defaults may disable heavy visual tools for latency, which produces “the paper can solve the maze; the product cannot.”
Agents and harness: capability often stalls on config, not weights
Whether a multimodal stack “has” a visual mechanism often depends on Agent configuration rather than base weights. Common pitfalls: docs name high-level fields while runtime uses a JSON config or environment variables; CLI examples are stale; global tools are not upgraded so a profile never takes effect.
Engineering practice: put model choice, visual-tool switches, maximum image side length, and whether cropped images are returned into versioned configuration, and publish reproducible upgrade steps. Internal eval and public docs must share the same profile, or official write-ups and actual behavior will diverge. Configuration should be auditable: logs must show whether a session called detection and whether primitive fields were written.
For users: lock the runtime version, then pin the eval model ID and visual-pipeline flags, then regress on a fixed test set. Do not assume “vision on” equals the paper’s full primitive stack. Treat the harness as a first-class citizen: it decides whether intermediate images enter the next thought step and whether primitives ever get used.
Evaluation should match the task definition, not marketing copy
Crowd counting and maze navigation are extremely pipeline-sensitive. A 25-person scene counted as 27 in a web client usually comes from duplicate boxes, people cut at crop borders, or a natural-language “estimate again” hallucination. Maze failures often come from planning only in language space without projecting back to pixels, or from disabling multi-step crop in the interactive client.
A minimal eval pack:
- Fixed resolution, fixed prompts, no extra search.
- For counting, optionally provide annotated boxes as a tool and compare a pure language-model curve with a primitive-assisted curve.
- For planning, require a coordinate sequence, overlay it for visualization, and check wall collisions by hand or script.
Comparisons are meaningful only when paper setup, Agent defaults, and the web product share the same tool switches. Experimental builds should state clearly if they default to primitives off and only think-with-images, so readers do not judge product defaults by paper metrics.
Deployment: a robust mix for enterprise scenes
For customer-service QA, warehouse inventory, drawing review, and similar work, a more robust mix is: detection/segmentation emit primitives; the language model handles semantics and rules; the Agent runs multi-turn correction and human confirmation. In the cloud, object storage can hold originals and crops, logs can record tool calls, and monitoring can track count drift. Do not bind to one experimental model name; write structured visual intermediate representations as a platform convention.
Keep three configuration principles: explicit, upgradable, replayable. Explicit: visual tools and model IDs live in config, not tribal knowledge. Upgradable: runtime and docs stay in sync. Replayable: each failure can reconstruct image patches and IDs from logs. Then even if the base model shifts between primitives and think-with-images, counting and planning can stay stable on the business side.
Summary
Whether multimodal systems use visual primitives cannot be read from a paper title. It depends on whether reasoning uses unambiguous pointers in continuous visual space, and whether the Agent writes those pointers back into context. Govern the perception gap with resolution and local re-recognition; govern the referring gap with IDs and coordinates. If an experimental build is closer to think-with-images, orchestration often decides product experience before a new encoder does. Developers should treat harness, eval alignment, and structured intermediate representations as equal to the model if they want reproducible dense recognition and spatial planning.
