napi-rs Docs
@napi-rs/pinyin
@napi-rs/pinyin
rust-pinyin binding to Node.js.
Performance
Hardware info:
Model Name: MacBook ProModel Identifier: MacBookPro15,1Processor Name: 6-Core Intel Core i7Processor Speed: 2.6 GHzNumber of Processors: 1Total Number of Cores: 6L2 Cache (per Core): 256 KBL3 Cache: 12 MBHyper-Threading Technology: EnabledMemory: 16 GB
Running "Short input without segment" suite...Progress: 100% @napi-rs/pinyin: 962 035 ops/s, ±0.68% | fastest node-pinyin: 434 241 ops/s, ±0.66% | slowest, 54.86% slowerFinished 2 cases! Fastest: @napi-rs/pinyin Slowest: node-pinyinRunning "Long input without segment" suite...Progress: 100% @napi-rs/pinyin: 59 ops/s, ±0.83% | fastest node-pinyin: 2 ops/s, ±3.30% | slowest, 96.61% slowerFinished 2 cases! Fastest: @napi-rs/pinyin Slowest: node-pinyinRunning "Short input with segment" suite...Progress: 100% @napi-rs/pinyin: 530 228 ops/s, ±1.94% | fastest node-pinyin: 307 788 ops/s, ±0.83% | slowest, 41.95% slowerFinished 2 cases! Fastest: @napi-rs/pinyin Slowest: node-pinyinRunning "Long input with segment" suite...Progress: 100% @napi-rs/pinyin: 152 ops/s, ±1.09% | fastest node-pinyin: 3 ops/s, ±3.08% | slowest, 98.03% slowerFinished 2 cases! Fastest: @napi-rs/pinyin Slowest: node-pinyin✨ Done in 53.36s.