harness: keep a session under the 8-image request cap
Summary
A coding session resends every earlier image, and the gateway allows 8 per request. Claude Code and Claude Desktop drop the oldest images that are not part of the latest user turn. OpenCode, OpenClaw, Hermes, the DeepSeek harness, and Prime Agent get the same trim on the way out, and each is told which models take pictures. MiMo stays text-only.
Prime Agent 0.10 rejects -e, so its provider is written to models.json instead of a one-shot extension.
Relates to #192.
Test plan
- In an existing Claude Code session, paste a 9th image on
deepseek-v4.1-flashand onglm-5.3-flash. The new image should go through. - Same check on OpenCode, Hermes, OpenClaw, the DeepSeek harness, and Prime Agent.
- MiMo should still not send an image.
-
wally prime-agentshould start withoutUnknown option: -e.
Made with Cursor
Summary by cubic
Keeps coding sessions under the 8-image request cap so a picture pasted later in a session still goes through. The gateway counts every earlier image in the request; OpenCode, OpenClaw, Hermes, the DeepSeek harness, and Prime Agent now drop the oldest images that are not in the latest user turn. MiMo images become a text note.
Harness config changes
- Prime Agent 0.10 rejects
-e, so its provider is written intomodels.jsonin the agent directory instead of a one-shot extension. - Hermes reads vision support only from
model.supports_visioninconfig.yaml, so wally writes that key and skips the edit whenmodelis a scalar.
Summary by CodeRabbit
- New Features
- Image requests now retain the newest images, up to a limit of eight; older images are replaced with a note when needed. Images in the latest user turn are preserved unless that turn alone exceeds the limit.
- Agent model setup now reflects whether a model supports image input, and Hermes configuration is updated accordingly.
- Bug Fixes
- Text-only requests no longer include images, and image content is omitted from requests to MiMo models.
- Hosted chat requests now pass through image handling before reaching the endpoint.