Catalog PyPI
Back to packageRELEASE DETAILS

0.1.1

PyPI

ai-data-scrubber

A lightweight tool for removing personal data from text before uploading to LLMs

anonymizationdata-cleaningllmpiiprivacyspacytext-processing
Published15 Oct 2025
Direct dependencies2
Transitive dependenciesNot calculated

README

Version 0.1.1 documentation

AI Data Scrubber

The AI Data Scrubber is a lightweight privacy-focused tool designed to remove personal information from text documents before uploading them to Large Language Models (LLMs). You can use it to clean sensitive documents like resumes or contracts. It's not guaranteed to remove everything, so you should still check before you upload your file to a LLM.

It uses a mixture of regular expressions and named entity recognition models from spaCy. It's less accurate than asking a LLM to remove PII - but then you don't need to either run a LLM on your own machine, or upload your document to a LLM.

What It Does

The AI Data Scrubber removes personal information including:

  • Names
  • Email addresses
  • Phone numbers
  • Street addresses & ZIP codes
  • URLs
  • License plates

Currently, only US formats are supported.

You can run it via a command line interface or you can import it into your Python script.

Quick Start

# Install using pip
pip install ai-data-scrubber

# Download required language model (~560MB)
python -m spacy download en_core_web_lg

# Clean your file
ai-data-scrubber your-file.txt

Usage

Command Line:

# Auto-generates an output file with _scrubbed suffix
ai-data-scrubber input.txt

# Or you can specify the output file with the -o flag
ai-data-scrubber input.txt -o output.txt

Python:

from ai_data_scrubber import scrub_text, scrub_file

# Scrub text directly
cleaned = scrub_text("Your text with personal information here")

# Or scrub a file
scrub_file("input.txt", "output.txt")

Example

Original text:

John Smith
123 Main Street, Apt 4B
New York, NY 10001
Email: john.smith@example.com
Phone: (555) 123-4567

Cleaned text:

[NAME]
[ADDRESS], [UNIT]
New York, NY [ZIP_CODE]
Email: [EMAIL]
Phone: [PHONE]

Documentation

You can find further documentation in the docs folder:

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

Contributions welcome! Feel free to submit a Pull Request.

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 2

Native requirements
2 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
spacy
Environment
{
  "extras": "",
  "marker": null,
  "requires_python": ">=3.10",
  "evaluation": "NOT_EVALUATED"
}
spacy>=3.5.0runtime
pytest
Environment
{
  "extras": "",
  "marker": "extra == \"dev\"",
  "requires_python": ">=3.10",
  "evaluation": "NOT_EVALUATED"
}
pytest>=8.0.0; extra == "dev"runtime

Distribution files

2 collected
ai_data_scrubber-0.1.1-py3-none-any.whl

bdist_wheel · 6.74 KB · Python py3

Source file
ai_data_scrubber-0.1.1.tar.gz

sdist · 8.92 KB · Python source

Source file

Repository

PENDING
catherinenelson1/ai-data-scrubber

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 10:24 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:b4de0fc2ca1fa753d63a3f3a5f0d71c88edae190af08515c81edc29d12ff5ac5

Other collected versions

View all collected versions →