Practical overview
When it fits
Use it when you want to inspect or adapt a PyTorch implementation for text-to-semantic speech modeling, or follow its example dataset-generation code.
Who it is for
- Researchers experimenting with multi-speaker text-to-speech and text-to-semantic modeling.
- PyTorch developers exploring speech-model training, decoding or pseudo-labelled dataset workflows.
Documented uses
- Build a TextToSemantic model using a HuBERT-with-k-means component.
- Generate audio-text dataset files from a supplied dataset through the documented generator.
- Explore a text-to-semantic component intended to condition a SoundStorm pipeline.
Requirements & limits
The repository is public and MIT-licensed. The README documents installation through pip.
- The example depends on local HuBERT checkpoint and k-means files, plus audiolm-pytorch's HubertWithKmeans.
- The README's dataset-generation demonstration uses MockDataset rather than a real speech corpus.
- The repository lists cached key/value support and additional audio-text workflow work as unfinished.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Set up the documented example dataset workflow
Install the library and follow the README's example for generating and loading audio-text dataset files.
Before you start
- Python environment with the documented packages available: PyTorch, audiolm-pytorch, and spear-tts-pytorch.
- HuBERT checkpoint and k-means files at the paths used by the example.
- A dataset; the example uses MockDataset.
Steps
Install the package with the command below.
pip install spear-tts-pytorchInitialize HubertWithKmeans using the checkpoint and k-means paths.
Create TextToSemantic and pass it with a dataset to SemanticToTextDatasetGenerator, specifying an output folder.
Call the generator with a maximum length, then load the output folder with GeneratedAudioTextDataset.
Expected outcome
The example produces files in the specified folder and creates a GeneratedAudioTextDataset from that folder.
Guide limitations
- The README example uses MockDataset(10); it does not document a real-corpus preparation workflow.
- The shown assertion is an example expectation, not an independently verified execution result.
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 15 October 2026
- Original website title
- lucidrains/spear-tts-pytorch · Official homepage title · retained in its source language

