You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[FEATURE]:Expose image file path alongside [image] placeholder so non-vision models can use MCP vision tools #31221
I have verified this feature I'm about to request hasn't been suggested before.
Describe the enhancement you want to request
What do you want to change or add?
Currently, when pasting an image (or even an image file path) into OpenCode, it gets converted to an [image] placeholder. For vision-capable models this works great — they can directly interpret the image. However, for text-only models (e.g., deepseek-v4-pro), the [image] placeholder is opaque and contains no referenceable file path.
Many users pair text-only models with external MCP vision tools (like agent-vision which accepts a local file path / URL) to analyze images. Without the actual file path, these models have no way to access the pasted image.
Proposed solution
When an image is pasted and stored to a temp location, expose that file path to the model in the message context, e.g.:
[image: C:\Users...\AppData\Local\Temp\opencode\paste-20250607-xxxxx.png]
Benefits
Enables text-only models to leverage MCP vision tools for image analysis
Gives users more flexibility in model choice without sacrificing image input capability
Low implementation cost — it's mainly about exposing the temp path that already exists under the hood
Workaround today
Manually type out the absolute file path in chat instead of pasting it, so the AI receives the raw text path.
Activity
github-actions commentedon Jun 7, 2026
This issue might be a duplicate of existing issues. Please check:
If your request is already covered by one of those, please add a comment or reaction there rather than opening a new issue.