#5959th of 75 in ML frameworks and libraries

hanlp

Multilingual NLP toolkit for tokenization, tagging, parsing and NER, mainly Chinese

Stars
36.5k
License
Apache-2.0
Last commit
Sep 2026
Last release
Jan 2025
Language
Python
Stars, last 29 weeks+525
31 Mar 2026: 35,995 stars7 Apr 2026: 36,006 stars14 Apr 2026: 36,035 stars21 Apr 2026: 36,054 stars28 Apr 2026: 36,080 stars5 May 2026: 36,096 stars12 May 2026: 36,121 stars19 May 2026: 36,132 stars26 May 2026: 36,162 stars2 Jun 2026: 36,180 stars9 Jun 2026: 36,234 stars16 Jun 2026: 36,271 stars23 Jun 2026: 36,289 stars30 Jun 2026: 36,302 stars7 Jul 2026: 36,322 stars14 Jul 2026: 36,336 stars21 Jul 2026: 36,348 stars28 Jul 2026: 36,363 stars4 Aug 2026: 36,381 stars11 Aug 2026: 36,394 stars18 Aug 2026: 36,407 stars25 Aug 2026: 36,421 stars1 Sept 2026: 36,427 stars8 Sept 2026: 36,441 stars15 Sept 2026: 36,452 stars22 Sept 2026: 36,471 stars29 Sept 2026: 36,482 stars6 Oct 2026: 36,487 stars13 Oct 2026: 36,501 stars20 Oct 2026: 36,520 stars

35,995 on 31 Mar 202636,520 on 20 Oct 2026

From GitHub's daily star counts.

Checked on GitHub.

Overview

HanLP is a Python NLP toolkit with pretrained PyTorch and TensorFlow 2.x models for tokenization, POS tagging, NER, dependency and constituency parsing, semantic role labeling, AMR and more. It offers a native API that loads models locally, and a RESTful client (Python, Go, Java) that calls a hosted server. Output is a uniform JSON-compatible Document. The README states support for 130 languages through joint multi-task models.

Who it is for: NLP engineers and researchers doing Chinese or multilingual text analysis

Strengths

  • Covers many classic NLP tasks with pretrained models: tok, POS, NER, dep, con, SRL, SDP, AMR
  • Native and RESTful APIs share the same semantics, so code ports between them
  • Custom trie dictionaries with force, merge and correct rules feed into downstream models
  • Multi-task models save speed and memory; single-task models can be chained in a pipeline

Weaknesses

  • Native API requires Python 3.6 to 3.10, which is dated
  • Last release is 2025-01-13; the README is Chinese-first
  • Native API takes sentences as input, so sentence splitting is a separate step
  • Hosted RESTful API gives anonymous users limited quota; an auth key is recommended

What it needs

  • GPU optional
  • Needs PyTorch, TensorFlow 2.x
  • Models: PyTorch, TensorFlow 2.x, ELECTRA, mMiniLMv2

Also in ML frameworks and libraries

See all 75
Also in ML frameworks and libraries
RankProjectScore
1transformersPython library defining open models for text, vision, audio and multimodal tasks167.9k starsApache-2.094 out of 100
2pytorchPython tensor library with GPU support and tape-based autograd for deep learning104.9k starscustom license94 out of 100
3ultralyticsPython library and CLI for training and running YOLO vision models62.7k starsAGPL-3.092 out of 100
#4pytorch-image-modelsPyTorch library of image models, pretrained weights and reference training scripts37.2k starsApache-2.091 out of 100
#5supervisionPython toolkit for loading, annotating and counting computer vision detections Live demo ↗ (opens in a new tab)51.3k starsMIT90 out of 100