File size: 5,650 Bytes
cec55f7
 
 
 
2bad1d7
 
 
 
 
 
 
 
 
 
 
cec55f7
a16faeb
d043d60
 
2bad1d7
d043d60
2bad1d7
d043d60
2bad1d7
d043d60
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
 
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
a16faeb
2bad1d7
 
 
 
 
a16faeb
2bad1d7
 
 
a16faeb
 
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
a16faeb
2bad1d7
 
 
 
 
 
 
 
 
 
 
 
 
 
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
 
 
a16faeb
2bad1d7
 
 
 
a16faeb
 
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
 
 
 
 
 
 
 
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
a16faeb
2bad1d7
 
 
 
 
 
a16faeb
2bad1d7
a16faeb
2bad1d7
 
 
 
a16faeb
2bad1d7
a16faeb
2bad1d7
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
---
license: other
license_name: model-license
license_link: https://github.com/alibaba-damo-academy/FunASR
language:
- en
pipeline_tag: automatic-speech-recognition
tags:
- FunASR
- Paraformer
- ASR
- automatic-speech-recognition
- non-autoregressive
- speech-recognition
library_name: funasr
---

<div align="center">

# Paraformer-en

**A 220M offline, non-autoregressive English speech recognition model for 16 kHz audio.**

Powered by [FunASR](https://github.com/modelscope/FunASR). Follow the project or give it a star to receive new model, runtime, and deployment updates.

[FunASR](https://github.com/modelscope/FunASR) 路 [Fun-ASR](https://github.com/QwenAudio/Fun-ASR) 路 [SenseVoice](https://github.com/QwenAudio/SenseVoice) 路 [FunClip](https://github.com/modelscope/FunClip)

</div>

Paraformer predicts output tokens in parallel instead of decoding them one by one. This checkpoint is intended for high-throughput English transcription where complete utterances or files are available before decoding.

## Quick start

Install PyTorch and FunASR:

```bash
python -m pip install -U torch torchaudio funasr
```

For CUDA-specific PyTorch wheels, select the command for your platform in the [PyTorch installation guide](https://pytorch.org/get-started/locally/), then install `funasr`.

Run the audio example included in this repository:

```python
from funasr import AutoModel

model = AutoModel(
    model="funasr/paraformer-en",
    hub="hf",
    device="cpu",  # Change to "cuda:0" for NVIDIA GPU inference.
)

audio = f"{model.model_path}/example/asr_example.wav"
result = model.generate(input=audio)
print(result[0]["text"])
```

Using the full repository ID is recommended. It selects this English checkpoint directly and avoids ambiguity with similarly named Paraformer models.

## Long audio pipeline

Add voice activity detection to split long recordings and punctuation restoration to produce readable text:

```python
from funasr import AutoModel

model = AutoModel(
    model="funasr/paraformer-en",
    hub="hf",
    vad_model="funasr/fsmn-vad",
    punc_model="funasr/ct-punc",
    device="cuda:0",
)

result = model.generate(
    input="meeting.wav",
    batch_size_s=300,
)
print(result[0]["text"])
```

The pipeline accepts common audio file paths and 16 kHz waveform input. Resample other sample rates to 16 kHz for predictable results.

## OpenAI-compatible serving

Expose the model behind a local `/v1/audio/transcriptions` endpoint:

```bash
python -m pip install -U torch torchaudio funasr fastapi uvicorn python-multipart
funasr-server --model-path funasr/paraformer-en --hub hf --device cuda
```

```bash
curl http://localhost:8000/v1/audio/transcriptions \
  -F file=@audio.wav \
  -F model=custom
```

`funasr-server` registers a checkpoint supplied through `--model-path` under the API model name `custom`.

See the [OpenAI-compatible API examples](https://github.com/modelscope/FunASR/tree/main/examples/openai_api), [deployment matrix](https://github.com/modelscope/FunASR/blob/main/docs/deployment_matrix.md), and [FunASR deployment hub](https://www.funasr.com/) for clients, containers, security guidance, and production topologies.

## Model details

| Property | Value |
| --- | --- |
| Architecture | Paraformer, non-autoregressive ASR |
| Parameters | 220M |
| Language | English |
| Input | 16 kHz speech audio |
| Mode | Offline / non-streaming |
| Framework | PyTorch through FunASR |
| Vocabulary | 10,020 tokens |

### Artifact provenance

This Hugging Face repository mirrors the PyTorch checkpoint published as [`iic/speech_paraformer-large-vad-punc_asr_nat-en-16k-common-vocab10020`](https://www.modelscope.cn/models/iic/speech_paraformer-large-vad-punc_asr_nat-en-16k-common-vocab10020) on ModelScope. It is not a TensorFlow 1.x Paraformer variant.

For reproducibility, the `model.pt` artifact in revision `d043d60434a65ae49b2b2462a09660049871b8e9` has:

- size: `887,289,223` bytes
- SHA-256: `e11203abf1f449b4c6515dee494c017ee27a4b716730378473d827ad3c7fe41c`

## Intended use and limitations

This model is suitable for offline English transcription, subtitle preparation, call or meeting processing, and batch speech pipelines. It is not a streaming checkpoint; use a streaming Paraformer model when partial low-latency results are required.

Recognition quality can degrade with heavy noise, overlapping speakers, strong accents, uncommon proper nouns, or domain-specific terminology. Validate accuracy on representative audio before production use, and review transcripts before using them in safety-critical or high-impact decisions.

## Related models

| Model | Purpose |
| --- | --- |
| [funasr/fsmn-vad](https://huggingface.co/funasr/fsmn-vad) | Voice activity detection for long audio |
| [funasr/ct-punc](https://huggingface.co/funasr/ct-punc) | Chinese and English punctuation restoration |
| [funasr/paraformer-zh](https://huggingface.co/funasr/paraformer-zh) | Offline Mandarin and English ASR |
| [funasr/paraformer-zh-streaming](https://huggingface.co/funasr/paraformer-zh-streaming) | Streaming Paraformer ASR |

## Resources

- [FunASR GitHub repository](https://github.com/modelscope/FunASR)
- [FunASR documentation](https://modelscope.github.io/FunASR/)
- [Paraformer paper](https://arxiv.org/abs/2206.08317)
- [Issue tracker](https://github.com/modelscope/FunASR/issues)

## Citation

```bibtex
@inproceedings{gao2022paraformer,
  title={Paraformer: Fast and Accurate Parallel Transformer for Non-autoregressive End-to-End Speech Recognition},
  author={Gao, Zhifu and Zhang, Shiliang and McLoughlin, Ian and Yan, Zhijie},
  booktitle={INTERSPEECH},
  year={2022}
}
```