Scan your whole stack
From OX Research Newsroom
Are you using opencc-fmmseg-wasm?
Find out what’s in your code.
Scan your apps free in minutes (opens in a new tab)Latest version: v0.5.6
opencc-fmmseg-wasm was last scanned on 30 Nov 2026 at version 0.5.6. Risk score 0 of 100. No malicious behavior was detected.
| Version | Published | Status |
|---|---|---|
| 0.5.6 LATEST | 30 Nov 2026 | 1 rule fired |
| 0.5.5 | 21 Nov 2026 | 1 rule fired |
| 0.5.4 | 17 Nov 2026 | 1 rule fired |
| 0.5.3 | 8 Nov 2026 | Not shown |
| 0.5.2 | 30 Oct 2026 | Not shown |
Findings for v0.5.6. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.
The package includes a WebAssembly (.wasm) module. It cannot be reviewed as source, but it runs sandboxed inside the JavaScript runtime and can access only what the host code gives it. WebAssembly is common in parsers, codecs and cryptography libraries. Shown for awareness.
LOWThe score describes 0.5.6; other versions have their own rules, not their own score.
The publisher’s own README, as collected from the registry.
OpenCC FMM segmentation WebAssembly bindings for browsers and JavaScript runtimes.
This package provides high-quality Simplified Chinese ↔ Traditional Chinese conversion powered by the Rust
opencc-fmmseg engine.
Features:
zho_check)Package profile:
Try opencc-fmmseg-wasm directly in your browser:
Open the live WASM demo: CJK Conversion Tool
The interactive demo includes:
Document text extraction and PDF processing are powered by reusable Rust WASM helpers from
pdfium-helper.
All processing runs locally in your browser using WebAssembly. Your files are never uploaded to a server.
Note: PDF extraction requires an existing text layer. OCR and password-protected PDF extraction are not currently supported.
No installation or server backend required.
npm install @laisuk/opencc-fmmseg-wasm
Or installation from the mirror package:
npm install opencc-fmmseg-wasm
import init, {
OpenccWasm
} from "@laisuk/opencc-fmmseg-wasm";
await init();
const cc = new OpenccWasm("s2t");
console.log(cc.convert("汉字转换测试", false));
// 漢字轉換測試
const cc = new OpenccWasm("s2t");
Parameters:
config (optional): OpenCC config string"s2t"Example:
const cc = new OpenccWasm("t2s");
Taiwan phrase config example:
const cc = new OpenccWasm("s2twp");
cc.convert("预订‘奔驰’品牌出租车", true);
// 預訂『賓士』品牌計程車
Hong Kong phrase config example:
const cc = new OpenccWasm("hk2sp");
cc.convert("作業系統加密保護個人私隱權", false);
// 操作系统加密保护个人隐私权
cc.convert(text, punctuation)
Parameters:
text: input stringpunctuation: whether to convert punctuation variantsReturns:
Example:
cc.convert("汉字", false);
cc.setConfig("t2s");
Returns:
true if validfalse if invalidcc.getConfig();
Returns current config string.
OpenccWasm.isValidConfig("s2t");
OpenccWasm.getSupportedConfigs();
Returns all supported config strings.
Includes s2hkp, hk2sp, t2hkp, and hk2tp.
const slots = OpenccWasm.getAvailableSlots();
Returns all canonical dictionary slot names accepted by newWithCustomDicts as a string array. The list is sourced from
the core DictSlot definitions, so callers can use it to populate selectors or validate custom dictionary input without
maintaining their own slot list.
if (!OpenccWasm.getAvailableSlots().includes(slot)) {
throw new Error(`Unsupported dictionary slot: ${slot}`);
}
Detect Chinese script type.
cc.zhoCheck(text);
Returns:
| Value | Meaning |
|---|---|
0 |
Unknown / mixed |
1 |
Traditional Chinese |
2 |
Simplified Chinese |
Normalize Unicode CJK Compatibility Ideographs before conversion.
cc.normalizeCompat(text)
Parameters:
text: input stringReturns:
Example:
const cc = new OpenccWasm("t2s");
const input = "天龍八部書裡的喬峰是契丹人";
const normalized = cc.normalizeCompat(input);
console.log(normalized);
// 天龍八部書裡的喬峰是契丹人
console.log(cc.convert(normalized, false));
// 天龙八部书里的乔峰是契丹人
This is an optional pre-conversion pass for text that contains CJK Compatibility Ideographs. Unmapped characters are
preserved unchanged. Normal OpenCC conversion does not automatically run this pass, so call it explicitly when
compatibility normalization is desired.
Normalize additional Unicode compatibility forms, CJK radicals, allographs, legacy glyphs, and selected compatibility-like punctuation before conversion.
cc.normalizeUnicodeCompat(text)
Parameters:
text: input stringReturns:
Example:
const cc = new OpenccWasm("t2s");
const input = "聼聼竒羙⽟䂖甁噐⾳";
const normalized = cc.normalizeUnicodeCompat(input);
console.log(normalized);
// 聽聽奇美玉石瓶器音
console.log(cc.convert(normalized, false));
// 听听奇美玉石瓶器音
This pass uses the extended Unicode compatibility table and is separate from normalizeCompat(). It is useful for text
containing radical forms, historical or allographic Han forms, and other compatibility-like characters that are not
covered by the CJK Compatibility Ideograph ranges.
Unmapped characters are preserved unchanged.
Apply complete compatibility normalization before conversion.
cc.normalizeCompatExtended(text)
Parameters:
text: input stringReturns:
Example:
const cc = new OpenccWasm("t2s");
const input = "天龍八部書裡的聼眾";
const normalized = cc.normalizeCompatExtended(input);
console.log(normalized);
// 天龍八部書裡的聽眾
console.log(cc.convert(normalized, false));
// 天龙八部书里的听众
normalizeCompatExtended() combines the extended Unicode compatibility table with CJK Compatibility Ideograph
normalization. Use this when input may contain characters handled by either normalization set.
The normalization order is:
Normal OpenCC conversion does not automatically perform compatibility normalization. Call this method explicitly
before
convert() when complete compatibility normalization is desired.
Replace tofu-risk rare CJK extension characters with display-compatible fallbacks.
cc.detofu(text, level)
Parameters:
text: input stringlevel: DetofuLevelWasm threshold for the CJK extension ranges to replaceReturns:
Supported levels:
| Enum | CLI value |
|---|---|
DetofuLevelWasm.ExtB |
ext-b |
DetofuLevelWasm.ExtC |
ext-c |
DetofuLevelWasm.ExtD |
ext-d |
DetofuLevelWasm.ExtE |
ext-e |
DetofuLevelWasm.ExtF |
ext-f |
DetofuLevelWasm.ExtG |
ext-g |
DetofuLevelWasm.ExtH |
ext-h |
DetofuLevelWasm.ExtI |
ext-i |
Example:
import init, {
OpenccWasm,
DetofuLevelWasm
} from "@laisuk/opencc-fmmseg-wasm";
await init();
const cc = new OpenccWasm("t2s");
const converted = cc.convert("儼驂騑於上路", false);
console.log(converted);
// 俨骖𬴂于上路
console.log(cc.detofu(converted, DetofuLevelWasm.ExtB));
// 俨骖騑于上路
convertDetofuConvert text and apply detofu in one call.
cc.convertDetofu(text, punctuation, level)
Parameters:
text: input stringpunctuation: whether to convert punctuation variantslevel: DetofuLevelWasm threshold for the CJK extension ranges to replaceReturns:
Example:
cc.convertDetofu("儼驂騑於上路", false, DetofuLevelWasm.ExtB);
// 俨骖騑于上路
Construct a converter with in-memory custom dictionary pairs.
const cc = OpenccWasm.newWithCustomDicts(config, specs);
Parameters:
config: OpenCC config string, such as "s2t"specs: array of custom dictionary specsTypeScript-style spec shape:
type WasmCustomDictSpec = {
slot: string;
mode?: "Append" | "Override";
pairs: Array<[string, string]>;
};
mode defaults to "Append" when omitted.
Each pairs entry is a [source, target] string tuple for the selected slot.
TypeScript example:
import init, {OpenccWasm} from "@laisuk/opencc-fmmseg-wasm";
await init();
const specs: WasmCustomDictSpec[] = [
{
slot: "STPhrases",
pairs: [
["云端", "雲端"]
]
}
];
const cc = OpenccWasm.newWithCustomDicts("s2t", specs);
Practical example:
import init, {OpenccWasm} from "@laisuk/opencc-fmmseg-wasm";
await init();
const cc = OpenccWasm.newWithCustomDicts("s2t", [
{
slot: "STPhrases",
mode: "Append",
pairs: [
["帕兰蒂尔", "柏蘭蒂爾"],
["软件", "軟體"]
]
}
]);
console.log(cc.convert("帕兰蒂尔软件", false));
// 柏蘭蒂爾軟體
Override example:
const cc = OpenccWasm.newWithCustomDicts("s2t", [
{
slot: "STPhrases",
mode: "Override",
pairs: [
["软件", "軟體"]
]
}
]);
Override replaces the selected slot before inserting the provided pairs. It is powerful and should be used only when
the caller intentionally wants to discard built-in entries for that slot.
Custom dictionary specs identify the target dictionary slot by DictSlot name. Slot names are trimmed and matched
case-insensitively, so "stphrases", " STPhrases ", and "STPhrases" all select STPhrases. Canonical names are
recommended in TypeScript code and docs; use OpenccWasm.getAvailableSlots() to retrieve the current list.
Suffixes such as .txt are not accepted, even though case and surrounding whitespace are normalized. Use
"STPhrases" or "stphrases", not "STPhrases.txt".
Merge contract:
DictionaryMaxlength before OpenCC::from_dictionary(...).Append mode merges into the selected slot.Override mode clears the selected slot first, then inserts the provided custom pairs.This API is useful for browser apps, user-defined terminology, database-loaded terms, generated dictionaries,
localStorage or IndexedDB terms, testing, and embedded WASM environments. Customization happens at construction
time, not during conversion.
Find threats in your stack.
OX Radar can check high-priority threats, like critical package CVEs, against your context.
Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.
The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).
The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.