Tiangong AI Music Composition: Generating Instrumental and Vocal Tracks via HTTP APIs within an Agent

Preface

When making short videos, podcasts, or product demos, background music often gets stuck at two steps: “finding assets” and “copyright”. Ready-made BGM tends to clash in style, while writing your own music lacks the toolchain. Integrating music generation into a conversational Agent, the ideal state is: describe the scene in natural language, and the Skill submits the task via a fixed interface, polls the progress, and returns a playable link.

Below is an introduction to Tiangong Music AI Songwriting (@user_e493aefd/xing-he-tiangong-music) on SkillHub. It wraps the music service provided by Xinghe Shiguang into a universal SKILL.md. The Agent only makes HTTP REST calls to https://ai.growingth.com/api, without relying on MCP or web scraping. After installation, you can complete songwriting, scoring, cover versions, and accompaniment separation workflows in conversation within clients that support Skills, such as Cursor.

What is this

Tiangong Music AI Songwriting is a design-media class Skill from community source (community), published by user_e493aefd. The SkillHub store page marks the version as v1.1.2.

In one sentence: an AI music creation assistant for Agents, connecting to Suno-style songwriting and arrangement capabilities, supporting video scoring, BGM, light music, running/dance accompaniment, cover versions, and accompaniment separation. The official introduction also states that commercial copyright certificates can be obtained, and it can be used across multiple platforms including the Tiangong Music mini-program, App, and web https://xhyue.com with data sharing.

The store-side tags include requires_api_key=true: business interfaces require configuring MIAOYIN_API_TOKEN in the Skill directory’s config.json (obtained via WeChat scan or backup login page). Anonymous calls are not allowed.

Core Functions

The following capabilities are all from the official Skill documentation (SKILL.md / api.md), divided by interface:

  1. Song Generation (generateCustom): Submit a task based on lyrics prompt, style tags, optional title, and make_instrumental (instrumental). The default model is chirp-v5.
  2. Status Query (getMusic): Use taskId or song id to check queued, generating, completed, or failed states. After submission, the Agent should automatically poll every 10 seconds as documented. The interval must not be shorter than 10 seconds.
  3. Continuation (generateContinue): Extend an existing track from a specified second continue_at.
  4. Cover / Remix (generateCover): Change style, lyrics, or timbre parameters while preserving the main melody.
  5. Merge Continuation (concat): Merge the continuation fragment with the parent track into a complete version.
  6. Generate Video (generateVideo): Generate a video version for a completed song.
  7. WAV Export (makeWav): Convert to lossless WAV (documentation notes this may be subject to copyright policy restrictions).
  8. Accompaniment Separation (generateStem): Modes such as two / twelve / dry; the documentation explicitly states that vocal extraction is not supported, only accompaniment-related tracks.

Interaction layer rules (constraints for Agents using the Skill, which also affect your experience as a user):

  • When there is a creative intent, first confirm lyrics and style, then login or submit; when not logged in, do not default to popping up a QR code. The user needs to send “Login” before proceeding with WeChat scanning or Backup Login.
  • After generation is complete, the externally displayed audio/cover domain needs to be rewritten (e.g., cdn1.suno.ai → file.growingth.com/song/sv4), and a clickable audio link and an HTML preview page should be provided simultaneously as much as possible.

Installation and Activation

1. Install SkillHub CLI (if not installed)

First check if the CLI is already available:

command -v skillhub && skillhub --version

If not installed, you can follow the official SkillHub instructions (full installation example):

curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash

2. Install this Skill

When installing, you must use --dir to point to the current Agent’s skills directory; otherwise, if it defaults to ./skills/, it may not be loaded by the client.

The common path for Cursor is ~/.cursor/skills/:

skillhub install xing-he-tiangong-music --namespace user_e493aefd --dir ~/.cursor/skills/

You can also ask the Agent in conversation to install the coordinates according to the SkillHub installation instructions:

Please install `@user_e493aefd/xing-he-tiangong-music` according to https://skillhub.cn/install/skillhub.md.

Other client paths (from the same installation document, select as needed):

  • Claude Code: ~/.claude/skills/
  • Codex: ~/.codex/skills/ or .agents/skills/ under the project
  • Windsurf: ~/.codeium/windsurf/skills/ or .windsurf/skills/

After installation, restart the client or reload Skills as required by the product.

3. Login and Configuration

The initial form of config.json under the Skill directory is:

{
  "MIAOYIN_API_TOKEN": ""
}

After successful login, write the API Key into MIAOYIN_API_TOKEN. The environment variable with the same name is only for compatibility (environment variables are read only when config is empty). Balance can be checked at https://xhyue.com/skill/connect.

The package also provides install.sh, with the default target being OpenClaw’s ~/.openclaw/workspace/skills/miaoyin-ai-music; if you are using Cursor or other clients, it is still recommended to prioritize the skillhub install --dir method above to avoid installing into unrecognized directories.

Typical Usage

In an Agent where the Skill is installed and loaded, you can directly use natural language. Examples given in the documentation include:

  • “Help me generate a pop song about summer, with piano and guitar”
  • “Check if the song from just now is ready”
  • “Show my recent music list”
  • “Get the lyrics for this song”

The Agent should follow SKILL.md to first understand the requirements (organize style and lyrics and ask you to confirm), then check if config.json has the key; if not logged in, guide the preview and send “Login”, and submit the generation with the remembered plan after successful login.

Underlying API Form (for verifying behavior)

All business requests use a fixed Base URL of https://ai.growingth.com/api, with methods primarily POST. Headers use api-token (except for login-related interfaces), the body is JSON, and most interfaces are shaped like:

{
  "name": "operation name",
  "data": { }
}

Submit Generation example (generateCustom):

curl -X POST 'https://ai.growingth.com/api/song/proxy?name=generateCustom' \
  -H 'Content-Type: application/json; charset=utf-8' \
  -H 'api-token: YOUR_MIAOYIN_API_TOKEN' \
  -d '{
    "data": {
      "prompt": "pop song about summer",
      "tags": "Piano, Guitar",
      "model": "chirp-v5",
      "make_instrumental": false
    }
  }'

On success, returns data[0].taskId, then use getMusic to query (documentation requires polling interval ≥10 seconds):

curl -X POST 'https://ai.growingth.com/api/song/proxy?name=getMusic' \
  -H 'Content-Type: application/json; charset=utf-8' \
  -H 'api-token: YOUR_MIAOYIN_API_TOKEN' \
  -d '{
    "data": {
      "ids": "c13975cda17449da2261"
    }
  }'

Scan Code Login Session (no api-token needed):

curl -X POST 'https://ai.growingth.com/api/music/skill/connect/session' \
  -H 'Content-Type: application/json; charset=utf-8' \
  -d '{ "type": "skill" }'

After returning sid and qrcode, the Agent polls GET https://ai.growingth.com/api/music/skill/connect/status?sid={sid} every 5 seconds as documented. On success, writes the token to config.json.

For more complete parameter tables and interfaces such as continuation/cover/separation, refer to api.md in the Skill package.

Applicable Scenarios and Notes

Who is it for

  • Teams or individuals who need to quickly produce BGM, light music, short video scores within Agent workflows and want to integrate with the xhyue.com account system.
  • Those who accept usage/quota billing (when the balance is insufficient, the documentation points to https://xhyue.com/skill/pay and the WeChat mini-program “Tiangong Music AI Songwriting”).
  • Those willing to let the Agent strictly poll and display progress according to the Skill documentation, rather than manually asking “is it ready?” repeatedly.

Limitations and Notes

  1. API Key Required: requires_api_key=true, business interfaces cannot be called without login.
  2. Query Frequency: Automatic polling of getMusic must not be shorter than 10 seconds. Excessive frequency may result in being banned.
  3. Separation Capability: generateStem cannot perform vocal separation; if the requirement is “keep only vocals”, the documentation requires the Agent to directly state that it is not supported.
  4. Copyright and Export: When copyright protection is triggered, high-quality WAV and other exports may fail. You need to switch to original content and retry.
  5. Version and Store Data: Subject to the SkillHub page, the current version is v1.1.2; as of the crawl, the store shows a rating of 100000 and approximately 1806 downloads (data will change over time).
  6. Agent Environment: If using an embedded browser to play the result page, the sandbox CSP needs to allow https://file.growingth.com, otherwise audio may be blocked (see item 15 of the Skill documentation).

Conclusion

Tiangong Music AI Songwriting converges songwriting, scoring, cover versions, and accompaniment processing into a set of HTTP APIs and detailed Agent operation procedures. It is suitable for hanging in the Skills directory of clients like Cursor, completing from plan confirmation to track delivery via conversation. Installation and details are subject to SkillHub:

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye