Sand AISand AI MAGI-2MAGI-2 est maintenant sur SandBase : vidéo 1080p avec audio natifEssayer maintenant

Index TTS 2.0

sandbase-ai/index-tts-2

Index TTS 2.0 from bilibili's IndexTeam speaks text in the voice of a reference recording (zero-shot cloning) and controls emotion separately through a second reference clip, per-emotion strengths, or a text description.

Prix de base
$0.02USD / exécution
Exécution
async
Type de modèle
audio
Champs d'entrée
7
Route de production

Essayer le modèle

Bac à sable

Ouvrir le Playground
Entrée
The text to speak.
Reference speech audio file or URL; the output is spoken in this voice (zero-shot cloning).
Optional audio file or URL whose emotional style is transferred to the output.
01
Strength of the emotional style transfer. Higher values give stronger emotional influence. Plage : de 0 à 1.
Per-emotion strengths (0-1) for fine-grained control: happy, angry, sad, afraid, disgusted, melancholic, surprised, calm.
Derive emotional strengths from the text (or from emotion_prompt when set). Overrides emotional_strengths.
Text whose emotion is used instead of the spoken text. Requires should_use_prompt_for_emotion.
SortiePrêt

Votre sortie apparaîtra ici

Complétez les entrées, puis cliquez sur Exécuter.

Fiche modèle

Spécifications

Tarification

Prix de base
$0.02 / exécution

Contexte et modalités

Entrée
Défini par le schéma
Sortie
audio

Fonctionnalités

Chat
Non pris en charge
Vision
Non pris en charge
Raisonnement
Non pris en charge
Sortie structurée
Non pris en charge
Appel de fonction
Non pris en charge
Entrée audio
Non pris en charge

Accès

Fournisseur
sandbase-ai
ID du modèle
sandbase-ai/index-tts-2
Exécution
async
URL de base
https://api.sandbase.ai
API
Unified Run API
Point de terminaison
/v1/run

README de l'API

Index TTS 2.0

Index TTS 2.0 clones the voice in a reference clip and speaks new text with it. Emotion is controlled separately: from a second reference clip, eight per-emotion strengths, or the emotion inferred from text.

Fields

FieldTypeDefaultNotes
textstring, required—Text to speak.
audioaudio file or URL, required—Voice to clone.
emotional_audioaudio file or URL—Clip whose emotional style is transferred.
strengthnumber 0–11Strength of the emotional style transfer.
emotional_strengthsobject of numbers 0–1—happy, angry, sad, afraid, disgusted, melancholic, surprised, calm.
should_use_prompt_for_emotionbooleanfalseInfer emotion from the text or emotion_prompt; overrides emotional_strengths.
emotion_promptstring—Text describing the emotion; used when should_use_prompt_for_emotion is true.

Billing

$0.002 per second of generated audio. The quote before submission assumes 10 seconds; the final charge uses the measured output length.

OutputPrice
10 seconds$0.02
30 seconds$0.06
1 minute$0.12

Failed runs are not charged.

Prompting

  • Use a clean 5–15 second reference clip of a single speaker.
  • Pick one emotion control: a reference clip, emotional_strengths, or should_use_prompt_for_emotion.

Commencer à construire

Envoyez votre première requête

Point de terminaison compatible OpenAI avec authentification unifiée et suivi de l'utilisation.

API de production
point de terminaison Unified Run API
https://api.sandbase.ai/v1/run
ID du modèle
sandbase-ai/index-tts-2
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
  -X POST "https://api.sandbase.ai/v1/run" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  --data-binary @- <<'SANDBASE_JSON'
{
  "model": "sandbase-ai/index-tts-2",
  "text": "Hide! He's coming! He's coming to get us!",
  "audio": "https://storage.googleapis.com/falserverless/example_inputs/index-tts-2/tts_in.mp3",
  "strength": 1,
  "emotion_prompt": "You scared me to death! What are you, a ghost?",
  "should_use_prompt_for_emotion": false
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
  status=$(printf '%s' "$result" | jq -r .status)
  case "$status" in completed|failed|timeout) break ;; esac
  sleep 2
  result=$(curl --fail-with-body --silent \
    -H "Authorization: Bearer $SANDBASE_API_KEY" \
    "https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"
01

Schéma d'entrée

7 paramètres · 2 obligatoires · 5 facultatifs

ParamètreTypeObligatoireDescription
textstringObligatoireThe text to speak.
audiostringObligatoireReference speech audio file or URL; the output is spoken in this voice (zero-shot cloning).
strengthnumberFacultatifStrength of the emotional style transfer. Higher values give stronger emotional influence. · Min : 0 · Max : 1 · Par défaut : 1
emotion_promptstringFacultatifText whose emotion is used instead of the spoken text. Requires should_use_prompt_for_emotion.
emotional_audiostringFacultatifOptional audio file or URL whose emotional style is transferred to the output.
emotional_strengthsobjectFacultatifPer-emotion strengths (0-1) for fine-grained control: happy, angry, sad, afraid, disgusted, melancholic, surprised, calm.
should_use_prompt_for_emotionbooleanFacultatifDerive emotional strengths from the text (or from emotion_prompt when set). Overrides emotional_strengths. · Par défaut : false
02

Schéma de sortie

ChampTypeDescription
idstringIdentifiant unique de la tâche de génération
statusstringStatut de la tâche : pending, running, completed, failed, timeout
modelstringModèle utilisé pour la génération
outputsarrayTableau des éléments de sortie
outputs[].urlstringURL de l'artefact généré
outputs[].content_typestringType MIME (par ex. image/png, video/mp4)
errorobject | nullDétails de l'erreur en cas d'échec, null en cas de succès
error.typestringCode de type d'erreur lisible par machine
error.messagestringDescription de l'erreur lisible par l'humain

Flux de travail asynchrone

Ce modèle s’exécute de manière asynchrone. Envoyez une requête, puis interrogez le résultat.

  1. Envoyer : faites un POST vers /v1/run et lisez le id renvoyé.
  2. Interroger : faites un GET sur /v1/run/{id} jusqu’à ce que le statut soit completed, failed ou timeout.
  3. Récupérer : lisez outputs dans la réponse terminée.

Choisissez votre modèle

Comparer les modèles

Tous les modèles d’image et de vidéo
ModèleTypePrix par défautLancement
Index TTS 2.0Ce modèle
sandbase-ai
Audio$0.02 / exécution7 oct. 2025
SandBase AIAudio$0.01 / exécution16 juin 2026
SandBase AIAudio$0.06 / exécution7 janv. 2026
SandBase AIAudio$0.01 / exécution24 oct. 2025
SandBase AIAudio$0.05 / exécution4 avr. 2025
SandBase AIAudio$0.05 / exécution4 avr. 2025

Questions

FAQ

Comment appeler sandbase-ai Index TTS 2.0 via SandBase ?

Créez une clé API SandBase, puis envoyez des requêtes avec l’identifiant de modèle "sandbase-ai/index-tts-2" à Unified Run API (/v1/run) sur https://api.sandbase.ai. Les exemples de requêtes sur cette page montrent la charge utile exacte.

Ai-je besoin d’un compte sandbase-ai distinct ?

Non. Une seule clé API SandBase et un seul solde vous donnent accès à sandbase-ai Index TTS 2.0 et aux autres modèles du catalogue ; vous n’avez pas besoin de créer un compte sandbase-ai séparément.