byted-music-generate
Generate music using Volcengine Imagination API. Supports vocal songs, instrumental BGM, and lyrics generation. Use when the user wants to create songs, background music, soundtracks, write lyrics, or mentions "music generation", "BGM", or "songwriting".
What this skill does
# Music Generate Skill
Generate music using the [Volcengine Music Generation API](https://www.volcengine.com/docs/84992). Supports vocal songs, instrumental BGM, and AI lyrics generation.
## Trigger Conditions
1. User wants to generate a song (with lyrics or a text prompt)
2. User needs background music, instrumental tracks, or soundtracks
3. User wants AI-generated lyrics
4. User mentions "write a song", "music generation", "BGM", "background music", "lyrics"
## Environment Variables
Two authentication methods are supported (gateway takes priority):
**Option 1: API Gateway (recommended)**
- `ARK_SKILL_API_BASE` — API gateway base URL
- `ARK_SKILL_API_KEY` — API gateway authentication key
**Option 2: Direct AK/SK**
- `VOLCENGINE_ACCESS_KEY` — AccessKey ID
- `VOLCENGINE_SECRET_KEY` — AccessKey Secret
- How to obtain: [Volcengine Console](https://console.volcengine.com/) → Account → Key Management → Create Key
## Usage
1. Determine user intent and select the mode (`song` / `bgm` / `lyrics`).
2. `cd` to the skill directory: `skills/byted-music-generate`.
3. Run the script. The script polls the API internally and may take **several minutes** to complete (typically 1–5 minutes for song/bgm).
4. **Monitor execution**: If the runtime environment moves the command to background, you MUST periodically (every 10 seconds) read the terminal output to check whether the script has finished. The script prints polling progress to stderr and outputs a single JSON line to stdout upon completion.
5. Once completed, return the `audio_url` or `lyrics` from the JSON output to the user.
## Three Modes
### 1. song — Vocal Song
User provides lyrics (Lyrics) or a text prompt (Prompt) to generate a vocal song.
```bash
# With text prompt
python scripts/music_generate.py song --prompt "A song about summer at the beach" --genre Pop --gender Female
# With lyrics
python scripts/music_generate.py song --lyrics "[verse]\nMoonlight on the windowsill\nMemories flowing like water\n[chorus]\nYou are my moonlight" --genre Folk --mood "Sentimental/Melancholic/Lonely"
```
**Note**: `--lyrics` and `--prompt` are mutually exclusive; lyrics takes priority. If the user hasn't provided lyrics, you can first use the `lyrics` mode to generate them, then pass the result to the `song` mode.
### 2. bgm — Instrumental BGM
Describe the desired music in natural language. The v5.0 model does not require Genre/Mood parameters — just describe everything in the `--text` field.
```bash
python scripts/music_generate.py bgm --text "Relaxed coffee shop ambiance music with piano and guitar" --duration 60
# With song structure segments
python scripts/music_generate.py bgm --text "Epic game soundtrack" --segments '[{"Name":"intro","Duration":10},{"Name":"chorus","Duration":30}]'
```
### 3. lyrics — Lyrics Generation
Returns synchronously (no polling needed). Can be used standalone or as a pre-step for the `song` mode.
```bash
python scripts/music_generate.py lyrics --prompt "A song about graduation farewell" --genre Folk --mood "Sentimental/Melancholic/Lonely" --gender Female
```
### Manual Task Query (timeout fallback)
```bash
python scripts/music_generate.py query --task-id "202601397834584670076931"
```
## Mode Detection Logic
```
User Request
↓
Contains "instrumental/BGM/background music/soundtrack"?
├─ Yes → bgm mode
└─ No → Contains "lyrics/write lyrics" and does NOT request audio?
├─ Yes → lyrics mode
└─ No → song mode
├─ User provided lyrics → --lyrics
└─ User only described a theme → --prompt (or lyrics first, then song)
```
## Script Parameters
### song mode
| Parameter | Required | Description |
|-------------------|----------|------------------------------------------------------|
| `--lyrics` | either | Lyrics with structure tags |
| `--prompt` | either | Text prompt (Chinese, 5-700 chars) |
| `--model-version` | no | `v4.0` or `v4.3` (default: v4.3) |
| `--genre` | no | Music genre |
| `--mood` | no | Music mood |
| `--gender` | no | `Female` / `Male` |
| `--timbre` | no | Vocal timbre |
| `--duration` | no | Duration in seconds [30-240] |
| `--key` | no | Musical key (v4.3 only) |
| `--kmode` | no | `Major` / `Minor` (v4.3 only) |
| `--tempo` | no | Tempo (v4.3 only) |
| `--instrument` | no | Instruments, comma-separated (v4.3 only) |
| `--genre-extra` | no | Secondary genres, comma-separated, max 2 (v4.3 only) |
| `--scene` | no | Scene tags, comma-separated (v4.3 only) |
| `--lang` | no | Language (v4.3 only) |
| `--vod-format` | no | `wav` / `mp3` (v4.3 only) |
| `--billing` | no | `prepaid` / `postpaid` (default: postpaid) |
| `--timeout` | no | Max wait seconds (default: 300) |
### bgm mode
| Parameter | Required | Description |
|--------------------------|----------|----------------------------------------|
| `--text` | yes | Natural language description |
| `--duration` | no | Duration in seconds [30-120] |
| `--segments` | no | JSON array of song structure segments |
| `--version` | no | Model version (default: v5.0) |
| `--enable-input-rewrite` | no | Enable prompt rewriting |
| `--billing` | no | `prepaid` / `postpaid` (default: postpaid) |
| `--timeout` | no | Max wait seconds (default: 300) |
### lyrics mode
| Parameter | Required | Description |
|-----------|----------|------------------------------------------|
| `--prompt` | yes | Lyrics prompt (Chinese only, <500 chars) |
| `--genre` | no | Music genre |
| `--mood` | no | Music mood |
| `--gender` | no | `Female` / `Male` |
## Script Return Info
The script outputs JSON with the following fields:
```json
{
"status": "success | timeout | error",
"mode": "song | bgm | lyrics | query",
"task_id": "...",
"audio_url": "https://...",
"duration": 46.0,
"lyrics": "...",
"error": null
}
```
Return the `audio_url` to the user for download or playback. URLs are valid for approximately 1 year, but users should save the file promptly.
## Error Handling
- IF the script raises `PermissionError: Authentication not configured ...`, inform the user to configure either API gateway (`ARK_SKILL_API_BASE` + `ARK_SKILL_API_KEY`) or direct AK/SK (`VOLCENGINE_ACCESS_KEY` + `VOLCENGINE_SECRET_KEY`) environment variables. Write them to the workspace environment variable file, then retry.
- IF `status` is `"timeout"`, the task is still generating. Provide the user with the `task_id` and the manual query command from the output.
- IF copyright check fails (code 50000001), suggest the user enrich the description or increase the audio duration, then retry.
## References
- Available parameter values (Genre/Mood/Timbre/Instrument etc.): [references/parameters.md](references/parameters.md)
- [Volcengine Music Generation Docs](https://www.volcengine.com/docs/84992)
- [API Signature Guide](https://www.volcengine.com/docs/6369/67269)
Related in Backend & APIs
jfrog
IncludedInteract with the JFrog Platform via the JFrog CLI and REST/GraphQL APIs. Use this skill when the user wants to manage Artifactory repositories, upload or download artifacts, manage builds, configure permissions, manage users and groups, work with access tokens, configure JFrog CLI servers, search artifacts, manage properties, set up replication, manage JFrog Projects, run security audits or scans, look up CVE details, query exposures scan results from JFrog Advanced Security, manage release bundles and lifecycle operations, aggregate or export platform data, or perform any JFrog Platform administration task. Also use when the user mentions jf, jfrog, artifactory, xray, distribution, evidence, apptrust, onemodel, graphql, workers, mission control, curation, advanced security, exposures, or any JFrog product name.
cupynumeric-migration-readiness
IncludedPre-migration readiness assessor for porting NumPy to cuPyNumeric. Use BEFORE substantial porting work begins when the user asks whether code will scale on GPU, whether they should migrate to cuPyNumeric, which NumPy patterns transfer cleanly, what must be refactored before porting, or mentions pre-port assessment, scaling analysis, or refactor planning. Inspect the user's source code, look up NumPy usage, cross-reference the cuPyNumeric API support manifest, and distinguish distributed-scaling-friendly patterns from blockers such as unsupported APIs, scalar synchronization, host round-trips, Python/object-heavy control flow, shape/data-dependent branching, and in-place mutation hazards. Produce a verdict of READY, LIGHT REFACTOR, SIGNIFICANT REFACTOR, or NOT RECOMMENDED, with concrete refactor pointers.
alibabacloud-data-agent-skill
IncludedInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
token-optimizer
IncludedReduce OpenClaw token usage and API costs through smart model routing, heartbeat optimization, budget tracking, and native 2026.2.15 features (session pruning, bootstrap size limits, cache TTL alignment). Use when token costs are high, API rate limits are being hit, or hosting multiple agents at scale. The 4 executable scripts (context_optimizer, model_router, heartbeat_optimizer, token_tracker) are local-only — no network requests, no subprocess calls, no system modifications. Reference files (PROVIDERS.md, config-patches.json) document optional multi-provider strategies that require external API keys and network access if you choose to use them. See SECURITY.md for full breakdown.
resend-cli
IncludedUse this skill when the task is specifically about operating Resend from an AI agent, terminal session, or CI job via the official resend CLI: installing/authenticating the CLI, sending/listing/updating/cancelling emails, batch sends, domains and DNS, webhooks and local listeners, inbound receiving, contacts, topics, segments, broadcasts, templates, API keys, profiles, or debugging Resend CLI/API failures. Trigger on mentions of Resend CLI, `resend`, `resend doctor`, `resend emails send`, `resend domains`, `resend webhooks listen`, `resend emails receiving`, or agent-friendly terminal automation.
alibabacloud-odps-maxframe-coding
IncludedUse this skill for MaxFrame SDK development and documentation navigation on Alibaba Cloud MaxCompute (ODPS). Helps answer MaxFrame API, concept, official example, and supported pandas API questions; create data processing programs; read/write MaxCompute tables; debug jobs (remote or local); and build custom DPE runtime images. Trigger when users mention MaxFrame, MaxCompute with MaxFrame, ODPS table processing, DPE runtime, MaxFrame docs/examples, DataFrame/Tensor operations, or GPU runtime setup. Works for both English and Chinese queries about Alibaba Cloud data processing with MaxFrame.