Files
Abolfazl Ranjbaran 4821d812dc feat(accuracy): Persian accuracy stack v2 — measured -24.3 WER points on the default stack
Every decision below is measured on the 12-clip Common Voice fa fixture
with a reproducible harness; no number is hand-written.

- fa_polish module: orthographic-only repair (ZWNJ fusion, split
  imperatives like 'بی پوش' -> 'بپوش', Arabic code points, digits).
  Wired into the pipeline (FA_POLISH=true) and ported 1:1 to the browser
  demo (16-case parity test vs Python). -3.6 WER points.
- Persian orthography initial_prompt as the default: whisper copies the
  prompt's script style. -1.3 points (small), -4.8 (fine-tuned).
- Default engine small -> medium: 56.2% WER vs 75.0% (v2 harness) at
  ~1.1x realtime on 2 CPU cores. small stays the speed-first profile.
- Browser demo: default model base -> small (90.2% -> 75.0% under v2),
  polished output identical to the server's shape.
- benchmarks/tune_decode.py: the sweep harness behind every decision
  (prompt x beam x VAD x condition_on_previous_text).
- training/export_web_onnx.py: LoRA merge -> ONNX -> int8 -> HF Hub so
  the next fine-tune can run inside the browser demo.
- baseline.json regenerated for the v2 harness; weekly benchmark now
  guards small AND medium; gate test updated.

Fixture: small 80.5% -> 75.0%, fine-tuned 79.3% -> 75.0%, medium 56.2%.
2026-11-26 09:44:41 +00:00
..

title, emoji, colorFrom, colorTo, sdk, pinned, license, license_name, license_link, short_description
title emoji colorFrom colorTo sdk pinned license license_name license_link short_description
Sokhan سخن 🎤 indigo purple static false other PolyForm Noncommercial 1.0.0 https://github.com/Abolfazlrwm/sokhan/blob/main/LICENSE تبدیل گفتار فارسی به نوشتار — اجرا کامل درون مرورگر

Sokhan — Persian speech-to-text, in your browser

A live demo of Sokhan's speech engine that runs entirely client-side: Whisper (ONNX) executes on the visitor's own machine via transformers.js — nothing is uploaded, no backend, no compute cost. Persian RTL UI, mic recording, file upload and a bundled benchmark sample clip.

Speed and reliability: the demo picks the fastest backend the browser offers — WebGPU (fp32 encoder + q4 decoder) on Chrome/Edge, WASM q8 everywhere else — and owns the 30 s/5 s windowing itself, so it reports per-window progress with an ETA, shows an elapsed timer, enforces a duration cap (30 min on WebGPU, 10 min on WASM) and offers a real cancel button that terminates the worker. Audio is decoded at the context's natural rate and resampled offline to 16 kHz, avoiding a Chromium hang on opus/webm inputs.

Two untuned checkpoints are selectable (base / small) so anyone can hear the difference. The fine-tuned checkpoint (Abol0pati/whisper-small-fa-sokhan, LoRA on 500 Common Voice fa clips, measured WER 79.3% vs 80.5% baseline) is served by the same engine Sokhan runs in production — the app for that lives in space/gradio/ for self-hosting, because HF's 2026 pricing gates hosted Gradio/Docker Spaces behind a PRO subscription and only static Spaces (like this page) remain free. Porting the fine-tune to ONNX for the browser is on the roadmap (docs/ROADMAP.md).

Persian Common Voice is colloquial and noisy — expect real mistakes, from every Whisper size.