Skip to main content

Linguistic feature extraction and annotation utilities for text.

Project description

PyLift is the Python branch of the LiFT library.

Installation

Core package:

pip install py_lift

Optional tooling dependencies (examples/workbench):

poetry install --with examples

spaCy language models are optional and must be installed separately when using Spacy_Preprocessor with the default model names:

python -m py_lift.model_setup --languages en de fr sl tr

For Turkish (tr_core_news_md) and for SE_AbstractnessAnnotator (lift-resources-lists), install the required internal packages from your organization's package source.

py_lift.model_setup supports language-specific wheel URLs via built-in defaults and overrides. Turkish currently uses this built-in URL by default:

https://pypi.cats.fernuni-hagen.de/packages/tr_core_news_md-1.0-py3-none-any.whl

You can override sources for any language via environment variables:

export PY_LIFT_MODEL_URL_TR="https://your-internal-source/tr_core_news_md-1.0-py3-none-any.whl"
python -m py_lift.model_setup --languages tr

Or via CLI:

python -m py_lift.model_setup --languages tr --model-url tr=https://your-internal-source/tr_core_news_md-1.0-py3-none-any.whl

You can also let the preprocessor auto-install missing models at runtime:

from py_lift.preprocessing import Spacy_Preprocessor

prep = Spacy_Preprocessor("en", auto_install_models=True)

Standalone Python example

Run a non-visual end-to-end pipeline example:

python examples/pure_python_pipeline.py

The script is located at examples/pure_python_pipeline.py and demonstrates:

  • language detection
  • spaCy preprocessing
  • spelling anomaly annotation
  • readability + count feature extraction
  • plain stdout output (no visualization)

Other examples (now also in top-level examples/):

  • examples/visualization_streamlit.py
  • examples/visualization_notebook.ipynb

Release (PyPI)

Short release checklist:

  1. Update the version in pyproject.toml.

  2. Run tests:

    poetry install --with dev
    poetry run pytest
    

Model-dependent tests (for example py_lift/tests/test_preprocessing.py) are marked as requires_models and skipped by default. Run them explicitly with:

poetry run pytest --run-model-tests
  1. Build distribution artifacts:

    poetry build
    
  2. Publish:

    export POETRY_PYPI_TOKEN_PYPI="pypi-XXXXXXXXXXXXXXXXXXXX"
    poetry publish
    

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lift_linguistic_features_py-0.1.0.tar.gz (206.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lift_linguistic_features_py-0.1.0-py3-none-any.whl (228.8 kB view details)

Uploaded Python 3

File details

Details for the file lift_linguistic_features_py-0.1.0.tar.gz.

File metadata

  • Download URL: lift_linguistic_features_py-0.1.0.tar.gz
  • Upload date:
  • Size: 206.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.2 CPython/3.13.0 Darwin/25.5.0

File hashes

Hashes for lift_linguistic_features_py-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d0d9ca1792e1d6c60711d1eb9c372d29a9f1cc7924720e668cb1919813738847
MD5 43e5d0d3462b379ea4617f4df2b18e58
BLAKE2b-256 03fc5afb6b818e3b88b93f13ee6e0ac31efc325577bd1ee4809e5eb8770ae518

See more details on using hashes here.

File details

Details for the file lift_linguistic_features_py-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for lift_linguistic_features_py-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d2d6c9cd330805284d33efb9604ef0d90bce390ea6a8f382b1948756b84f8de2
MD5 b760c80445163a1c0b7fd9788d0ac6a1
BLAKE2b-256 bab6299a29eba651755545b474255916db948b033b488c2d79b56063d422c420

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page