Skip to content

Open-source speech recognition toolkit for training, inference, streaming ASR, VAD, punctuation, speaker diarization pipelines, and OpenAI-compatible/MCP serving.

docs(site): explain hotword protocols and standalone runtime upgrades

zhifu gaoeb8cb1443a55
diff --git a/web-pages/product-site/content/legacy-manifest.json b/web-pages/product-site/content/legacy-manifest.json
index 20e7c98ac..f35c31d1e 100644
--- a/web-pages/product-site/content/legacy-manifest.json
+++ b/web-pages/product-site/content/legacy-manifest.json
@@ -138,6 +138,8 @@
"static/online/wav.js": "63344c3e282b80349bdc64f7508f32346ce783609881dbfbc97827a36d594c35",
"static/online/wsconnecter.js": "a619a1cab5e111c5ff4b77ec8e68e47f9dde6ba5d7a62ca2db0c1b083c33e8ca",
"voice/index.html": "1a6bae9e1637fea91f2f97506f5847ebd0ce429136444afa61f0a75da0beea0b",
- "vs-whisper.html": "7d73ff1f771e4c17117108b172c2ce1952e98738787bb7101f061bf51aa8f03c"
+ "vs-whisper.html": "7d73ff1f771e4c17117108b172c2ce1952e98738787bb7101f061bf51aa8f03c",
+ "blog/hotwords-package-boundaries.html": "be0aaad687d18fc9387fb35ed10f44272bd47e161ae3e489cb68ca4c860d4307",
+ "en/blog/hotwords-package-boundaries.html": "4eae4e3f485e5fd8c7ab1b64d6e2fb28e0e529d821b02e87f040a0a73bbd3085"
}
}
diff --git a/web-pages/product-site/data/blog.json b/web-pages/product-site/data/blog.json
index 270e0f26f..e9899ea89 100644
--- a/web-pages/product-site/data/blog.json
+++ b/web-pages/product-site/data/blog.json
@@ -9,6 +9,19 @@
],
"lead_image": "/img/funclip-v2-1-0-interface.jpg",
"articles": [
+ {
+ "slug": "hotwords-package-boundaries",
+ "category": "explanations",
+ "reviewed": true,
+ "zh": {
+ "title": "热词没有生效?先核对传递链路和安装包",
+ "summary": "从 WebSocket 消息到 Torch 独立运行时,核对热词格式、安装版本和批次时间戳,避免把接口修复当作准确率保证。"
+ },
+ "en": {
+ "title": "Hotwords not working? Check the request path and installed package",
+ "summary": "Check hotword encoding, standalone package versions and batched timestamps, without confusing interface fixes with recognition accuracy guarantees."
+ }
+ },
{
"slug": "sensevoice-finetuning-acceptance",
"category": "explanations",
diff --git a/web-pages/product-site/legacy/blog/hotwords-package-boundaries.html b/web-pages/product-site/legacy/blog/hotwords-package-boundaries.html
new file mode 100644
index 000000000..13c692ede
--- /dev/null
+++ b/web-pages/product-site/legacy/blog/hotwords-package-boundaries.html
@@ -0,0 +1,86 @@
+<!DOCTYPE html>
+
+<html lang="zh"><head><meta charset="utf-8"/><meta content="width=device-width,initial-scale=1" name="viewport"/>
+<title>热词没有生效?先核对传递链路和安装包 | FunASR</title><meta content="从 WebSocket 消息到 Torch 独立运行时,核对热词格式、安装版本和批次时间戳,避免把接口修复当作准确率保证。" name="description"/>
+<link href="/logo.png" rel="icon"/><meta content="热词没有生效?先核对传递链路和安装包" property="og:title"/><meta content="从 WebSocket 消息到 Torch 独立运行时,核对热词格式、安装版本和批次时间戳,避免把接口修复当作准确率保证。" property="og:description"/>
+<meta content="article" property="og:type"/><meta content="https://www.funasr.com/blog/hotwords-package-boundaries.html" property="og:url"/><meta content="https://www.funasr.com/logo.png" property="og:image"/>
+<link href="https://www.funasr.com/blog/hotwords-package-boundaries.html" rel="canonical"/><link href="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" hreflang="en" rel="alternate"/><link href="https://www.funasr.com/blog/hotwords-package-boundaries.html" hreflang="zh" rel="alternate"/><link href="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" hreflang="x-default" rel="alternate"/>
+<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&amp;display=swap" rel="stylesheet"/>
+<script type="application/ld+json">{"@context":"https://schema.org","@type":"BlogPosting","headline":"热词没有生效?先核对传递链路和安装包","description":"从 WebSocket 消息到 Torch 独立运行时,核对热词格式、安装版本和批次时间戳,避免把接口修复当作准确率保证。","datePublished":"2026-11-13","dateModified":"2026-11-13","author":{"@type":"Organization","name":"FunASR / Tongyi Lab"},"publisher":{"@type":"Organization","name":"FunASR","logo":{"@type":"ImageObject","url":"https://www.funasr.com/logo.png"}},"mainEntityOfPage":{"@type":"WebPage","@id":"https://www.funasr.com/blog/hotwords-package-boundaries.html"},"image":"https://www.funasr.com/logo.png"}</script>
+<style>:root{--primary:#2563eb;--primary-dark:#1d4ed8;--bg:#fff;--surface:#f8fafc;--border:#e2e8f0;--text:#0f172a;--text-soft:#475569;--text-muted:#94a3b8;--radius:12px}
+*{margin:0;padding:0;box-sizing:border-box}
+body{font-family:'Inter',-apple-system,sans-serif;color:var(--text);line-height:1.7}
+a{color:var(--primary);text-decoration:none}a:hover{text-decoration:underline}
+.container{max-width:800px;margin:0 auto;padding:0 24px}
+.nav{position:fixed;top:0;left:0;right:0;z-index:100;background:rgba(255,255,255,0.9);backdrop-filter:blur(12px);border-bottom:1px solid var(--border);padding:14px 0}
+.nav .container{max-width:1120px;display:flex;align-items:center;gap:24px}
+.nav-logo{font-size:1.2rem;font-weight:800;color:var(--text)}.nav-logo span{color:var(--primary)}
+.nav-links{display:flex;gap:20px;margin-left:auto;flex-wrap:wrap}
+.nav-links a{font-size:0.85rem;font-weight:500;color:var(--text-soft)}
+.nav-btn{padding:7px 16px;background:var(--primary);color:#fff;border-radius:7px;font-size:0.83rem;font-weight:600}
+article{padding:120px 0 80px}
+h1{font-size:2rem;font-weight:800;line-height:1.3;margin-bottom:14px}
+h2{font-size:1.3rem;font-weight:700;margin:36px 0 14px;padding-top:16px;border-top:1px solid var(--border)}
+h3{font-size:1.05rem;font-weight:700;margin:22px 0 10px}
+p{margin-bottom:14px;color:var(--text-soft)}
+ul,ol{margin:0 0 14px 22px;color:var(--text-soft)}li{margin-bottom:6px}
+table{width:100%;border-collapse:collapse;margin:16px 0;font-size:0.86rem}
+th,td{padding:10px 12px;text-align:left;border-bottom:1px solid var(--border)}
+th{font-weight:600;background:var(--surface);font-size:0.78rem;color:var(--text-muted)}
+pre{background:#1e293b;color:#e2e8f0;padding:18px;border-radius:10px;overflow-x:auto;font-size:0.82rem;line-height:1.7;margin:14px 0}
+code{font-family:ui-monospace,Menlo,monospace}
+p code,li code{background:var(--surface);padding:2px 6px;border-radius:5px;font-size:0.85em;color:var(--primary-dark)}
+.post-meta{color:var(--text-muted);font-size:0.85rem;margin-bottom:24px}
+.cta{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:24px;margin:28px 0;text-align:center}
+.cta a.btn{display:inline-block;padding:10px 24px;background:var(--primary);color:#fff;border-radius:8px;font-weight:600}
+.post-list{list-style:none;margin:0;padding:0}
+.post-list li{margin:0 0 8px}
+.post-card{display:block;border:1px solid var(--border);border-radius:var(--radius);padding:20px 22px;margin-bottom:14px}
+.post-card:hover{border-color:var(--primary);text-decoration:none}
+.post-card h2{border:none;padding:0;margin:0 0 6px;font-size:1.15rem;color:var(--text)}
+.post-card p{margin:0;color:var(--text-soft);font-size:0.9rem}
+.post-card .date{color:var(--text-muted);font-size:0.8rem}
+footer{background:#0f172a;color:#94a3b8;padding:28px 0;text-align:center;font-size:0.8rem}
+footer a{color:#94a3b8}
+@media(max-width:900px){.nav-links{display:none}.nav .container{gap:16px}.nav-logo{margin-right:auto}h1{font-size:1.75rem}table{table-layout:fixed;font-size:0.78rem}th,td{padding:8px 4px;overflow-wrap:anywhere}p code,li code{overflow-wrap:anywhere;word-break:break-word}}
+article p a,article li a{color:#006a57;text-decoration:underline;text-underline-offset:.15em}
+</style></head><body>
+<nav class="nav"><div class="container"><a class="nav-logo" href="/">Fun<span>ASR</span></a><div class="nav-links"><a href="/#capabilities">核心能力</a><a href="/#usage">如何使用</a><a href="/#benchmark">性能</a><a href="/#demo">演示</a><a href="https://modelscope.github.io/FunASR/zh/" target="_blank">文档</a><a href="/quickstart.html">快速上手</a><a href="/models.html">模型</a><a href="/ecosystem.html">生态</a><a href="/blog/">技术博客</a><a href="/vs-whisper.html">对比 Whisper</a><a href="/donors.html">功德榜</a></div><a href="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" style="font-size:0.83rem;font-weight:600;color:var(--text-soft)">EN</a><a class="nav-btn" href="/go/github" target="_blank">GitHub ★</a></div></nav>
+<article><div class="container"><h1>热词没有生效?先核对传递链路和安装包</h1>
+<p class="post-meta">FunASR 技术博客 · 2026-11-13</p>
+<p class="lead" data-editorial="opening">团队接入语音识别时,产品名和人名常常需要热词提示。识别结果不理想,不一定是词表不够大:先确认客户端传出的词,确实以模型支持的形式到达了推理入口。</p>
+<p data-editorial="example">例如,客户端把两个术语放进带权重的 JSON 对象,再将它编码成 WebSocket 消息中的字符串。服务端不能把大括号、引号和数字一起当作热词正文。下面沿着消息、服务脚本和独立运行时三层,给出可核对的路径。</p>
+<p data-editorial="boundary">热词是提示,不是强制替换或正确率保证。本文解释已经验证的协议和运行时边界,不提供新的识别准确率、性能排名或生产部署承诺。</p>
+<h2>一、先分清你使用的入口</h2>
+<table><thead><tr><th>入口</th><th>应核对的对象</th></tr></thead><tbody>
+<tr><td>Python WebSocket 服务</td><td>仓库中的 <code>runtime/python/websocket/funasr_wss_server.py</code> 和实际运行的源码提交。</td></tr>
+<tr><td>Torch 独立运行时</td><td><code>funasr-torch==0.1.7</code>;导入名是 <code>funasr_torch</code>。</td></tr>
+<tr><td>ONNX 独立运行时</td><td><code>funasr-onnx==0.4.11</code>;导入名是 <code>funasr_onnx</code>。</td></tr>
+</tbody></table>
+<p>这三个入口不是同一个发布物。升级根包 <code>funasr</code>,不会自动更新你复制的服务脚本,也不能替代独立运行时的安装。WebSocket 热词修复见 <a href="https://github.com/modelscope/FunASR/pull/3892">#3892(保留 #3880 作者历史)</a>;不要仅凭一个版本号推断整个服务已升级。</p>
+<h2>二、让 JSON 热词成为模型实际接收的词</h2>
+<p>以下只展示消息编码,不会启动服务、下载权重或发送音频:</p>
+<pre><code data-language="python">import json
+
+hotwords = {"阿里巴巴": 20, "通义实验室": 30}
+message = {"hotwords": json.dumps(hotwords, ensure_ascii=False)}
+assert json.loads(message["hotwords"]) == hotwords
+print(json.dumps(message, ensure_ascii=False))</code></pre>
+<p>修复后的 Python 服务会把 JSON 对象的键整理为以空格分隔的词,分别写入离线和在线模型参数;空对象变为空字符串。普通字符串及不能解析成 JSON 的字符串仍按原文本传递。这里的 AutoModel 接口不接收数值权重,因此 <strong>20 和 30 不会成为模型的相对偏置强度</strong>。需要权重能力时,应单独核对所选模型与部署协议,不能把另一套运行时的约定直接搬过来。</p>
+<p>线上的完整消息还需要按相应客户端协议设置音频和分块参数。上述片段不是完整的流式客户端,其他格式也不能仅凭此示例认定兼容。部署时还需配置 TLS、鉴权、资源限制,并避免把私人音频、转录或敏感词表写进公开日志。</p>
+<h2>三、检查真正安装和导入的 Torch 包</h2>
+<p>在独立测试环境中安装指定版本,再查看包元数据和实际导入位置。不要直接改动正在服务的共享环境:</p>
+<pre><code data-language="shell">python -m pip install "funasr-torch==0.1.7"
+python -m pip check
+python -c 'import importlib.metadata as m, funasr_torch; print(m.version("funasr-torch")); print(funasr_torch.__file__)'</code></pre>
+<p>Contextual 和 Seaco 包装器使用的导出热词嵌入宽度为 10。0.1.7 会忽略空白条目,长热词保留前十个字符,并将索引限制在对应嵌入范围内。这解决的是运行时边界,不代表超长词的剩余部分仍能参与提示。请优先使用业务中有区分度的短词,并用获得授权的录音检查收益与误触发。</p>
+<h2>四、用单条与批次结果检查时间戳</h2>
+<p>把短音频与长音频分别运行一次,再组成同一批次运行。输出数量、文本和短音频的时间戳都应按各自录音核对。0.1.7 的 Paraformer 修复会按每条输入的特征长度截取峰值序列,防止填充帧拉长短音频的末尾时间戳。同一版本还包括末尾缩写合并及富转录片段词间空格修复。</p>
+<p>发布前分别测试了 wheel 和源码分发包的安装后行为。真实 GPU 证据使用既有合成夹具,且逐文件绑定运行时代码;它不是新的预训练模型准确率评测,也不是任意模型和硬件的完整兼容性证明。将自己常用的语言、噪声和长短录音纳入验收,仍然不可省略。</p>
+<h2>发布物与下一步</h2>
+<p>查看 <a href="https://github.com/modelscope/FunASR/releases/tag/runtime-torch-v0.1.7">Torch 0.1.7 Release 与校验清单</a>、<a href="https://pypi.org/project/funasr-torch/0.1.7/">PyPI 安装包</a>及 <a href="https://github.com/modelscope/FunASR/releases/tag/runtime-onnx-v0.4.11">ONNX 0.4.11 Release</a>。源码修复分别记录在 <a href="https://github.com/modelscope/FunASR/pull/3882">#3882</a>、<a href="https://github.com/modelscope/FunASR/pull/3871">#3871</a>和 <a href="https://github.com/modelscope/FunASR/pull/3869">#3869</a>。</p>
+<p data-editorial="next-step">下一步,用你有权处理的一小组录音,按<a href="/blog/meeting-transcript-acceptance.html">会议转写验收清单</a>检查术语、遗漏和时间戳,再决定何时更新自己的服务。</p>
+</div></article>
+<footer><div class="container">FunASR · 通义实验室开源语音识别 · <a href="/go/github">GitHub</a></div></footer>
+</body></html>
+
diff --git a/web-pages/product-site/legacy/en/blog/hotwords-package-boundaries.html b/web-pages/product-site/legacy/en/blog/hotwords-package-boundaries.html
new file mode 100644
index 000000000..331138755
--- /dev/null
+++ b/web-pages/product-site/legacy/en/blog/hotwords-package-boundaries.html
@@ -0,0 +1,86 @@
+<!DOCTYPE html>
+
+<html lang="en"><head><meta charset="utf-8"/><meta content="width=device-width,initial-scale=1" name="viewport"/>
+<title>Hotwords not working? Check the request path and installed package | FunASR</title><meta content="Check hotword encoding, standalone package versions and batched timestamps, without confusing interface fixes with recognition accuracy guarantees." name="description"/>
+<link href="/logo.png" rel="icon"/><meta content="Hotwords not working? Check the request path and installed package" property="og:title"/><meta content="Check hotword encoding, standalone package versions and batched timestamps, without confusing interface fixes with recognition accuracy guarantees." property="og:description"/>
+<meta content="article" property="og:type"/><meta content="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" property="og:url"/><meta content="https://www.funasr.com/logo.png" property="og:image"/>
+<link href="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" rel="canonical"/><link href="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" hreflang="en" rel="alternate"/><link href="https://www.funasr.com/blog/hotwords-package-boundaries.html" hreflang="zh" rel="alternate"/><link href="https://www.funasr.com/en/blog/hotwords-package-boundaries.html" hreflang="x-default" rel="alternate"/>
+<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&amp;display=swap" rel="stylesheet"/>
+<script type="application/ld+json">{"@context":"https://schema.org","@type":"BlogPosting","headline":"Hotwords not working? Check the request path and installed package","description":"Check hotword encoding, standalone package versions and batched timestamps, without confusing interface fixes with recognition accuracy guarantees.","datePublished":"2026-11-13","dateModified":"2026-11-13","author":{"@type":"Organization","name":"FunASR / Tongyi Lab"},"publisher":{"@type":"Organization","name":"FunASR","logo":{"@type":"ImageObject","url":"https://www.funasr.com/logo.png"}},"mainEntityOfPage":{"@type":"WebPage","@id":"https://www.funasr.com/en/blog/hotwords-package-boundaries.html"},"image":"https://www.funasr.com/logo.png"}</script>
+<style>:root{--primary:#2563eb;--primary-dark:#1d4ed8;--bg:#fff;--surface:#f8fafc;--border:#e2e8f0;--text:#0f172a;--text-soft:#475569;--text-muted:#94a3b8;--radius:12px}
+*{margin:0;padding:0;box-sizing:border-box}
+body{font-family:'Inter',-apple-system,sans-serif;color:var(--text);line-height:1.7}
+a{color:var(--primary);text-decoration:none}a:hover{text-decoration:underline}
+.container{max-width:800px;margin:0 auto;padding:0 24px}
+.nav{position:fixed;top:0;left:0;right:0;z-index:100;background:rgba(255,255,255,0.9);backdrop-filter:blur(12px);border-bottom:1px solid var(--border);padding:14px 0}
+.nav .container{max-width:1120px;display:flex;align-items:center;gap:24px}
+.nav-logo{font-size:1.2rem;font-weight:800;color:var(--text)}.nav-logo span{color:var(--primary)}
+.nav-links{display:flex;gap:20px;margin-left:auto;flex-wrap:wrap}
+.nav-links a{font-size:0.85rem;font-weight:500;color:var(--text-soft)}
+.nav-btn{padding:7px 16px;background:var(--primary);color:#fff;border-radius:7px;font-size:0.83rem;font-weight:600}
+article{padding:120px 0 80px}
+h1{font-size:2rem;font-weight:800;line-height:1.3;margin-bottom:14px}
+h2{font-size:1.3rem;font-weight:700;margin:36px 0 14px;padding-top:16px;border-top:1px solid var(--border)}
+h3{font-size:1.05rem;font-weight:700;margin:22px 0 10px}
+p{margin-bottom:14px;color:var(--text-soft)}
+ul,ol{margin:0 0 14px 22px;color:var(--text-soft)}li{margin-bottom:6px}
+table{width:100%;border-collapse:collapse;margin:16px 0;font-size:0.86rem}
+th,td{padding:10px 12px;text-align:left;border-bottom:1px solid var(--border)}
+th{font-weight:600;background:var(--surface);font-size:0.78rem;color:var(--text-muted)}
+pre{background:#1e293b;color:#e2e8f0;padding:18px;border-radius:10px;overflow-x:auto;font-size:0.82rem;line-height:1.7;margin:14px 0}
+code{font-family:ui-monospace,Menlo,monospace}
+p code,li code{background:var(--surface);padding:2px 6px;border-radius:5px;font-size:0.85em;color:var(--primary-dark)}
+.post-meta{color:var(--text-muted);font-size:0.85rem;margin-bottom:24px}
+.cta{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:24px;margin:28px 0;text-align:center}
+.cta a.btn{display:inline-block;padding:10px 24px;background:var(--primary);color:#fff;border-radius:8px;font-weight:600}
+.post-list{list-style:none;margin:0;padding:0}
+.post-list li{margin:0 0 8px}
+.post-card{display:block;border:1px solid var(--border);border-radius:var(--radius);padding:20px 22px;margin-bottom:14px}
+.post-card:hover{border-color:var(--primary);text-decoration:none}
+.post-card h2{border:none;padding:0;margin:0 0 6px;font-size:1.15rem;color:var(--text)}
+.post-card p{margin:0;color:var(--text-soft);font-size:0.9rem}
+.post-card .date{color:var(--text-muted);font-size:0.8rem}
+footer{background:#0f172a;color:#94a3b8;padding:28px 0;text-align:center;font-size:0.8rem}
+footer a{color:#94a3b8}
+@media(max-width:900px){.nav-links{display:none}.nav .container{gap:16px}.nav-logo{margin-right:auto}h1{font-size:1.75rem}table{table-layout:fixed;font-size:0.78rem}th,td{padding:8px 4px;overflow-wrap:anywhere}p code,li code{overflow-wrap:anywhere;word-break:break-word}}
+article p a,article li a{color:#006a57;text-decoration:underline;text-underline-offset:.15em}
+</style></head><body>
+<nav class="nav"><div class="container"><a class="nav-logo" href="/">Fun<span>ASR</span></a><div class="nav-links"><a href="/en/#capabilities">Capabilities</a><a href="/en/#usage">How to Use</a><a href="/en/#benchmark">Benchmark</a><a href="/en/#demo">Demo</a><a href="https://modelscope.github.io/FunASR/" target="_blank">Docs</a><a href="/en/quickstart.html">Quickstart</a><a href="/en/models.html">Models</a><a href="/en/ecosystem.html">Ecosystem</a><a href="/en/blog/">Blog</a><a href="/en/vs-whisper.html">vs Whisper</a><a href="/en/donors.html">Donors</a></div><a href="https://www.funasr.com/blog/hotwords-package-boundaries.html" style="font-size:0.83rem;font-weight:600;color:var(--text-soft)">中文</a><a class="nav-btn" href="/go/github" target="_blank">GitHub ★</a></div></nav>
+<article><div class="container"><h1>Hotwords not working? Check the request path and installed package</h1>
+<p class="post-meta">FunASR Blog · 2026-11-13</p>
+<p class="lead" data-editorial="opening">Your team may use hotwords for product names and personal names. Before expanding the vocabulary, check that the terms sent by the client actually reach the model in a supported form.</p>
+<p data-editorial="example">A client may encode two weighted terms as a JSON object, then place that JSON string inside a WebSocket message. The server must not treat braces, quotes and numbers as the terms themselves. Here is how to check the message, server script and standalone runtime separately.</p>
+<p data-editorial="boundary">Hotwords are hints, not forced replacements or accuracy guarantees. This article describes verified protocol and runtime boundaries, not a new recognition benchmark, speed ranking or production deployment guarantee.</p>
+<h2>1. Identify the entry point you actually use</h2>
+<table><thead><tr><th>Entry point</th><th>What to check</th></tr></thead><tbody>
+<tr><td>Python WebSocket server</td><td>The actual source revision of <code>runtime/python/websocket/funasr_wss_server.py</code>.</td></tr>
+<tr><td>Standalone Torch runtime</td><td><code>funasr-torch==0.1.7</code>, imported as <code>funasr_torch</code>.</td></tr>
+<tr><td>Standalone ONNX runtime</td><td><code>funasr-onnx==0.4.11</code>, imported as <code>funasr_onnx</code>.</td></tr>
+</tbody></table>
+<p>These are separate deliverables. Updating the root <code>funasr</code> package does not update a copied server script or replace a standalone runtime installation. The WebSocket fix is tracked in <a href="https://github.com/modelscope/FunASR/pull/3892">#3892, preserving the original #3880 author history</a>. One version number is not proof that the entire service was upgraded.</p>
+<h2>2. Turn JSON hotwords into model input</h2>
+<p>This example only encodes a message. It does not start a server, download weights or transmit audio:</p>
+<pre><code data-language="python">import json
+
+hotwords = {"阿里巴巴": 20, "通义实验室": 30}
+message = {"hotwords": json.dumps(hotwords, ensure_ascii=False)}
+assert json.loads(message["hotwords"]) == hotwords
+print(json.dumps(message, ensure_ascii=False))</code></pre>
+<p>The fixed Python server joins JSON object keys with spaces and supplies them to both offline and online model parameters. An empty object becomes an empty string. Plain strings and strings that cannot be parsed as JSON retain their original text. This AutoModel interface does not accept numeric hotword weights, so <strong>20 and 30 do not become relative model bias strengths</strong>. Check the chosen model and deployment protocol separately if weighted biasing is required.</p>
+<p>A complete client must also follow its audio and chunking protocol. The snippet is not a complete streaming client, nor proof that other message formats are compatible. Configure TLS, authentication and resource limits for deployment. Do not put private audio, transcripts or sensitive vocabulary into public logs.</p>
+<h2>3. Verify the installed and imported Torch package</h2>
+<p>Use a dedicated test environment, install the pinned version, then inspect package metadata and the import location. Do not modify a shared serving environment directly:</p>
+<pre><code data-language="shell">python -m pip install "funasr-torch==0.1.7"
+python -m pip check
+python -c 'import importlib.metadata as m, funasr_torch; print(m.version("funasr-torch")); print(funasr_torch.__file__)'</code></pre>
+<p>The exported embedding used by the Contextual and Seaco wrappers has a hotword width of ten. Version 0.1.7 removes empty whitespace entries, retains the first ten characters of longer terms, and keeps indexes within that embedding range. This fixes a runtime boundary; it does not preserve the truncated suffix as a hint. Prefer short, distinctive terms and check both useful matches and false triggers on recordings you are authorized to process.</p>
+<h2>4. Compare individual and batched timestamps</h2>
+<p>Run a short recording and a long recording individually, then together in a batch. Check output count, text and timestamps against each recording. The Paraformer change in 0.1.7 slices each peak sequence by its own feature length, preventing padded frames from extending the shorter recording's final timestamp. The package also includes terminal abbreviation grouping and word-boundary fixes for rich-transcription segments.</p>
+<p>Installed behavior is tested separately for the wheel and source distribution. Existing real GPU evidence uses synthetic fixtures and is bound to the runtime source file by file. It is not a new pretrained-model accuracy evaluation or a full compatibility guarantee for every model and device. Your own languages, noise conditions and recording lengths still need acceptance testing.</p>
+<h2>Release artifacts and your next step</h2>
+<p>See the <a href="https://github.com/modelscope/FunASR/releases/tag/runtime-torch-v0.1.7">Torch 0.1.7 release and checksums</a>, <a href="https://pypi.org/project/funasr-torch/0.1.7/">PyPI package</a> and <a href="https://github.com/modelscope/FunASR/releases/tag/runtime-onnx-v0.4.11">ONNX 0.4.11 release</a>. Source changes are tracked in <a href="https://github.com/modelscope/FunASR/pull/3882">#3882</a>, <a href="https://github.com/modelscope/FunASR/pull/3871">#3871</a> and <a href="https://github.com/modelscope/FunASR/pull/3869">#3869</a>.</p>
+<p data-editorial="next-step">Next, use a small set of authorized recordings and the <a href="/en/blog/meeting-transcript-acceptance.html">meeting-transcript acceptance checklist</a> to inspect terminology, omissions and timestamps before upgrading your service.</p>
+</div></article>
+<footer><div class="container">FunASR · Open-source speech recognition by Tongyi Lab · <a href="/go/github">GitHub</a></div></footer>
+</body></html>
+
diff --git a/web-pages/product-site/tests/browser/blog-editorial.spec.ts b/web-pages/product-site/tests/browser/blog-editorial.spec.ts
index 586657b2f..2fbf8c6ad 100644
--- a/web-pages/product-site/tests/browser/blog-editorial.spec.ts
+++ b/web-pages/product-site/tests/browser/blog-editorial.spec.ts
@@ -1,4 +1,8 @@
import { expect, test } from '@playwright/test';
+import { readFileSync } from 'node:fs';
+import { resolve } from 'node:path';
+
+const catalogue = JSON.parse(readFileSync(resolve(__dirname, '../../data/blog.json'), 'utf8'));
for (const prefix of ['', 'en/']) {
for (const width of [390, 1440]) {
@@ -78,7 +82,10 @@ for (const prefix of ['', 'en/']) {
}
await page.locator(`[data-blog-more] a[href="/${prefix}blog/archive/"]`).click();
const archive = page.locator('[data-blog-view="archive"]');
- await expect(archive.locator('[data-blog-story]')).toHaveCount(37);
+ await expect(archive.locator('[data-blog-story]')).toHaveCount(catalogue.articles.length);
+ for (const { slug } of catalogue.articles) {
+ await expect(archive.locator(`[data-blog-story][href="/${prefix}blog/${slug}.html"]`)).toHaveCount(1);
+ }
await page.screenshot({ path: testInfo.outputPath('archive.png') });
await archive.locator(`a[href="/${prefix}blog/self-hosted-deepgram-assemblyai-alternative.html"]`).click();
await expect(page.locator('article h1')).toBeVisible();
diff --git a/web-pages/product-site/tests/test_hotword_release_article.py b/web-pages/product-site/tests/test_hotword_release_article.py
new file mode 100644
index 000000000..efcf56369
--- /dev/null
+++ b/web-pages/product-site/tests/test_hotword_release_article.py
@@ -0,0 +1,78 @@
+"""Keep the daily integration article bilingual, reproducible and bounded."""
+import contextlib
+import io
+import json
+from pathlib import Path
+import sys
+
+from bs4 import BeautifulSoup
+import pytest
+
+SITE = Path(__file__).resolve().parents[1]
+sys.path.insert(0, str(SITE))
+from build import build
+
+SLUG = "hotwords-package-boundaries"
+
+
+def test_catalogue_contains_daily_article_once():
+ data = json.loads((SITE / "data/blog.json").read_text())
+ entries = [row for row in data["articles"] if row["slug"] == SLUG]
+ assert len(entries) == 1
+ assert entries[0]["reviewed"] and entries[0]["category"] == "explanations"
+ assert data["selected"] == [
+ "meeting-transcript-acceptance", "fun-asr-nano-transformers",
+ "self-hosted-openai-whisper-api-alternative", "funasr-transcribe-long-audio",
+ ]
+
+
[email protected](scope="module", params=["source", "built"])
+def tree(request, tmp_path_factory):
+ if request.param == "source":
+ return SITE / "legacy"
+ output = tmp_path_factory.mktemp("hotword-article")
+ build(output)
+ return output
+
+
[email protected](params=["", "en/"])
+def article(request, tree):
+ prefix = request.param
+ path = tree / prefix / "blog" / (SLUG + ".html")
+ return prefix, BeautifulSoup(path.read_text(), "html.parser")
+
+
+def test_article_metadata_and_package_boundaries(article):
+ prefix, soup = article
+ metadata = json.loads(soup.select_one('script[type="application/ld+json"]').get_text())
+ assert metadata["datePublished"] == metadata["dateModified"] == "2026-11-13"
+ assert metadata["headline"] == soup.select_one("article h1").get_text()
+ assert soup.select_one('link[rel="canonical"]')["href"] == f"https://www.funasr.com/{prefix}blog/{SLUG}.html"
+ links = {a["href"] for a in soup.select("article a[href]")}
+ assert "https://pypi.org/project/funasr-torch/0.1.7/" in links
+ assert "https://github.com/modelscope/FunASR/releases/tag/runtime-torch-v0.1.7" in links
+ assert "https://github.com/modelscope/FunASR/pull/3892" in links
+ text = soup.select_one("article").get_text(" ", strip=True)
+ assert "funasr-torch==0.1.7" in text and "funasr-onnx==0.4.11" in text
+ assert soup.select_one('[data-editorial="boundary"]')
+ assert len(soup.select('[data-editorial="next-step"] a')) == 1
+
+
+def test_json_example_executes_without_a_model_or_network(article):
+ _, soup = article
+ code = soup.select_one('code[data-language="python"]').get_text()
+ scope = {}
+ with contextlib.redirect_stdout(io.StringIO()) as output:
+ exec(compile(code, "article-example", "exec"), scope)
+ message = json.loads(output.getvalue())
+ assert json.loads(message["hotwords"]) == {"\u963f\u91cc\u5df4\u5df4": 20, "\u901a\u4e49\u5b9e\u9a8c\u5ba4": 30}
+
+
[email protected]("prefix", ["", "en/"])
+def test_new_article_is_discoverable_without_removing_existing_entrypoints(prefix, tmp_path):
+ build(tmp_path)
+ for category in ("archive", "explanations"):
+ soup = BeautifulSoup((tmp_path / prefix / "blog" / category / "index.html").read_text(), "html.parser")
+ cards = soup.select(f'a[href="/{prefix}blog/{SLUG}.html"]')
+ assert len(cards) == 1
+ assert cards[0].select_one('time[datetime="2026-11-13"]')