Automatic Speech Recognition
Transformers
cohere_streaming
feature-extraction
asr
streaming
speech-recognition
cache-aware
fastconformer
distillation
custom_code
Instructions to use Steveeeeeeen/cohere-streaming with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Steveeeeeeen/cohere-streaming with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("automatic-speech-recognition", model="Steveeeeeeen/cohere-streaming", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Steveeeeeeen/cohere-streaming", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Document public self-contained inference and merged smol-audio example
Browse files
README.md
CHANGED
|
@@ -82,7 +82,7 @@ print(model.finish())
|
|
| 82 |
|
| 83 |
The loader chooses CUDA, Apple Metal, or CPU. Pass `device="cuda"` or `device="cpu"` to choose explicitly, and `dtype=torch.bfloat16` or `dtype=torch.float32` to choose precision. Streaming supports one device. `reset()` starts an utterance, `step()` updates its partial transcript, and `finish()` flushes the remaining audio and decodes the endpoint.
|
| 84 |
|
| 85 |
-
Inference loads the weights and processor from this repository; it does not download the original Cohere weights.
|
| 86 |
|
| 87 |
`trust_remote_code=True` loads the streaming implementation shipped here. This adapter exposes the streaming methods above; standard ASR pipeline streaming and `AutoModel.from_config()` are not implemented.
|
| 88 |
|
|
@@ -92,7 +92,7 @@ To save a copy with its code and processor:
|
|
| 92 |
model.save_pretrained("cohere-streaming-local")
|
| 93 |
```
|
| 94 |
|
| 95 |
-
The directory contains `student.safetensors`, `config.json`, `mel_stats.json`, `model.py`, processor/tokenizer files, and `generation_config.json`. The published repository also retains `log.json` from training. The local `CohereStreaming` adapter in the [smol-audio example](https://github.com/Deep-unlearning/smol-audio/tree/
|
| 96 |
|
| 97 |
## How it was made
|
| 98 |
|
|
|
|
| 82 |
|
| 83 |
The loader chooses CUDA, Apple Metal, or CPU. Pass `device="cuda"` or `device="cpu"` to choose explicitly, and `dtype=torch.bfloat16` or `dtype=torch.float32` to choose precision. Streaming supports one device. `reset()` starts an utterance, `step()` updates its partial transcript, and `finish()` flushes the remaining audio and decodes the endpoint.
|
| 84 |
|
| 85 |
+
Inference loads the weights and processor from this public repository without an authentication token; it does not download the original Cohere weights. Access to the original gated Cohere model is still needed for teacher labeling and distillation.
|
| 86 |
|
| 87 |
`trust_remote_code=True` loads the streaming implementation shipped here. This adapter exposes the streaming methods above; standard ASR pipeline streaming and `AutoModel.from_config()` are not implemented.
|
| 88 |
|
|
|
|
| 92 |
model.save_pretrained("cohere-streaming-local")
|
| 93 |
```
|
| 94 |
|
| 95 |
+
The directory contains `student.safetensors`, `config.json`, `mel_stats.json`, `model.py`, processor/tokenizer files, and `generation_config.json`. The published repository also retains `log.json` from training. The local `CohereStreaming` adapter in the [smol-audio example](https://github.com/Deep-unlearning/smol-audio/tree/master/cohere_transcribe_streaming) remains compatible with this checkpoint.
|
| 96 |
|
| 97 |
## How it was made
|
| 98 |
|