How to Use Image Editing Reframe in opencode
Image Editing Reframe adapts an existing image to a different aspect ratio while aiming to maintain the main subject. Use it to rework a photo for a banner, square tile, or portrait layout.
Prompts to try with Image Editing Reframe in opencode
Copy an example into opencode, or ask in your own words.
Use Image Editing Reframe to make a 16:9 version of the homepage hero photo in this project. Save it as a separate asset and show me the result beside the original.
Find the product photo used by the collection card and use Image Editing Reframe to make a square version. Preview it in the existing card component.
Use Image Editing Reframe on the article cover image to create a 3:4 composition. Add it to the mobile article preview so I can assess the subject placement.
Use Image Editing Reframe to prepare a 21:9 composition of the campaign image in the assets directory. Show a preview in the campaign banner.
Use Image Editing Reframe to create a 9:16 composition from the project's promotional photo. Report the returned pixel dimensions and show me the result.
How to set up Image Editing Reframe in opencode
Pick the way that suits you. Each takes about two minutes.
Use Spiral's MCP server
- Add the server
Leave out --global to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.
opencode mcp add spiral --global --url https://api.spiral.ai/mcp
- Sign in
Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, /mcps starts the same sign-in.
opencode mcp auth spiral
- Check it
Spiral shows as connected.
opencode mcp list
Use the Spiral skill
- Send opencode this message
Your agent reads Spiral's skill and sets itself up.
set up https://spiral.ai/SKILL.md
- Sign in or paste a key
Approve Spiral in the browser, or give the agent a key from the console.
Use the Spiral CLI
- 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
- Create an API key
In the console, under API keys.
- Run Image Editing Reframe
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": "fal", "model": "fal-ai/image-editing/reframe", "input": { "image_url": "https://v3.fal.media/files/elephant/7ekErKT--mhgKJ5kgtvU__image.webp" } }'
Then paste one of the prompts above: opencode finds Image Editing Reframe on Spiral, shows the price and runs it.
Image Editing Reframe providers and prices
Spiral runs Image Editing Reframe through fal. Open a card for today's price, with every fee included.
Settings you can ask for
Image Editing Reframe works from your image URL. Ask opencode for any of these in your prompt.
| Setting | Allowed values | Default | Description |
|---|---|---|---|
| Guidance scale | 0 to 20 | 3.5 | The CFG (Classifier Free Guidance) scale is a measure of how close you want the model to stick to your prompt when looking for a related image to show you. |
| Number of inference steps | 1 to 50 | 30 | Number of inference steps for sampling. |
| Safety tolerance | 1 to 6 | 2 | The safety tolerance level for the generated image. 1 being the most strict and 6 being the most permissive. |
| Output format | jpeg or png | jpeg | The format of the generated image. |
| Aspect ratio | 21:9, 16:9, 4:3, 3:2, 1:1, 2:3, 3:4, 9:16 and 1 more | 16:9 | The desired aspect ratio for the reframed image. |
| Seed | a whole number | The same seed and the same prompt given to the same version of the model will output the same image every time. |
Every API field of Image Editing Reframe is on its tool page: open its card above.
What can you do with Image Editing Reframe in opencode?
Adapt existing project images to the layouts your site needs. Ask the agent to identify the intended placement, reframe the source, and check the result in context.
Website hero images
Adapt an existing campaign photo to a wide banner, then review how the main subject fits the page.
Portrait social images
Reframe a landscape campaign image for a portrait social layout while aiming to retain the main subject.
Square product tiles
Prepare square compositions from existing product photos for a catalog or collection page.
Editorial image placements
Adapt an existing article photo to the wide and portrait placements in an editorial layout.
Presentation visuals
Rework an existing photo into a widescreen composition for a presentation slide.
Poster compositions
Turn an existing promotional image into a tall composition for a poster draft.
More on Image Editing Reframe and opencode
Overview
Image Editing Reframe in other agents
Questions about Image Editing Reframe in opencode
Can opencode use Image Editing Reframe?
Yes. Add Spiral to opencode as an MCP server, and opencode can find and run Image Editing Reframe like any built-in tool.
How much does Image Editing Reframe cost in opencode?
$0.052 per image. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your opencode plan is separate.
Do I need a fal account to use Image Editing Reframe in opencode?
No. Spiral runs Image Editing Reframe on its own fal account. You sign in to Spiral once and never paste a key.
How long does it take to set up Image Editing Reframe in opencode?
About two minutes: add the server, then sign in, then check it.
Does opencode wait while Image Editing Reframe runs?
Image Editing Reframe runs in the background. opencode starts the run, checks on it and gives you the image when it's ready.
What is Image Editing Reframe useful for?
Use it to adapt an existing image to a different layout, such as turning a portrait photo into a wide banner or a landscape image into a square tile.
What does Image Editing Reframe try to preserve?
fal describes preservation of the main subject's position, composition, pose, and perspective. Compare the result with the original to decide whether it meets your needs.
How should I phrase a request for Image Editing Reframe?
Tell your agent which image to use and where the result will appear. Reframe's published schema has no text prompt input, so make the requested layout clear, such as a wide presentation image or a portrait poster.
Can I specify an exact output size in pixels?
The documentation describes aspect ratios but does not publish an exact pixel-size control or a fixed output resolution. Check the returned image's dimensions before using it in a layout with strict size requirements.
When should I choose Image Editing Reframe?
Choose it when you already have the subject and scene you want, but need a different image shape. Its documented task is changing aspect ratio while maintaining the subject.
Start using Image Editing Reframe in opencode
One Spiral account for every tool your agent needs. No subscription; you pay per run.
Paste this into opencode:
set up https://spiral.ai/SKILL.md


