Spiral gives your agent every tool with one account. Browse the tools →

Codex · LLMReleased 2026-10-15

How to Use Moondream 3 Preview in Codex

Moondream 3 Preview answers questions about images, writes captions, and extracts visual details into JSON. It supports reasoning for harder visual questions, but tiny text can trip it up.

Prompts to try with Moondream 3 Preview in Codex

Copy an example into Codex, or ask in your own words.

Use Moondream 3 Preview to draft one sentence of alt text for each image in public/products. Review each draft against the page where the image appears before updating the alt text.

Moondream 3 PreviewCodex
Try asking
  • Use Moondream 3 Preview to transcribe the readable error message in screenshots/checkout-error.png. Return the exact visible wording and mark any unreadable characters.

  • Use Moondream 3 Preview to describe the visible state of the quantity control in screenshots/cart.png. Enable reasoning and identify the visual evidence for the answer.

  • Use Moondream 3 Preview to convert the table in docs/images/spec-table.png into Markdown. Preserve row order and mark uncertain cells for review.

  • Use Moondream 3 Preview to describe each image in public/gallery as JSON with subject, dominant_colors, and setting. Validate the JSON before saving the descriptions.

How to set up Moondream 3 Preview in Codex

Pick the way that suits you. Each takes about two minutes.

Use Spiral's MCP server

  1. Add the hosted server
    codex mcp add spiral --url https://api.spiral.ai/mcp
  2. Sign in

    Codex opens the browser: sign in to Spiral and click Authorize. No API key. codex mcp list then shows Spiral.

    codex mcp login spiral

Use the Spiral skill

  1. Send Codex this message

    Your agent reads Spiral's skill and sets itself up.

    set up https://spiral.ai/SKILL.md
  2. Sign in or paste a key

    Approve Spiral in the browser, or give the agent a key from the console.

Use the Spiral CLI

  1. Install and sign in

    Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

    npx -y spiral-cli@latest init

Call the Spiral API

  1. Create an API key

    In the console, under API keys.

  2. Run Moondream 3 Preview

    One request; the result comes back by polling or a webhook.

    curl https://api.spiral.ai/v1/runs \
      -H "Authorization: Bearer $SPIRAL_API_KEY" \
      -H "Content-Type: application/json" \
      -H "Idempotency-Key: $(uuidgen)" \
      -d '{
        "provider": "openrouter",
        "model": "moondream/moondream3-preview",
        "input": {
          "messages": [
            {
              "role": "system"
            }
          ]
        }
      }'

Then paste one of the prompts above: Codex finds Moondream 3 Preview on Spiral, shows the price and runs it.

Moondream 3 Preview providers and prices

Spiral runs Moondream 3 Preview through OpenRouter. Open a card for today's price, with every fee included.

OpenRouterLLM
Moondream: Moondream 3 Preview
moondream/moondream3-preview

Settings you can ask for

Ask Codex for any of these in your prompt.

SettingAllowed valuesDefaultDescription
Top p0 to 1
Max tokens1 to 4096

The most output tokens to generate.

Temperature0 to 2

Every API field of Moondream: Moondream 3 Preview is on its tool page: open its card above.

What can you do with Moondream 3 Preview in Codex?

Turn project screenshots and image assets into descriptions, readable text, and structured observations. A coding agent can use those results when updating content or investigating a visible interface problem.

Draft alt text

Turn website images into concise descriptions of the visible subject and action. Review the drafts in the context of the surrounding page.

Describe product photos

Extract visible product attributes such as color, shape, and arrangement for catalog descriptions. Ask it to mark details that cannot be determined from the photo.

Convert pictured tables into Markdown

Transcribe a clearly readable table from an image into editable Markdown. Check small print and ambiguous characters against the source.

Explain support screenshots

Describe the visible interface state or transcribe a readable error message to give a support agent concrete evidence.

Catalog an image collection

Create captions and structured descriptions that record the subjects, colors, and setting shown in each image.

Check image descriptions

Ask whether a photo supports a specific description, and request the visible evidence behind the answer.

Prepare visual observation reports

Summarize what is visible in a scene photo using a consistent set of requested details, such as object type, color, and position.

Questions about Moondream 3 Preview in Codex

Can Codex use Moondream 3 Preview?

Yes. Add Spiral to Codex as an MCP server, and Codex can find and run Moondream 3 Preview like any built-in tool.

How much does Moondream 3 Preview cost in Codex?

Up to $0.013327 per run at the default inputs. $0.39 per 1M input tokens, $3.25 per 1M output tokens. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Codex plan is separate.

Do I need an OpenRouter account to use Moondream 3 Preview in Codex?

No. Spiral runs Moondream 3 Preview on its own OpenRouter account. You sign in to Spiral once and never paste a key.

How long does it take to set up Moondream 3 Preview in Codex?

About two minutes: add the hosted server, then sign in.

Does Codex wait while Moondream 3 Preview runs?

Moondream 3 Preview runs in the background. Codex starts the run, checks on it and gives you the text, json when it's ready.

What is Moondream 3 good at?

Moondream 3 answers questions about images, describes scenes, and turns visible details into structured text. Useful tasks include product descriptions, alt text, and checking whether an image matches a description.

Can Moondream 3 read text in images?

Yes, including converting a pictured table into Markdown. Tiny fonts are a documented weakness, so check small text against the original image.

Can Moondream 3 return JSON?

Yes. Specify the keys you want and describe what each entry should represent, such as one object per visible product with its color and position.

How much context can Moondream 3 Preview handle?

The model card documents a usable context length of 32K tokens. That describes context capacity, not a promise of a 32K-token answer.

Does Moondream 3 use a fixed image resolution?

Moondream resizes images into overlapping tiles rather than using one fixed resolution. Its documentation describes roughly 378-by-378-pixel tiles, with up to 12 local tiles plus a global view.

Get started

Start using Moondream 3 Preview in Codex

One Spiral account for every tool your agent needs. No subscription; you pay per run.

Paste this into Codex:

Set up Codex

set up https://spiral.ai/SKILL.md
Are you an AI agent? See setup options