OpenAB can pass inbound image attachments to ACP agents as image content blocks, but the downstream coding agent and selected local model must both support image input.
User image
→ OpenAB inbound attachment pipeline
→ ACP ImageContent / ContentBlock::Image
→ Pi/OpenCode model config that declares image input support
→ local vision-capable inference endpoint
OpenAB can create the ACP image block, but it cannot make a text-only coding agent or text-only local model understand it. Use this guide for local OpenAI-compatible endpoints such as llama-server.
- The local inference server exposes an OpenAI-compatible chat completions endpoint that accepts
image_urlcontent parts with base64 data URLs. - The selected model is a vision/multimodal model, not a text-only GGUF.
- The coding-agent model metadata declares image input support.
- The model can still emit reliable tool calls through the OpenAI-compatible endpoint if you want to use it as a coding agent.
Hosted GGUF from Hugging Face, when the repo includes a multimodal projector:
llama-server \
-hf ggml-org/Qwen2.5-VL-7B-Instruct-GGUF:Q4_K_M \
--alias local-vision \
--host 0.0.0.0 \
--port 8080 \
-c 32768In this mode, llama.cpp auto-loads the projector when the hosted GGUF repo provides one.
Local GGUF files require both the text model and the multimodal projector:
llama-server \
-m /models/qwen2.5-vl-7b-instruct-q4_k_m.gguf \
--mmproj /models/mmproj-qwen2.5-vl-7b-instruct-f16.gguf \
--alias local-vision \
--host 0.0.0.0 \
--port 8080 \
-c 32768Do not add --no-mmproj for image input. If llama-server runs in the same pod as OpenAB and the coding agent, use http://127.0.0.1:8080/v1. If it runs as a separate Kubernetes Service, use that Service URL instead.
Pi must declare image input support in ~/.pi/agent/models.json with input: ["text", "image"].
kubectl exec deployment/openab-pi -- mkdir -p /home/node/.pi/agent
kubectl exec -i deployment/openab-pi -- sh -c 'cat >/home/node/.pi/agent/models.json'<<'EOF'
{
"providers": {
"local-vision": {
"baseUrl": "http://127.0.0.1:8080/v1",
"api": "openai-completions",
"apiKey": "not-needed",
"compat": {
"supportsDeveloperRole": false,
"supportsReasoningEffort": false,
"maxTokensField": "max_tokens"
},
"models": [
{
"id": "local-vision",
"name": "Local Vision (llama.cpp)",
"reasoning": false,
"input": ["text", "image"],
"contextWindow": 32768,
"maxTokens": 4096,
"cost": { "input": 0, "output": 0, "cacheRead": 0, "cacheWrite": 0 }
}
]
}
}
}
EOFThen select local-vision/local-vision in Pi with /model, or verify it with:
kubectl exec deployment/openab-pi -- pi --list-models local-visionFor OpenAB deployments, persist the Pi config on the PVC before starting the bot.
OpenCode must declare image input support in opencode.json with modalities.input: ["text", "image"].
Create opencode.json in the working directory, usually /home/node:
kubectl exec -i deployment/openab-opencode -- sh -c 'cat >/home/node/opencode.json'<<'EOF'
{
"$schema": "https://opencode.ai/config.json",
"model": "local-vision/local-vision",
"provider": {
"local-vision": {
"npm": "@ai-sdk/openai-compatible",
"name": "Local llama.cpp vision",
"options": {
"baseURL": "http://127.0.0.1:8080/v1",
"apiKey": "not-needed"
},
"models": {
"local-vision": {
"name": "Local Vision (llama.cpp)",
"tool_call": true,
"limit": {
"context": 32768,
"output": 4096
},
"modalities": {
"input": ["text", "image"],
"output": ["text"]
}
}
}
}
}
}
EOFRestart OpenAB/OpenCode after changing the config:
kubectl rollout restart deployment/openab-opencode
kubectl exec deployment/openab-opencode -- opencode models local-visiontool_call: true tells OpenCode the model can be used for coding-agent tool calls. Keep it only if the selected local model and server can reliably emit tool calls through the OpenAI-compatible endpoint.
Upload a screenshot and confirm the response references the image content. Then verify normal file-edit or shell-tool workflows still work. Image description alone is not enough for a coding agent.
- Use a vision/multimodal GGUF from the
llama.cppmultimodal list, not a text-only model. - With local files, always provide the matching
--mmprojfile. - Do not use
--no-mmproj; it disables the projector needed for image input. - Use enough context for image tokens plus coding-agent tools and repository context. Start around 16k-32k if the model and hardware allow it.
- Smoke-test tool calls. Some local vision models can describe images but are not reliable enough for coding-agent tool use.
- Inbound Attachments — how OpenAB converts uploaded images into ACP image content
- Pi — Pi coding agent setup
- OpenCode — OpenCode setup