Google Lyria โ
Endpoint: POST https://mps.intl.tencentcloudapi.comAction: CreateAigcAudioTask
Google Lyria is a music generation model: write the style and lyrics in a single prompt to generate a song (lyrics are written automatically if omitted), with 192 kbps output. 3.0-clip produces about 30 seconds for intros and short stings, while 3.0-pro produces about 2.5 minutes for full tracks.
Basic Information โ
| Item | Value |
|---|---|
| ModelName | GL |
| ModelVersion | 3.0-clip / 3.0-pro |
| SceneType | music |
Two versions are available: clip and full track.
Request Parameters โ
| Parameter | Required | Type | Description |
|---|---|---|---|
ModelName | Required | String | Fixed value GL |
ModelVersion | Optional | String | 3.0-clip or 3.0-pro |
SceneType | Required | String | music |
Prompt | Required | String | Describe the genre, instrumentation, mood, and tempo in detail |
Duration | Optional | Integer | Length (seconds). 0~60 |
OutputAudioFormat | Optional | String | mp3 |
Use ModelName=GL. It appears as Google Lyria in the console.
Request Example โ
{
"ModelName": "GL",
"ModelVersion": "3.0-pro",
"SceneType": "music",
"Prompt": "an epic orchestral soundtrack with rising tension, strings and brass. Lyrics: Hold on to the light, we will make it through the night",
"Duration": 30,
"Operator": "admin"
}Response Example โ
{
"Response": {
"Status": "DONE",
"Message": "ok",
"AudioInfos": [
{
"Url": "https://aigc-output-audio-file-<id>.cos.<region>.myqcloud.com/<file>.mp3?q-sign-algorithm=sha1&..."
}
],
"VideoInfos": ,
"RequestId": "<request-id>"
}
}Special Configuration โ
Version Comparison โ
| Item | 3.0-clip | 3.0-pro |
|---|---|---|
| Length | About 30 seconds | About 2 minutes 30 seconds or longer |
| Processing time | Short | Long |
| File size | Small | Large |
| Use case | Intros, short incidental music | Complete tracks |
Prompt Writing Rules โ
GL puts the lyrics and the style into a single prompt.
Specifying Both Lyrics and Style โ
{style description}
Lyrics:
{lyrics}Leave one blank line between the style description and the lyrics, and place the lyrics after the Lyrics: line.
Specifying Style Only โ
If you omit the lyrics field, the model generates the lyrics automatically.
Instrumental Only โ
Append instrumental, no vocals. after the style description.
Follow the format for the lyrics to take effect
The Lyrics: notation and the blank lines before and after it are required for the model to recognize the lyrics. If the format is wrong, the lyrics are treated as part of the style description.