|
| 1 | +--- |
| 2 | +title: "Stability AI Stable Audio 2.5 API Node ComfyUI Official workflow example" |
| 3 | +description: "This article will introduce how to use Stability AI Stable Audio 2.5 API node's text-to-audio, audio-to-audio and audio-inpainting capabilities in ComfyUI" |
| 4 | +sidebarTitle: "Stable Audio 2.5" |
| 5 | +--- |
| 6 | + |
| 7 | +import ReqHint from "/snippets/tutorials/api-nodes/req-hint.mdx"; |
| 8 | +import UpdateReminder from "/snippets/tutorials/update-reminder.mdx"; |
| 9 | + |
| 10 | +The [Stability AI Stable Audio 2.5](/built-in-nodes/api-node/audio/stability-ai/stability-ai-stable-audio-2-5) API node allows you to use Stability AI's latest audio generation model to create high-quality music through text prompts, audio transformations, and audio inpainting capabilities. |
| 11 | + |
| 12 | +Stable Audio 2.5 is designed for enterprise use, featuring improved musical structure, better prompt adherence, and the ability to generate minutes-long compositions in seconds. The model offers three main workflows: **Text-to-Audio** for generating music from descriptions, **Audio-to-Audio** for transforming existing audio into new compositions, and **Audio Inpainting** for completing or extending existing tracks. |
| 13 | + |
| 14 | +Trained exclusively on licensed audio, Stable Audio 2.5 is commercially safe and perfect for advertisers, game studios, and content creators who need professional-quality audio generation with enterprise-grade reliability. |
| 15 | + |
| 16 | +<ReqHint/> |
| 17 | +<UpdateReminder/> |
| 18 | + |
| 19 | +## Text-to-Audio Workflow |
| 20 | + |
| 21 | +For text-to-audio, you can generate audio through text prompts. You need to describe the music you want to generate. |
| 22 | + |
| 23 | +<a className="prose" target='_blank' href="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/refs/heads/main/templates/api_stability_ai_text_to_audio.json" style={{ display: 'inline-block', backgroundColor: '#0078D6', color: '#ffffff', padding: '10px 20px', borderRadius: '8px', borderColor: "transparent", textDecoration: 'none', fontWeight: 'bold'}}> |
| 24 | + <p className="prose" style={{ margin: 0, fontSize: "0.8rem" }}>Download JSON Workflow</p> |
| 25 | +</a> |
| 26 | + |
| 27 | + |
| 28 | +1. Modify the text prompt. You should use keywords to describe the music you want to generate. |
| 29 | +2. (Optional) Modify the `duration` parameter. It's `190` by default. |
| 30 | +3. Click the `Run` button or use the shortcut `Ctrl(cmd) + Enter` to execute the audio generation. The audio will be saved to the `ComfyUI/output/audio` directory. |
| 31 | + |
| 32 | +## Audio-to-Audio Workflow |
| 33 | + |
| 34 | +Audio-to-audio is basically music re-sampling. You can use it to generate new music from a given piece of music, or you can just hum a melody, and then the model will generate new music based on the input audio. |
| 35 | + |
| 36 | +<a className="prose" target='_blank' href="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/refs/heads/main/templates/api_stability_ai_audio_to_audio.json" style={{ display: 'inline-block', backgroundColor: '#0078D6', color: '#ffffff', padding: '10px 20px', borderRadius: '8px', borderColor: "transparent", textDecoration: 'none', fontWeight: 'bold'}}> |
| 37 | + <p className="prose" style={{ margin: 0, fontSize: "0.8rem" }}>Download JSON Workflow</p> |
| 38 | +</a> |
| 39 | + |
| 40 | +<a className="prose" target='_blank' href="https://raw.githubusercontent.com/Comfy-Org/example_workflows/refs/heads/main/api_nodes/stability_ai/stable_audio/beatbox.mp3" style={{ display: 'inline-block', backgroundColor: '#0078D6', color: '#ffffff', padding: '10px 20px', borderRadius: '8px', borderColor: "transparent", textDecoration: 'none', fontWeight: 'bold'}}> |
| 41 | + <p className="prose" style={{ margin: 0, fontSize: "0.8rem" }}>Download Input Audio</p> |
| 42 | +</a> |
| 43 | + |
| 44 | + |
| 45 | + |
| 46 | +1. In this workflow, we have provided two nodes for you to input the audio(at least 6 seconds) you want to edit: |
| 47 | + - 1.1 `Record Audio` node: You can use it to record any of your music ideas, such as a hummed melody. It should be at least 6 seconds. |
| 48 | + - 1.2 `LoadAudio` node: You can use it to upload audio that you want to be used in this workflow. |
| 49 | +2. Modify the text prompt. You should use keywords to describe the music you want to generate. |
| 50 | +3. The `strength` parameter is used to control the difference from the original audio. The lower the value, the more similar the generated audio will be to the original audio. |
| 51 | +4. Click the `Run` button or use the shortcut `Ctrl(cmd) + Enter` to execute the audio generation. The audio will be saved to the `ComfyUI/output/audio` directory. |
| 52 | + |
| 53 | +## Audio Inpainting Workflow |
| 54 | + |
| 55 | +Audio inpainting is used to complete or extend existing tracks. You can use it to complete the missing part of music or extend the music to a longer duration. |
| 56 | + |
| 57 | +You need to set where you want to start and end the inpainting. |
| 58 | + |
| 59 | +<a className="prose" target='_blank' href="https://raw.githubusercontent.com/Comfy-Org/workflow_templates/refs/heads/main/templates/api_stability_ai_audio_inpaint.json" style={{ display: 'inline-block', backgroundColor: '#0078D6', color: '#ffffff', padding: '10px 20px', borderRadius: '8px', borderColor: "transparent", textDecoration: 'none', fontWeight: 'bold'}}> |
| 60 | + <p className="prose" style={{ margin: 0, fontSize: "0.8rem" }}>Download JSON Workflow</p> |
| 61 | +</a> |
| 62 | + |
| 63 | +<a className="prose" target='_blank' href="https://raw.githubusercontent.com/Comfy-Org/example_workflows/refs/heads/main/api_nodes/stability_ai/stable_audio/audio_input.wav" style={{ display: 'inline-block', backgroundColor: '#0078D6', color: '#ffffff', padding: '10px 20px', borderRadius: '8px', borderColor: "transparent", textDecoration: 'none', fontWeight: 'bold'}}> |
| 64 | + <p className="prose" style={{ margin: 0, fontSize: "0.8rem" }}>Download Input Audio</p> |
| 65 | +</a> |
| 66 | + |
| 67 | + |
| 68 | +1. Upload audio to the `LoadAudio` node. |
| 69 | +2. Modify the text prompt. You should use keywords to describe the music you want to generate. |
| 70 | +3. (Optional) Modify the `duration` parameter. It's `190` by default. |
| 71 | +4. (Important) Modify the `mask_start` and `mask_end` parameters. You need to set where you want to start and end the inpainting. |
| 72 | +5. Click the `Run` button or use the shortcut `Ctrl(cmd) + Enter` to execute the audio generation. The audio will be saved to the `ComfyUI/output/audio` directory. |
0 commit comments