sunobark-small
Bark¶
Selects a Bark history prompt and bounds semantic token sampling.
Parameter metadata: Not reported: the audited metadata available for the registered default does not provide an exact parameter total.
Usage¶
Complete the VoiceHub installation once, then run this repository-authored example. Model pages intentionally contain no package-install command.
This example is maintained against VoiceHub's public API; it is not copied from an upstream demo or package README.
Model-specific path: Selects a Bark history prompt and bounds semantic token sampling.
Inputs and controls: History-prompt names are checkpoint assets and can encode voice plus acoustic context.
from pathlib import Path
from voicehub import AutoModelForTextToSpeech, TTSGenerationConfig
model = AutoModelForTextToSpeech.from_pretrained(
'suno/bark-small',
model_type='bark',
device="cuda",
lazy_load=True,
)
output = model.generate(
'VoiceHub keeps model integrations explicit and reproducible.',
generation_config=TTSGenerationConfig(
seed=42,
output_file=Path("output.wav"),
),
voice_preset="v2/en_speaker_6",
temperature=0.7,
max_new_tokens=768,
)
print(output.file_path, output.sample_rate, output.metadata)
Use authorized recordings. Verify hardware needs and pin a revision in production.
Overview¶
bark is a VoiceHub text to speech
integration. This page is generated from its registry contract. Open the bark Colab notebook.
| Property | Value |
|---|---|
| Task | Text to speech |
| Architecture | bark |
| Runtime | VoiceHub-native |
| Languages | de, en, es, fr, … complete audited list below |
| Capabilities | text-to-speech, expressive-speech, voice-prompt, safetensors, fine-tuning, voicehub-native, native-runtime, preencoded-stage-training, restricted-pickle-conversion |
| Reusable components | encodec |
| Normalized output | TTSOutput |
Language support¶
Supported language abbreviations
de, en, es, fr, hi, it, ja, ko, pl, pt, ru, tr, zh
Paper and GitHub¶
- Paper: No dedicated upstream research paper is published for this integration.
- Upstream GitHub: Bark
- VoiceHub source: VoiceHub model implementation
Configuration¶
Load configuration without constructing the model:
| Property | Value |
|---|---|
| Canonical model type | bark |
| Configuration class | BarkConfig |
| Architecture class | BarkForTextToSpeech |
Processing¶
Create the registered processor without allocating model weights:
from voicehub import AutoProcessor
processor = AutoProcessor.from_pretrained(
'suno/bark-small',
model_type='bark',
)
print(type(processor).__name__)
Inference¶
The Usage example returns TTSOutput through AutoModelForTextToSpeech.
Input and output contract¶
| Property | Value |
|---|---|
| Readiness | preprocessed |
| Data architecture | hybrid |
| Sample rate | 24,000 Hz |
| Contract getter | get_tts_dataset_spec('bark') |
| Variant | Required fields | One of | Boundary | Other rules |
|---|---|---|---|---|
causal-stage |
input_ids, labels, training_phase |
— | Prepared | — |
fine-stage |
input_ids, labels, codebook_idx, training_phase |
— | Prepared | — |
all-stages |
semantic_input_ids, semantic_labels, coarse_input_ids, coarse_labels, fine_input_ids, fine_labels, codebook_idx |
— | Prepared | — |
Multi-component language-model, diffusion, acoustic, or GAN data. See the data workflow.
Training and optimization¶
Use available_optimization_passes() to discover reversible public passes.
Unsupported runtime or hardware fails closed before mutation.
Training contract¶
| Property | Value |
|---|---|
| Support | preprocessed |
| Family | composite |
| Recipe | multi-phase |
| Default phase | semantic |
| Training checkpoint | suno/bark-small |
| Native training graph | yes |
| Phase | Kind | Components | Required inputs | Loss keys |
|---|---|---|---|---|
semantic |
objective | training_model.semantic |
input_ids, labels |
loss |
coarse |
objective | training_model.coarse |
input_ids, labels |
loss |
fine |
objective | training_model.fine |
input_ids, labels, codebook_idx |
loss |
Prepare the exact tensors listed in the data contract before this step. Call model.validate_training_support() first, then follow the
training workflow.
Checkpoints, provenance, license, and limitations¶
| Property | Value |
|---|---|
| Default checkpoint | suno/bark-small |
| Hugging Face ID | suno/bark-smallRepository availability verified through the Hugging Face model API on 2026-08-11; pin a revision before production use. |
| Checkpoint status | Registry default; pin an immutable revision for production and reproducible evidence |
| Optional dependency extra | Core package |
| Hardware and runtime | Usage selects cuda; verify checkpoint-specific requirements |
| Real-checkpoint evidence | Release evidence; a registry default alone is not execution evidence |
| Implementation | voicehub.models.bark.modeling_bark.BarkForTextToSpeech |
| Configuration | voicehub.models.bark.configuration_bark.BarkConfig |
| Source provenance | voicehub/architectures/bark/SOURCE.json |
| License | Checkpoint-specific |
No VoiceHub-specific license override is registered. Verify the checkpoint and upstream source terms before use.
Confirm the checkpoint revision, access terms, provenance, and license.
Limitations¶
- No integration-specific checkpoint limitation is registered. Verify the selected checkpoint revision and its documented runtime requirements.
- Validate memory, precision, and optional dependencies on the target system.
- Public optimizations fail closed when the runtime or hardware cannot satisfy their validation contract; an unavailable pass is not reported as applied.
- Contract tests do not replace the linked released-checkpoint evidence.
Public API¶
Use the stable configuration, processor, and task-model facades below.
Configuration
BarkConfig¶
Parameters¶
**config_kwargs— Configuration fields validated by BarkConfig.
Model
BarkForTextToSpeech¶
Parameters¶
pretrained_model_name_or_path— Hub ID or compatible local directory.model_type— Canonical model type; use 'bark'.config— Optional preloaded BarkConfig instance.**model_kwargs— Model-specific loading arguments.
from voicehub import get_model_spec
spec = get_model_spec('bark')
print(spec.display_name, spec.task.value)
| Purpose | Public object |
|---|---|
| Discover | get_model_spec('bark') |
| Load and run | AutoModelForTextToSpeech |
| Configure | BarkConfig |
| Process | AutoProcessor |
| Model implementation | BarkForTextToSpeech |
| Normalized output | TTSOutput |
| Training contract | get_training_spec('bark') |
| Optimization lifecycle | available_optimization_passes, apply_optimization_plan, optimization_manifest, restore_optimization_plan |
See all model guides, inference, and the training matrix.