anaksor-ocr
Sokheng · Kit
Reads Khmer and English text from documents, receipts and photos of signs, using a detector for text lines and a recogniser for each line. Suits developers who…
Compresses speech into a fixed number of variable-length events with durations, and decodes them back as it streams. A neural speech codec for people building streaming text-to-speech in English, Japanese and Chinese.
RubatoCodec is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on . Download it on this page, a zip of its files. Nothing in it runs by itself.
cd RubatoCodec uv sync
RubatoCodec is a neural speech codec. It splits speech into a fixed number of events, each with discrete code indices and a duration. Because the event count follows the utterance length exactly, a speech generator knows in advance how many tokens it must produce. A causal decoder renders finished events step by step, which suits streaming text-to-speech.
Researchers and developers who build speech generation systems and need a predictable token budget with streaming decoding.
| Industry | Who uses it | How they use it | Example |
|---|---|---|---|
| Speech AI | Researchers | Use the codec as the token layer for speech generators | Train a text-to-speech model on its codes |
| Software | Developers | Add streaming speech decoding to an app | Render speech as events arrive |
| Research | Audio engineers | Study low-bitrate speech coding | Compare reconstructions at two depths |
If you want a ready speech enhancement or transcription tool, you can skip it.
| Use case | Who | What they get back |
|---|---|---|
| Encoding speech | Researchers | Event codes and durations from a waveform |
| Decoding speech | Developers | Audio at 44.1 kHz |
| Lower bitrate decoding | Developers | Audio from only the first layers |
cd RubatoCodec uv sync
To fetch only the codec weights, use the Hugging Face steps.
pip install -U huggingface_hub hf download third-intelligence/RubatoCodec
Load the codec, read a mono waveform, encode it to codes and durations, then decode. Passing a depth value decodes with fewer layers for a lower bitrate.
import soundfile as sf
import torch
from rubatocodec import RubatoCodec
codec = RubatoCodec.from_pretrained("third-intelligence/RubatoCodec", device="cuda")
data, sr = sf.read("speech.wav", dtype="float32") # mono waveform
wav = torch.from_numpy(data)
enc = codec.encode(wav, sr=sr) # {"codes": (16, K) int64, "durs": (K,) int64}
audio = codec.decode(enc) # (1, 1, T_audio) at 44.1 kHz, full depth
audio = codec.decode(enc, depth=8) # lower bitrate with the first 8 layers
sf.write("recon.wav", audio[0, 0].cpu().numpy(), codec.output_sr)| Tool | What it does |
|---|---|
| codec.encode | Turns a waveform into event codes and durations |
| codec.decode | Rebuilds audio from the codes, at full depth or less |
| depth argument | Uses only the first layers for a lower bitrate |
You encode a short mono recording named speech.wav, then decode it with depth 8. The script writes recon.wav, a 44.1 kHz reconstruction made at a lower bitrate than the full-depth decode.
If you are new, run the script on a short clip and compare recon.wav with the original by ear. A codec compresses audio into small codes and rebuilds it, so some detail is lost.
For experts, the quantizer has 16 layers of 4,096 entries each. Layer 0 is semantically supervised FSQ, and layers 1 to 15 are residual VQ. The latent grid runs at 50 Hz and keeps 12.5 events per second. You can decode at any depth from 1 up to 16 layers.
The card reports decoding one event takes about 11 ms on an H200, far less than the audio it represents.
Compresses speech into a fixed number of variable-length events with durations, and decodes them back as it streams. A neural speech codec for people building streaming text-to-speech in English, Japanese and Chinese.
Made by third-intelligence on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.
What it is: RubatoCodec is a neural speech codec. It splits speech into a fixed number of events, each with discrete code indices and a duration. Because the event count follows the utterance length exactly, a speech generator knows in advance how many tokens it must produce. A causal decoder renders finished events step by step, which suits streaming text-to-speech.
Who it suits: Researchers and developers who build speech generation systems and need a predictable token budget with streaming decoding.
Industry | Who uses it | How they use it | Example
Speech AI | Researchers | Use the codec as the token layer for speech generators | Train a text-to-speech model on its codes
Software | Developers | Add streaming speech decoding to an app | Render speech as events arrive
Research | Audio engineers | Study low-bitrate speech coding | Compare reconstructions at two depths
If you want a ready speech enhancement or transcription tool, you can skip it.
Where to use it:
Use case | Who | What they get back
Encoding speech | Researchers | Event codes and durations from a waveform
Decoding speech | Developers | Audio at 44.1 kHz
Lower bitrate decoding | Developers | Audio from only the first layers
How to set it up:
cd RubatoCodec
uv sync
To fetch only the codec weights, use the Hugging Face steps.
pip install -U huggingface_hub
hf download third-intelligence/RubatoCodec
How to use it: Load the codec, read a mono waveform, encode it to codes and durations, then decode. Passing a depth value decodes with fewer layers for a lower bitrate.
import soundfile as sf
import torch
from rubatocodec import RubatoCodec
codec = RubatoCodec.from_pretrained("third-intelligence/RubatoCodec", device="cuda")
data, sr = sf.read("speech.wav", dtype="float32") # mono waveform
wav = torch.from_numpy(data)
enc = codec.encode(wav, sr=sr) # {"codes": (16, K) int64, "durs": (K,) int64}
audio = codec.decode(enc) # (1, 1, T_audio) at 44.1 kHz, full depth
audio = codec.decode(enc, depth=8) # lower bitrate with the first 8 layers
sf.write("recon.wav", audio[0, 0].cpu().numpy(), codec.output_sr)
Tool | What it does
codec.encode | Turns a waveform into event codes and durations
codec.decode | Rebuilds audio from the codes, at full depth or less
depth argument | Uses only the first layers for a lower bitrate
Example: You encode a short mono recording named speech.wav, then decode it with depth 8. The script writes recon.wav, a 44.1 kHz reconstruction made at a lower bitrate than the full-depth decode.
For newcomers and experts: If you are new, run the script on a short clip and compare recon.wav with the original by ear. A codec compresses audio into small codes and rebuilds it, so some detail is lost.
For experts, the quantizer has 16 layers of 4,096 entries each. Layer 0 is semantically supervised FSQ, and layers 1 to 15 are residual VQ. The latent grid runs at 50 Hz and keeps 12.5 events per second. You can decode at any depth from 1 up to 16 layers.
Speech at 16 kHz is encoded
Adaptive firing picks the event positions
Each event gets codes and a duration
A causal decoder renders audio at 44.1 kHz
Good to know: The card reports decoding one event takes about 11 ms on an H200, far less than the audio it represents.
Title: Event decoding time against audio per event
Decode time per event on an H200: 11 ms
Audio each event represents on average: 80 ms
Download its files with Hugging Face's command line:
pip install -U huggingface_hub
hf download third-intelligence/RubatoCodec
Then follow the usage in its model card. Nothing in this kit runs by itself.
README.md 6 KB
Listed Hugging Face models in the same category that share the most tags with this one.
| Product | Downloads, last 30 days | Likes | Parameters | License | Last change |
|---|---|---|---|---|---|
| RubatoCodec This page | 670 | 18 | 246M | apache-2.0 | |
| IndiCodecShares speech-tokenizer · audio-to-audio · speech | 81 | 7 | 624M | apache-2.0 | |
| Realtime-VenusShares streaming · speech · audio | 2,101 | 135 | — | apache-2.0 | |
| Maya 2 NativeShares streaming · multilingual · text-to-speech | 5,774 | 170 | 2.5B | apache-2.0 | |
| Ming-3.0-audio-flashShares speech · audio · text-to-speech | 2,122 | 87 | 128B | mit | |
| AuKShares speech · audio · text-to-speech | 1,455 | 396 | — | mit |
Sokheng · Kit
Reads Khmer and English text from documents, receipts and photos of signs, using a detector for text lines and a recogniser for each line. Suits developers who…
Qwen · Kit
Qwen2.5-7B-Instruct as GGUF files in eight quantization sizes, to chat with locally through llama.cpp. For people who want a capable 7.6B model on their own co…
ACE-Step · Kit
Generates music from text with a 4B diffusion decoder, 50 steps and guidance control, aiming for higher audio quality than the base. For creators with a GPU of…
alirezarezvani · Skill
Adds 411 ready-made skills for Claude Code and other coding agents, grouped by role from engineering and product to marketing, finance and compliance. Installs…
block · Kit
Self-hostable workspace where people and AI agents share the same rooms, built on a Nostr relay that logs every action as a signed event. For teams that want t…
backnotprop · Kit
Opens your AI coding agent's plans, specs and code changes in a browser so you can annotate or comment on them and send the feedback straight back to the agent.