Model reference · open weights

whisper-small-uyghur

Available as managed deployment Audio anke01 · community Speech→text 1 variants 553 dl/mo

whisper-small-uyghur is an open-weight audio or speech model from anke01. AxForge deploys and operates it for you on dedicated EU-owned hardware — with the licence handled where one is required.

Available as managed deployment — configured and operated for you on dedicated EU hardware, quoted per deployment.

What it is

Released byanke01
TypeAudio & music
TaskSpeech→text
Parameters (lead)242M
Runs withtransformers
Released2026-03-11
Popularity553 downloads / month
LicenceOpen weights

About

What whisper-small-uyghur is

针对维吾尔语语音识别微调的OpenAI Whisper Small模型。

Read the full model card

模型信息

  • 基础模型: openai/whisper-small
  • 语言: 维吾尔语 (Uyghur)
  • 语言Token: `` (Token ID: 51865)
  • 任务: 自动语音识别 (ASR)
  • 微调数据: THUYG-20数据集 (7,600条)

性能指标

  • 字符错误率 (CER): ~16.5% (100步演示训练)
  • 字符准确率: ~83.5%
  • 预期CER (3000步): < 10%

快速开始

安装依赖

pip install transformers torch soundfile numpy

基本用法

from transformers import WhisperProcessor, WhisperForConditionalGeneration
import soundfile as sf
import numpy as np

# 加载模型
model_name = "anke01/whisper-small-uyghur"
processor = WhisperProcessor.from_pretrained(model_name)
model = WhisperForConditionalGeneration.from_pretrained(model_name)

# 加载音频
waveform, sample_rate = sf.read("audio.wav", dtype='float32')

# 转为单声道
if len(waveform.shape) > 1:
    waveform = np.mean(waveform, axis=1)

# 重采样到16kHz
if sample_rate != 16000:
    old_len = len(waveform)
    new_len = int(old_len * 16000 / sample_rate)
    waveform = np.interp(
        np.linspace(0, old_len - 1, new_len),
        np.arange(old_len),
        waveform
    )

# 处理音频
inputs = processor(waveform, sampling_rate=16000, return_tensors="pt")

# 使用维吾尔语token生成
lang_token_id = processor.tokenizer.convert_tokens_to_ids("")
forced_decoder_ids = [
    (1, lang_token_id),
    (2, processor.tokenizer.convert_tokens_to_ids("")),
]

predicted_ids = model.generate(
    inputs.input_features,
    forced_decoder_ids=forced_decoder_ids
)

# 解码
transcription = processor.batch_decode(predicted_ids, skip_special_tokens=True)[0]
print(transcription)

脚本说明

推理脚本

# 转录音频文件
python inference.py audio.wav

# 指定模型路径
python inference.py audio.wav ./model

评估脚本

# 在数据集上评估
python evaluate.py data/val.json

# 指定模型路径
python evaluate.py data/val.json ./model

# 只评估前100条
python evaluate.py data/val.json ./model 100

配置修复脚本

# 自动修复模型配置
python fix_model_config.py

语言支持

本模型扩展了原始Whisper的词汇表:

  • 原始词汇表大小: 51,865
  • 新词汇表大小: 51,866 (+1个 ``)

模型文件

.
├── model.safetensors       # 模型权重 (925MB)
├── vocab.json              # 分词器词汇表
├── tokenizer_config.json   # 分词器配置
├── preprocessor_config.json # 音频预处理器配置
├── config.json             # 模型配置
├── generation_config.json  # 生成配置 (包含语言映射)
├── language_info.json      # 语言元数据
├── inference.py            # 推理脚本
├── evaluate.py             # 评估脚本
├── fix_model_config.py     # 配置修复脚本
└── README.md               # 本文件

训练详情

  • 数据集: THUYG-20 (7,600条)
  • 训练步数: 100 (演示) / 3000 (完整)
  • 学习率: 1e-5
  • 批次大小: 4
  • 优化器: AdamW
  • 预热步数: 500

示例输出

输入: thuyg20_00000_*.wav (8.30秒)

输出:

بىز نەچچە يىل تىرىشىش ئارقىلىق بۇ قاقاس يەرنى ئاخىرى مۇنبەت ئىتىزغا ئايلاندۇردۇق

中文翻译: "我们经过多年的努力,终于把这片荒地变成了肥沃的田地"

限制说明

  • 训练数据有限 (7,600条)
  • 不同口音的性能可能有差异
  • 生产环境建议进一步微调

引用

@misc{whisper-uyghur,
  title={Whisper Small Fine-tuned for Uyghur},
  author={Your Name},
  year={2024},
  publisher={Hugging Face}
}

致谢

  • 原始Whisper模型由OpenAI提供
  • THUYG-20数据集由清华大学和新疆大学提供

许可证

与原始Whisper模型相同 (Apache 2.0)。

From the published model card. Full card on the HuggingFace links in the sidebar.

Using it via the API

Call it like any OpenAI endpoint

Once AxForge deploys whisper-small-uyghur for you, it answers on the OpenAI-compatible API — the same base URL and keys as every other model. (whisper-small-uyghur below is illustrative; you get the exact model name on deployment.)

$ curl -sS https://api.axforge.ai/v1/audio/transcriptions \
  -H "Authorization: Bearer $AXFORGE_API_KEY" \
  -F model="whisper-small-uyghur" -F file=@audio.mp3

Create an account — your API key is available in the console. 3M free tokens every 30 days with every new account.

© 2026 AxForge · EU-hosted AI infrastructure Pricing Docs Trust Privacy Terms