Model or dataset
fxy2311-youyou/expression-trainer avatar
fxy2311-youyou/expression-trainer

fxy2311-youyou/expression-trainer: an offline Chinese speech coach built on Electron and Sherpa-ONNX

宇宙无敌表达训练系统 — 实时语音转文字 + 27000词情感词库 + AI表达分析报告。离线运行,对着它说话,它帮你看见自己的表达问题。

1,240 stars224 forksJavaScriptMIT

At a glance

What is it?
A desktop app that transcribes your speech locally, flags filler and hedging words against a 27,000-word lexicon, and sends the transcript to a configurable AI backend for a six-dimension report. It is built for Mandarin speakers drilling spoken precision, and it needs a model download before it will do anything.
Who is it for?
Adopt it if you speak Mandarin and want a local loop that shows you your filler words and hedging in real time, and you are willing to download the Sherpa-ONNX streaming paraformer bilingual model and point the app at an AI backend. Skip it if you need English-only recognition, a packaged installer, or a browser-only workflow; the online version at exprtrain.online covers that last case.
Can I use it commercially?
Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 62 days ago.
What is it written in?
Mainly JavaScript, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 18, 2026, and from our analysis. They are not legal advice.

DEEP OPEN-SOURCE ANALYSIS

What the expression trainer actually measures

The problem is not that people cannot speak. It is that they cannot hear themselves. A recording gives you the whole performance at once, which is too much to act on. This project narrows the feedback to a few countable things: filler words (嗯, 啊, 那个, 然后), hedging words (可能, 也许, 我觉得), and vague words that have a more precise substitute in the lexicon. The README lists 24 filler entries, 19 hedging entries and 25 groups of vague-to-precise replacements, all inside data/emotion-lexicon.json. The lexicon also carries 130 or more emotion words tagged by category (喜怒哀惧恶惊) and intensity from 1 to 9, plus four-level degree gradients and 10 abstract-to-concrete rewrites. The intended user is a Mandarin speaker practising spoken delivery: someone preparing for presentations, interviews or client calls who wants a number attached to a habit. It is not a transcription service and not a meeting recorder. The app assumes one person talking into one microphone, and every design decision follows from that.

Electron main process, Sherpa-ONNX, and where the transcript goes

The architecture is split across two processes. The Electron main process runs three things: Sherpa-ONNX for offline speech recognition, the lexicon matcher, and the AI feedback client. The renderer process handles the full-screen subtitle display, the live statistics panel and the report modal. Audio comes in through the microphone, Sherpa-ONNX emits streaming partial text, and that text is matched against data/emotion-lexicon.json. Matches are colour-coded in the subtitle layer: red wavy underline for filler, orange for hedging, yellow dashed for vague words, green for what the project calls strong expression. The right-hand panel requests AI feedback every 50 characters, which the README states as a fixed interval rather than a configurable one. When you stop, the full transcript can be sent to a report generator that scores six dimensions: logic, directness, filler, density, vocabulary and highlights. The offline claim is accurate only for recognition and lexicon matching. The AI feedback layer is an HTTP call to a remote backend, so the app is offline in the sense that it still works without one, not in the sense that nothing leaves the machine.

Installing it and getting a first transcript

The repository has no packaged installer. You clone it and run it through npm, and the README gives the sequence. Node.js 18 or later is required, along with macOS 12+, Windows 10+ or Linux, and microphone permission. First install the dependencies, which pulls Electron 33 and sherpa-onnx-node 1.10 as declared in package.json.

bash
cd expression-trainer
npm install

The second step is the one people skip: the speech model is not in the repository. The models/ directory exists but you have to populate it with the Sherpa-ONNX streaming paraformer bilingual zh-en model.

bash
cd models
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/sherpa-onnx-streaming-paraformer-bilingual-zh-en.tar.bz2
tar xvf sherpa-onnx-streaming-paraformer-bilingual-zh-en.tar.bz2

After extraction, models/ should contain a folder named sherpa-onnx-streaming-paraformer-bilingual-zh-en holding encoder.int8.onnx, decoder.int8.onnx and tokens.txt. If those three files are not there, recognition will not start, and the README does not describe the error you would see. Then launch the app.

bash
npm start

For development with DevTools open, the package defines npm run dev, which is the same electron command with a --dev flag. Once the window is up, the workflow is: click 开始录制, speak, watch the centred subtitles and the left-hand counters, then click 结束 and 生成报告. To make the report work you need to open the settings page from the gear icon in the top right and choose a backend.

Choosing an AI backend and what it costs you

The README presents four backends in a comparison table: DeepSeek, OpenAI, Ollama and Groq (Groq appears in the feature list but not in the table). Ollama runs locally and is listed as free, with speed depending on your hardware. DeepSeek is described as extremely low cost with fast generation, and the README explicitly recommends it for report quality against cost. OpenAI is listed as medium cost. The settings page is where the key goes, and the repository ships settings.example.json at the top level, which implies you create your own settings file from that template. This is the part of the app that is not self-contained. If you pick a hosted backend, your transcripts leave the machine, which sits awkwardly next to a project whose selling point is local processing. If that matters, Ollama is the only listed option that keeps the whole loop on your hardware, and it is also the one whose latency you cannot predict from the documentation. There is no statement in the README about what the AI feedback prompt contains, beyond lib/prompts.js holding the templates, so if you care about what is transmitted you would need to read that file.

Where the offline design breaks down

The honest limitation is that the strongest feature and the weakest feature are the same layer. Recognition is genuinely local, but the six-dimension report depends on an external model, and the README does not document a fallback when the backend is unreachable, when a key is invalid, or when the response is malformed. The lexicon analysis keeps working, so you lose the report, not the session, but nothing in the documentation says that explicitly. Second, the model is bilingual zh-en, which means it will transcribe English, but every lexicon category in data/emotion-lexicon.json is Chinese-language, so the colour coding and the counters are effectively meaningless for English speech. Third, the feedback interval of 50 characters is hard-coded per the README; there is no documented setting to change it. Fourth, the project has no releases retrieved, so there is no versioned artefact to pin. If you need a tool that scores English delivery, or one that runs entirely without an API key and still produces a written report, this is the wrong project.

How it differs from a general transcription tool

Whisper-based transcription tools solve a different problem. They produce an accurate text file and stop there. The difference here is the evaluation layer: the lexicon matcher classifies words into filler, hedging and vague categories as they arrive, and the subtitle colours make the classification visible while you are still speaking. That real-time loop is the point. A Whisper transcription gives you a better transcript and no opinion about it; this project gives you a rougher transcript and an opinion attached to specific words. The trade-off is that the opinion is rule-based and Chinese-specific, so it will not tell you that an argument was weak, only that you said 我觉得 four times. The AI report layer is closer to what a general-purpose LLM chat session would give you, with the difference that the transcript and the lexicon hits are assembled for you rather than pasted in by hand. If you already have a transcription workflow and a habit of reviewing your own recordings, adding this app duplicates work. If you have never reviewed a recording, the coloured subtitles are a lower-friction starting point.

Maintenance, upgrades and the MIT licence

The last push to the default branch was on 2026-07-18, which is recent enough that the project should not be described as abandoned, but there are no retrieved releases, so there is no changelog to read and no version to pin beyond the 1.0.0 in package.json. Upgrading means pulling the branch and re-running npm install. The heavier upgrade cost is the model: the Sherpa-ONNX streaming paraformer archive is downloaded by hand from a GitHub release or Hugging Face, so a model swap is a manual directory replacement, not a dependency bump. Electron 33 and sherpa-onnx-node 1.10 are the only two declared dependencies, and both are pinned with carets in package.json, which means a fresh npm install can move them within the major range. If you need reproducible builds, lock them. The licence is MIT, which permits commercial and private use and modification with the copyright notice retained. The repository ships a LICENSE file at the top level. Nothing in the README addresses the licence terms of the Sherpa-ONNX model weights themselves, which are downloaded separately from the code, so if you plan to redistribute the app with the model bundled, that is the question to check before shipping.

Editorial conclusion

Adopt it if you speak Mandarin and want a local loop that shows you your filler words and hedging in real time, and you are willing to download the Sherpa-ONNX streaming paraformer bilingual model and point the app at an AI backend. Skip it if you need English-only recognition, a packaged installer, or a browser-only workflow; the online version at exprtrain.online covers that last case. Before relying on it, verify that the model directory loads without errors, and check settings.example.json to see which backend keys the app expects, because the README does not document what happens when a backend key is missing or malformed.

Frequently asked questions

Does expression-trainer need an internet connection to work?

Speech recognition and lexicon matching run offline through Sherpa-ONNX and the local emotion-lexicon.json file. The AI feedback and the six-dimension report require a backend, which can be a hosted API such as DeepSeek or OpenAI, or a local Ollama instance.

Which speech recognition model does expression-trainer use?

The README specifies the Sherpa-ONNX streaming paraformer bilingual zh-en model, downloaded from the k2-fsa/sherpa-onnx releases or from Hugging Face. After extraction, models/ must contain encoder.int8.onnx, decoder.int8.onnx and tokens.txt.

Which AI backends can expression-trainer use for its reports?

The feature list names Groq, OpenAI, DeepSeek and Ollama, and the README's comparison table covers DeepSeek, OpenAI and Ollama, recommending DeepSeek for report quality against cost. Ollama is the only listed option that runs locally.

What do the subtitle colours mean in expression-trainer?

A red wavy underline marks filler words, orange marks hedging words, a yellow dashed line marks vague words that have a precise replacement in the lexicon, and green marks what the project counts as strong expression.

Official sources

  1. fxy2311-youyou/expression-trainer on GitHub
  2. Issues
  3. License: MIT
  4. README
Community notes

Community notes