Download README.md from Holocortex/Smith-Pincette-Nitro: direct link, hf CLI and curl.
- Browser
- Download file 5.57 kB
-
https://huggingface.co/Holocortex/Smith-Pincette-Nitro/resolve/main/README.md
- Command line
-
hf download hf://Holocortex/Smith-Pincette-Nitro/README.md
-
curl -L -o README.md https://huggingface.co/Holocortex/Smith-Pincette-Nitro/resolve/main/README.md
license: apache-2.0
library_name: smith-pincette
pipeline_tag: token-classification
base_model: jhu-clsp/mmBERT-small
tags:
- pii-detection
- span-extraction
- data-masking
- smith-pincette
- onnx
Smith-Pincette-Nitro v0.55
Part of the Smith-Pincette Model Family: compact models that extract exact spans of personal data (names, contact details, addresses, ID and bank numbers, and more) from text, so it can be masked before it reaches logs, LLMs or third parties. Smith-Pincette-Nitro is the fast default, with calibrated per-class thresholds. This is a preview release: expect rough edges, and expect the models and API to change. See also Smith-Pincette-Sprint.
| Version | v0.55 |
| Parameters | 146.7M |
| Encoder | jhu-clsp/mmBERT-small + Smith-Pincette span heads |
| Classes | 43 (table below) |
| Input | any length; processed in 512-token windows with 64-token overlap |
| Output | character-offset spans (start, end, label, score), non-overlapping |
| Format | ONNX, runs with onnxruntime on CPU or CUDA GPU, fully local |
| License | Apache-2.0 |
Quickstart
pip install "git+https://github.com/holocortex/Smith-Pincette-Models"
from smith_pincette import SmithPincette
model = SmithPincette.from_pretrained("Holocortex/Smith-Pincette-Nitro", revision="v0.55")
text = "Please refund Maria Schneider (maria.schneider@example.com), IBAN DE89 3704 0044 0532 0130 00."
for span in model.detect(text):
print(span.label, span.score, span.text)
print(model.mask(text))
# Please refund [PERSON] ([EMAIL]), IBAN [IBAN].
More examples (CLI masking, JSONL batches, reversible masking for LLM prompts, a local MCP server for agents): https://github.com/holocortex/Smith-Pincette-Models.
Classes
| Group | Classes |
|---|---|
| Government IDs | ssn, national_id, passport_number, drivers_license_number, license_number, tax_id |
| Banking & payment | credit_card_number, card_expiry, card_cvv, iban, bank_account, routing_number, currency |
| Credentials & endpoints (experimental) | password, secret_key, jwt_token, private_key, hostname_or_endpoint |
| Digital identity | crypto_address, ip_address, username, account_id, mac_address |
| Person | person, date_of_birth, occupation, age, gender, education_level |
| Contact & location | email, phone_number, street_address, city, state_or_region, postal_code, country, nationality, coordinate |
| Organization, health | organization, medical_condition |
| Dates, time, numbers | date, time, quantity |
model.detect(text, labels={"email", "iban"}) keeps only some classes. Every class has its own calibrated threshold;
model.detect(text, threshold=0.4) sets one flat cutoff instead.
How it works
A multilingual encoder with span-extraction heads, shipped as one ONNX graph. Decoding applies calibrated per-class thresholds and returns the best non-overlapping set of spans.
Intended use and limitations
- Intended for detecting and masking sensitive data in text you control: support tickets, chat and LLM prompts, emails, forms and documents.
- It is a statistical model. It will miss some sensitive values and flag some harmless ones. Do not use it as the only safeguard where a leak has legal or safety consequences.
- The credential classes (
password,secret_key,jwt_token,private_key,hostname_or_endpoint) are experimental in this preview and miss many values, especially in config and log lines. Do not use the model as a secret scanner. - Very dense text (many values per window, such as long customer lists) is recalled less well; split it into smaller records.
- Best covered languages are English and German; other languages work to a lesser degree.
Training data
Synthetic documents plus Wikipedia text:
- Generated documents (most of the data): fully generated templates for tickets, forms, emails, chats, logs, contracts, invoices and similar texts, filled with synthetic values (names, addresses, IDs, bank details, secrets, ...), and documents and chats written by Qwen3.8-27B (Apache-2.0) in several languages.
- Wikipedia passages in several languages, as real-world text, labeled automatically. Wikipedia content is available under CC BY-SA 4.0; we thank the Wikipedia contributors.
- Labels come from the generators themselves and from automatic annotation by Apache-2.0 models.
No benchmark test data was used for training on purpose, and no training document is identical to a document of the public benchmarks we check. Some short lines (such as boilerplate and formulaic phrases) occur in both.
Files
| File | Content |
|---|---|
model.onnx |
the model (runs with onnxruntime, no PyTorch needed) |
tokenizer.json |
tokenizer |
config.json |
class names per output slot, window size |
calibrated_thresholds.json |
per-class decision thresholds |
Support
Provided as is, without support or warranty. Bug reports are welcome as GitHub issues; there is no guaranteed response.
License
Apache-2.0. The encoder weights it builds on (jhu-clsp/mmBERT-small) are MIT-licensed.