Lethe
Data anonymization CLI for structured files and SQL dumps. Scan for PII with compliance framework mapping, then anonymize using Presidio and spaCy NER with Faker-generated replacements that stay consistent across your dataset.
Lethe performs pseudo-anonymization: PII is replaced with realistic fake values, preserving data structure and relationships. This is different from true anonymization, which irreversibly removes personal data. See Architecture docs for the full distinction and GDPR implications.
Install
pip install lethe-cli
python -m spacy download en_core_web_trf
For a faster, lighter model instead of the transformer:
python -m spacy download en_core_web_sm
Usage
Scan
Analyze a file for PII and map findings to compliance frameworks (GDPR, HIPAA, CCPA, PCI-DSS, SOX, FERPA). No data is modified.
lethe scan data.csv # quick scan with Rich report
lethe scan data.csv --json # machine-readable JSON output
lethe scan data.csv --model trf # accurate transformer model
Anonymize
Replace detected PII with consistent fake values:
lethe anonymize data.csv -o anonymized.csv
lethe anonymize data.csv --model sm --threshold 0.7
lethe anonymize notes.txt -o clean.txt --locale nl_NL
Multiply
Generate synthetic rows from an existing dataset:
lethe multiply data.csv --factor 5 -o expanded.csv
lethe multiply data.csv --factor 10 --sanitize --seed 42
Options
Run lethe scan --help, lethe anonymize --help, or lethe multiply --help for the full list of options.
License
MIT
Metadata
Release files for lethe-cli 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| lethe_cli-0.3.0.tar.gz | 78.7 kB | Without provenance | Details for lethe_cli-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| lethe_cli-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for lethe_cli-0.3.0-py3-none-any.whl |
Total release size: 110.6 kB
Release files / lethe_cli-0.3.0.tar.gz
| Download URL | lethe_cli-0.3.0.tar.gz |
|---|---|
| Size | 78.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0ef517e6daae807a934e7c13d3f92ccffac4e28b9e69ab73e2628fed9921b92d
|
|
BLAKE2b-256 checksum How to use checksums |
78c9732e45ca92cf0c659bdca316098037f0511927b879f8b59b7b704db1456e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.2
|
Release files / lethe_cli-0.3.0-py3-none-any.whl
| Download URL | lethe_cli-0.3.0-py3-none-any.whl |
|---|---|
| Size | 31.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2d402997fd1cc2f46b50cfa4c38c14b500bd59e1eac0bcd40e2cbfb5b0d14c4a
|
|
BLAKE2b-256 checksum How to use checksums |
d44466ef560795de1d04af3bad145c3e74fb18ab97e62fb38278e64a93a0d8e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.2
|
Security for lethe-cli 0.3.0
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.