music_generator
Input: A text prompt describing the desired music and a music category ID and duration in seconds which needs to be in between 0 to 30 seconds which is optional and defaults to 15 seconds if not provided. Asking User to set the duration in seconds is optional.
Output: We will return the generated music URL to the user.
Functionality: This tool generates music based on a text prompt and selected music category ID. It follows these steps:
Gets user_id from context and validates tokens.
Generates music using the prompt and category ID.
Retrieves the final music URL from the queue.
Args: prompt: Text description of the desired music music_category_id: The ID of the music category (integer)
Returns: The URL of the generated music file
INSTRUCTION FOR CLIENT MODEL:
Extract the required input parameters 'prompt' (type: string, describing the desired music) and 'music_category_id' (type: integer) from the user's prompt.
The music_category_id should be a valid integer ID from the available categories.
Ignore any extraneous information in the user's input.
Pass the extracted values to this tool as 'prompt' and 'music_category_id'.
RECOMMENDATION: Call get_music_categories() first to see available category IDs before choosing a music_category_id.
Example: For user input "Create a jazz song about summer rain with category ID 5", extract 'prompt' as 'about summer rain' and 'music_category_id' as 5.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | ||
| duration | No | ||
| music_category_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |