I play the guitar and sing in open mics in my spare time. To perform, I usually play with a backing track but sometimes it’s hard to find a “karaoke” version and even harder to find one with all my desired instruments (I’d like to hear everything but the guitar because I’m going to play it!).
There are a few ways to create a backing track from a song (maybe there are more but these are the ones that I know of):
- With Logic Pro for iPad: Since 2024 it has a way to split a song into tracks (bass, drums, other, vocals). This feature is called stem splitter .
- With
Demucs
, which is an open-source tool capable of separating
drums, bass, and vocals from the rest of the accompaniment.
- It has a feature where it can split a song using more instruments (bass, drums, guitar, other, piano, vocals). In this mode, I can keep important tracks in the backing track, such as the “other” and “piano” tracks, which make the backing track feel complete.
In this article, I show how to give the full workflow to a coding agent while keeping the audio operations explicit.
Creating the backing track with an agent
You only need to tell your coding agent which song to use and which parts you plan to perform. The agent can get the
open-mic
project, set it up, separate the song, and create the backing track.
Start with this prompt and replace the placeholders with your song and the parts you plan to perform:
Use https://github.com/mauriciopoppe/open-mic to create a backing track for
<song-url>.
I will perform <parts-you-will-perform>. Remove those parts from the backing
track, keep the other instruments, and tell me where you saved the finished track.
The repository contains a README.md for people and an AGENTS.md with detailed instructions for coding agents. Those files tell the agent how to install the open-mic command, where generated files belong, and how to check its work. You do not need to copy the installation commands into your prompt.
Putting the theory into practice
I want to sing and play guitar over December 21 by Prince Royce . I will create two backing tracks for comparison:
- A minimal version with bass and drums.
- A fuller version with bass, drums, piano, and other instruments.
Both versions should exclude the vocals and guitar. This prompt gives the agent the song, the performance plan, and the two outputs to create:
Use https://github.com/mauriciopoppe/open-mic to create a backing track for
https://www.youtube.com/watch?v=A9B1Uo-VQas.
I will sing and play guitar. Remove the vocals and guitar, then create two versions:
1. A backing track with bass and drums.
2. A backing track with bass, drums, piano, and other.
Tell me where you saved both finished tracks.
Once the agent starts, open-mic uses
yt-dlp
to download the audio and
Demucs
to separate it into six stems:
workspace/stems/htdemucs_6s/<song>/
├── bass.mp3
├── drums.mp3
├── guitar.mp3
├── other.mp3
├── piano.mp3
└── vocals.mp3
The agent combines the requested stems and saves both backing tracks under the project’s workspace/ directory. The original download, individual stems, and final mixes remain in that workspace.
Here is the original song followed by the two backing tracks:
As you can hear, the backing track created with Demucs has lots of details from the original song minus
the voice or guitar which is exactly what I need. Demucs is an amazing tool and so useful for open mics!