File size: 12,832 Bytes
f4e9d11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
c124dd8
 
 
 
 
 
 
 
 
 
 
 
 
f4e9d11
 
 
c124dd8
 
f4e9d11
 
c124dd8
 
 
 
 
f4e9d11
 
 
 
 
 
 
 
 
 
c124dd8
 
f4e9d11
 
 
 
 
 
 
 
 
 
c124dd8
 
f4e9d11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
c124dd8
 
f4e9d11
 
 
 
 
 
 
 
 
 
 
 
c124dd8
 
 
 
f4e9d11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
c124dd8
 
 
f4e9d11
 
 
c124dd8
 
 
 
f4e9d11
 
 
 
 
 
c124dd8
 
f4e9d11
 
 
 
 
c124dd8
 
 
f4e9d11
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
---
annotations_creators:
- machine-generated
- expert-generated
language:
- en
language_creators:
- machine-generated
- expert-generated
license: cc-by-4.0
multilinguality:
- monolingual
pretty_name: PII-Bench (ACL 2026)
size_categories:
- 1K<n<10K
source_datasets:
- original
task_categories:
- token-classification
- text-classification
- question-answering
tags:
- pii
- privacy
- privacy-preserving-nlp
- benchmark
- llm-evaluation
- acl-2026
configs:
- config_name: default
  default: true
  data_files:
  - split: single
    path: data/default/single.parquet
  - split: multi
    path: data/default/multi.parquet
  - split: hard
    path: data/default/hard.parquet
  - split: distract
    path: data/default/distract.parquet
- config_name: paper_exact
  data_files:
  - split: single
    path: data/paper_exact/single.parquet
  - split: multi
    path: data/paper_exact/multi.parquet
  - split: hard
    path: data/paper_exact/hard.parquet
  - split: distract
    path: data/paper_exact/distract.parquet
- config_name: privacy_utility
  data_files:
  - split: test
    path: data/privacy_utility/test.parquet
---

# PII-Bench: Evaluating Query-Aware Privacy Protection Systems (ACL 2026)

[![Conference](https://img.shields.io/badge/ACL-2026-blue.svg)](#citation)
[![Dataset](https://img.shields.io/badge/Dataset-2%2C842%20Samples-green.svg)](#dataset-statistics)
[![GitHub](https://img.shields.io/badge/GitHub-shenhao--stu%2FPII--Bench-black.svg)](https://github.com/shenhao-stu/PII-Bench)
[![ModelScope](https://img.shields.io/badge/ModelScope-shenhao23%2FPII--Bench-purple.svg)](https://modelscope.cn/datasets/shenhao23/PII-Bench)
[![License: CC BY 4.0](https://img.shields.io/badge/License-CC%20BY%204.0-lightgrey.svg)](LICENSE)

- **Paper:** *PII-Bench: Evaluating Query-Aware Privacy Protection Systems* (ACL 2026)
- **Authors:** Hao Shen<sup>1,2</sup>, Zhouhong Gu<sup>3</sup>, HaoKai Hong<sup>1</sup>, Weili Han<sup>1,2\*</sup>, Hongfeng Chai<sup>1</sup>
- **Affiliations:** <sup>1</sup>Institute of Fintech, Fudan University; <sup>2</sup>Laboratory of Data Analytics and Security, Fudan University; <sup>3</sup>Fudan University
- **Official Repositories & Mirrors:**
  - **GitHub (Evaluation Code + JSONL):** https://github.com/shenhao-stu/PII-Bench
  - **HuggingFace (Parquet):** https://huggingface.co/datasets/shenhao/PII-Bench
  - **ModelScope (Parquet, China Mirror):** https://modelscope.cn/datasets/shenhao23/PII-Bench

> **Iterative Updates Notice:** PII-Bench is actively maintained and **will be iteratively updated** (future versions may add new splits such as `PII-Real`, extended evaluation subsets, and further quality refinements). The **`paper_exact`** configuration remains permanently frozen to guarantee **0.0000** bit-exact reproducibility of all ACL 2026 paper results.

---

## Overview

**PII-Bench** is a benchmark for evaluating **query-aware privacy protection systems** on user prompts sent to Large Language Models (LLMs). Instead of leaving all Personally Identifiable Information (PII) exposed (*No Masking*) or masking every PII entity indiscriminately (*All PII Masking*), PII-Bench evaluates **Query-Unrelated PII Masking**:

1. **Task 1 — PII Detection:** Identify all PII entities ($E$) across one or more subjects, attribute each entity to its subject ($s \in S$), and classify its coarse PII type ($t \in T$).
2. **Task 2 — Query-Related PII Detection:** Determine the minimal subset of PII entities necessary to answer a user query ($E_q \subseteq E$).
3. **Task 3 — Query-Unrelated PII Masking:** Mask only the query-unrelated PII ($E \setminus E_q$) while preserving $E_q$ and prompt utility.

PII-Bench contains **2,842 core benchmark samples** across **7 coarse PII types** (`PER`, `CODE`, `LOC`, `ORG`, `DEM`, `DATETIME`, `QUANTITY`) and fine-grained subcategories (55 defined in Table 11; 54 observed canonical tags in the cleaned dataset), organized into four official splits:

- **`single`** (1,214 samples; 607 unique single-subject descriptions $\times$ 2 queries each)
- **`multi`** (1,228 samples; 614 unique two-subject descriptions $\times$ 2 queries each, covering `Intersection`, `Contains`, and `No Intersection` relationships)
- **`hard`** (200 samples; challenging subset drawn from `single` [114] and `multi` [86] — see `metadata/hard_subset_indices.json`)
- **`distract`** (200 samples; complex multi-party forum/network dialogues integrating 5 descriptions and ~7.5 subjects per sample)

Plus the **`privacy_utility`** configuration (200 samples from Section 4.5 / Table 8 with span-safe full and query-unrelated masked prompts).

---

## Configurations (`default` vs. GitHub `cleaned` vs. `paper_exact`)

> **Naming Note:** HuggingFace's **`default`** config and the GitHub repository's **`data/cleaned/`** directory contain **100% identical data** (verified row-for-row). HuggingFace uses the reserved config name `default` so `load_dataset("shenhao/PII-Bench")` loads the recommended cleaned v1.1 release automatically.

| HF Config | Matching GitHub Path | Splits | Intended Use |
|---|---|---|---|
| **`default`** *(recommended)* | `data/cleaned/pii_{single,multi,hard,distract}.jsonl` | `single` (1,214), `multi` (1,228), `hard` (200), `distract` (200) | Schema-verified, cleaned **v1.1** release: zero leaked prediction fields, zero `UNKNOWN` types, 100% aligned entity arrays, 100% twin-description entity symmetry across all 1,221 pairs, zero absent-from-text ghost entities, canonicalized tags, and realistic synthetic formats preserved. Verified $\le +0.0015$ F1 delta vs. raw ACL 2026 evaluations with identical model rankings. |
| **`paper_exact`** *(frozen)* | `data/paper_exact/PII_{single_final,multi_final,hard,distract}.jsonl` | `single` (1,214), `multi` (1,228), `hard` (200), `distract` (200) | Bit-exact ground-truth strings from the ACL 2026 camera-ready experiments (removing only the accidentally saved `'predict'` output field from `hard`), reproducing Table 3, Table 10, and Tables 4–26 with **0.0000** drift. |
| **`privacy_utility`** | `data/cleaned/pii_masked_200.jsonl` | `test` (200) | Cleaned v1.1 200-sample subset for Section 4.5 Privacy-Utility tradeoff evaluation using span-safe, case-insensitive, `most_related`-protected masking (zero corrupted query-relevant spans and zero case-mismatch leaks; verbatim raw prompts are preserved in GitHub `data/paper_exact/PII_masked.jsonl`). |

---

## Quickstart

```python
from datasets import load_dataset

# Load the recommended cleaned release (v1.1; identical to GitHub data/cleaned/)
ds = load_dataset("shenhao/PII-Bench")
print(ds)
# DatasetDict({single: 1214, multi: 1228, hard: 200, distract: 200})

sample = ds["single"][0]
print("Description:", sample["usr_desc"][:160])
print("Query:", sample["query"])
print("All PII:", sample["entities"]["total"])
print("Query-Related PII:", sample["most_related"])
print("Query-Unrelated PII (to mask):", sample["query_unrelated"])

# Load the frozen bit-exact ACL 2026 reproduction config
ds_exact = load_dataset("shenhao/PII-Bench", "paper_exact")

# Load the Section 4.5 Privacy-Utility tradeoff subset (span-safe v1.1)
ds_pu = load_dataset("shenhao/PII-Bench", "privacy_utility", split="test")
```

---

## Dataset Statistics

### Cleaned `default` (v1.1) vs. `paper_exact` (ACL 2026)

| Split | #Samples | Unique Descs | Avg #Subjects | Avg #Chars (Desc) | Avg #PII (Desc) | Avg #Chars (Query) | Avg #PII (Query) | Total Entities (`default` v1.1 / `paper_exact` Table 10) |
|---|---:|---:|---:|---:|---:|---:|---:|---:|
| `single` | 1,214 | 607 | 1.00 | 893.48 | 7.66 / 7.67 | 211.21 | 1.95 | 9,300 / 9,303 |
| `multi` | 1,228 | 614 | 2.00 | 652.65 | 13.14 | 236.21 | 2.06 | 16,136 / 16,136 |
| `hard`\* | 200 | 200 | 1.43 | 746.08 | 9.18 / 9.17 | 222.66 | 2.06 | 1,835 / 1,834 |
| `distract` | 200 | 200 | 7.47 | 4,403.64 | 51.05 / 51.08 | 859.68 / 859.69 | 5.82 | 10,210 / 10,211 |
| **Total** | **2,842** | **1,421\*\*** | **1.92** | **1,026.07** | **13.19** | **268.45** | **2.28** | **37,481 / 37,484** |

- \* `hard` is an overlapping challenging subset selected from `single` (114) and `multi` (86) via `metadata/hard_subset_indices.json`; its `paper_exact` entity distribution matches ACL 2026 Table 10 (1,834 entities) and Table 23 evaluations verbatim.
- \*\* 607 (`single`) + 614 (`multi`) + 200 (`distract`) = 1,421 non-overlapping unique descriptions (`hard` reuses 200 of the 1,221 `single`+`multi` descriptions).

---

## Data Schema

Each record in `default` and `paper_exact` shares an identical strongly-typed schema:

| Field | Type | Description |
|---|---|---|
| `sample_id` | `string` | Globally unique identifier (`single_0000`, `multi_0000`, `hard_0000`, `distract_0000`) |
| `split` | `string` | Split name (`single`, `multi`, `hard`, `distract`) |
| `id` | `int64` | Original within-file integer ID from ACL 2026 source JSONL |
| `from_id` | `string` | Source description lineage identifier (`origin_*`, `extra_*`, or comma-separated component IDs in `distract`) |
| `rel` | `string` | Multi-subject relationship type (`Intersection`, `Contains`, `No Intersection`, or `""` for single/distract) |
| `scene` | `string` | Target real-world consultation scenario |
| `num_subjects` | `int64` | Number of distinct subjects ($|S|$) in `usr_desc` |
| `usr_desc` | `string` | User background description containing synthetic PII ($d$) |
| `query` | `string` | User query ($q$) |
| `most_related` | `list[string]` | Ground-truth query-relevant PII entities ($E_q$) |
| `subjects` | `list[string]` | Subject IDs (`A`, `B`, `AB`, ...) aligned 1-to-1 with `most_related` |
| `query_unrelated` | `list[string]` | Ground-truth query-unrelated PII entities to mask ($E \setminus E_q$) |
| `entities.total` | `list[string]` | Deduplicated list of all PII entities ($E$) |
| `entities.total_subjects` | `list[string]` | Subject attribution (`A`, `AB`, ...) aligned 1-to-1 with `entities.total` |
| `entities.total_types` | `list[string]` | Coarse PII type (`PER`/`CODE`/`LOC`/`ORG`/`DEM`/`DATETIME`/`QUANTITY`) aligned with `entities.total` |
| `entities.total_tags` | `list[string]` | Fine-grained PII subcategory aligned with `entities.total` |
| `entities.values` | `list[list[string]]` | Per-subject entity lists (`values[i]` = entities of subject $i$) |
| `entities.types` | `list[list[string]]` | Per-subject coarse PII types aligned with `entities.values` |
| `entities.tags` | `list[list[string]]` | Per-subject fine-grained tags aligned with `entities.values` |

---

## Reference Benchmark Results (ACL 2026)

1. **Task 1 — PII Detection** (Strict-F1 across `single`, `multi`, `hard`, `distract`; deduplicated to unique `usr_desc`):
   - Human Baseline: `97.2` (`single`), `95.4` (`multi`), `91.3` (`hard`), `92.8` (`distract`)
   - GPT-4o: `0.893` / `0.891` / `0.817` / `0.715`
   - Claude-3.5-Sonnet: `0.858` / `0.890` / `0.813` / `0.910`
   - GPT-5 (Table 23): `0.871` / `0.884` / `0.840` / `0.832`
   - DeepSeek-R1 (Table 23): `0.876` / `0.879` / `0.835` / `0.826`
2. **Task 2 — Query-Related PII Detection** (`PII-Single` best non-oracle F1):
   - Human Baseline: `95.1` F1
   - GPT-4o (Self-Consistency): `0.72` F1 | GPT-5 (Self-CoT): `0.733` F1 | DeepSeek-V3.2 (Self-CoT): `0.765` F1 | DeepSeek-R1 (Self-CoT): `0.745` F1
3. **Task 3 — Query-Unrelated PII Masking** (`PII-Single` best non-oracle F1):
   - GPT-4o (Self-Consistency, single+multi): `0.77` F1 | GPT-5 (Self-CoT, single): `0.840` F1 | DeepSeek-V3.2 (Self-CoT, single): `0.852` F1

---

## Data Cleaning, Realism & Maintenance

See [DATA_CARD_AUDIT.md](DATA_CARD_AUDIT.md) for the complete v1.1 cleaning log (474 audited events) and exact empirical parity verification against ACL 2026 saved predictions.

- **Synthetic Realism Preserved:** All 2,842 released samples are fully synthetic (generated via rule-based templates, Faker, and GPT-4-0806, followed by multi-round human verification). Realistic formats — including common email suffixes (e.g., `@163.com`, `@gmail.com`) and authentic regional formats (e.g., Chinese license plates `湘A-65225`, `黑A53975`, `鄂A·55978`) — are **intentionally preserved** to maintain real-world evaluation fidelity.
- **Versioning & Iterative Updates:** This dataset will continue to be iteratively maintained and expanded in future releases (including potential future release of `PII-Real` and additional benchmarks), while keeping `paper_exact` immutable for ACL 2026 paper reproducibility.

---

## Citation

```bibtex
@inproceedings{shen2026piibench,
  title     = {{PII-Bench}: Evaluating Query-Aware Privacy Protection Systems},
  author    = {Shen, Hao and Gu, Zhouhong and Hong, HaoKai and Han, Weili and Chai, Hongfeng},
  booktitle = {Proceedings of the 64th Annual Meeting of the Association for Computational Linguistics (ACL 2026)},
  year      = {2026}
}
```