Media understanding
RemoteClaw can summarize inbound media (image/audio/video) before the reply pipeline runs. It auto-detects when local tools or provider keys are available, and can be disabled or customized. If understanding is off, models still receive the original files/URLs as usual.
Vendor-specific media behavior is registered by vendor plugins, while RemoteClaw core owns the shared tools.media config, fallback order, and reply-pipeline integration.
Goals
- Optional: pre-digest inbound media into short text for faster routing + better command parsing.
- Preserve original media delivery to the model (always).
- Support provider APIs and CLI fallbacks.
- Allow multiple models with ordered fallback (error/size/timeout).
High-level behavior
- `Body` becomes `[Image]`, `[Audio]`, or `[Video]` block.- Audio sets `{{Transcript}}`; command parsing uses caption text when present, otherwise the transcript.- Captions are preserved as `User text:` inside the block.If understanding fails or is disabled, the reply flow continues with the original body + attachments.
Config overview
tools.media supports shared models plus per-capability overrides:
{ tools: { media: { models: [ /* shared list */ ], image: { /* optional overrides */ }, audio: { /* optional overrides */ echoTranscript: true, echoFormat: 'π "{transcript}"', }, video: { /* optional overrides */ }, }, },}Model entries
Each models[] entry can be provider or CLI:
CLI templates can also use:
- `{{MediaDir}}` (directory containing the media file)- `{{OutputDir}}` (scratch dir created for this run)- `{{OutputBase}}` (scratch file base path, no extension)Provider credentials (apiKey)
Provider media understanding uses the same provider auth resolution as normal
model calls: auth profiles, environment variables, then
models.providers.<providerId>.apiKey.
tools.media.*.models[] entries do not accept an inline apiKey field. The
provider value in a media model entry, such as openai or moonshot, must
have credentials available through one of the standard provider auth sources.
Minimal example:
{ models: { providers: { openai: { apiKey: "<OPENAI_API_KEY>" }, moonshot: { apiKey: "<MOONSHOT_API_KEY>" }, }, },}For the full provider auth reference, including profiles, environment variables, and custom base URLs, see Tools and custom providers.
Defaults and limits
Recommended defaults:
maxChars: 500 for image/video (short, command-friendly)maxChars: unset for audio (full transcript unless you set a limit)maxBytes:- image: 10MB
- audio: 20MB
- video: 50MB
Auto-detect media understanding (default)
If tools.media.<capability>.enabled is not set to false and you havenβt configured models, RemoteClaw auto-detects in this order and stops at the first working option:
- `sherpa-onnx-offline` (requires `SHERPA_ONNX_MODEL_DIR` with encoder/decoder/joiner/tokens)- `whisper-cli` (`whisper-cpp`; uses `WHISPER_CPP_MODEL` or the bundled tiny model)- `whisper` (Python CLI; downloads models automatically)Bundled fallback order:
- Audio: OpenAI β Groq β xAI β Deepgram β OpenRouter β Google β SenseAudio β ElevenLabs β Mistral- Image: OpenAI β Anthropic β Google β MiniMax β MiniMax Portal β Z.AI- Video: Google β Qwen β MoonshotTo disable auto-detection, set:
{ tools: { media: { audio: { enabled: false, }, }, },}Proxy environment support (provider models)
When provider-based audio and video media understanding is enabled, RemoteClaw honors standard outbound proxy environment variables for provider HTTP calls:
HTTPS_PROXYHTTP_PROXYALL_PROXYhttps_proxyhttp_proxyall_proxy
If no proxy env vars are set, media understanding uses direct egress. If the proxy value is malformed, RemoteClaw logs a warning and falls back to direct fetch.
Capabilities (optional)
If you set capabilities, the entry only runs for those media types. For shared lists, RemoteClaw can infer defaults:
openai,anthropic,minimax: imageminimax-portal: imagemoonshot: image + videoopenrouter: image + audiogoogle(Gemini API): image + audio + videoqwen: image + videomistral: audiozai: imagegroq: audioxai: audiodeepgram: audio- Any
models.providers.<id>.models[]catalog with an image-capable model: image
For CLI entries, set capabilities explicitly to avoid surprising matches. If you omit capabilities, the entry is eligible for the list it appears in.
Provider support matrix (RemoteClaw integrations)
| Capability | Provider integration | Notes |
|---|---|---|
| Image | OpenAI, OpenAI Codex OAuth, Codex app-server, OpenRouter, Anthropic, Google, MiniMax, Moonshot, Qwen, Z.AI, config providers | Vendor plugins register image support; openai-codex/* uses OAuth provider plumbing; codex/* uses a bounded Codex app-server turn; MiniMax and MiniMax OAuth both use MiniMax-VL-01; image-capable config providers auto-register. |
| Audio | OpenAI, Groq, xAI, Deepgram, OpenRouter, Google, SenseAudio, ElevenLabs, Mistral | Provider transcription (Whisper/Groq/xAI/Deepgram/OpenRouter STT/Gemini/SenseAudio/Scribe/Voxtral). |
| Video | Google, Qwen, Moonshot | Provider video understanding via vendor plugins; Qwen video understanding uses the Standard DashScope endpoints. |
minimax,minimax-cn,minimax-portal, andminimax-portal-cnimage understanding comes from the plugin-ownedMiniMax-VL-01media provider.- Automatic image routing keeps using
MiniMax-VL-01even if legacy MiniMax M2.x chat metadata claims image input.
Model selection guidance
- Prefer the strongest latest-generation model available for each media capability when quality and safety matter.
- For tool-enabled agents handling untrusted inputs, avoid older/weaker media models.
- Keep at least one fallback per capability for availability (quality model + faster/cheaper model).
- CLI fallbacks (
whisper-cli,whisper,gemini) are useful when provider APIs are unavailable. parakeet-mlxnote: with--output-dir, RemoteClaw reads<output-dir>/<media-basename>.txtwhen output format istxt(or unspecified); non-txtformats fall back to stdout.
Attachment policy
Per-capability attachments controls which attachments are processed:
When mode: "all", outputs are labeled [Image 1/2], [Audio 2/2], etc.
Config examples
Status output
When media understanding runs, /status includes a short summary line:
π Media: image ok (openai/gpt-5.4) Β· audio skipped (maxBytes)This shows per-capability outcomes and the chosen provider/model when applicable.
Notes
- Understanding is best-effort. Errors do not block replies.
- Attachments are still passed to models even when understanding is disabled.
- Use
scopeto limit where understanding runs (e.g. only DMs).