#4747th of 50 in Data and scraping for AI

keybert

Python library that extracts keywords and keyphrases using sentence embeddings

Stars
4.2k
License
MIT
Last commit
Aug 2026
Last release
Feb 2025
Language
Python
Stars, last 29 weeks+96
21 Apr 2026: 4,129 stars28 Apr 2026: 4,136 stars5 May 2026: 4,138 stars12 May 2026: 4,144 stars19 May 2026: 4,151 stars26 May 2026: 4,153 stars2 Jun 2026: 4,158 stars9 Jun 2026: 4,161 stars16 Jun 2026: 4,165 stars23 Jun 2026: 4,169 stars30 Jun 2026: 4,174 stars7 Jul 2026: 4,179 stars14 Jul 2026: 4,182 stars21 Jul 2026: 4,188 stars28 Jul 2026: 4,191 stars4 Aug 2026: 4,194 stars11 Aug 2026: 4,198 stars18 Aug 2026: 4,199 stars25 Aug 2026: 4,201 stars1 Sept 2026: 4,203 stars8 Sept 2026: 4,205 stars15 Sept 2026: 4,207 stars22 Sept 2026: 4,211 stars29 Sept 2026: 4,212 stars6 Oct 2026: 4,213 stars13 Oct 2026: 4,215 stars20 Oct 2026: 4,219 stars27 Oct 2026: 4,222 stars3 Nov 2026: 4,223 stars10 Nov 2026: 4,225 stars

4,129 on 21 Apr 20264,225 on 10 Nov 2026

From GitHub's daily star counts.

Checked on GitHub.

Overview

KeyBERT embeds a document and its candidate n-grams, then ranks phrases by cosine similarity to the document. It supports Sentence-Transformers, Flair, spaCy, Gensim and USE embeddings, with Max Sum and MMR options for diversifying results. A separate KeyLLM class sends text to an LLM such as OpenAI for keyword extraction.

Who it is for: Python developers who need keyword extraction from documents

Strengths

  • Uses pretrained embeddings, so no training step; extraction takes a few lines of Python
  • Max Sum Distance and MMR options reduce near-duplicate keywords
  • Several embedding backends: Sentence-Transformers, Flair, spaCy, Gensim, USE
  • Light install without PyTorch is possible via Model2Vec

Weaknesses

  • Library only: no UI, server or API; you write Python to use it
  • Max Sum Distance has super-exponential time cost with large top_n
  • KeyLLM example needs the openai package and an API key
  • Last release is 2025-02-07, older than the latest commit

What it needs

  • GPU optional
  • Needs Python 3.10+, scikit-learn, sentence-transformers, openai (for KeyLLM)
  • Models: Sentence-Transformers, Flair, spaCy, Gensim, Universal Sentence Encoder

Quick answers

Is keybert open source?

Yes. Its code is on GitHub under the MIT license.

Does keybert need a GPU?

No. It runs on a CPU and can use a GPU when you have one.

Also in Data and scraping for AI

See all 50
Also in Data and scraping for AI
RankProjectScore
1doclingPython library that converts PDFs, Office files and more into structured text70.4k stars+1,818 (+2.6%) in 30 daysMIT92 out of 100
2mineruParses PDFs, images and Office files into Markdown and structured JSON Live demo ↗ (opens in a new tab)83.5k stars+2,196 (+2.7%) in 30 dayscustom license91 out of 100
3opendataloader-pdfPDF parser that outputs Markdown, JSON with bounding boxes, and Tagged PDF30.3k stars+728 (+2.5%) in 30 daysApache-2.090 out of 100
#4agent-reachCLI that gives coding agents read access to login-gated and Chinese web platforms111.1k starsMIT88 out of 100
#5markitdownPython library and CLI that converts office files, PDFs and audio to Markdown194.9k stars+5,738 (+3.0%) in 30 daysMIT87 out of 100