# KeyBERT Minimal Keyword Extraction with BERT Embeddings

> KeyBERT is a minimal and easy-to-use Python library that leverages BERT embeddings and cosine similarity to extract keywords and keyphrases from documents. It supports multiple embedding backends including sentence-transformers, Flair, and spaCy, with built-in diversity algorithms like Max Sum Similarity and Maximal Marginal Relevance.

- Skill: `agentskillexchange/keybert-minimal-keyword-extraction-with-bert-embeddings` (Agent Skill)
- Install (CLI): `npx skillmds@latest add agentskillexchange/keybert-minimal-keyword-extraction-with-bert-embeddings`
- Raw SKILL.md: https://api.skillmd.com/api/skills/agentskillexchange/keybert-minimal-keyword-extraction-with-bert-embeddings/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: agentskillexchange (https://skillmd.com/u/agentskillexchange)
- Updated: 2026-09-08
- Page: https://skillmd.com/skills/agentskillexchange/keybert-minimal-keyword-extraction-with-bert-embeddings

---


# KeyBERT Minimal Keyword Extraction with BERT Embeddings

KeyBERT is a minimal and easy-to-use Python library that leverages BERT embeddings and cosine similarity to extract keywords and keyphrases from documents. It supports multiple embedding backends including sentence-transformers, Flair, and spaCy, with built-in diversity algorithms like Max Sum Similarity and Maximal Marginal Relevance.

## Installation

Use the upstream install or setup path that matches your environment:
- pip install keybert
- pip install keybert[flair]
- pip install keybert[gensim]
- pip install keybert[spacy]

Requirements and caveats from upstream:
- [![PyPI - Python](https://img.shields.io/badge/python-3.10+-blue.svg)](https://pypi.org/project/keybert/)
- python

Basic usage or getting-started notes:
- [Getting Started](#gettingstarted)
- 2.2. [Basic Usage](#usage)
- Thus, the goal was a pip install keybert and at most 3 lines of code in usage.

- Source: https://github.com/MaartenGr/KeyBERT
- Extracted from upstream docs: https://raw.githubusercontent.com/MaartenGr/KeyBERT/HEAD/README.md

## Source

- [Agent Skill Exchange](https://agentskillexchange.com/skills/keybert-keyword-extraction-bert/)

