Chinese language Model(kenlm)

kenlm language model:

  • big model: zh_giga.no_cna_cmn.prune01244.klm
  • small model: people2014corpus_chars.klm

Usage

本项目开源在 pycorrector 项目:pycorrector,可支持kenlm模型,通过如下命令调用:

Install package:

pip install -U pycorrector
from pycorrector import Corrector
model = Corrector(language_model_path='people2014corpus_chars.klm')
print(model.correct('少先队员因该为老人让坐')) # ['少先队员应该为老人让座。']

如果需要训练文本纠错模型,请参考https://github.com/shibing624/pycorrector

Citation

@software{pycorrector,
  author = {Ming Xu},
  title = {pycorrector: Text Error Correction Tool},
  year = {2023},
  url = {https://github.com/shibing624/pycorrector},
}
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference API
Unable to determine this model's library. Check the docs .