Automatic Speech Recognition
Transformers
Core ML
Safetensors
English
parakeet_tdt
feature-extraction
underdog
speech-to-text
asr
stt
parakeet
tdt
Instructions to use LoyalAI/Underdog-Bark-3.0-Pro with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use LoyalAI/Underdog-Bark-3.0-Pro with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("automatic-speech-recognition", model="LoyalAI/Underdog-Bark-3.0-Pro")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("LoyalAI/Underdog-Bark-3.0-Pro", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Underdog Bark 3.0 Pro
Browse filesFiles from ConwayResearch/bark-3.0-pro@1f94282afed294f2866b65de3048b15a9529ff39 (unchanged weights and runtimes), with the Underdog model card and NOTICE. Adds mlx/config.json (same bytes as the other Bark 3.0 repos) for the vocabulary.
- .gitattributes +1 -0
- NOTICE +13 -0
- README.md +191 -0
- bark_frontier.png +3 -0
- config.json +50 -0
- coreml/Decoder.mlpackage/Data/com.apple.CoreML/model.mlmodel +3 -0
- coreml/Decoder.mlpackage/Data/com.apple.CoreML/weights/weight.bin +3 -0
- coreml/Decoder.mlpackage/Manifest.json +18 -0
- coreml/Encoder.mlpackage/Data/com.apple.CoreML/model.mlmodel +3 -0
- coreml/Encoder.mlpackage/Data/com.apple.CoreML/weights/weight.bin +3 -0
- coreml/Encoder.mlpackage/Manifest.json +18 -0
- coreml/JointDecisionv3.mlpackage/Data/com.apple.CoreML/model.mlmodel +3 -0
- coreml/JointDecisionv3.mlpackage/Data/com.apple.CoreML/weights/weight.bin +3 -0
- coreml/JointDecisionv3.mlpackage/Manifest.json +18 -0
- coreml/LICENSE +396 -0
- coreml/NOTICE +13 -0
- coreml/Preprocessor.mlpackage/Data/com.apple.CoreML/model.mlmodel +3 -0
- coreml/Preprocessor.mlpackage/Data/com.apple.CoreML/weights/weight.bin +3 -0
- coreml/Preprocessor.mlpackage/Manifest.json +18 -0
- coreml/parakeet_v3_vocab.json +0 -0
- generation_config.json +16 -0
- mlx/config.json +0 -0
- model.safetensors +3 -0
- processor_config.json +16 -0
- runtime/coreml/Package.resolved +14 -0
- runtime/coreml/Package.swift +8 -0
- runtime/coreml/Sources/main.swift +70 -0
- runtime/requirements.txt +6 -0
- runtime/transcribe_bark_pro.py +53 -0
- tokenizer.json +0 -0
- tokenizer_config.json +10 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
bark_frontier.png filter=lfs diff=lfs merge=lfs -text
|
NOTICE
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
Underdog Bark 3.0 Pro (ConwayResearch/Underdog-Bark-3.0-Pro), part of the Bark 3.0 family
|
| 2 |
+
|
| 3 |
+
This model derives from:
|
| 4 |
+
|
| 5 |
+
nvidia/parakeet-tdt-0.6b-v3, (c) NVIDIA Corporation, CC-BY-4.0
|
| 6 |
+
https://huggingface.co/nvidia/parakeet-tdt-0.6b-v3
|
| 7 |
+
moondream/parakeet-ultra, (c) Moondream, CC-BY-4.0
|
| 8 |
+
https://huggingface.co/moondream/parakeet-ultra
|
| 9 |
+
|
| 10 |
+
License: https://creativecommons.org/licenses/by/4.0/
|
| 11 |
+
|
| 12 |
+
Changes: post-trained and compressed by Conway Research. The FastConformer encoder architecture, TDT decoder,
|
| 13 |
+
tokenizer and feature-extractor configuration derive from the models above and remain under CC-BY-4.0.
|
README.md
ADDED
|
@@ -0,0 +1,191 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: cc-by-4.0
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
library_name: transformers
|
| 6 |
+
pipeline_tag: automatic-speech-recognition
|
| 7 |
+
base_model: nvidia/parakeet-tdt-0.6b-v3
|
| 8 |
+
base_model_relation: finetune
|
| 9 |
+
tags:
|
| 10 |
+
- underdog
|
| 11 |
+
- speech-to-text
|
| 12 |
+
- asr
|
| 13 |
+
- stt
|
| 14 |
+
- parakeet
|
| 15 |
+
- tdt
|
| 16 |
+
metrics:
|
| 17 |
+
- wer
|
| 18 |
+
---
|
| 19 |
+
|
| 20 |
+
# Underdog Bark 3.0 Pro
|
| 21 |
+
|
| 22 |
+
Bark 3.0 Pro is state-of-the-art open speech recognition: a 0.6B English model at full precision (bf16, 1.25 GB). Across the Open ASR Leaderboard's seven English sets it averages 4.29 % word error, the lowest of any open model by the leaderboard's own scoring: 4.286 against 4.291 for Hojo-ASR-V1, a 12 GB download. Every other open model is further behind, including Qwen3-ASR-1.7B (4.43 %) and Canary-Qwen 2.5B (4.55 %).
|
| 23 |
+
|
| 24 |
+
It has the lowest error of any open model on the leaderboard for parliamentary speech (1.70 % on VoxPopuli) and earnings calls (5.65 % on Earnings-22), and 7.16 % on meetings (AMI). It loads as a stock `transformers` model with no custom code.
|
| 25 |
+
|
| 26 |
+

|
| 27 |
+
|
| 28 |
+
## In Underdog
|
| 29 |
+
|
| 30 |
+
[Underdog](https://underdog.ai)'s native Swift runtime loads `model.safetensors` directly on Apple silicon with MLX, with no Python, and keeps the weights in bf16 as published. It reads the vocabulary from `mlx/config.json`, which is the same file the smaller Bark 3.0 models ship. Your audio never leaves the device.
|
| 31 |
+
|
| 32 |
+
## Highlights
|
| 33 |
+
|
| 34 |
+
- State of the art: the most accurate open-weight speech model on the Open ASR Leaderboard's seven English sets by its own scoring: 4.286 %, just ahead of Hojo-ASR-V1 (4.291 %) from about a tenth of the download.
|
| 35 |
+
- More accurate than every other open model, including Qwen3-ASR-1.7B (4.43 %), higgs-audio-v3-stt (4.45 %), Canary-Qwen 2.5B (4.55 %), Granite Speech 4.1 2B (4.69 %), Cohere Transcribe (4.85 %), Voxtral Small 24B (5.21 %) and Whisper large-v3 (6.04 %).
|
| 36 |
+
- More accurate than paid speech APIs including OpenAI GPT-Transcribe (4.70 %), AssemblyAI Universal-3.5 Pro (4.46 %), Gladia Solaria-3 (4.70 %), Smallest.ai Pulse (4.54 %) and Meta Muse Voice Transcribe (4.93 %).
|
| 37 |
+
- The Bark 3.0 family holds the accuracy frontier for open speech recognition at every size from 163 MB to 1.25 GB.
|
| 38 |
+
- The lowest error of any open model on parliamentary speech (1.70 % on VoxPopuli) and earnings calls (5.65 % on Earnings-22).
|
| 39 |
+
|
| 40 |
+
|
| 41 |
+
## Benchmarks
|
| 42 |
+
|
| 43 |
+
| Model | Download | LS clean | LS other | AMI | Earnings-22 | GigaSpeech | SPGISpeech | VoxPopuli | Average |
|
| 44 |
+
|---|--:|--:|--:|--:|--:|--:|--:|--:|--:|
|
| 45 |
+
| **Bark 3.0 Pro** | **1,254 MB** | 1.38 | 3.11 | 7.16 | **5.65** | 7.46 | 3.54 | **1.70** | **4.29** |
|
| 46 |
+
| Bark 3.0 Plus | 180 MB | 1.71 | 3.82 | 7.76 | 6.70 | 7.77 | 3.64 | 1.92 | 4.76 |
|
| 47 |
+
| Bark 3.0 | 163 MB | 1.89 | 4.08 | 7.82 | 7.05 | 7.95 | 3.72 | 2.05 | 4.94 |
|
| 48 |
+
| Phonon-2† | 164 MB | 1.73 | 3.92 | 9.32 | 6.96 | 8.35 | 3.70 | 2.46 | 5.21 |
|
| 49 |
+
| Hojo-ASR-V1† | 11,957 MB | 1.30 | 3.24 | 7.54 | 6.97 | **6.14** | 1.74 | 3.11 | 4.29 |
|
| 50 |
+
| Qwen3-ASR-1.7B† | 4,699 MB | 1.26 | 2.94 | 8.31 | 5.84 | 7.22 | 2.57 | 2.85 | 4.43 |
|
| 51 |
+
| higgs-audio-v3-stt† | 5,351 MB | 1.08 | 2.61 | 7.19 | 7.04 | 7.45 | 2.07 | 3.73 | 4.45 |
|
| 52 |
+
| Canary-Qwen 2.5B† | 5,119 MB | 1.23 | 2.63 | 7.91 | 6.41 | 7.80 | **1.70** | 4.14 | 4.55 |
|
| 53 |
+
| Granite Speech 4.1 2B† | 4,832 MB | 1.03 | 2.19 | 7.06 | 6.69 | 8.18 | 3.47 | 4.18 | 4.69 |
|
| 54 |
+
| Cohere Transcribe† | 4,132 MB | **0.97** | **2.05** | **7.02** | 7.88 | 7.88 | 2.74 | 5.38 | 4.85 |
|
| 55 |
+
| Granite Speech 5.0 470M (NC)† | 946 MB | 1.45 | 2.67 | 7.31 | 8.23 | 8.37 | 1.75 | 4.67 | 4.92 |
|
| 56 |
+
| Parakeet TDT 0.6B v3† | 2,508 MB | 1.52 | 3.13 | 9.42 | 5.85 | 7.99 | 3.63 | 3.05 | 4.94 |
|
| 57 |
+
| Granite Speech 5.0 470M† | 946 MB | 1.48 | 2.71 | 7.71 | 6.75 | 8.74 | 3.22 | 4.90 | 5.07 |
|
| 58 |
+
| Qwen3-ASR-0.6B† | 1,876 MB | 1.70 | 4.01 | 9.33 | 7.83 | 7.62 | 2.74 | 2.90 | 5.16 |
|
| 59 |
+
| Whisper large-v3† | 9,261 MB | 1.56 | 3.52 | 13.63 | 7.99 | 8.35 | 2.71 | 4.53 | 6.04 |
|
| 60 |
+
| Whisper large-v3-turbo† | 1,618 MB | 2.13 | 3.71 | 13.88 | 8.09 | 8.47 | 2.79 | 7.02 | 6.58 |
|
| 61 |
+
|
| 62 |
+
Word error rate (%), lower is better, on the full test sets of the Open ASR Leaderboard's seven English sets (cleaned versions of AMI, Earnings-22, GigaSpeech and VoxPopuli). † The leaderboard's published row, as of 9 October 2026; the Bark rows use its scoring code and are not on the leaderboard yet. Bold marks the best value in each column. At three decimals, by the leaderboard's own averaging, Bark 3.0 Pro averages 4.286 and Hojo-ASR-V1 4.291. NC: non-commercial licence. Download is the size of the weight files on Hugging Face.
|
| 63 |
+
|
| 64 |
+
|
| 65 |
+
### Disfluent speech
|
| 66 |
+
|
| 67 |
+
On the DisfluencySpeech test set (250 clips of unscripted conversation full of "um", "uh", restarts and repeats), scored against its verbatim transcripts with fillers counted:
|
| 68 |
+
|
| 69 |
+
| Model | Word error rate (%) |
|
| 70 |
+
|---|--:|
|
| 71 |
+
| Bark 3.0 Pro | **2.95** |
|
| 72 |
+
| Bark 3.0 | 3.15 |
|
| 73 |
+
| Bark 3.0 Plus | 3.21 |
|
| 74 |
+
| Phonon-2 | 3.39 |
|
| 75 |
+
|
| 76 |
+
Bark 3.0 writes what was said, fillers included. It does not clean speech up.
|
| 77 |
+
|
| 78 |
+
## Run it
|
| 79 |
+
|
| 80 |
+
Choose one runtime below. Windows CUDA uses the original BF16 Safetensors weights at the repository root. Mac Core ML uses the separate `coreml/` model files; GPU and ANE share those files. Selective downloads avoid downloading both formats.
|
| 81 |
+
|
| 82 |
+
### Mac: Core ML GPU or ANE
|
| 83 |
+
|
| 84 |
+
Requires an Apple Silicon Mac, macOS 15 or later, and Swift 6.2 or later (Xcode / Command Line Tools). The runner uses the GPU or ANE for supported encoder operations and the CPU for preprocessing and decoding. Both paths were tested on an M5 Max. For iPhone and iPad, see the iOS section below.
|
| 85 |
+
|
| 86 |
+
Install the download CLI, then download only the Core ML package and its runner. If repository access requires authentication, run `hf auth login` first.
|
| 87 |
+
|
| 88 |
+
```bash
|
| 89 |
+
python3 -m venv .venv-download
|
| 90 |
+
source .venv-download/bin/activate
|
| 91 |
+
python -m pip install huggingface_hub==2.2.0
|
| 92 |
+
BARK_REVISION=main
|
| 93 |
+
hf download ConwayResearch/Underdog-Bark-3.0-Pro --revision "$BARK_REVISION" \
|
| 94 |
+
--local-dir bark-pro \
|
| 95 |
+
--include 'coreml/*' --include 'runtime/coreml/*' --include 'NOTICE'
|
| 96 |
+
|
| 97 |
+
swift --version
|
| 98 |
+
swift build --package-path bark-pro/runtime/coreml -c release
|
| 99 |
+
```
|
| 100 |
+
|
| 101 |
+
Use a mono, 16 kHz WAV file. To convert another input with FFmpeg, if needed:
|
| 102 |
+
|
| 103 |
+
```bash
|
| 104 |
+
ffmpeg -i input.wav -ac 1 -ar 16000 recording-16k.wav
|
| 105 |
+
```
|
| 106 |
+
|
| 107 |
+
Run on the Apple GPU:
|
| 108 |
+
|
| 109 |
+
```bash
|
| 110 |
+
bark-pro/runtime/coreml/.build/release/bark-pro-coreml \
|
| 111 |
+
bark-pro/coreml recording-16k.wav gpu
|
| 112 |
+
```
|
| 113 |
+
|
| 114 |
+
Run the same model with CPU + ANE instead:
|
| 115 |
+
|
| 116 |
+
```bash
|
| 117 |
+
bark-pro/runtime/coreml/.build/release/bark-pro-coreml \
|
| 118 |
+
bark-pro/coreml recording-16k.wav ane
|
| 119 |
+
```
|
| 120 |
+
|
| 121 |
+
The program prints the transcript and exits. It adds the evaluated 0.25 seconds of leading silence and automatically selects the 8-second encoder function for short inputs, otherwise the 15-second path with FluidAudio long-audio handling. GPU/ANE selection is a compute-unit configuration, not a guarantee that every operation runs on that accelerator.
|
| 122 |
+
|
| 123 |
+
GPU and ANE use the same Core ML model files. The `gpu` option lets Core ML execute supported encoder operations on the Apple GPU; `ane` uses the Apple Neural Engine instead. Preprocessing and decoding stay on the CPU in both modes.
|
| 124 |
+
|
| 125 |
+
The package shares encoder weights between its 8-second and 15-second functions, so short recordings need less computation without duplicating the full model. Its greedy joint selects the next token without producing unused top-K candidate outputs. Both optimizations are enabled automatically on GPU and ANE; no extra flags are needed.
|
| 126 |
+
|
| 127 |
+
The Core ML download is approximately 1.23 GB: FP16 learned weights with an FP32 preprocessor. Initial model compilation/loading is additional to inference time. This runner uses greedy decoding without contextual vocabulary biasing or language filtering. Core ML may emit an initialization shape diagnostic from the preprocessor; the tested nonempty, padded inputs completed successfully. Empty input is rejected. The root benchmark table describes the original model's evaluation, not separate measurements of every runtime.
|
| 128 |
+
|
| 129 |
+
See [Core ML license](coreml/LICENSE) and [attribution](coreml/NOTICE). The Swift dependency is pinned in `runtime/coreml/Package.swift` and `Package.resolved`; its first build requires network access. No Python model runtime is needed after downloading these files.
|
| 130 |
+
|
| 131 |
+
### iPhone and iPad (iOS)
|
| 132 |
+
|
| 133 |
+
Requires iOS 18 or later (the encoder's shared 8-second and 15-second functions are a Core ML multifunction model) and a Swift package dependency on [FluidAudio](https://github.com/FluidInference/FluidAudio), pinned to the revision in `runtime/coreml/Package.swift`. The model files are the same as on the Mac; nothing is converted for iOS. **Not yet tested on an iPhone or iPad.**
|
| 134 |
+
|
| 135 |
+
What an app needs:
|
| 136 |
+
|
| 137 |
+
- The files in `coreml/` (about 1.23 GB): `Preprocessor`, `Encoder`, `Decoder` and `JointDecisionv3` (`.mlpackage`) and `parakeet_v3_vocab.json`. Add the packages to the Xcode target, which compiles them to `.mlmodelc` at build time, or download them and compile each once on the device with `MLModel.compileModel(at:)`, then keep the compiled copies (the Mac runner deletes its temporary compiled copies after each run; an app should not).
|
| 138 |
+
- The model loading and transcription code of `runtime/coreml/Sources/main.swift`, which uses only Core ML, AVFoundation and FluidAudio, all available on iOS. Replace the command-line arguments with app settings: the compute units for the encoder (`.cpuAndNeuralEngine` for the ANE, `.cpuAndGPU` for the GPU), and the folder of the compiled models. Keep the rest as in the runner: preprocessor, decoder and joint on the CPU; 0.25 seconds of leading silence; the `short8` encoder function for inputs up to 8 seconds including that silence, otherwise `full15`; `AsrModels(..., version: .ultra)`, `AsrManager` and `TdtDecoderState`.
|
| 139 |
+
- Mono 16 kHz float audio. The runner reads a WAV file in that format; in an app, convert microphone or file audio with `AVAudioConverter` first.
|
| 140 |
+
- To save memory and load time, create the models once and reuse them for every request.
|
| 141 |
+
|
| 142 |
+
### Windows: NVIDIA GPU with PyTorch CUDA
|
| 143 |
+
|
| 144 |
+
Requires 64-bit Windows, Python 3.11, an NVIDIA GPU, and a driver compatible with the CUDA 12.8 PyTorch wheel. BF16 requires a BF16-capable GPU. This is a PyTorch execution path, not an ONNX or DirectML package. Tested on Windows with an NVIDIA GPU (CUDA, BF16).
|
| 145 |
+
|
| 146 |
+
In PowerShell:
|
| 147 |
+
|
| 148 |
+
```powershell
|
| 149 |
+
py -3.11 -m venv .venv-bark
|
| 150 |
+
.\.venv-bark\Scripts\python.exe -m pip install huggingface_hub==2.2.0
|
| 151 |
+
# If access requires authentication:
|
| 152 |
+
# .\.venv-bark\Scripts\hf.exe auth login
|
| 153 |
+
$BarkRevision = "main"
|
| 154 |
+
.\.venv-bark\Scripts\hf.exe download ConwayResearch/Underdog-Bark-3.0-Pro --revision $BarkRevision --local-dir bark-pro --include "model.safetensors" --include "config.json" --include "generation_config.json" --include "processor_config.json" --include "tokenizer.json" --include "tokenizer_config.json" --include "runtime/transcribe_bark_pro.py" --include "runtime/requirements.txt" --include "NOTICE"
|
| 155 |
+
.\.venv-bark\Scripts\python.exe -m pip install torch==2.8.0 --index-url https://download.pytorch.org/whl/cu128
|
| 156 |
+
.\.venv-bark\Scripts\python.exe -m pip install -r bark-pro/runtime/requirements.txt
|
| 157 |
+
.\.venv-bark\Scripts\python.exe -c "import torch; print('CUDA available:', torch.cuda.is_available()); print('GPU:', torch.cuda.get_device_name(0) if torch.cuda.is_available() else 'none')"
|
| 158 |
+
.\.venv-bark\Scripts\python.exe bark-pro/runtime/transcribe_bark_pro.py recording.wav --model bark-pro --device cuda --dtype bfloat16
|
| 159 |
+
```
|
| 160 |
+
|
| 161 |
+
The Python runner downmixes/resamples audio to mono 16 kHz and adds 0.25 seconds of leading silence. It loads the processor once and fails explicitly if CUDA is unavailable; it does not silently fall back to CPU. If the NVIDIA GPU lacks BF16 support, `--dtype float16` is an explicit alternative requiring separate accuracy validation. For CPU-only execution, install the CPU PyTorch wheel instead and use `--device cpu --dtype float32`.
|
| 162 |
+
|
| 163 |
+
The pinned Python runtime dependencies include `librosa`, which the feature extractor requires. Follow [PyTorch's installation instructions](https://pytorch.org/get-started/previous-versions/#v280) if the GPU or driver requires a different wheel. Installing CUDA-enabled PyTorch does not make AMD or Intel GPUs CUDA-compatible.
|
| 164 |
+
|
| 165 |
+
### Python API
|
| 166 |
+
|
| 167 |
+
The original Transformers interface remains available with the Python dependencies above:
|
| 168 |
+
|
| 169 |
+
```python
|
| 170 |
+
import numpy as np, soundfile as sf, soxr, torch
|
| 171 |
+
from transformers import AutoProcessor, ParakeetForTDT
|
| 172 |
+
|
| 173 |
+
repo = "ConwayResearch/Underdog-Bark-3.0-Pro"
|
| 174 |
+
processor = AutoProcessor.from_pretrained(repo)
|
| 175 |
+
model = ParakeetForTDT.from_pretrained(repo, dtype=torch.bfloat16).to("cuda").eval()
|
| 176 |
+
|
| 177 |
+
wave, sr = sf.read("recording.wav", dtype="float32", always_2d=True)
|
| 178 |
+
wave = soxr.resample(wave.mean(1), sr, 16000) if sr != 16000 else wave.mean(1)
|
| 179 |
+
wave = np.concatenate([np.zeros(4000, np.float32), wave])
|
| 180 |
+
inputs = processor(wave, sampling_rate=16000, return_tensors="pt").to("cuda", torch.bfloat16)
|
| 181 |
+
with torch.inference_mode():
|
| 182 |
+
out = model.generate(**inputs)
|
| 183 |
+
ids = out.sequences if hasattr(out, "sequences") else out
|
| 184 |
+
print(processor.batch_decode(ids, skip_special_tokens=True)[0])
|
| 185 |
+
```
|
| 186 |
+
|
| 187 |
+
For a small download, use Bark 3.0 (163 MB) or Bark 3.0 Plus (180 MB).
|
| 188 |
+
|
| 189 |
+
## Notes
|
| 190 |
+
|
| 191 |
+
Based on parakeet-tdt-0.6b-v3 by NVIDIA, through moondream/parakeet-ultra; the tokenizer and output conventions (punctuation, casing, numerals) are the original's. Licence CC-BY-4.0, same as the original; `NOTICE` lists the attribution. English only.
|
bark_frontier.png
ADDED
|
Git LFS Details
|
config.json
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"ParakeetForTDT"
|
| 4 |
+
],
|
| 5 |
+
"blank_token_id": 8192,
|
| 6 |
+
"decoder_hidden_size": 640,
|
| 7 |
+
"dtype": "bfloat16",
|
| 8 |
+
"durations": [
|
| 9 |
+
0,
|
| 10 |
+
1,
|
| 11 |
+
2,
|
| 12 |
+
3,
|
| 13 |
+
4
|
| 14 |
+
],
|
| 15 |
+
"encoder_config": {
|
| 16 |
+
"activation_dropout": 0.1,
|
| 17 |
+
"attention_bias": false,
|
| 18 |
+
"attention_dropout": 0.1,
|
| 19 |
+
"conv_kernel_size": 9,
|
| 20 |
+
"convolution_bias": false,
|
| 21 |
+
"dropout": 0.1,
|
| 22 |
+
"dropout_positions": 0.0,
|
| 23 |
+
"dtype": "float32",
|
| 24 |
+
"hidden_act": "silu",
|
| 25 |
+
"hidden_size": 1024,
|
| 26 |
+
"initializer_range": 0.02,
|
| 27 |
+
"intermediate_size": 4096,
|
| 28 |
+
"layerdrop": 0.1,
|
| 29 |
+
"max_position_embeddings": 5000,
|
| 30 |
+
"model_type": "parakeet_encoder",
|
| 31 |
+
"num_attention_heads": 8,
|
| 32 |
+
"num_hidden_layers": 24,
|
| 33 |
+
"num_key_value_heads": 8,
|
| 34 |
+
"num_mel_bins": 128,
|
| 35 |
+
"scale_input": false,
|
| 36 |
+
"subsampling_conv_channels": 256,
|
| 37 |
+
"subsampling_conv_kernel_size": 3,
|
| 38 |
+
"subsampling_conv_stride": 2,
|
| 39 |
+
"subsampling_factor": 8
|
| 40 |
+
},
|
| 41 |
+
"hidden_act": "relu",
|
| 42 |
+
"initializer_range": 0.02,
|
| 43 |
+
"is_encoder_decoder": true,
|
| 44 |
+
"max_symbols_per_step": 10,
|
| 45 |
+
"model_type": "parakeet_tdt",
|
| 46 |
+
"num_decoder_layers": 2,
|
| 47 |
+
"pad_token_id": 2,
|
| 48 |
+
"transformers_version": "5.19.0",
|
| 49 |
+
"vocab_size": 8193
|
| 50 |
+
}
|
coreml/Decoder.mlpackage/Data/com.apple.CoreML/model.mlmodel
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:00cd3bdf438e859eff16d1376cab86f6214d0e44b1876316e30550e35d012763
|
| 3 |
+
size 11612
|
coreml/Decoder.mlpackage/Data/com.apple.CoreML/weights/weight.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b6bfa9053e8e20d1e80a7522ddba5c66e2c8c77cfc956d4ebccf749baf4d3d69
|
| 3 |
+
size 23604992
|
coreml/Decoder.mlpackage/Manifest.json
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"fileFormatVersion": "1.0.0",
|
| 3 |
+
"itemInfoEntries": {
|
| 4 |
+
"564E09DE-5280-41E0-AE98-570196CC0D11": {
|
| 5 |
+
"author": "com.apple.CoreML",
|
| 6 |
+
"description": "CoreML Model Specification",
|
| 7 |
+
"name": "model.mlmodel",
|
| 8 |
+
"path": "com.apple.CoreML/model.mlmodel"
|
| 9 |
+
},
|
| 10 |
+
"BF4D2139-CE97-4C8B-AF18-93B63A516FC7": {
|
| 11 |
+
"author": "com.apple.CoreML",
|
| 12 |
+
"description": "CoreML Model Weights",
|
| 13 |
+
"name": "weights",
|
| 14 |
+
"path": "com.apple.CoreML/weights"
|
| 15 |
+
}
|
| 16 |
+
},
|
| 17 |
+
"rootModelIdentifier": "564E09DE-5280-41E0-AE98-570196CC0D11"
|
| 18 |
+
}
|
coreml/Encoder.mlpackage/Data/com.apple.CoreML/model.mlmodel
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d82718558f523dc13f9c0ede57d6f8e37d953950808a5aaa3a4633a7f752dd77
|
| 3 |
+
size 1206573
|
coreml/Encoder.mlpackage/Data/com.apple.CoreML/weights/weight.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:619757bd47bc5cc131a85e54e94ffacc1b8c1bce737c1f1f6569eda8621a30d6
|
| 3 |
+
size 1195742464
|
coreml/Encoder.mlpackage/Manifest.json
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"fileFormatVersion": "1.0.0",
|
| 3 |
+
"itemInfoEntries": {
|
| 4 |
+
"2B9AFE96-7F23-44FD-A759-FFE0483668C3": {
|
| 5 |
+
"author": "com.apple.CoreML",
|
| 6 |
+
"description": "CoreML Model Weights",
|
| 7 |
+
"name": "weights",
|
| 8 |
+
"path": "com.apple.CoreML/weights"
|
| 9 |
+
},
|
| 10 |
+
"C66849D3-2556-4CAC-90AE-3F8AEAD772CE": {
|
| 11 |
+
"author": "com.apple.CoreML",
|
| 12 |
+
"description": "CoreML Model Specification",
|
| 13 |
+
"name": "model.mlmodel",
|
| 14 |
+
"path": "com.apple.CoreML/model.mlmodel"
|
| 15 |
+
}
|
| 16 |
+
},
|
| 17 |
+
"rootModelIdentifier": "C66849D3-2556-4CAC-90AE-3F8AEAD772CE"
|
| 18 |
+
}
|
coreml/JointDecisionv3.mlpackage/Data/com.apple.CoreML/model.mlmodel
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1057c2d9e9efce23258dbf2e7747e6facf7a42f4fcbcf2a21cdd160e065b18ac
|
| 3 |
+
size 8759
|
coreml/JointDecisionv3.mlpackage/Data/com.apple.CoreML/weights/weight.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:90257de4d4582921c31db6efe9668017274b7c4cfdfe5aac9b9183233f7a9bdd
|
| 3 |
+
size 12642764
|
coreml/JointDecisionv3.mlpackage/Manifest.json
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"fileFormatVersion": "1.0.0",
|
| 3 |
+
"itemInfoEntries": {
|
| 4 |
+
"17EA6AF8-377A-4DA4-9C71-204E80672667": {
|
| 5 |
+
"author": "com.apple.CoreML",
|
| 6 |
+
"description": "CoreML Model Weights",
|
| 7 |
+
"name": "weights",
|
| 8 |
+
"path": "com.apple.CoreML/weights"
|
| 9 |
+
},
|
| 10 |
+
"BB47EC72-0325-48B9-95CC-B0A6E6AA57A5": {
|
| 11 |
+
"author": "com.apple.CoreML",
|
| 12 |
+
"description": "CoreML Model Specification",
|
| 13 |
+
"name": "model.mlmodel",
|
| 14 |
+
"path": "com.apple.CoreML/model.mlmodel"
|
| 15 |
+
}
|
| 16 |
+
},
|
| 17 |
+
"rootModelIdentifier": "BB47EC72-0325-48B9-95CC-B0A6E6AA57A5"
|
| 18 |
+
}
|
coreml/LICENSE
ADDED
|
@@ -0,0 +1,396 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
Attribution 4.0 International
|
| 2 |
+
|
| 3 |
+
=======================================================================
|
| 4 |
+
|
| 5 |
+
Creative Commons Corporation ("Creative Commons") is not a law firm and
|
| 6 |
+
does not provide legal services or legal advice. Distribution of
|
| 7 |
+
Creative Commons public licenses does not create a lawyer-client or
|
| 8 |
+
other relationship. Creative Commons makes its licenses and related
|
| 9 |
+
information available on an "as-is" basis. Creative Commons gives no
|
| 10 |
+
warranties regarding its licenses, any material licensed under their
|
| 11 |
+
terms and conditions, or any related information. Creative Commons
|
| 12 |
+
disclaims all liability for damages resulting from their use to the
|
| 13 |
+
fullest extent possible.
|
| 14 |
+
|
| 15 |
+
Using Creative Commons Public Licenses
|
| 16 |
+
|
| 17 |
+
Creative Commons public licenses provide a standard set of terms and
|
| 18 |
+
conditions that creators and other rights holders may use to share
|
| 19 |
+
original works of authorship and other material subject to copyright
|
| 20 |
+
and certain other rights specified in the public license below. The
|
| 21 |
+
following considerations are for informational purposes only, are not
|
| 22 |
+
exhaustive, and do not form part of our licenses.
|
| 23 |
+
|
| 24 |
+
Considerations for licensors: Our public licenses are
|
| 25 |
+
intended for use by those authorized to give the public
|
| 26 |
+
permission to use material in ways otherwise restricted by
|
| 27 |
+
copyright and certain other rights. Our licenses are
|
| 28 |
+
irrevocable. Licensors should read and understand the terms
|
| 29 |
+
and conditions of the license they choose before applying it.
|
| 30 |
+
Licensors should also secure all rights necessary before
|
| 31 |
+
applying our licenses so that the public can reuse the
|
| 32 |
+
material as expected. Licensors should clearly mark any
|
| 33 |
+
material not subject to the license. This includes other CC-
|
| 34 |
+
licensed material, or material used under an exception or
|
| 35 |
+
limitation to copyright. More considerations for licensors:
|
| 36 |
+
wiki.creativecommons.org/Considerations_for_licensors
|
| 37 |
+
|
| 38 |
+
Considerations for the public: By using one of our public
|
| 39 |
+
licenses, a licensor grants the public permission to use the
|
| 40 |
+
licensed material under specified terms and conditions. If
|
| 41 |
+
the licensor's permission is not necessary for any reason--for
|
| 42 |
+
example, because of any applicable exception or limitation to
|
| 43 |
+
copyright--then that use is not regulated by the license. Our
|
| 44 |
+
licenses grant only permissions under copyright and certain
|
| 45 |
+
other rights that a licensor has authority to grant. Use of
|
| 46 |
+
the licensed material may still be restricted for other
|
| 47 |
+
reasons, including because others have copyright or other
|
| 48 |
+
rights in the material. A licensor may make special requests,
|
| 49 |
+
such as asking that all changes be marked or described.
|
| 50 |
+
Although not required by our licenses, you are encouraged to
|
| 51 |
+
respect those requests where reasonable. More considerations
|
| 52 |
+
for the public:
|
| 53 |
+
wiki.creativecommons.org/Considerations_for_licensees
|
| 54 |
+
|
| 55 |
+
=======================================================================
|
| 56 |
+
|
| 57 |
+
Creative Commons Attribution 4.0 International Public License
|
| 58 |
+
|
| 59 |
+
By exercising the Licensed Rights (defined below), You accept and agree
|
| 60 |
+
to be bound by the terms and conditions of this Creative Commons
|
| 61 |
+
Attribution 4.0 International Public License ("Public License"). To the
|
| 62 |
+
extent this Public License may be interpreted as a contract, You are
|
| 63 |
+
granted the Licensed Rights in consideration of Your acceptance of
|
| 64 |
+
these terms and conditions, and the Licensor grants You such rights in
|
| 65 |
+
consideration of benefits the Licensor receives from making the
|
| 66 |
+
Licensed Material available under these terms and conditions.
|
| 67 |
+
|
| 68 |
+
|
| 69 |
+
Section 1 -- Definitions.
|
| 70 |
+
|
| 71 |
+
a. Adapted Material means material subject to Copyright and Similar
|
| 72 |
+
Rights that is derived from or based upon the Licensed Material
|
| 73 |
+
and in which the Licensed Material is translated, altered,
|
| 74 |
+
arranged, transformed, or otherwise modified in a manner requiring
|
| 75 |
+
permission under the Copyright and Similar Rights held by the
|
| 76 |
+
Licensor. For purposes of this Public License, where the Licensed
|
| 77 |
+
Material is a musical work, performance, or sound recording,
|
| 78 |
+
Adapted Material is always produced where the Licensed Material is
|
| 79 |
+
synched in timed relation with a moving image.
|
| 80 |
+
|
| 81 |
+
b. Adapter's License means the license You apply to Your Copyright
|
| 82 |
+
and Similar Rights in Your contributions to Adapted Material in
|
| 83 |
+
accordance with the terms and conditions of this Public License.
|
| 84 |
+
|
| 85 |
+
c. Copyright and Similar Rights means copyright and/or similar rights
|
| 86 |
+
closely related to copyright including, without limitation,
|
| 87 |
+
performance, broadcast, sound recording, and Sui Generis Database
|
| 88 |
+
Rights, without regard to how the rights are labeled or
|
| 89 |
+
categorized. For purposes of this Public License, the rights
|
| 90 |
+
specified in Section 2(b)(1)-(2) are not Copyright and Similar
|
| 91 |
+
Rights.
|
| 92 |
+
|
| 93 |
+
d. Effective Technological Measures means those measures that, in the
|
| 94 |
+
absence of proper authority, may not be circumvented under laws
|
| 95 |
+
fulfilling obligations under Article 11 of the WIPO Copyright
|
| 96 |
+
Treaty adopted on December 20, 1996, and/or similar international
|
| 97 |
+
agreements.
|
| 98 |
+
|
| 99 |
+
e. Exceptions and Limitations means fair use, fair dealing, and/or
|
| 100 |
+
any other exception or limitation to Copyright and Similar Rights
|
| 101 |
+
that applies to Your use of the Licensed Material.
|
| 102 |
+
|
| 103 |
+
f. Licensed Material means the artistic or literary work, database,
|
| 104 |
+
or other material to which the Licensor applied this Public
|
| 105 |
+
License.
|
| 106 |
+
|
| 107 |
+
g. Licensed Rights means the rights granted to You subject to the
|
| 108 |
+
terms and conditions of this Public License, which are limited to
|
| 109 |
+
all Copyright and Similar Rights that apply to Your use of the
|
| 110 |
+
Licensed Material and that the Licensor has authority to license.
|
| 111 |
+
|
| 112 |
+
h. Licensor means the individual(s) or entity(ies) granting rights
|
| 113 |
+
under this Public License.
|
| 114 |
+
|
| 115 |
+
i. Share means to provide material to the public by any means or
|
| 116 |
+
process that requires permission under the Licensed Rights, such
|
| 117 |
+
as reproduction, public display, public performance, distribution,
|
| 118 |
+
dissemination, communication, or importation, and to make material
|
| 119 |
+
available to the public including in ways that members of the
|
| 120 |
+
public may access the material from a place and at a time
|
| 121 |
+
individually chosen by them.
|
| 122 |
+
|
| 123 |
+
j. Sui Generis Database Rights means rights other than copyright
|
| 124 |
+
resulting from Directive 96/9/EC of the European Parliament and of
|
| 125 |
+
the Council of 11 March 1996 on the legal protection of databases,
|
| 126 |
+
as amended and/or succeeded, as well as other essentially
|
| 127 |
+
equivalent rights anywhere in the world.
|
| 128 |
+
|
| 129 |
+
k. You means the individual or entity exercising the Licensed Rights
|
| 130 |
+
under this Public License. Your has a corresponding meaning.
|
| 131 |
+
|
| 132 |
+
|
| 133 |
+
Section 2 -- Scope.
|
| 134 |
+
|
| 135 |
+
a. License grant.
|
| 136 |
+
|
| 137 |
+
1. Subject to the terms and conditions of this Public License,
|
| 138 |
+
the Licensor hereby grants You a worldwide, royalty-free,
|
| 139 |
+
non-sublicensable, non-exclusive, irrevocable license to
|
| 140 |
+
exercise the Licensed Rights in the Licensed Material to:
|
| 141 |
+
|
| 142 |
+
a. reproduce and Share the Licensed Material, in whole or
|
| 143 |
+
in part; and
|
| 144 |
+
|
| 145 |
+
b. produce, reproduce, and Share Adapted Material.
|
| 146 |
+
|
| 147 |
+
2. Exceptions and Limitations. For the avoidance of doubt, where
|
| 148 |
+
Exceptions and Limitations apply to Your use, this Public
|
| 149 |
+
License does not apply, and You do not need to comply with
|
| 150 |
+
its terms and conditions.
|
| 151 |
+
|
| 152 |
+
3. Term. The term of this Public License is specified in Section
|
| 153 |
+
6(a).
|
| 154 |
+
|
| 155 |
+
4. Media and formats; technical modifications allowed. The
|
| 156 |
+
Licensor authorizes You to exercise the Licensed Rights in
|
| 157 |
+
all media and formats whether now known or hereafter created,
|
| 158 |
+
and to make technical modifications necessary to do so. The
|
| 159 |
+
Licensor waives and/or agrees not to assert any right or
|
| 160 |
+
authority to forbid You from making technical modifications
|
| 161 |
+
necessary to exercise the Licensed Rights, including
|
| 162 |
+
technical modifications necessary to circumvent Effective
|
| 163 |
+
Technological Measures. For purposes of this Public License,
|
| 164 |
+
simply making modifications authorized by this Section 2(a)
|
| 165 |
+
(4) never produces Adapted Material.
|
| 166 |
+
|
| 167 |
+
5. Downstream recipients.
|
| 168 |
+
|
| 169 |
+
a. Offer from the Licensor -- Licensed Material. Every
|
| 170 |
+
recipient of the Licensed Material automatically
|
| 171 |
+
receives an offer from the Licensor to exercise the
|
| 172 |
+
Licensed Rights under the terms and conditions of this
|
| 173 |
+
Public License.
|
| 174 |
+
|
| 175 |
+
b. No downstream restrictions. You may not offer or impose
|
| 176 |
+
any additional or different terms or conditions on, or
|
| 177 |
+
apply any Effective Technological Measures to, the
|
| 178 |
+
Licensed Material if doing so restricts exercise of the
|
| 179 |
+
Licensed Rights by any recipient of the Licensed
|
| 180 |
+
Material.
|
| 181 |
+
|
| 182 |
+
6. No endorsement. Nothing in this Public License constitutes or
|
| 183 |
+
may be construed as permission to assert or imply that You
|
| 184 |
+
are, or that Your use of the Licensed Material is, connected
|
| 185 |
+
with, or sponsored, endorsed, or granted official status by,
|
| 186 |
+
the Licensor or others designated to receive attribution as
|
| 187 |
+
provided in Section 3(a)(1)(A)(i).
|
| 188 |
+
|
| 189 |
+
b. Other rights.
|
| 190 |
+
|
| 191 |
+
1. Moral rights, such as the right of integrity, are not
|
| 192 |
+
licensed under this Public License, nor are publicity,
|
| 193 |
+
privacy, and/or other similar personality rights; however, to
|
| 194 |
+
the extent possible, the Licensor waives and/or agrees not to
|
| 195 |
+
assert any such rights held by the Licensor to the limited
|
| 196 |
+
extent necessary to allow You to exercise the Licensed
|
| 197 |
+
Rights, but not otherwise.
|
| 198 |
+
|
| 199 |
+
2. Patent and trademark rights are not licensed under this
|
| 200 |
+
Public License.
|
| 201 |
+
|
| 202 |
+
3. To the extent possible, the Licensor waives any right to
|
| 203 |
+
collect royalties from You for the exercise of the Licensed
|
| 204 |
+
Rights, whether directly or through a collecting society
|
| 205 |
+
under any voluntary or waivable statutory or compulsory
|
| 206 |
+
licensing scheme. In all other cases the Licensor expressly
|
| 207 |
+
reserves any right to collect such royalties.
|
| 208 |
+
|
| 209 |
+
|
| 210 |
+
Section 3 -- License Conditions.
|
| 211 |
+
|
| 212 |
+
Your exercise of the Licensed Rights is expressly made subject to the
|
| 213 |
+
following conditions.
|
| 214 |
+
|
| 215 |
+
a. Attribution.
|
| 216 |
+
|
| 217 |
+
1. If You Share the Licensed Material (including in modified
|
| 218 |
+
form), You must:
|
| 219 |
+
|
| 220 |
+
a. retain the following if it is supplied by the Licensor
|
| 221 |
+
with the Licensed Material:
|
| 222 |
+
|
| 223 |
+
i. identification of the creator(s) of the Licensed
|
| 224 |
+
Material and any others designated to receive
|
| 225 |
+
attribution, in any reasonable manner requested by
|
| 226 |
+
the Licensor (including by pseudonym if
|
| 227 |
+
designated);
|
| 228 |
+
|
| 229 |
+
ii. a copyright notice;
|
| 230 |
+
|
| 231 |
+
iii. a notice that refers to this Public License;
|
| 232 |
+
|
| 233 |
+
iv. a notice that refers to the disclaimer of
|
| 234 |
+
warranties;
|
| 235 |
+
|
| 236 |
+
v. a URI or hyperlink to the Licensed Material to the
|
| 237 |
+
extent reasonably practicable;
|
| 238 |
+
|
| 239 |
+
b. indicate if You modified the Licensed Material and
|
| 240 |
+
retain an indication of any previous modifications; and
|
| 241 |
+
|
| 242 |
+
c. indicate the Licensed Material is licensed under this
|
| 243 |
+
Public License, and include the text of, or the URI or
|
| 244 |
+
hyperlink to, this Public License.
|
| 245 |
+
|
| 246 |
+
2. You may satisfy the conditions in Section 3(a)(1) in any
|
| 247 |
+
reasonable manner based on the medium, means, and context in
|
| 248 |
+
which You Share the Licensed Material. For example, it may be
|
| 249 |
+
reasonable to satisfy the conditions by providing a URI or
|
| 250 |
+
hyperlink to a resource that includes the required
|
| 251 |
+
information.
|
| 252 |
+
|
| 253 |
+
3. If requested by the Licensor, You must remove any of the
|
| 254 |
+
information required by Section 3(a)(1)(A) to the extent
|
| 255 |
+
reasonably practicable.
|
| 256 |
+
|
| 257 |
+
4. If You Share Adapted Material You produce, the Adapter's
|
| 258 |
+
License You apply must not prevent recipients of the Adapted
|
| 259 |
+
Material from complying with this Public License.
|
| 260 |
+
|
| 261 |
+
|
| 262 |
+
Section 4 -- Sui Generis Database Rights.
|
| 263 |
+
|
| 264 |
+
Where the Licensed Rights include Sui Generis Database Rights that
|
| 265 |
+
apply to Your use of the Licensed Material:
|
| 266 |
+
|
| 267 |
+
a. for the avoidance of doubt, Section 2(a)(1) grants You the right
|
| 268 |
+
to extract, reuse, reproduce, and Share all or a substantial
|
| 269 |
+
portion of the contents of the database;
|
| 270 |
+
|
| 271 |
+
b. if You include all or a substantial portion of the database
|
| 272 |
+
contents in a database in which You have Sui Generis Database
|
| 273 |
+
Rights, then the database in which You have Sui Generis Database
|
| 274 |
+
Rights (but not its individual contents) is Adapted Material; and
|
| 275 |
+
|
| 276 |
+
c. You must comply with the conditions in Section 3(a) if You Share
|
| 277 |
+
all or a substantial portion of the contents of the database.
|
| 278 |
+
|
| 279 |
+
For the avoidance of doubt, this Section 4 supplements and does not
|
| 280 |
+
replace Your obligations under this Public License where the Licensed
|
| 281 |
+
Rights include other Copyright and Similar Rights.
|
| 282 |
+
|
| 283 |
+
|
| 284 |
+
Section 5 -- Disclaimer of Warranties and Limitation of Liability.
|
| 285 |
+
|
| 286 |
+
a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
|
| 287 |
+
EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
|
| 288 |
+
AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
|
| 289 |
+
ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
|
| 290 |
+
IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
|
| 291 |
+
WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
| 292 |
+
PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
|
| 293 |
+
ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
|
| 294 |
+
KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
|
| 295 |
+
ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.
|
| 296 |
+
|
| 297 |
+
b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
|
| 298 |
+
TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
|
| 299 |
+
NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
|
| 300 |
+
INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
|
| 301 |
+
COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
|
| 302 |
+
USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
|
| 303 |
+
ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
|
| 304 |
+
DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
|
| 305 |
+
IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.
|
| 306 |
+
|
| 307 |
+
c. The disclaimer of warranties and limitation of liability provided
|
| 308 |
+
above shall be interpreted in a manner that, to the extent
|
| 309 |
+
possible, most closely approximates an absolute disclaimer and
|
| 310 |
+
waiver of all liability.
|
| 311 |
+
|
| 312 |
+
|
| 313 |
+
Section 6 -- Term and Termination.
|
| 314 |
+
|
| 315 |
+
a. This Public License applies for the term of the Copyright and
|
| 316 |
+
Similar Rights licensed here. However, if You fail to comply with
|
| 317 |
+
this Public License, then Your rights under this Public License
|
| 318 |
+
terminate automatically.
|
| 319 |
+
|
| 320 |
+
b. Where Your right to use the Licensed Material has terminated under
|
| 321 |
+
Section 6(a), it reinstates:
|
| 322 |
+
|
| 323 |
+
1. automatically as of the date the violation is cured, provided
|
| 324 |
+
it is cured within 30 days of Your discovery of the
|
| 325 |
+
violation; or
|
| 326 |
+
|
| 327 |
+
2. upon express reinstatement by the Licensor.
|
| 328 |
+
|
| 329 |
+
For the avoidance of doubt, this Section 6(b) does not affect any
|
| 330 |
+
right the Licensor may have to seek remedies for Your violations
|
| 331 |
+
of this Public License.
|
| 332 |
+
|
| 333 |
+
c. For the avoidance of doubt, the Licensor may also offer the
|
| 334 |
+
Licensed Material under separate terms or conditions or stop
|
| 335 |
+
distributing the Licensed Material at any time; however, doing so
|
| 336 |
+
will not terminate this Public License.
|
| 337 |
+
|
| 338 |
+
d. Sections 1, 5, 6, 7, and 8 survive termination of this Public
|
| 339 |
+
License.
|
| 340 |
+
|
| 341 |
+
|
| 342 |
+
Section 7 -- Other Terms and Conditions.
|
| 343 |
+
|
| 344 |
+
a. The Licensor shall not be bound by any additional or different
|
| 345 |
+
terms or conditions communicated by You unless expressly agreed.
|
| 346 |
+
|
| 347 |
+
b. Any arrangements, understandings, or agreements regarding the
|
| 348 |
+
Licensed Material not stated herein are separate from and
|
| 349 |
+
independent of the terms and conditions of this Public License.
|
| 350 |
+
|
| 351 |
+
|
| 352 |
+
Section 8 -- Interpretation.
|
| 353 |
+
|
| 354 |
+
a. For the avoidance of doubt, this Public License does not, and
|
| 355 |
+
shall not be interpreted to, reduce, limit, restrict, or impose
|
| 356 |
+
conditions on any use of the Licensed Material that could lawfully
|
| 357 |
+
be made without permission under this Public License.
|
| 358 |
+
|
| 359 |
+
b. To the extent possible, if any provision of this Public License is
|
| 360 |
+
deemed unenforceable, it shall be automatically reformed to the
|
| 361 |
+
minimum extent necessary to make it enforceable. If the provision
|
| 362 |
+
cannot be reformed, it shall be severed from this Public License
|
| 363 |
+
without affecting the enforceability of the remaining terms and
|
| 364 |
+
conditions.
|
| 365 |
+
|
| 366 |
+
c. No term or condition of this Public License will be waived and no
|
| 367 |
+
failure to comply consented to unless expressly agreed to by the
|
| 368 |
+
Licensor.
|
| 369 |
+
|
| 370 |
+
d. Nothing in this Public License constitutes or may be interpreted
|
| 371 |
+
as a limitation upon, or waiver of, any privileges and immunities
|
| 372 |
+
that apply to the Licensor or You, including from the legal
|
| 373 |
+
processes of any jurisdiction or authority.
|
| 374 |
+
|
| 375 |
+
|
| 376 |
+
=======================================================================
|
| 377 |
+
|
| 378 |
+
Creative Commons is not a party to its public
|
| 379 |
+
licenses. Notwithstanding, Creative Commons may elect to apply one of
|
| 380 |
+
its public licenses to material it publishes and in those instances
|
| 381 |
+
will be considered the “Licensor.” The text of the Creative Commons
|
| 382 |
+
public licenses is dedicated to the public domain under the CC0 Public
|
| 383 |
+
Domain Dedication. Except for the limited purpose of indicating that
|
| 384 |
+
material is shared under a Creative Commons public license or as
|
| 385 |
+
otherwise permitted by the Creative Commons policies published at
|
| 386 |
+
creativecommons.org/policies, Creative Commons does not authorize the
|
| 387 |
+
use of the trademark "Creative Commons" or any other trademark or logo
|
| 388 |
+
of Creative Commons without its prior written consent including,
|
| 389 |
+
without limitation, in connection with any unauthorized modifications
|
| 390 |
+
to any of its public licenses or any other arrangements,
|
| 391 |
+
understandings, or agreements concerning use of licensed material. For
|
| 392 |
+
the avoidance of doubt, this paragraph does not form part of the
|
| 393 |
+
public licenses.
|
| 394 |
+
|
| 395 |
+
Creative Commons may be contacted at creativecommons.org.
|
| 396 |
+
|
coreml/NOTICE
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
Underdog Bark 3.0 Pro (ConwayResearch/Underdog-Bark-3.0-Pro), part of the Bark 3.0 family
|
| 2 |
+
|
| 3 |
+
This model derives from:
|
| 4 |
+
|
| 5 |
+
nvidia/parakeet-tdt-0.6b-v3, (c) NVIDIA Corporation, CC-BY-4.0
|
| 6 |
+
https://huggingface.co/nvidia/parakeet-tdt-0.6b-v3
|
| 7 |
+
moondream/parakeet-ultra, (c) Moondream, CC-BY-4.0
|
| 8 |
+
https://huggingface.co/moondream/parakeet-ultra
|
| 9 |
+
|
| 10 |
+
License: https://creativecommons.org/licenses/by/4.0/
|
| 11 |
+
|
| 12 |
+
Changes: post-trained and compressed by Conway Research. The FastConformer encoder architecture, TDT decoder,
|
| 13 |
+
tokenizer and feature-extractor configuration derive from the models above and remain under CC-BY-4.0.
|
coreml/Preprocessor.mlpackage/Data/com.apple.CoreML/model.mlmodel
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:dd4a5266ed9048aae620e73aa983eab93256654a343ded1226f9456b79f79a67
|
| 3 |
+
size 18839
|
coreml/Preprocessor.mlpackage/Data/com.apple.CoreML/weights/weight.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:7a31e2bd311bfa97ea3fe73d4a6c029824327a71590397bd8784089a88754a77
|
| 3 |
+
size 1184512
|
coreml/Preprocessor.mlpackage/Manifest.json
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"fileFormatVersion": "1.0.0",
|
| 3 |
+
"itemInfoEntries": {
|
| 4 |
+
"22F5E68F-99CC-4D5F-8792-1879ABFBD54A": {
|
| 5 |
+
"author": "com.apple.CoreML",
|
| 6 |
+
"description": "CoreML Model Specification",
|
| 7 |
+
"name": "model.mlmodel",
|
| 8 |
+
"path": "com.apple.CoreML/model.mlmodel"
|
| 9 |
+
},
|
| 10 |
+
"5F322A42-93E0-4180-B7D4-6ECE73F06D5C": {
|
| 11 |
+
"author": "com.apple.CoreML",
|
| 12 |
+
"description": "CoreML Model Weights",
|
| 13 |
+
"name": "weights",
|
| 14 |
+
"path": "com.apple.CoreML/weights"
|
| 15 |
+
}
|
| 16 |
+
},
|
| 17 |
+
"rootModelIdentifier": "22F5E68F-99CC-4D5F-8792-1879ABFBD54A"
|
| 18 |
+
}
|
coreml/parakeet_v3_vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
generation_config.json
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_from_model_config": true,
|
| 3 |
+
"decoder_start_token_id": 8192,
|
| 4 |
+
"eos_token_id": 3,
|
| 5 |
+
"output_attentions": false,
|
| 6 |
+
"output_hidden_states": false,
|
| 7 |
+
"pad_token_id": 2,
|
| 8 |
+
"suppress_tokens": [
|
| 9 |
+
8193,
|
| 10 |
+
8194,
|
| 11 |
+
8195,
|
| 12 |
+
8196,
|
| 13 |
+
8197
|
| 14 |
+
],
|
| 15 |
+
"transformers_version": "5.19.0"
|
| 16 |
+
}
|
mlx/config.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6f84b33e63ebd1851e910e8b2fe299d29f5e0efc6f57e84d92d2f79af464e0e5
|
| 3 |
+
size 1254196636
|
processor_config.json
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"blank_token": "<blank>",
|
| 3 |
+
"feature_extractor": {
|
| 4 |
+
"feature_extractor_type": "ParakeetFeatureExtractor",
|
| 5 |
+
"feature_size": 128,
|
| 6 |
+
"hop_length": 160,
|
| 7 |
+
"n_fft": 512,
|
| 8 |
+
"padding_side": "right",
|
| 9 |
+
"padding_value": 0.0,
|
| 10 |
+
"preemphasis": 0.97,
|
| 11 |
+
"return_attention_mask": true,
|
| 12 |
+
"sampling_rate": 16000,
|
| 13 |
+
"win_length": 400
|
| 14 |
+
},
|
| 15 |
+
"processor_class": "ParakeetProcessor"
|
| 16 |
+
}
|
runtime/coreml/Package.resolved
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"originHash" : "3013a88a5b3cbc7220d78e5f89c17d41060231cf0222959900c2e5b5bc409720",
|
| 3 |
+
"pins" : [
|
| 4 |
+
{
|
| 5 |
+
"identity" : "fluidaudio",
|
| 6 |
+
"kind" : "remoteSourceControl",
|
| 7 |
+
"location" : "https://github.com/FluidInference/FluidAudio.git",
|
| 8 |
+
"state" : {
|
| 9 |
+
"revision" : "a00964e1aa8eff99c4bce80bc9c8ff2d4dd1568d"
|
| 10 |
+
}
|
| 11 |
+
}
|
| 12 |
+
],
|
| 13 |
+
"version" : 3
|
| 14 |
+
}
|
runtime/coreml/Package.swift
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
// swift-tools-version: 6.2
|
| 2 |
+
import PackageDescription
|
| 3 |
+
let package = Package(
|
| 4 |
+
name: "BarkProCoreML", platforms: [.macOS(.v15)],
|
| 5 |
+
dependencies: [.package(url: "https://github.com/FluidInference/FluidAudio.git",
|
| 6 |
+
revision: "a00964e1aa8eff99c4bce80bc9c8ff2d4dd1568d", traits: [])],
|
| 7 |
+
targets: [.executableTarget(name: "bark-pro-coreml",
|
| 8 |
+
dependencies: [.product(name: "FluidAudio", package: "FluidAudio")], path: "Sources")])
|
runtime/coreml/Sources/main.swift
ADDED
|
@@ -0,0 +1,70 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import Foundation
|
| 2 |
+
import CoreML
|
| 3 |
+
import AVFoundation
|
| 4 |
+
import FluidAudio
|
| 5 |
+
|
| 6 |
+
@main struct BarkPro {
|
| 7 |
+
static func main() async throws {
|
| 8 |
+
let args = CommandLine.arguments
|
| 9 |
+
guard args.count == 4, ["gpu", "ane", "cpu"].contains(args[3]) else {
|
| 10 |
+
throw Failure("Usage: bark-pro-coreml MODEL_DIR AUDIO.wav gpu|ane|cpu")
|
| 11 |
+
}
|
| 12 |
+
let root = URL(fileURLWithPath: args[1])
|
| 13 |
+
let units: MLComputeUnits = args[3] == "gpu" ? .cpuAndGPU : (args[3] == "ane" ? .cpuAndNeuralEngine : .cpuOnly)
|
| 14 |
+
var temporary: [URL] = []
|
| 15 |
+
defer { for url in temporary { try? FileManager.default.removeItem(at: url) } }
|
| 16 |
+
var compiled: [String: URL] = [:]
|
| 17 |
+
func load(_ name: String, _ compute: MLComputeUnits, function: String? = nil) throws -> MLModel {
|
| 18 |
+
let url: URL
|
| 19 |
+
if let cached = compiled[name] { url = cached }
|
| 20 |
+
else {
|
| 21 |
+
let existing = root.appendingPathComponent(name + ".mlmodelc")
|
| 22 |
+
if FileManager.default.fileExists(atPath: existing.path) { url = existing }
|
| 23 |
+
else {
|
| 24 |
+
let package = root.appendingPathComponent(name + ".mlpackage")
|
| 25 |
+
guard FileManager.default.fileExists(atPath: package.path) else {
|
| 26 |
+
throw Failure("Missing model component: \(package.path)")
|
| 27 |
+
}
|
| 28 |
+
url = try MLModel.compileModel(at: package)
|
| 29 |
+
temporary.append(url)
|
| 30 |
+
}
|
| 31 |
+
compiled[name] = url
|
| 32 |
+
}
|
| 33 |
+
let config = MLModelConfiguration()
|
| 34 |
+
config.computeUnits = compute
|
| 35 |
+
config.functionName = function
|
| 36 |
+
return try MLModel(contentsOf: url, configuration: config)
|
| 37 |
+
}
|
| 38 |
+
let file = try AVAudioFile(forReading: URL(fileURLWithPath: args[2]))
|
| 39 |
+
guard file.processingFormat.sampleRate == 16000,
|
| 40 |
+
file.processingFormat.channelCount == 1, file.length > 0,
|
| 41 |
+
file.length <= AVAudioFramePosition(UInt32.max),
|
| 42 |
+
let buffer = AVAudioPCMBuffer(pcmFormat: file.processingFormat,
|
| 43 |
+
frameCapacity: AVAudioFrameCount(file.length)) else {
|
| 44 |
+
throw Failure("Expected nonempty mono 16 kHz WAV. See the documented conversion command.")
|
| 45 |
+
}
|
| 46 |
+
try file.read(into: buffer)
|
| 47 |
+
guard let ptr = buffer.floatChannelData?[0] else { throw Failure("Cannot read floating-point audio.") }
|
| 48 |
+
let samples = Array(repeating: Float(0), count: 4000) + Array(UnsafeBufferPointer(start: ptr, count: Int(buffer.frameLength)))
|
| 49 |
+
// Both functions share weights. Select the tested short path automatically.
|
| 50 |
+
let function = samples.count <= 128000 ? "short8" : "full15"
|
| 51 |
+
let raw = try JSONDecoder().decode([String: String].self,
|
| 52 |
+
from: Data(contentsOf: root.appendingPathComponent("parakeet_v3_vocab.json")))
|
| 53 |
+
let vocabulary = Dictionary(uniqueKeysWithValues: raw.compactMap { k, v in Int(k).map { ($0, v) } })
|
| 54 |
+
let config = MLModelConfiguration()
|
| 55 |
+
config.computeUnits = .cpuOnly
|
| 56 |
+
let models = try AsrModels(encoder: load("Encoder", units, function: function),
|
| 57 |
+
preprocessor: load("Preprocessor", .cpuOnly), decoder: load("Decoder", .cpuOnly),
|
| 58 |
+
joint: load("JointDecisionv3", .cpuOnly), configuration: config,
|
| 59 |
+
vocabulary: vocabulary, version: .ultra)
|
| 60 |
+
let manager = AsrManager(models: models)
|
| 61 |
+
var state = try TdtDecoderState()
|
| 62 |
+
let result = try await manager.transcribe(samples, decoderState: &state)
|
| 63 |
+
print(result.text)
|
| 64 |
+
}
|
| 65 |
+
}
|
| 66 |
+
|
| 67 |
+
struct Failure: Error, CustomStringConvertible {
|
| 68 |
+
let description: String
|
| 69 |
+
init(_ message: String) { description = message }
|
| 70 |
+
}
|
runtime/requirements.txt
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Install the platform-specific PyTorch wheel separately (see README).
|
| 2 |
+
transformers==5.19.0
|
| 3 |
+
numpy==2.4.6
|
| 4 |
+
librosa==0.11.0
|
| 5 |
+
soundfile==0.14.0
|
| 6 |
+
soxr==1.1.0
|
runtime/transcribe_bark_pro.py
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Single-file Bark 3.0 Pro inference; no training or benchmark dependencies."""
|
| 2 |
+
import argparse
|
| 3 |
+
from pathlib import Path
|
| 4 |
+
|
| 5 |
+
|
| 6 |
+
def main():
|
| 7 |
+
parser = argparse.ArgumentParser(description=__doc__)
|
| 8 |
+
parser.add_argument('audio', type=Path)
|
| 9 |
+
parser.add_argument('--model', default='ConwayResearch/Underdog-Bark-3.0-Pro')
|
| 10 |
+
parser.add_argument('--revision', default='main')
|
| 11 |
+
parser.add_argument('--device', choices=['cuda', 'mps', 'cpu'], default='cuda')
|
| 12 |
+
parser.add_argument('--dtype', choices=['bfloat16', 'float16', 'float32'], default='bfloat16')
|
| 13 |
+
args = parser.parse_args()
|
| 14 |
+
if not args.audio.is_file():
|
| 15 |
+
parser.error(f'Audio file not found: {args.audio}')
|
| 16 |
+
|
| 17 |
+
import numpy as np
|
| 18 |
+
import soundfile as sf
|
| 19 |
+
import soxr
|
| 20 |
+
import torch
|
| 21 |
+
from transformers import AutoProcessor, ParakeetForTDT
|
| 22 |
+
|
| 23 |
+
if args.device == 'cuda':
|
| 24 |
+
if not torch.cuda.is_available():
|
| 25 |
+
parser.error('CUDA unavailable. Install a CUDA-enabled PyTorch and compatible NVIDIA driver, or explicitly use --device cpu --dtype float32.')
|
| 26 |
+
if args.dtype == 'bfloat16' and not torch.cuda.is_bf16_supported():
|
| 27 |
+
parser.error('This GPU does not support BF16. Try --dtype float16; accuracy for this setting must be validated separately.')
|
| 28 |
+
if args.device == 'mps' and not torch.backends.mps.is_available():
|
| 29 |
+
parser.error('MPS is unavailable on this machine.')
|
| 30 |
+
if args.device == 'cpu' and args.dtype != 'float32':
|
| 31 |
+
parser.error('Use --dtype float32 for the CPU fallback.')
|
| 32 |
+
|
| 33 |
+
source = Path(args.model)
|
| 34 |
+
kwargs = {'local_files_only': True} if source.is_dir() else {'revision': args.revision}
|
| 35 |
+
dtype = getattr(torch, args.dtype)
|
| 36 |
+
processor = AutoProcessor.from_pretrained(args.model, **kwargs)
|
| 37 |
+
model = ParakeetForTDT.from_pretrained(args.model, dtype=dtype, **kwargs).to(args.device).eval()
|
| 38 |
+
wave, sr = sf.read(args.audio, dtype='float32', always_2d=True)
|
| 39 |
+
wave = wave.mean(axis=1)
|
| 40 |
+
if not len(wave):
|
| 41 |
+
parser.error('Audio is empty.')
|
| 42 |
+
if sr != 16000:
|
| 43 |
+
wave = soxr.resample(wave, sr, 16000)
|
| 44 |
+
wave = np.concatenate([np.zeros(4000, np.float32), wave])
|
| 45 |
+
inputs = processor(wave, sampling_rate=16000, return_tensors='pt').to(args.device, dtype)
|
| 46 |
+
with torch.inference_mode():
|
| 47 |
+
output = model.generate(**inputs)
|
| 48 |
+
ids = output.sequences if hasattr(output, 'sequences') else output
|
| 49 |
+
print(processor.batch_decode(ids, skip_special_tokens=True)[0])
|
| 50 |
+
|
| 51 |
+
|
| 52 |
+
if __name__ == '__main__':
|
| 53 |
+
main()
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"backend": "tokenizers",
|
| 3 |
+
"clean_up_tokenization_spaces": false,
|
| 4 |
+
"eos_token": "<|endoftext|>",
|
| 5 |
+
"model_max_length": 1000000000000000019884624838656,
|
| 6 |
+
"pad_token": "<pad>",
|
| 7 |
+
"processor_class": "ParakeetProcessor",
|
| 8 |
+
"tokenizer_class": "ParakeetTokenizer",
|
| 9 |
+
"unk_token": "<unk>"
|
| 10 |
+
}
|