Skip to main content

Disvortilo

Disvortilo is a simple tool that breaks Esperanto words into roots and affixes.

Getting Started

You can install Disvortilo from PyPI using pip:

pip install disvortilo

Examples

from disvortilo import Disvortilo, rank

disvortilo = Disvortilo()

print(disvortilo.parse("malliberejo"))
# > [('mal', 'liber', 'ej', 'o')]

# some have more than one possible output
print(disvortilo.parse("esperantistino"))
# > [('esper', 'ant', 'ist', 'in', 'o'), ('esperant', 'ist', 'in', 'o')]

# you can also get the morphemes along their categories
print(disvortilo.parse_detailed("plibonigojn"))
# > [(('pli', WordPart.FULL_WORD), ('bon', WordPart.ROOT), ('ig', WordPart.SUFFIX), ('ojn', WordPart.POS))]

# sort the values from most likely to less likely
print(rank(disvortilo.parse_detailed("envias"), n=2))  # get the 2 most likely options
# > [(('envi', WordPart.ROOT), ('as', WordPart.POS)), (('en', WordPart.FULL_WORD), ('vi', WordPart.FULL_WORD), ('as', WordPart.POS))]

API Reference

Disvortilo

Parser class for splitting Esperanto words into morphemes.

Disvortilo.parse(word: str) -> list[tuple[str, ...]]

Returns all valid analyses of word. Each analysis is a tuple of morpheme strings in order.

Example return value:

[('esper', 'ant', 'ist', 'in', 'o'), ('esperant', 'ist', 'in', 'o')]

Disvortilo.parse_detailed(word: str) -> list[tuple[tuple[str, WordPart], ...]]

Like parse, but each morpheme is returned together with its detected category (WordPart). Each analysis is a tuple of (morpheme, WordPart) pairs.

Example return value:

[(('pli', WordPart.FULL_WORD), ('bon', WordPart.ROOT), ('ig', WordPart.SUFFIX), ('ojn', WordPart.POS))]

rank(options, n: int | None = None) -> list[tuple[tuple[str, WordPart], ...]]

Sorts options based on a heuristic of the most likely option.

Note, that this will only work with the returned values from parse_detailed.

Example return value:

[(('neĝ', WordPart.ROOT), ('is', WordPart.POS)), (('ne', WordPart.FULL_WORD), ('ĝis', WordPart.FULL_WORD))]

WordPart

Enum values used by parse_detailed:

  • PREFIX
  • ROOT
  • SUFFIX
  • FULL_WORD
  • POS
  • NUMBER
  • NAME
  • CORRELATIVE_START
  • CORRELATIVE_END

split_sentence(sentence: str) -> list[str]

Splits a sentence into Esperanto word-like tokens. Supports Esperanto diacritics, optional trailing apostrophes, and forms like 3 and 3an.

Example:

from disvortilo import split_sentence

split_sentence("Mi vidas 3an domon.")
# > ['Mi', 'vidas', '3an', 'domon']

split_sentence_detailed(sentence: str) -> Generator[tuple[str, int, int], None, None]

Split a sentence into Esperanto word-line tokens. Unline split_sentence, it yields the position of each word.

Example:

from disvortilo import split_sentence_detailed

list(split_sentence_detailed("Mi vidis 3an domon."))
# > [('Mi', 0, 2), ('vidis', 3, 8), ('3an', 9, 12), ('domon', 13, 18)]

Metadata

Release files for disvortilo 0.8.3.post1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for disvortilo 0.8.3.post1
File Size Uploaded Provenance Actions
disvortilo-0.8.3.post1.tar.gz 10.8 kB With provenance Details for disvortilo-0.8.3.post1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for disvortilo 0.8.3.post1
File Interpreter ABI Platform Actions
disvortilo-0.8.3.post1-py3-none-any.whl Python 3 none any Details for disvortilo-0.8.3.post1-py3-none-any.whl

Total release size: 21.6 kB

Release files / disvortilo-0.8.3.post1.tar.gz

Download URL disvortilo-0.8.3.post1.tar.gz
Size 10.8 kB
Tags Source
SHA-256 checksum
How to use checksums
f7e49137533c96429324c443459a78d771b37c49e22806e63c3e4fc6843175a8
BLAKE2b-256 checksum
How to use checksums
dec65b7b80992fcdde535735d46888b132444267399fb7a1d2733e8ba6c64253
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 1, 2026.

Transparency log

Release files / disvortilo-0.8.3.post1-py3-none-any.whl

Download URL disvortilo-0.8.3.post1-py3-none-any.whl
Size 10.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e20047bb69d69e0712fef7640d8d3f9565abbc63dc0071dbde96c9e02e5582e2
BLAKE2b-256 checksum
How to use checksums
a68c41da92417cd0a75f9ddf44eb41354186f82a31ba5c97449789b0413600f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 1, 2026.

Transparency log

Security for disvortilo 0.8.3.post1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for disvortilo-0.8.3.post1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 1, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page