How to Use Stable Audio 3 Small SFX Inpainting in opencode
Stable Audio 3 Small SFX Inpainting replaces a selected section of an existing sound effect while keeping the surrounding audio. Unlike Stable Audio 3 Small Music, it specializes in sound effects rather than music composition.
Prompts to try with Stable Audio 3 Small SFX Inpainting in opencode
Copy an example into opencode, or ask in your own words.
Use Stable Audio 3 Small SFX Inpainting on assets/audio/door.wav, a 10-second clip. Replace seconds 3 through 5 with a heavy oak door closing, a low wooden thud and a short decay in a dry room. Save a separate edited copy.
Use Stable Audio 3 Small SFX Inpainting on the project's 12-second robot boot recording. Replace seconds 4 through 7 with close mechanical servo clicks followed by a brief motor whine. Use eight sampling steps and save the result for listening.
Use Stable Audio 3 Small SFX Inpainting on assets/audio/rain.wav, a 30-second ambience. Rework seconds 10 through 15 as steady rain striking a metal roof, with a distant thunder rumble and an outdoor recording character.
Use Stable Audio 3 Small SFX Inpainting on the 8-second impact clip in the game's audio assets. Replace seconds 2 through 4 with a blunt metal shield impact and a short ringing tail. Make two separate edits with different seeds for review.
Use Stable Audio 3 Small SFX Inpainting on assets/audio/footsteps.wav, a 15-second recording. Replace seconds 6 through 9 with slow leather boots walking across loose gravel, recorded close to the ground. Keep a record of the seed used.
How to set up Stable Audio 3 Small SFX Inpainting 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 Stable Audio 3 Small SFX Inpainting
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/stable-audio-3/small/sfx/audio-inpainting", "input": { "prompt": "punchy kick drum fill", "audio_url": "https://storage.googleapis.com/falserverless/model_tests/diffrythm/rock_en.wav", "mask_start_seconds": 4, "mask_end_seconds": 8 } }'
Then paste one of the prompts above: opencode finds Stable Audio 3 Small SFX Inpainting on Spiral, shows the price and runs it.
Stable Audio 3 Small SFX Inpainting providers and prices
Spiral runs Stable Audio 3 Small SFX Inpainting through fal. Open a card for today's price, with every fee included.
$0.03367 per run at the default inputs.
Settings you can ask for
Stable Audio 3 Small SFX Inpainting works from your prompt and audio URL. Ask opencode for any of these in your prompt.
| Setting | Allowed values | Default | Description |
|---|---|---|---|
| Negative prompt | what to leave out, in words | Text description of qualities to avoid in the output. | |
| Number of inference steps | 1 to 100 | 8 | Number of sampling steps. Post-trained (distilled) checkpoints look good with the default 8 and gain little from going higher. |
| Guidance scale | 0 to 25 | 1 | Classifier-free guidance scale. Higher values follow the prompt more strictly. Only effective on base (non-distilled) checkpoints. |
| Seed | a whole number | Random seed for reproducible outputs. Omit for a random seed. | |
| Enable prompt expansion | on or off | off | If True, the prompt will be expanded using an LLM for more detailed and higher quality results. |
| Output format | mp3, wav, flac, ogg, opus, m4a, or aac | mp3 | Container format for the generated audio output. |
| Mask start seconds | 0 to 120 | Start of the region to regenerate, in seconds. | |
| Mask end seconds | 0 to 120 | End of the region to regenerate, in seconds. |
Every API field of Stable Audio 3 Small SFX Audio Inpainting · Audio Inpainting Small SFX is on its tool page: open its card above.
What can you do with Stable Audio 3 Small SFX Inpainting in opencode?
Replace individual effects in your project's audio assets while retaining the surrounding recording. A coding agent can turn a scene's sound brief into a targeted edit and save a separate result for review.
Replace a game impact
Rework one impact in an existing combat recording, describing the material, weight, and decay while retaining the surrounding action.
Revise a robot sound
Replace a section of a robot sound cue with servo clicks, motor whine, or a mechanical latch while keeping its opening and ending.
Rework environmental ambience
Regenerate a short section of an existing rain, wind, or forest recording with a description that matches the surrounding atmosphere.
Change a Foley action
Replace a door closure, drawer slam, or footstep passage in an existing effects clip. Specify the surface and recording distance.
Revise a podcast transition
Rework the sound-effect section of an existing transition, such as a paper rustle or mechanical click, while preserving the rest of the clip.
Audition a different vehicle effect
Replace a passage in an existing vehicle recording with a different engine texture, brake hiss, or horn description.
More on Stable Audio 3 Small SFX Inpainting and opencode
Overview
Stable Audio 3 Small SFX Inpainting in other agents
Questions about Stable Audio 3 Small SFX Inpainting in opencode
Can opencode use Stable Audio 3 Small SFX Inpainting?
Yes. Add Spiral to opencode as an MCP server, and opencode can find and run Stable Audio 3 Small SFX Inpainting like any built-in tool.
How much does Stable Audio 3 Small SFX Inpainting cost in opencode?
$0.03367 per run at the default inputs. 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 Stable Audio 3 Small SFX Inpainting in opencode?
No. Spiral runs Stable Audio 3 Small SFX Inpainting on its own fal account. You sign in to Spiral once and never paste a key.
How long does it take to set up Stable Audio 3 Small SFX Inpainting in opencode?
About two minutes: add the server, then sign in, then check it.
Does opencode wait while Stable Audio 3 Small SFX Inpainting runs?
Stable Audio 3 Small SFX Inpainting runs in the background. opencode starts the run, checks on it and gives you the audio when it's ready.
What does Stable Audio 3 Small SFX Inpainting change?
It regenerates a selected section of an existing recording. Audio outside that section stays intact, so you can replace one effect without rebuilding the whole clip.
How long can the audio be, and what is its audio resolution?
Stable Audio 3 Small SFX supports audio up to 120 seconds. Stable Audio 3 uses stereo audio at 44.1 kHz.
What should I put in a sound-effect prompt?
Describe the object making the sound, what it does, and how the recording should sound. For example: a heavy wooden door closing with a low thud, recorded close up in a small dry room.
Will more steps or stronger guidance improve the edit?
Start with eight sampling steps; higher counts do not necessarily improve this post-trained model. Guidance scale and negative prompts have no effect on post-trained checkpoints, so refine the main description instead.
Which language should I use for prompts?
Use English as the documented starting point. The Stable Audio 3 Small SFX model card lists English and does not establish broader language support.
Start using Stable Audio 3 Small SFX Inpainting 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


