7 releases (stable)

2.0.4 Nov 10, 2023
2.0.3 Oct 12, 2022
2.0.2 Sep 10, 2022
2.0.1 Aug 2, 2022
0.1.0 May 6, 2020

#155 in Internationalization (i18n)

Download history 85/week @ 2024-12-11 37/week @ 2024-12-18 14/week @ 2024-12-25 29/week @ 2025-01-01 40/week @ 2025-01-08 24/week @ 2025-01-15 10/week @ 2025-01-22 5/week @ 2025-01-29 43/week @ 2025-02-05 8/week @ 2025-02-12 9/week @ 2025-02-19 32/week @ 2025-02-26 39/week @ 2025-03-12 5/week @ 2025-03-19 19/week @ 2025-03-26

73 downloads per month
Used in chinese_dictionary

MIT license

1.5MB
124 lines

chinese_detection

v2.0.0

About

Classify a string as either English, Chinese, or Pinyin.

Usage

extern crate chinese_detection;

use chinese_detection::{ClassificationResult, classify};

assert_eq!(ClassificationResult::EN, classify("test"));
assert_eq!(ClassificationResult::PY, classify("shiyan")); 
assert_eq!(ClassificationResult::ZH, classify("实验")); 

License

MIT

Dependencies