threejs-audio-generator

Generate and process game audio assets for Three.js projects using the ElevenLabs API.

1|Updated Aug 20, 2023
One-click install
npx skills add https://github.com/imanlangaran/mini-projects --skill threejs-audio-generator-imanlangaran
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: threejs-audio-generator
Source: https://github.com/imanlangaran/mini-projects/tree/main/building-sell/.claude/skills/threejs-audio-generator
Command: npx skills add https://github.com/imanlangaran/mini-projects --skill threejs-audio-generator-imanlangaran

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve? Creating sound effects, ambience loops, and voice lines for browser-based Three.js games typically requires sourcing audio libraries or hiring voice talent. This Skill generates game-ready audio assets directly from text prompts via the ElevenLabs API and provides guidance for wiring them into a Web Audio runtime. ## Core Features & Use Cases - SFX and Ambience Generation: Create short sound effects (hits, pickups, UI clicks) and seamless looping ambience beds with duration, loop, and prompt-influence controls. - Voice Workflows: Generate TTS announcer lines, clean noisy dialogue with audio isolation, and convert scratch performances into target character voices via speech-to-speech. - Runtime Integration Guidance: Includes a reference covering audio matrices, prompting strategy, Web Audio manager patterns, volume groups, and autoplay unlock handling. - Use Case: While building a Three.js racing game, generate a boost pickup SFX, a looping track ambience, and an announcer voice line, then map them to gameplay events through a grouped audio manager. ## Quick Start Ask the AI to use the threejs-audio-generator skill to probe the ElevenLabs API key and generate a short jump sound effect saved to assets/audio/sfx/jump.mp3.

Frequently Asked Questions about threejs-audio-generator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate sound effects for a Three.js game?

Run the threejs_audio_asset.py script with the sfx subcommand, providing a descriptive prompt, duration, and output path. It calls the ElevenLabs sound-generation endpoint and saves an MP3 file ready for Web Audio loading.

How do I create a seamless looping ambience with ElevenLabs?

Use the sfx subcommand with the --loop flag and a duration of 8-30 seconds. The script passes the loop parameter to the ElevenLabs API, which generates audio designed to loop seamlessly in the game.

Can I convert a recorded voice performance into a character voice?

Yes, the voice-change subcommand uses ElevenLabs speech-to-speech to convert a scratch recording into a target voice ID while preserving timing and emotion. You can optionally enable background noise removal during conversion.

Why does the script report ELEVENLABS_API_KEY as missing?

Keys defined only in a shell profile may not appear in the process environment. Run the probe subcommand first, and if it prints MISSING unexpectedly, wrap it in a login shell that sources your profile files.

How should generated audio be integrated into a Three.js game?

Load files through a Web Audio manager after a user gesture unlocks the AudioContext, organize sounds into volume groups like sfx, ui, and ambience, and loop ambience via AudioBufferSourceNode. The references file includes a minimal implementation pattern.