Instructions to use sumeshi/privacy-filter-jp-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use sumeshi/privacy-filter-jp-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="sumeshi/privacy-filter-jp-GGUF", filename="privacy-filter-jp-f16.gguf", )
output = llm( "Once upon a time,", max_tokens=512, echo=True ) print(output)
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use sumeshi/privacy-filter-jp-GGUF with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf sumeshi/privacy-filter-jp-GGUF:F16 # Run inference directly in the terminal: llama cli -hf sumeshi/privacy-filter-jp-GGUF:F16
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf sumeshi/privacy-filter-jp-GGUF:F16 # Run inference directly in the terminal: llama cli -hf sumeshi/privacy-filter-jp-GGUF:F16
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf sumeshi/privacy-filter-jp-GGUF:F16 # Run inference directly in the terminal: ./llama-cli -hf sumeshi/privacy-filter-jp-GGUF:F16
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf sumeshi/privacy-filter-jp-GGUF:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf sumeshi/privacy-filter-jp-GGUF:F16
Use Docker
docker model run hf.co/sumeshi/privacy-filter-jp-GGUF:F16
- LM Studio
- Jan
- Ollama
How to use sumeshi/privacy-filter-jp-GGUF with Ollama:
ollama run hf.co/sumeshi/privacy-filter-jp-GGUF:F16
- Unsloth Studio
How to use sumeshi/privacy-filter-jp-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for sumeshi/privacy-filter-jp-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for sumeshi/privacy-filter-jp-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for sumeshi/privacy-filter-jp-GGUF to start chatting
- Atomic Chat new
- Docker Model Runner
How to use sumeshi/privacy-filter-jp-GGUF with Docker Model Runner:
docker model run hf.co/sumeshi/privacy-filter-jp-GGUF:F16
- Lemonade
How to use sumeshi/privacy-filter-jp-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull sumeshi/privacy-filter-jp-GGUF:F16
Run and chat with the model
lemonade run user.privacy-filter-jp-GGUF-F16
List all available models
lemonade list
card: sync from privacy-filter.cpp (privacy-filter-jp.md)
Browse files
README.md
CHANGED
|
@@ -42,71 +42,92 @@ production guarantee.
|
|
| 42 |
|
| 43 |
## Training Summary
|
| 44 |
|
| 45 |
-
|
| 46 |
|
| 47 |
- base: multilingual privacy-filter compatible checkpoint
|
| 48 |
-
- final checkpoint: `runs/pf-jp/model-ft-
|
| 49 |
-
-
|
| 50 |
-
|
| 51 |
-
-
|
| 52 |
-
|
| 53 |
-
|
| 54 |
-
- GGUF sha256: `
|
|
|
|
| 55 |
|
| 56 |
-
Training data summary:
|
| 57 |
|
| 58 |
- small in-repository benchmark train split
|
| 59 |
- synthetic Japanese address examples using public Japan Post postal-code data
|
| 60 |
as area-level material plus fabricated street/building/room details
|
| 61 |
- synthetic Japanese date and account-number examples
|
| 62 |
- synthetic structured PII examples for email, phone, URL, and secret
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 63 |
- synthetic Japanese boundary examples for honorifics, roles, URL prefixes, and
|
| 64 |
multi-address text
|
| 65 |
- converted Japanese person-name NER examples
|
| 66 |
|
| 67 |
No real PII is intentionally used.
|
| 68 |
|
| 69 |
-
##
|
| 70 |
|
| 71 |
-
|
| 72 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 73 |
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
|
|
|
|
|
|
| 77 |
|
| 78 |
-
|
|
|
|
|
|
|
| 79 |
|
| 80 |
-
|
| 81 |
-
| --- | ---: | ---: | ---: |
|
| 82 |
-
| `private_person` | 0.583 | 0.917 | 1 |
|
| 83 |
-
| `private_address` | 0.400 | 1.000 | 0 |
|
| 84 |
-
| other 6 labels | 0.400 | 0.833 | 1 |
|
| 85 |
-
| micro | 0.475 | 0.929 | 2 |
|
| 86 |
-
|
| 87 |
-
Label-level FT v2 result on `datasets/benchmark/challenge.jsonl`:
|
| 88 |
|
| 89 |
| label | precision | recall | F1 | partial-fn |
|
| 90 |
| --- | ---: | ---: | ---: | ---: |
|
| 91 |
-
| `account_number` |
|
| 92 |
-
| `private_address` |
|
| 93 |
-
| `private_date` |
|
| 94 |
-
| `private_email` |
|
| 95 |
-
| `private_person` | 0.
|
| 96 |
-
| `private_phone` |
|
| 97 |
-
| `private_url` | 0.
|
| 98 |
-
| `secret` |
|
| 99 |
-
| micro | 0.
|
| 100 |
-
|
| 101 |
-
|
|
|
|
| 102 |
deterministic detectors for URLs, email addresses, phone numbers, IDs, and
|
| 103 |
secrets when those spans are high-risk.
|
| 104 |
|
| 105 |
## Limitations
|
| 106 |
|
| 107 |
-
- Experimental
|
| 108 |
- Primary target is Japanese text; English is not benchmarked here.
|
| 109 |
-
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 110 |
- Does not guarantee complete anonymization.
|
| 111 |
- Validate on your own data before use in any workflow that affects privacy,
|
| 112 |
compliance, or security.
|
|
|
|
| 42 |
|
| 43 |
## Training Summary
|
| 44 |
|
| 45 |
+
v2 release candidate trained locally on 2026-07-03:
|
| 46 |
|
| 47 |
- base: multilingual privacy-filter compatible checkpoint
|
| 48 |
+
- final checkpoint: `runs/pf-jp/model-ft-v2b`
|
| 49 |
+
- one-shot fine-tune from the base model (no incremental stages): 3 epochs,
|
| 50 |
+
learning rate `1e-4`, batch size 8, max length 384
|
| 51 |
+
- label space unchanged from the base model (no new classifier rows; Japanese
|
| 52 |
+
identifiers are aliased into `account_number`), so model size and inference
|
| 53 |
+
speed are identical to v1
|
| 54 |
+
- GGUF f16 sha256: `e2bafc05ef7e6beb354e78cd77c8cfb5101d55044f23b2cdf343731a882f3b1c`
|
| 55 |
+
- GGUF q8 (experts-only Q8_0) sha256: `de9499518ade053d65d20c2eaae2833954e114d29dd77fa7466dade782da9cd6`
|
| 56 |
|
| 57 |
+
Training data summary (~34,000 rows, all offsets machine-validated):
|
| 58 |
|
| 59 |
- small in-repository benchmark train split
|
| 60 |
- synthetic Japanese address examples using public Japan Post postal-code data
|
| 61 |
as area-level material plus fabricated street/building/room details
|
| 62 |
- synthetic Japanese date and account-number examples
|
| 63 |
- synthetic structured PII examples for email, phone, URL, and secret
|
| 64 |
+
- synthetic Japanese phone numbers in all common formats (mobile / landline
|
| 65 |
+
with 2–4 digit area codes / 0120 / 0570 / +81 / fullwidth digits /
|
| 66 |
+
parentheses / no separators) and Japan-specific identifiers (My Number,
|
| 67 |
+
driver's license, passport, pension, health insurance, bank and yucho
|
| 68 |
+
accounts, residence card) labeled as `account_number`
|
| 69 |
+
- synthetic ordinary Japanese person names (kanji/kana/romaji, furigana pairs,
|
| 70 |
+
joint names, honorific and title boundaries)
|
| 71 |
+
- synthetic long multi-PII business documents (150–600 chars: emails with
|
| 72 |
+
signature blocks, application forms, support logs, delivery notes, minutes,
|
| 73 |
+
incident reports)
|
| 74 |
+
- key=value log / .env / HTTP-header style PII lines
|
| 75 |
+
- PII-free negative rows (prices, model numbers, versions, error codes) to
|
| 76 |
+
suppress over-detection
|
| 77 |
- synthetic Japanese boundary examples for honorifics, roles, URL prefixes, and
|
| 78 |
multi-address text
|
| 79 |
- converted Japanese person-name NER examples
|
| 80 |
|
| 81 |
No real PII is intentionally used.
|
| 82 |
|
| 83 |
+
## Benchmark
|
| 84 |
|
| 85 |
+
Exact-match span micro F1, measured with the runtime span post-processing that
|
| 86 |
+
ships with `privacy-filter.cpp` (edge trimming and person-span splitting).
|
| 87 |
+
The v2 benchmark (`datasets/benchmark/{eval2,challenge2}.jsonl`, 106
|
| 88 |
+
hand-written examples) targets realistic multi-paragraph business documents,
|
| 89 |
+
Japanese phone-format variants, Japan-specific identifiers, furigana name
|
| 90 |
+
pairs, and PII-free negatives. `challenge2` is kept blind: it is never used
|
| 91 |
+
for tuning or per-row error analysis.
|
| 92 |
|
| 93 |
+
| benchmark | v1 model | v2 model |
|
| 94 |
+
| --- | ---: | ---: |
|
| 95 |
+
| `eval2` (realistic documents) | 0.400 | 0.717 |
|
| 96 |
+
| `challenge2` (blind held-out) | 0.453 | 0.693 |
|
| 97 |
+
| `challenge` (v1 split, regression) | 0.912 | 0.964 |
|
| 98 |
|
| 99 |
+
The v1 split numbers previously published (0.929 overall) predate this
|
| 100 |
+
pipeline and were optimistic: the v1 boundary training data shared
|
| 101 |
+
template-generated texts with the v1 `eval`/`challenge` splits.
|
| 102 |
|
| 103 |
+
Label-level v2 result on `eval2.jsonl`:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 104 |
|
| 105 |
| label | precision | recall | F1 | partial-fn |
|
| 106 |
| --- | ---: | ---: | ---: | ---: |
|
| 107 |
+
| `account_number` | 0.625 | 0.625 | 0.625 | 5 |
|
| 108 |
+
| `private_address` | 0.700 | 0.875 | 0.778 | 1 |
|
| 109 |
+
| `private_date` | 0.643 | 0.643 | 0.643 | 5 |
|
| 110 |
+
| `private_email` | 0.333 | 0.333 | 0.333 | 4 |
|
| 111 |
+
| `private_person` | 0.793 | 0.821 | 0.807 | 4 |
|
| 112 |
+
| `private_phone` | 0.917 | 0.917 | 0.917 | 1 |
|
| 113 |
+
| `private_url` | 0.500 | 0.500 | 0.500 | 3 |
|
| 114 |
+
| `secret` | 0.667 | 1.000 | 0.800 | 0 |
|
| 115 |
+
| micro | 0.696 | 0.740 | 0.717 | 23 |
|
| 116 |
+
|
| 117 |
+
Most remaining false negatives are partial (boundary differences on detected
|
| 118 |
+
entities rather than complete misses; see the `partial-fn` column). Use
|
| 119 |
deterministic detectors for URLs, email addresses, phone numbers, IDs, and
|
| 120 |
secrets when those spans are high-risk.
|
| 121 |
|
| 122 |
## Limitations
|
| 123 |
|
| 124 |
+
- Experimental checkpoint.
|
| 125 |
- Primary target is Japanese text; English is not benchmarked here.
|
| 126 |
+
- Benchmarks are small and do not represent production accuracy.
|
| 127 |
+
- Known gaps: dates at the head of numbered list items ("5. 2026年7月3日、")
|
| 128 |
+
can fall below threshold; identifiers in key=value log lines are sometimes
|
| 129 |
+
labeled as a different PII category than expected (still redacted); email
|
| 130 |
+
span boundaries in long documents are the weakest label.
|
| 131 |
- Does not guarantee complete anonymization.
|
| 132 |
- Validate on your own data before use in any workflow that affects privacy,
|
| 133 |
compliance, or security.
|