Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问许可证需确认审计异常

modelslab-audio-generationmodelslab 音频生成

Agent Skill

用于辅助音频、音乐、语音转写、语音合成或声音素材处理。它适合让 Agent 生成配乐说明、整理音频流程、调用语音工具或处理播客和视频配音素材。使用时需要确认输入音频来源、输出格式、时长和模型限制;涉及人声克隆、版权音乐或公开发布时,应先核对授权和合规边界。

总安装

642

周安装

27

GitHub Stars

7

下载量

225
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:modelslab-audio-generation(modelslab 音频生成)
来源仓库:https://github.com/modelslab/skills
仓库路径:skills/modelslab-audio-generation
安装命令:
npx skills add https://github.com/modelslab/skills --skill modelslab-audio-generation
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/modelslab/skills --skill modelslab-audio-generation

简介

用于辅助音频处理和语音合成任务。modelslab-audio-generation 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

  • 适合生成配乐说明或处理播客配音素材。
  • 使用时需确认输入音频来源和版权授权。
  • 涉及人声克隆时应特别注意合规边界。
  • 通过 GitHub 安装,建议检查仓库活跃度。

SKILL.md

ModelsLab Audio Generation

Generate high-quality audio including speech, music, voice conversion, sound effects, and dubbing using AI.

When to Use This Skill

  • Convert text to natural-sounding speech (TTS)
  • Transcribe speech to text
  • Transform voice characteristics (speech-to-speech)
  • Generate music from text prompts
  • Create sound effects
  • Dub audio into different languages
  • Extend or inpaint songs
  • Build voice assistants or audiobooks

Available APIs (v7)

Voice Endpoints

  • Text to Speech: POST https://modelslab.com/api/v7/voice/text-to-speech
  • Speech to Text: POST https://modelslab.com/api/v7/voice/speech-to-text
  • Speech to Speech: POST https://modelslab.com/api/v7/voice/speech-to-speech
  • Music Generation: POST https://modelslab.com/api/v7/voice/music-gen
  • Sound Generation: POST https://modelslab.com/api/v7/voice/sound-generation
  • Create Dubbing: POST https://modelslab.com/api/v7/voice/create-dubbing
  • Song Extender: POST https://modelslab.com/api/v7/voice/song-extender
  • Song Inpaint: POST https://modelslab.com/api/v7/voice/song-inpaint
  • Fetch Result: POST https://modelslab.com/api/v7/voice/fetch/{id}
Note: v6 endpoints (/api/v6/voice/text_to_speech, etc.) still work but v7 is the current version. Parameter names have changed in v7 (e.g., text is now prompt, audio is now init_audio).

Discovering Audio Models

# Search audio/voice models
modelslab models search --feature audio_gen

# Search by provider
modelslab models search --search "eleven"

# Get model details
modelslab models detail --id eleven_multilingual_v2

Audio Model IDs

model_idNameUse With
eleven_multilingual_v2ElevenLabs Multilingual v2text-to-speech
eleven_english_sts_v2ElevenLabs Voice Changerspeech-to-speech
scribe_v1ElevenLabs Scribespeech-to-text
eleven_sound_effectElevenLabs Sound Effectssound-generation
music_v1ElevenLabs Musicmusic-gen
inworld-tts-1Inworld TTStext-to-speech

Text to Speech

import requests
import time

def text_to_speech(text, api_key, voice_id="21m00Tcm4TlvDq8ikWAM", model_id="eleven_multilingual_v2"):
    """Convert text to speech.

    Args:
        text: The text to convert to speech
        api_key: Your ModelsLab API key
        voice_id: ElevenLabs voice ID (see Available Voices below)
        model_id: TTS model to use
    """
    response = requests.post(
        "https://modelslab.com/api/v7/voice/text-to-speech",
        json={
            "key": api_key,
            "prompt": text,             # v7 uses "prompt" not "text"
            "voice_id": voice_id,
            "model_id": model_id
        }
    )

    data = response.json()

    if data["status"] == "success":
        return data["output"][0]
    elif data["status"] == "processing":
        return poll_audio_result(data["id"], api_key)
    else:
        raise Exception(f"Error: {data.get('message', 'Unknown error')}")

# Usage
audio_url = text_to_speech(
    "Hello! Welcome to ModelsLab. This is a test of our text-to-speech API.",
    "your_api_key"
)
print(f"Audio URL: {audio_url}")

Speech to Text (Transcription)

def speech_to_text(audio_url, api_key, model_id="scribe_v1"):
    """Transcribe speech from audio to text.

    Args:
        audio_url: URL of audio file (must be publicly accessible)
        model_id: STT model to use
    """
    response = requests.post(
        "https://modelslab.com/api/v7/voice/speech-to-text",
        json={
            "key": api_key,
            "init_audio": audio_url,    # v7 uses "init_audio" not "audio"
            "model_id": model_id
        }
    )

    data = response.json()

    if data["status"] == "success":
        return data["output"][0]
    elif data["status"] == "processing":
        return poll_audio_result(data["id"], api_key)
    else:
        raise Exception(data.get("message"))

# Transcribe audio
result = speech_to_text(
    "https://example.com/speech.mp3",
    "your_api_key"
)
print(f"Transcription: {result}")

Speech to Speech (Voice Conversion)

def speech_to_speech(audio_url, voice_id, api_key, model_id="eleven_english_sts_v2"):
    """Convert voice characteristics in audio.

    Args:
        audio_url: URL of the source audio
        voice_id: Target ElevenLabs voice ID
        model_id: Voice conversion model
    """
    response = requests.post(
        "https://modelslab.com/api/v7/voice/speech-to-speech",
        json={
            "key": api_key,
            "init_audio": audio_url,
            "voice_id": voice_id,
            "model_id": model_id
        }
    )

    data = response.json()
    if data["status"] == "success":
        return data["output"][0]
    elif data["status"] == "processing":
        return poll_audio_result(data["id"], api_key)

Sound Effects Generation

def generate_sound_effect(description, api_key, model_id="eleven_sound_effect"):
    """Generate a sound effect from a text description.

    Args:
        description: What sound to generate
        model_id: Sound effects model
    """
    response = requests.post(
        "https://modelslab.com/api/v7/voice/sound-generation",
        json={
            "key": api_key,
            "prompt": description,
            "model_id": model_id
        }
    )

    data = response.json()
    if data["status"] == "success":
        return data["output"][0]
    elif data["status"] == "processing":
        return poll_audio_result(data["id"], api_key)

# Generate door slam sound
sfx_url = generate_sound_effect(
    "Heavy wooden door slamming shut",
    "your_api_key"
)

Music Generation

def generate_music(prompt, api_key, model_id="music_v1"):
    """Generate music from a text description.

    Args:
        prompt: Description of music style/mood
        model_id: Music generation model
    """
    response = requests.post(
        "https://modelslab.com/api/v7/voice/music-gen",
        json={
            "key": api_key,
            "prompt": prompt,
            "model_id": model_id
        }
    )

    data = response.json()
    if data["status"] == "success":
        return data["output"][0]
    elif data["status"] == "processing":
        return poll_audio_result(data["id"], api_key)

# Generate background music
music_url = generate_music(
    "Upbeat electronic music with a driving beat, perfect for a tech startup video",
    "your_api_key"
)
print(f"Music: {music_url}")

Polling for Async Results

def poll_audio_result(request_id, api_key, timeout=300):
    """Poll for async audio generation results."""
    start_time = time.time()

    while time.time() - start_time < timeout:
        fetch = requests.post(
            f"https://modelslab.com/api/v7/voice/fetch/{request_id}",
            json={"key": api_key}
        )
        result = fetch.json()

        if result["status"] == "success":
            return result["output"][0]
        elif result["status"] == "failed":
            raise Exception(result.get("message", "Generation failed"))

        time.sleep(5)

    raise Exception("Timeout waiting for audio generation")

Available ElevenLabs Voice IDs

Voice IDNameStyle
21m00Tcm4TlvDq8ikWAMRachelNeutral, calm
AZnzlk1XvdvUeBnXmlldDomiConfident
EXAVITQu4vr4xnSDxMaLBellaSoft, warm
ErXwobaYiN019PkySvjVAntoniWell-rounded
MF3mGyEYCl7XYWbV9V6OElliYoung, clear
TxGEqnHWrfWFTfGW9XjXJoshDeep, warm
VR6AewLTigWG4xSOukaGArnoldStrong
pNInz6obpgDQGcFmaJgBAdamDeep, narrative
yoZ06aMxZJJ28mfd3POQSamDynamic

Key Parameters

Text to Speech

ParameterTypeRequiredDescription
promptstringYesText to convert to speech
voice_idstringYesElevenLabs voice identifier
model_idstringYesTTS model (e.g., eleven_multilingual_v2)
temperaturefloatNoVoice variation
webhookstringNoAsync notification URL

Speech to Text

ParameterTypeRequiredDescription
init_audiostringYesURL of audio to transcribe
model_idstringYesSTT model (e.g., scribe_v1)

Sound Generation

ParameterTypeRequiredDescription
promptstringYesSound effect description
model_idstringYesSFX model (e.g., eleven_sound_effect)

v6 to v7 Parameter Changes

v6 Parameterv7 ParameterNotes
textpromptTTS text input
audioinit_audioSTT/STS audio input
target_audioinit_audioVoice-to-voice source
(not required)model_idNow required on all endpoints

Best Practices

1. Use Correct Voice IDs

TTS requires valid ElevenLabs voice IDs (not generic names like "alloy").

2. Ensure Audio Accessibility

Audio URLs for speech-to-text must be publicly accessible without redirects or authentication.

3. Use Webhooks for Long Operations

payload = {
    "key": api_key,
    "prompt": "...",
    "model_id": "eleven_multilingual_v2",
    "webhook": "https://yourserver.com/webhook/audio",
    "track_id": "audio_001"
}

Error Handling

try:
    audio = text_to_speech(text, api_key)
    print(f"Audio generated: {audio}")
except Exception as e:
    print(f"Audio generation failed: {e}")

Resources

Related Skills

  • modelslab-model-discovery - Find and filter models
  • modelslab-video-generation - Add audio to videos
  • modelslab-chat-generation - Chat with LLM models
  • modelslab-webhooks - Handle async audio generation

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

38.1%
按下载量换算86

Claude

31.28%
按下载量换算70

Cursor

16.75%
按下载量换算38

Gemini CLI

8.69%
按下载量换算20

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

未通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills