AI Background Music Generator
Paste the following prompt into your AI chat to install this skill:
Please refer to https://skillhub.cn/install/skillhub.md to install @user_87b8e34f/bgm-maker.
About this skill
The Specific Problem to Solve
In content creation workflows, background music (BGM) is crucial for enhancing immersion in videos, games, or podcasts. Traditional methods for obtaining BGM have notable bottlenecks: searching music libraries is time-consuming with copyright risks, custom composition requires professional skills or external collaboration, and existing AI tools often operate in isolation, hindering integration into automated development or Agent workflows. This makes music generation a efficiency barrier during bulk content production, especially for technically-inclined independent developers or small teams.
How the Skill Works
This skill provides AI background music generation via the aimv command-line tool (CLI), with the core functionality calling Hainian Music's cloud AI model to convert text descriptions into instrumental tracks. Its operation revolves around three key steps:
- Initialization and Authentication: On first use, run
node /bin/aimv.js init; the CLI outputs a login page link (e.g.,https://lexuan.club/skills/connect?slug=bgm-maker&from=skill). After the user logs in via the web, they copy the API Key and runinit --api-key <key>to complete the connection. This Key is long-term and syncs with the Hainian Music account. - Music Generation: Use commands like
aimv bgm createor directly execute shell commands, inputting structured descriptions (e.g., "light electronic BGM for a city night vlog"). The AI generates two candidate tracks, with optional support for uploading reference audio to guide style. Generation is asynchronous, and the CLI provides status queries (aimv session tail) and error handling (e.g.,wait_timeoutindicates background generation in progress). - Result Management and Download: Once generated, works automatically sync to the Hainian Music account, allowing downloads via CLI or further editing in the mini-program
海绵音乐AI写歌and weblexuan.club. Error tags (e.g.,insufficient_points) directly guide users to recharge pages, creating a closed-loop operation.
The skill is designed for deep integration with development environments: when the Agent has shell execution permissions, the entire process can be automated via CLI; in restricted sandboxes, setting the environment variable AIMV_FORCE_CURL=1 forces the use of curl as the transport layer, or REST APIs can be called directly. This flexibility makes it suitable for embedding into CI/CD pipelines or batch processing scripts.
Applicable Boundaries and Considerations
- Environment Dependencies: Generation relies on Hainian Music's cloud services, requiring a stable internet connection; the local CLI needs a Node.js runtime, and the configuration directory can be redirected via the
AIMV_CONFIG_DIRenvironment variable. - Quotas and Permissions: Free quotas are limited; exceeding them returns API
code=402requiring recharge. Memberships can increase quotas. API Keys must be securely stored to prevent leaks. - Generation Limits: Output is instrumental BGM, suitable for short looping tracks; it does not support vocal synthesis or complex arrangements. Description quality directly impacts results, requiring specific mentions of mood (e.g., "calm"), tempo (e.g., "medium pace"), and instruments (e.g., "piano").
- Workflow Boundaries: The skill focuses solely on music generation, not video editing or content integration; generated results require users to manage copyright independently, especially for commercial use.
This tool transforms AI music generation into a programmable interface, ideal for technical creators in rapid prototyping, content farm bulk scoring, or multimedia project automation, while noting its service-based nature and output granularity.
Use Cases
- Creating a city night vlog for short video platforms, requiring a light electronic background music track, using CLI commands to quickly generate downloadable BGM by describing scenes, moods, and rhythms.
- In indie game development, designing looping background music for side-scrolling levels, specifying 'medium tempo, electronic synthesizer, tense atmosphere' with the aimv tool to batch-generate multiple candidate tracks for selection.
- A podcast intro needs quiet instrumental piano music, generated via text description, downloaded as WAV files for audio editing, and synced to Hainian Music account for online management.
- A product demo video requires clean, tech-savvy background music, with generation results providing download links for embedding in video editing software, and error handling ensuring a smooth workflow.
Best For
- Short video creators: Need to generate customized BGM weekly for multiple videos, avoiding music library copyright disputes and shortening production cycles.
- Indie game developers: Require programmable, batch-generable background music tools to quickly test different music styles' impact on game atmosphere during prototyping.
- Podcast hosts: Need consistent-style intro, outro, and transition music for regular shows, with online management of the work library.
- Commercial content producers: Need to quickly generate professional scoring for product demos and promotional videos, supporting team collaboration and iterative modifications.
Related Skills
Restyle a short video into a new visual style while preserving core elements such as characters, actions, and composition, suitable for various creative conversions like anime, illustration, ink wash, etc.
Create Douyin vertical video covers from topics, hooks, or materials with support for creative generation, image synthesis, and refinement.
An AI tool that transforms real photos into specified illustration styles while preserving subject recognition.
An engineering-driven solution that integrates design styles, UX workflows, design systems, and multi-platform implementation to solve cross-project design consistency.