Skip to main content

DataTrust AI

PyPI version Python Tests License: MIT

DataTrust AI Demo

A local PII (Personally Identifiable Information) scanner designed for AI chat interfaces.

It checks the text you are about to send to 120+ AI platforms (including ChatGPT, Claude, Gemini, and DeepSeek) and warns you if it contains sensitive information like citizenship numbers, PANs, Aadhaar, or phone numbers. Everything runs locally on your device. No data is sent to any server.

Why this exists

People casually paste personal information into AI chats. Once it's in the context window, you can't take it back.

Most existing privacy tools are either enterprise-focused or heavily bloated. DataTrust AI is lightweight, built with Python's standard library, and specifically handles local formats like Nepali and Indian IDs. It also uses mathematical checksums to prevent false positives.

Current Features

  • 120+ AI Platforms Supported: Works seamlessly on ChatGPT, Claude, Gemini, Copilot, Perplexity, DeepSeek, and many more.
  • Nepal & India Patterns: Detects Citizenship, NID, PAN, Aadhaar, UPI, Passport, and mobile numbers.
  • Devanagari Support: Automatically normalizes Devanagari digits (१२३) to ASCII (123) before scanning.
  • Checksum Validation: Uses the Luhn algorithm for Credit Cards and the Verhoeff algorithm for Aadhaar to ignore fake numbers.
  • Privacy-First: The scanner never returns the actual detected value. It only returns the type and position of the match.
  • Lightweight: Zero heavy dependencies. Uses Python's built-in re module.
  • Browser Extension: Real-time warning banner directly inside the AI chat interface.

Challenges Faced While Building This

Building a full-stack cybersecurity tool entirely from an Android phone using Termux was not easy. Here are some real challenges I solved during development:

  • Mobile Development Environment: Setting up Python, handling storage permissions (termux-setup-storage), and dealing with the Android file system restrictions.
  • PyPI Publishing Issues: Tools like twine and pydantic failed to compile because they rely on Rust, which is difficult to set up on mobile. I solved this by switching to a pure Python approach using the built-in http.server module and the flit build backend.
  • Browser Caching: The Lemur browser kept holding onto old cached JavaScript files, making it difficult to test the new UI. I had to learn how to force-reload unpacked extensions.
  • Regex Overlap: Writing regex for local IDs (like Citizenship numbers) often caused them to overlap with phone numbers. I had to implement a sorting logic in detector.py to keep only the longest, most accurate match.

How to use it

1. Command Line Interface (CLI)

You can install the package directly from PyPI.

pip install datatrust-privacy-guard

Metadata

Release files for datatrust-privacy-guard 0.3.0

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

Source distribution (sdist)

Source distribution for datatrust-privacy-guard 0.3.0
File Size Uploaded Provenance
datatrust_privacy_guard-0.3.0.tar.gz 9.5 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for datatrust-privacy-guard 0.3.0
File Interpreter ABI Platform
datatrust_privacy_guard-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.3 kB

Release files / datatrust_privacy_guard-0.3.0.tar.gz

Download URL datatrust_privacy_guard-0.3.0.tar.gz
Size 9.5 kB
Tags Source
SHA-256 checksum
How to use checksums
fe76448e8b76d13176e5cdf4bde0a64964f821e787fdf4ac6cf534b10fc439e1
BLAKE2b-256 checksum
How to use checksums
febd95549bf2e437a4fcdeb8eedc7f178cd19ff60c626c75fa79743fd759ebcb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-requests/2.34.2

Release files / datatrust_privacy_guard-0.3.0-py3-none-any.whl

Download URL datatrust_privacy_guard-0.3.0-py3-none-any.whl
Size 10.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c5331e3a38f431f7c616c9e66a292cb8fe1c7ca6004e38ed28aba3fcc1578a75
BLAKE2b-256 checksum
How to use checksums
6911257890a12cc94d0dfbbf2d0814bd1b7fd7c20d1a3468bd605337f0146859
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-requests/2.34.2

Security for datatrust-privacy-guard 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.

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