Registry / ai-ml / minisbd

minisbd

JSON →
library0.9.5pypypi✓ verified 83d ago

MiniSBD is a free and open-source Python library designed for fast and efficient sentence boundary detection (SBD). It provides a lightweight solution for splitting text into sentences, supporting various punctuation and language patterns. The current version is 0.9.5, with releases occurring periodically, often driven by improvements in tokenization or punctuation handling.

pip install minisbd
INSTALL
IMPORT
SIG · MINISBD
M
minisbd
ai-mlpythonv0.9.5
Install
7.1s avg
Import
Disk
167MB
Pass rate
5/ 10
Env Coverage5 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v0.9.5 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.910 runs
build_error
glibc
py 3.103.910 runs
installs and imports cleanly · install 7.1s · import 0.000s · 202MB
167MB installed
● package 167MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SBDetect
from minisbd import SBDetect
from minisbd import SBD

Initialize the SBD class once, then use its `segment` method to split a string into a list of sentences.

from minisbd import SBD sbd = SBD() # Initialize the SBD object once text1 = "Hello world. This is a test. Is it working?" sentences1 = sbd.segment(text1) print(f"Text 1: {sentences1}") text2 = "Hello world! This is another test. Is it working now?" sentences2 = sbd.segment(text2) print(f"Text 2: {sentences2}")
Debug
Known issues
gotchaInitializing the `SBD` object is an operation that should ideally be done once. Re-initializing it inside a loop will incur unnecessary overhead and degrade performance.
fix
Always initialize `sbd = SBD()` outside of performance-critical loops or functions that will be called repeatedly. Pass the initialized object around if necessary.
affects: All versions
gotchaMiniSBD is optimized for speed and general English text. While robust, its accuracy might vary for highly specialized domains, informal text (e.g., social media), or languages with very different sentence boundary rules than common Western languages. It may not handle all edge cases perfectly.
fix
For highly critical applications or non-standard text, evaluate its performance on a representative dataset. Consider pre-processing text or post-processing results if specific patterns cause issues. For deeply linguistic tasks, more complex NLP libraries might be required.
affects: All versions
Upgrade
Version history
0.9.5latest on PyPI · released Mar 3, 2026
Audit
Dependencies

No dependency data recorded yet.

Agent activity
57 hits · last 30 days
node
54
Amazon
1
Bingbot
1
Resources
minisbd — pip install minisbd · libregistry