{"categories":[{"label":"Scientific/Engineering","url":"https://skillfed.io/packages/category/scientific-engineering/4"}],"enrichment":{"capability":"Converts audio into discrete semantic speech tokens using a PyTorch implementation of the S3Tokenizer model, supporting batch inference and online extraction during model training.","skillfed_tags":["speech-tokenization","distributed-inference","audio-processing"],"use_cases":["Batch preprocessing of large audio datasets for speech model training with multi-GPU parallelization.","Online speech code extraction during SpeechLLM forward passes to avoid offline preprocessing bottlenecks.","Fine-tuning CosyVoice models when batch-size-1 extraction in the original pipeline is too slow.","Building speech-to-text or speech-to-speech systems that require semantic token representations.","Processing long-form audio (>30 seconds) with automatic windowing and segment batching."],"what_it_does":"S3Tokenizer is a PyTorch reimplementation of the Supervised Semantic Speech Tokenizer originally introduced in CosyVoice. It converts raw audio into discrete semantic tokens that preserve textual and paralinguistic information, designed for use in speech language models. The original authors released only an ONNX version and did not open-source the PyTorch implementation, so this package reverse-engineers that functionality.\n\nThe package provides three main workflows: offline batch inference (with CPU and multi-GPU support via torchrun), online token extraction during SpeechLLM training, and automatic long-audio processing for files longer than 30 seconds. It supports multiple model versions (V1 at 50Hz and 25Hz, V2 25Hz, V3 25Hz) and includes command-line tools for distributed processing. The key advantage over the original pipeline is throughput\u2014batch inference with proper distribution can achieve significant speedups, and online extraction eliminates the need for separate preprocessing passes.","worth_installing":"Yes, if you are training or fine-tuning speech language models (especially CosyVoice-based systems) and need efficient tokenization. The reverse-engineered PyTorch implementation removes a significant bottleneck in the original pipeline, and the package is actively maintained with no known vulnerabilities. The permissive Apache 2.0 license poses no restrictions. Install friction is low. Caveat: the aging maintenance status and relatively small user base (527 stars) mean fewer eyes on edge cases\u2014verify performance on your specific hardware before committing to production."},"id":"s3tokenizer","links":{"html":"https://skillfed.io/packages/s3tokenizer","md":"https://skillfed.io/packages/s3tokenizer.md","pypi":"https://pypi.org/project/s3tokenizer/"},"maintenance":{"status":"aging"},"meta":{"latest_release":"2025-12-22","license_spdx":null,"license_treatment":"permissive","name":"s3tokenizer","python_support":"supports_current","summary":"Reverse Engineering of Supervised Semantic Speech Tokenizer (S3Tokenizer) proposed in CosyVoice"},"popularity":{"monthly_downloads":405827,"position":6899,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"0.3.0"}
