← all repositories
hiDaDeng/cnsenti

A Chinese sentiment library that's already retired

cnsenti offered dictionary-based sentiment and emotion analysis for Chinese text, but has since merged into a larger project.

588 stars Python Language ModelsOther AI
cnsenti
Not currently ranked — collecting fresh signals.
star history

What it does

cnsenti counts positive and negative words in Chinese text using built-in dictionaries (Hownet for sentiment, Dalian University of Technology’s ontology for seven emotions: good, happy, sad, angry, fear, disgust, shock). It also attempts smarter scoring with sentiment_calculate, which weights intensity adverbs and negation flips. You can supply custom txt dictionaries for domain-specific terms like “industry leader” that generic lexicons miss.

The interesting bit

The library’s real utility was bridging a gap: most English sentiment tools don’t handle Chinese well, and academic Chinese dictionaries come with licensing strings attached. cnsenti packaged two established research dictionaries into pip-installable code—though you must cite DUT’s lab if you publish, and commercial use requires negotiation.

Key highlights

  • Two analysis modes: simple word counting (sentiment_count) or weighted scoring with adverb/negation handling (sentiment_calculate)
  • Seven-category emotion taxonomy from Dalian University of Technology’s emotional ontology
  • Custom dictionary support via UTF-8 txt files, with merge-or-replace behavior
  • ~588 stars, pure Python, pip-installable including Tsinghua mirror

Caveats

  • Deprecated: The README states cnsenti “has stopped maintenance” and all functionality merged into cntext
  • Dictionary-based approach misses context, irony, and non-adjective sentiment (e.g., “industry leader” scores zero without custom lexicon)
  • Academic licensing requirements for DUT emotion dictionary; commercial use requires explicit permission

Verdict

Skip this repo and evaluate cntext directly—it’s where active development moved. If you need a quick, transparent baseline for Chinese sentiment without neural overhead, the approach is sound but the implementation is frozen.

Frequently asked

What is hiDaDeng/cnsenti?
cnsenti offered dictionary-based sentiment and emotion analysis for Chinese text, but has since merged into a larger project.
Is cnsenti open source?
Yes — hiDaDeng/cnsenti is open source, released under the MIT license.
What language is cnsenti written in?
hiDaDeng/cnsenti is primarily written in Python.
How popular is cnsenti?
hiDaDeng/cnsenti has 588 stars on GitHub.
Where can I find cnsenti?
hiDaDeng/cnsenti is on GitHub at https://github.com/hiDaDeng/cnsenti.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.