sensitive-words-recognizer 0.1.1

A sensitive lexicon
Documentation
  • Coverage
  • 33.33%
    2 out of 6 items documented1 out of 3 items with examples
  • Size
  • Source code size: 13.6 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 191.96 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 8s Average build duration of successful builds.
  • all releases: 8s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • whiteCcinn/sensitive-words-recognizer
    0 2 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • whiteCcinn

sensitive-words-recognizer

This is a sensitive word crate.

The Features:

  • replace_sensitive_word()
fn filter_sensitive_words() {
    let str_vec = vec![
        "花呗信用卡代还OK套现",
        "套花呗分期代付",
        "马上套现信用卡",
        "期货套利",
        "空手套白狼",
        "守信用卡脖子",
        "坚定信心,同舟共济,科学防治,精准施策",
        "D+1还是T+1秒到结算免结算费",
        "Fuck you!",
        "Son of Bitch",
    ];

    println!("replace_sensitive_word......");
    for str in &str_vec {
        let replace_str = replace_sensitive_word(str, &MatchType::MinMatchType, '*');

        println!("{} --> {}", str, replace_str);
    }
}