Use SnowNLP for Chinese text processing
masterSnowNLP is a Python library for simplified Chinese text processing. It handles Unicode encoding, so ensure your input strings are decoded to Unicode.
Key features include:
- Word segmentation (
.words) - Part-of-speech tagging (
.tags) - Sentiment analysis (
.sentiments) - Pinyin conversion (
.pinyin) - Traditional to Simplified Chinese conversion (
.han) - Keyword extraction (
.keywords(n)) - Text summarization (
.summary(n)) - Sentence tokenization (
.sentences) - TF/IDF calculation
- Text similarity (
.sim(list)) - Text classification