From 6800f7251d2de7e36c9ca9e3f0c84368de623361 Mon Sep 17 00:00:00 2001 From: zihluwang Date: Fri, 25 Sep 2026 14:49:03 +0800 Subject: [PATCH] docs(blogs): drop dead scws download links MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Both URLs in the tip were dead. The GitHub one referenced an account that does not exist, and the Gitea one is retired. Point at the upstream SCWS project instead, and stop promising a pre-built Windows binary — upstream publishes source only, and the 1.2.3 the dead link referenced was OnixByte's own build. --- docs/en-gb/blogs/postgresql-zhparser-fuzzy-search.md | 12 ++++++++++-- .../blogs/postgresql-zhparser-fuzzy-search.md | 10 ++++++++-- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/docs/en-gb/blogs/postgresql-zhparser-fuzzy-search.md b/docs/en-gb/blogs/postgresql-zhparser-fuzzy-search.md index fca75a6..a499f65 100644 --- a/docs/en-gb/blogs/postgresql-zhparser-fuzzy-search.md +++ b/docs/en-gb/blogs/postgresql-zhparser-fuzzy-search.md @@ -73,7 +73,7 @@ This step requires `pg_config` from the self-compiled PostgreSQL installation. make USE_PGXS=1 PG_CONFIG=/usr/local/pgsql/bin/pg_config install ``` - *Note: The `install` step automatically places `zhparser.so` into PG's `pkglibdir` and extension scripts into the `extension` directory.* + _Note: The `install` step automatically places `zhparser.so` into PG's `pkglibdir` and extension scripts into the `extension` directory._ ### Resolving Dynamic Library Dependencies @@ -152,8 +152,15 @@ Leverage the structural parsing capabilities of **`companynameparser`** to strip ### Lexicon Compilation and Deployment + + :::tip -Users compiling `xdb` binary dictionary files on Windows can visit OnixByte’s [GitHub](https://github.com/onixbyte/scws/releases/tag/1.2.3) or [GitLab](https://git.onixbyte.cn/onixbyte/scws/-/releases/1.2.3) pages to download the native scws command-line tool for Windows, pre-compiled using MingW. +The native scws command-line tool for Windows is compiled with MingW. Source and +build instructions are available from the upstream +[SCWS project](https://github.com/hightman/scws). ::: Convert the text dictionary to SCWS's efficient binary format (XDB): @@ -208,5 +215,6 @@ SELECT * FROM ts_debug('chinese', '元一能源'); ``` **Optimisation Notes:** + - **Explicit Weight Compensation**: This is the key technique that resolved the "元一" tokenisation failure (shown as `x`). - **Distinguish Restart from Reload**: `shared_preload_libraries` must be activated via `restart`, not a simple reload. diff --git a/docs/zh-hans/blogs/postgresql-zhparser-fuzzy-search.md b/docs/zh-hans/blogs/postgresql-zhparser-fuzzy-search.md index 783ef92..6b97ac5 100644 --- a/docs/zh-hans/blogs/postgresql-zhparser-fuzzy-search.md +++ b/docs/zh-hans/blogs/postgresql-zhparser-fuzzy-search.md @@ -73,7 +73,7 @@ SCWS 是 `zhparser` 依赖的底层核心,必须先行安装。 make USE_PGXS=1 PG_CONFIG=/usr/local/pgsql/bin/pg_config install ``` - *注:`install` 步骤会自动将 `zhparser.so` 放入 PG 的 `pkglibdir`,将脚本放入 `extension` 目录。* + _注:`install` 步骤会自动将 `zhparser.so` 放入 PG 的 `pkglibdir`,将脚本放入 `extension` 目录。_ ### 解决动态链接库依赖 @@ -152,8 +152,13 @@ ALTER TEXT SEARCH CONFIGURATION chinese ADD MAPPING FOR n,v,a,i,e,l,t,b WITH sim ### 词库编译与部署 + + :::tip -对于使用 Windows 进行编译 `xdb` 二进制词典文件的用户,可以前往 OnixByte 的 [GitHub](https://github.com/onixbyte/scws/releases/tag/1.2.3) 或 [GitLab](https://git.onixbyte.cn/onixbyte/scws/-/releases/1.2.3) 页面下载使用 MingW 预编译好的,适用于 Windows 的原生 scws 命令行工具。 +适用于 Windows 的原生 scws 命令行工具使用 MingW 编译。源码与编译说明见上游 +[SCWS 项目](https://github.com/hightman/scws)。 ::: 将文本词典转换为 SCWS 高效二进制格式(XDB): @@ -208,5 +213,6 @@ SELECT * FROM ts_debug('chinese', '元一能源'); ``` **优化建议:** + - **显式提及权重补偿**:这是解决"元一"分词失败(显示为 `x`)的关键技术点。 - **区分重启与重载**:明确 `shared_preload_libraries` 必须通过 `restart` 激活。