Generate music using ElevenLabs Music API - instrumental tracks, songs with lyrics, and fine-grained composition plans
95
93%
Does it follow best practices?
Impact
99%
2.30xAverage score across 5 eval scenarios
Passed
No known issues
Python music generation basics
Correct Python package
100%
Correct import statement
100%
Client initialization
100%
Environment variable auth
100%
Uses music.compose method
100%
Passes prompt parameter
100%
Passes music_length_ms
100%
Valid duration value
100%
Streaming audio write
100%
MP3 output format
100%
Error handling present
100%
JavaScript composition plan workflow
Correct JS package
100%
No deprecated package
100%
Correct client import
100%
Client instantiation
100%
Composition plan creation
78%
Plan inspection step
100%
Two-step workflow
97%
Mutually exclusive params
100%
Stream handling
100%
Env var authentication
100%
Music length parameter
100%
Content safety and error handling
Catches bad_prompt error
94%
Uses prompt_suggestion
100%
Retries with suggestion
100%
Handles bad_composition_plan
81%
Uses composition_plan_suggestion
83%
Unsafe prompt example
100%
Safe prompt example
100%
Correct SDK usage
100%
Streaming audio save
100%
Logging present
100%
Returns meaningful result
100%
Detailed composition with metadata
Uses compose_detailed
100%
Accesses json field
100%
Accesses filename field
100%
Uses filename for saving
100%
Accesses audio field
100%
Audio as bytes
100%
Saves metadata to JSON
100%
Correct Python import
100%
Passes prompt parameter
100%
Passes music_length_ms
100%
Prints metadata summary
100%
Env var authentication
100%
REST API and advanced parameters
Correct API endpoint
100%
Correct auth header
100%
Reads key from environment
100%
Uses force_instrumental
100%
Force instrumental with prompt
100%
Valid jingle duration
100%
Valid ambient duration
100%
Valid sting duration
100%
JSON content type
100%
Sends JSON body
100%
Saves to MP3 files
100%
Script is executable
100%
Three distinct tracks
100%