josh-hud commited on
Commit
2421297
·
verified ·
1 Parent(s): ae15865

Release v3 cross-document coreference preview

Browse files

Cluster-preserving 36% sample of code-pii v3; 1.90M records, 856k clusters, 2.85M labeled spans, embedded entity tables and gold replacements.

README.md CHANGED
@@ -3,8 +3,8 @@ license: other
3
  license_name: mixed-permissive
4
  license_details: >-
5
  Same terms as josh-hud/code-pii: each record keeps the license of its base file (MIT,
6
- Apache-2.0, BSD-2/3-Clause, ISC, Unlicense or CC0-1.0, `license` column) as redistributed by
7
- codeparrot/github-code-clean (Apache-2.0 compilation). Generator code Apache-2.0.
8
  task_categories:
9
  - token-classification
10
  language:
@@ -17,9 +17,10 @@ tags:
17
  - code
18
  - synthetic
19
  - span-labels
20
- - security
 
21
  - preview
22
- pretty_name: code-pii preview (36% seeded sample of code-pii v2)
23
  size_categories:
24
  - 1M<n<10M
25
  configs:
@@ -31,54 +32,49 @@ configs:
31
 
32
  # code-pii-preview
33
 
34
- A **seeded, uniform ~36% sample of [josh-hud/code-pii](https://huggingface.co/datasets/josh-hud/code-pii) v2** (parent commit `8d1b820`), sized for local work: 4.03 GB of zstd Parquet instead of 11.17 GB. Same schema, same labels, same license terms. All documentation (construction, data dictionary, taxonomy, caveats, EDA notebook, generator code, CredData eval set) lives in the parent repo; this card only describes the sample.
35
 
36
- ## How it was sampled
37
 
38
- Every record of the parent's 70 JSONL shards was kept iff `blake2b("42:" + id) / 2^64 < 0.36` (`preview_subset.py --frac 0.36 --seed 42`, script in the parent repo). The decision depends only on the record `id`, so the sample is reproducible, order-independent, and uniform across shards; language, label, context and positive/negative proportions therefore match the parent in expectation, and `stats.md` verifies they match in practice to within 0.05 percentage points.
39
 
40
  ## Contents
41
 
42
  | path | description |
43
  |---|---|
44
- | `data/train-AAAAA-BBBBB.parquet` | 8 files (7 x ~520 MB + 1 x 404 MB), zstd; AAAAA-BBBBB = parent shard range the file was drawn from |
45
- | `sample.jsonl` | 500 records reservoir-sampled from the last file, same schema |
46
- | `stats.md` | counts, file list, and label / language / context / value_type comparison against the full v2 set |
47
 
48
  ## Numbers
49
 
50
- | | preview | full v2 | ratio |
51
  |---|---:|---:|---:|
52
- | records | 1,900,554 | 5,278,400 | 0.360 |
53
- | files with >=1 secret span | 1,211,296 (63.7%) | 3,365,090 (63.8%) | 0.360 |
54
- | secret spans | 2,435,889 | 6,765,485 | 0.360 |
55
- | hard-negative spans | 1,781,952 | 4,947,748 | 0.360 |
56
- | Parquet bytes | 4,030,406,662 | 11,167,063,550 | 0.361 |
 
57
 
58
- Label mix: api_key 43.5%, password 20.9%, token 15.6%, email 10.7%, private_key 9.3% (identical to the parent within 0.03 pp). Language mix: Java 19.2%, JavaScript 11.6%, HTML 10.8%, PHP 8.5%, C 8.0%, Markdown 7.1%, C# 7.1%, Python 6.5%, ... (within 0.05 pp of the parent).
59
 
60
- ## Schema (unchanged from the parent)
61
 
62
- `id, source, repo, license, language, path, text, spans[], hard_negatives[]`; each span `{start, end, label, value_type, context, synthetic, value}` with 0-based, end-exclusive **code-point** offsets into `text` (`text[start:end] == value`). `label` in `spans` is one of `api_key`, `password`, `token`, `private_key`, `email`; in `hard_negatives` it is always `not_secret`. Full field documentation: [parent `DATA_DICTIONARY.md`](https://huggingface.co/datasets/josh-hud/code-pii/blob/main/DATA_DICTIONARY.md).
63
 
64
  ## Loading
65
 
66
- ```bash
67
- # whole preview (4.03 GB)
68
- hf download josh-hud/code-pii-preview --repo-type dataset --local-dir ./code-pii-preview
69
- # (older CLI: huggingface-cli download josh-hud/code-pii-preview --repo-type dataset --local-dir ./code-pii-preview)
70
- ```
71
-
72
  ```python
73
  from datasets import load_dataset
74
- ds = load_dataset("josh-hud/code-pii-preview", split="train") # or streaming=True
75
  rec = ds[0]
76
  for s in rec["spans"]:
77
  assert rec["text"][s["start"]:s["end"]] == s["value"]
78
  ```
79
 
80
- Validation: `validate.py` (parent repo) run on `train-00063-00069.parquet` re-serialised to JSONL reported 0 offset mismatches across 190,413 records.
81
 
82
  ## Caveats
83
 
84
- Everything in the parent's caveats applies (random-line injection artifacts, unscrubbed base corpus, hex-key vs hash negatives distinguished only by variable name, Java/JS/HTML-heavy language mix, secrets + emails only). Because sampling is by record, repositories that appear in several parent files may be partially represented here. Use the parent's `eval_creddata.jsonl` (real CredData lines) for evaluation; do not evaluate on this sample.
 
3
  license_name: mixed-permissive
4
  license_details: >-
5
  Same terms as josh-hud/code-pii: each record keeps the license of its base file (MIT,
6
+ Apache-2.0, BSD-2/3-Clause, ISC, Unlicense or CC0-1.0) as redistributed by
7
+ codeparrot/github-code-clean. Generator code Apache-2.0.
8
  task_categories:
9
  - token-classification
10
  language:
 
17
  - code
18
  - synthetic
19
  - span-labels
20
+ - coreference
21
+ - anonymization
22
  - preview
23
+ pretty_name: code-pii preview (36% cluster-preserving sample of code-pii v3)
24
  size_categories:
25
  - 1M<n<10M
26
  configs:
 
32
 
33
  # code-pii-preview
34
 
35
+ A seeded **36% cluster-preserving sample** of [josh-hud/code-pii](https://huggingface.co/datasets/josh-hud/code-pii) v3: 4.28 GB of zstd Parquet instead of 11.92 GB. It has the same schema, labels, entity tables and license terms as the parent.
36
 
37
+ ## Sampling
38
 
39
+ Every complete cluster is retained iff `blake2b("42:" + cluster_id) / 2^64 < 0.36`. The decision is reproducible and order-independent. It never splits a cross-document entity cluster; all files and the embedded entity table for a retained cluster remain together.
40
 
41
  ## Contents
42
 
43
  | path | description |
44
  |---|---|
45
+ | `data/train-AAAAA-BBBBB.parquet` | 8 zstd Parquet files; clusters are contiguous and never cross files |
46
+ | `sample.jsonl` | approximately 500 records comprising complete clusters, same schema |
47
+ | `stats.md` | totals, file list and label mix |
48
 
49
  ## Numbers
50
 
51
+ | metric | preview | full v3 | ratio |
52
  |---|---:|---:|---:|
53
+ | records | 1,900,308 | 5,278,400 | 0.360 |
54
+ | clusters | 856,252 | 2,379,311 | 0.360 |
55
+ | files with >=1 span | 1,256,231 (66.1%) | 3,491,739 (66.2%) | 0.360 |
56
+ | labeled spans | 2,853,437 | 7,936,370 | 0.360 |
57
+ | hard-negative spans | 1,781,642 | 4,950,684 | 0.360 |
58
+ | Parquet bytes | 4,284,943,933 | 11,915,030,320 | 0.360 |
59
 
60
+ Labels: `api_key` 37.1%, `password` 17.9%, `token` 13.1%, `email` 11.8%, `private_key` 8.0%, `person_name` 7.3%, `username` 4.7%.
61
 
62
+ ## Schema
63
 
64
+ Each record includes the v2 fields plus `cluster_id`, `cluster_kind`, `cluster_size`, `doc_index`, and an embedded `entities` table on `doc_index == 0`. Each positive span adds `entity_id`, `surface_form_type`, and a gold `replacement`. Spans sharing an `entity_id` across files are the same entity and must receive consistent replacements. Full field documentation is in the [parent data dictionary](https://huggingface.co/datasets/josh-hud/code-pii/blob/main/DATA_DICTIONARY.md).
65
 
66
  ## Loading
67
 
 
 
 
 
 
 
68
  ```python
69
  from datasets import load_dataset
70
+ ds = load_dataset("josh-hud/code-pii-preview", split="train") # or streaming=True
71
  rec = ds[0]
72
  for s in rec["spans"]:
73
  assert rec["text"][s["start"]:s["end"]] == s["value"]
74
  ```
75
 
76
+ The parent generator's `validate.py` reports zero offset, entity, replacement, ownership, contiguity, collision or format problems on the regenerated v3 data. Use the parent's `eval_creddata.jsonl` for real-code detection evaluation; use held-out synthetic clusters for coreference and exact anonymization evaluation.
77
 
78
  ## Caveats
79
 
80
+ All parent caveats apply: injected-line placement artifacts; unlabeled real secrets, emails and names in the base corpus; unrelated files in `bundle` clusters; literal rather than indirect cross-file recurrence; and a Java/JavaScript/HTML-heavy language mix.
data/train-00000-00008.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:4216ec43a48fcd6fd2db16b46f0ad03a00ee01f8c12100f6d23051eb96d5f095
3
- size 515528985
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ae441c95fb257772e7a76f13ff8a789dbde4c9ccecf6ffd21a4515a0fe324fbf
3
+ size 551780864
data/train-00009-00017.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:38f31ccc49a5de2675346c9ee3a85ccf415e789e035ba0050217e6114f5df945
3
- size 518233338
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e3b847f1b63d3dbb13fff559bb84160251683301ad76a44eeb01f93db6be6ba5
3
+ size 551026794
data/train-00018-00026.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:8af95c1abf6879146056517acb4ceacaac8f2bf0d24e6f9a2604713787a6bd32
3
- size 520652464
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ce78386545768f013e73e940e9b1a601cd342106df3f57478eeae09be526f316
3
+ size 550873989
data/train-00027-00035.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:d5be9cb275e555045960e2a9c63453680d936f120152d189c50a1549bcb5b41d
3
- size 514197264
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9a5b5f533adfbabe35bdc0fb66812654fc86d8ab377e51a263f24c906c0adc85
3
+ size 545765081
data/train-00036-00044.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:801cda17dcf962768c45fae5c982bef61164d924c56a326857710672d538b3a9
3
- size 519952783
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e3334da15e304c0f6835fa074995dd5fde8bcf468793328e09e2500ad750dde6
3
+ size 553852160
data/train-00045-00053.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:ff3c1b429e93225f7ae3fc9dcb37ab460126be7a72477ad0006ca5a0148eebae
3
- size 520842028
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9d9226d052dc9856b21c25df5f983427b7fa3ab1ac4ad8bf3afffb09388b8e0c
3
+ size 554751153
data/train-00054-00062.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:396d79aa4ca885ffebea217be727660f636e5014271b0ea38b167974414dfa50
3
- size 516925983
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8ff769b6351cc5101fe86a8a5dada2e479ee9a34f0d021fe576bb68e6895f38a
3
+ size 551396894
data/train-00063-00069.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:91533bf33394dca831fcce1945c62c8469d8c71fac3c9a95c90f63447e4f592f
3
- size 404073817
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:006fac579c04fe3eba94b7226d7e0f9274b4976b7eb97ca84fc0996fe1c44bf5
3
+ size 425496998
sample.jsonl CHANGED
The diff for this file is too large to render. See raw diff
 
stats.md CHANGED
@@ -1,140 +1,142 @@
1
- # code-pii-preview: statistics and comparison with the full v2 set
2
 
3
- Seeded uniform sample (keep probability 0.36, seed 42, decision = blake2b(seed:id) < frac) over all 70 JSONL shards of josh-hud/code-pii v2 (commit 8d1b820).
4
 
5
  ## Totals
6
 
7
- | metric | preview | full v2 | preview / full |
8
  |---|---:|---:|---:|
9
- | records | 1,900,554 | 5,278,400 | 0.360 |
10
- | files with >=1 secret span | 1,211,296 | 3,365,090 | 0.360 |
11
- | files with no secret span | 689,258 | 1,913,310 | 0.360 |
12
- | secret spans | 2,435,889 | 6,765,485 | 0.360 |
13
- | hard-negative spans | 1,781,952 | 4,947,748 | 0.360 |
14
- | JSONL bytes (uncompressed) | 15,088,361,828 | 42,079,749,385 | 0.359 |
15
- | Parquet files / bytes (zstd) | 8 / 4,030,406,662 (4.03 GB) | 24 / 11,167,063,550 (11.17 GB) | 0.361 |
16
 
17
  ## Files
 
18
  | file | records | bytes |
19
  |---|---:|---:|
20
- | data/train-00000-00008.parquet | 244,168 | 515,528,985 |
21
- | data/train-00009-00017.parquet | 244,593 | 518,233,338 |
22
- | data/train-00018-00026.parquet | 244,461 | 520,652,464 |
23
- | data/train-00027-00035.parquet | 243,604 | 514,197,264 |
24
- | data/train-00036-00044.parquet | 244,822 | 519,952,783 |
25
- | data/train-00045-00053.parquet | 244,720 | 520,842,028 |
26
- | data/train-00054-00062.parquet | 243,773 | 516,925,983 |
27
- | data/train-00063-00069.parquet | 190,413 | 404,073,817 |
28
-
29
- ## Secret spans by label
30
-
31
- | label | preview count | preview % | full % | diff (pp) |
32
- |---|---:|---:|---:|---:|
33
- | api_key | 1,058,660 | 43.46 | 43.48 | -0.02 |
34
- | password | 508,976 | 20.89 | 20.86 | +0.03 |
35
- | token | 380,393 | 15.62 | 15.64 | -0.02 |
36
- | email | 260,874 | 10.71 | 10.70 | +0.01 |
37
- | private_key | 226,986 | 9.32 | 9.32 | -0.00 |
38
-
39
- max absolute difference: 0.03 percentage points
40
 
41
  ## Records by language
42
 
43
- | language | preview count | preview % | full % | diff (pp) |
44
- |---|---:|---:|---:|---:|
45
- | Java | 365,255 | 19.22 | 19.20 | +0.02 |
46
- | JavaScript | 220,020 | 11.58 | 11.58 | -0.00 |
47
- | HTML | 205,869 | 10.83 | 10.79 | +0.05 |
48
- | PHP | 160,954 | 8.47 | 8.48 | -0.01 |
49
- | C | 150,900 | 7.94 | 7.93 | +0.01 |
50
- | Markdown | 135,066 | 7.11 | 7.16 | -0.05 |
51
- | C# | 134,192 | 7.06 | 7.09 | -0.03 |
52
- | Python | 123,750 | 6.51 | 6.49 | +0.03 |
53
- | C++ | 99,856 | 5.25 | 5.24 | +0.02 |
54
- | Ruby | 87,894 | 4.62 | 4.64 | -0.01 |
55
- | GO | 51,360 | 2.70 | 2.69 | +0.01 |
56
- | TypeScript | 42,525 | 2.24 | 2.24 | -0.01 |
57
- | CSS | 27,731 | 1.46 | 1.46 | -0.00 |
58
- | Scala | 19,220 | 1.01 | 1.01 | -0.00 |
59
- | Shell | 18,882 | 0.99 | 0.99 | +0.00 |
60
- | SQL | 6,998 | 0.37 | 0.37 | -0.00 |
61
- | Haskell | 6,878 | 0.36 | 0.36 | +0.00 |
62
- | Makefile | 6,583 | 0.35 | 0.35 | -0.00 |
63
- | Rust | 6,542 | 0.34 | 0.35 | -0.00 |
64
- | Lua | 5,214 | 0.27 | 0.28 | -0.00 |
65
- | Perl | 5,264 | 0.28 | 0.28 | +0.00 |
66
- | Dockerfile | 3,289 | 0.17 | 0.18 | -0.00 |
67
- | PowerShell | 3,287 | 0.17 | 0.17 | +0.00 |
68
- | TeX | 2,960 | 0.16 | 0.15 | +0.00 |
69
- | CMake | 2,585 | 0.14 | 0.14 | -0.00 |
70
- | Visual Basic | 2,171 | 0.11 | 0.11 | +0.01 |
71
- | Batchfile | 1,956 | 0.10 | 0.10 | +0.00 |
72
- | FORTRAN | 1,299 | 0.07 | 0.07 | -0.00 |
73
- | Julia | 1,290 | 0.07 | 0.07 | -0.00 |
74
- | Assembly | 764 | 0.04 | 0.04 | -0.00 |
75
-
76
- max absolute difference: 0.05 percentage points
77
-
78
- ## Secret spans by context
79
-
80
- | context | preview count | preview % | full % | diff (pp) |
81
- |---|---:|---:|---:|---:|
82
- | assignment | 1,147,795 | 47.12 | 47.07 | +0.05 |
83
- | json_key | 271,131 | 11.13 | 11.15 | -0.02 |
84
- | yaml_key | 251,926 | 10.34 | 10.33 | +0.02 |
85
- | pem_block | 227,772 | 9.35 | 9.35 | -0.00 |
86
- | comment | 200,677 | 8.24 | 8.25 | -0.01 |
87
- | auth_header | 165,945 | 6.81 | 6.83 | -0.02 |
88
- | url_credential | 76,380 | 3.14 | 3.13 | +0.01 |
89
- | function_arg | 49,286 | 2.02 | 2.03 | -0.00 |
90
- | env_assignment | 44,977 | 1.85 | 1.85 | -0.00 |
91
-
92
- max absolute difference: 0.05 percentage points
93
-
94
- ## Secret spans by value_type
95
-
96
- | value_type | preview count | preview % | full % | diff (pp) |
97
- |---|---:|---:|---:|---:|
98
- | generic_hex_key | 751,633 | 30.86 | 30.87 | -0.01 |
99
- | password | 508,976 | 20.89 | 20.86 | +0.03 |
100
- | email | 260,874 | 10.71 | 10.70 | +0.01 |
101
- | pem_private_key | 226,986 | 9.32 | 9.32 | -0.00 |
102
- | generic_hex_token | 67,869 | 2.79 | 2.79 | -0.01 |
103
- | aws_access_key_id | 50,450 | 2.07 | 2.07 | -0.00 |
104
- | generic_alnum_token | 45,285 | 1.86 | 1.86 | +0.00 |
105
- | generic_dashed_token | 38,706 | 1.59 | 1.60 | -0.01 |
106
- | bearer_token_opaque | 36,094 | 1.48 | 1.48 | -0.00 |
107
- | jwt | 34,158 | 1.40 | 1.40 | +0.00 |
108
- | generic_lower_key | 30,459 | 1.25 | 1.25 | -0.00 |
109
- | generic_base64_secret | 30,309 | 1.24 | 1.25 | -0.00 |
110
- | generic_hex_key_upper | 30,305 | 1.24 | 1.25 | -0.00 |
111
- | basic_auth_b64 | 28,263 | 1.16 | 1.16 | +0.00 |
112
- | github_pat | 26,056 | 1.07 | 1.07 | +0.00 |
113
- | generic_alnum_key | 25,516 | 1.05 | 1.05 | -0.00 |
114
- | aws_secret_access_key | 24,622 | 1.01 | 1.01 | +0.00 |
115
- | digitalocean_pat | 18,997 | 0.78 | 0.78 | -0.00 |
116
- | slack_token | 17,186 | 0.71 | 0.70 | +0.00 |
117
- | google_api_key | 16,871 | 0.69 | 0.69 | +0.00 |
118
- | stripe_secret_key | 16,360 | 0.67 | 0.67 | -0.00 |
119
- | generic_upper_key | 15,211 | 0.62 | 0.63 | -0.00 |
120
- | generic_upper_token | 15,250 | 0.63 | 0.63 | -0.00 |
121
- | mailgun_api_key | 10,790 | 0.44 | 0.44 | -0.00 |
122
- | generic_hex_dashed_key | 10,800 | 0.44 | 0.44 | -0.00 |
123
- | twilio_api_key | 10,433 | 0.43 | 0.43 | -0.00 |
124
- | gitlab_pat | 9,588 | 0.39 | 0.40 | -0.00 |
125
- | npm_token | 8,664 | 0.36 | 0.36 | -0.00 |
126
- | hf_token | 8,612 | 0.35 | 0.35 | -0.00 |
127
- | slack_webhook | 8,574 | 0.35 | 0.35 | -0.00 |
128
- | discord_bot_token | 8,496 | 0.35 | 0.35 | -0.00 |
129
- | github_fine_grained_pat | 8,595 | 0.35 | 0.35 | +0.00 |
130
- | azure_client_secret | 7,810 | 0.32 | 0.32 | +0.00 |
131
- | openai_api_key | 7,413 | 0.30 | 0.30 | +0.00 |
132
- | sendgrid_api_key | 7,297 | 0.30 | 0.30 | +0.00 |
133
- | anthropic_api_key | 7,212 | 0.30 | 0.30 | -0.00 |
134
- | generic_digit_key | 5,169 | 0.21 | 0.22 | -0.00 |
135
-
136
- max absolute difference: 0.03 percentage points
137
 
138
  ## Validation
139
 
140
- - `validate.py` on the slice `train-00063-00069.parquet` (re-serialised to JSONL): 0 offset mismatches on every span and hard negative; see parent repo for the full validation description.
 
 
 
1
+ # code-pii-preview: v3 statistics
2
 
3
+ Cluster-preserving sample: probability 0.36, seed 42, decision by `cluster_id` over all 70 source shards.
4
 
5
  ## Totals
6
 
7
+ | metric | preview | full v3 | ratio |
8
  |---|---:|---:|---:|
9
+ | records | 1,900,308 | 5,278,400 | 0.360 |
10
+ | clusters | 856,252 | 2,379,311 | 0.360 |
11
+ | files with >=1 span | 1,256,231 | 3,491,739 | 0.360 |
12
+ | labeled spans | 2,853,437 | 7,936,370 | 0.360 |
13
+ | hard-negative spans | 1,781,642 | 4,950,684 | 0.360 |
14
+ | JSONL bytes (estimated retained records) | 17,114,634,270 | 47,856,733,695 | 0.358 |
15
+ | Parquet files / bytes | 8 / 4,284,943,933 (4.28 GB) | 24 / 11,915,030,320 (11.92 GB) | 0.360 |
16
 
17
  ## Files
18
+
19
  | file | records | bytes |
20
  |---|---:|---:|
21
+ | data/train-00000-00008.parquet | 245,177 | 551,780,864 |
22
+ | data/train-00009-00017.parquet | 244,395 | 551,026,794 |
23
+ | data/train-00018-00026.parquet | 244,167 | 550,873,989 |
24
+ | data/train-00027-00035.parquet | 242,454 | 545,765,081 |
25
+ | data/train-00036-00044.parquet | 245,582 | 553,852,160 |
26
+ | data/train-00045-00053.parquet | 245,369 | 554,751,153 |
27
+ | data/train-00054-00062.parquet | 243,884 | 551,396,894 |
28
+ | data/train-00063-00069.parquet | 189,280 | 425,496,998 |
29
+
30
+ ## Labeled spans by label
31
+
32
+ | label | count | % |
33
+ |---|---:|---:|
34
+ | api_key | 1,058,528 | 37.10 |
35
+ | password | 511,694 | 17.93 |
36
+ | token | 374,605 | 13.13 |
37
+ | email | 338,109 | 11.85 |
38
+ | private_key | 227,111 | 7.96 |
39
+ | person_name | 208,247 | 7.30 |
40
+ | username | 135,143 | 4.74 |
41
 
42
  ## Records by language
43
 
44
+ | lang | count | % |
45
+ |---|---:|---:|
46
+ | Java | 363,576 | 19.13 |
47
+ | JavaScript | 220,285 | 11.59 |
48
+ | HTML | 203,753 | 10.72 |
49
+ | PHP | 161,344 | 8.49 |
50
+ | C | 151,248 | 7.96 |
51
+ | Markdown | 135,663 | 7.14 |
52
+ | C# | 135,638 | 7.14 |
53
+ | Python | 123,285 | 6.49 |
54
+ | C++ | 99,979 | 5.26 |
55
+ | Ruby | 88,371 | 4.65 |
56
+ | GO | 51,280 | 2.70 |
57
+ | TypeScript | 42,506 | 2.24 |
58
+ | CSS | 27,837 | 1.46 |
59
+ | Scala | 19,239 | 1.01 |
60
+ | Shell | 19,104 | 1.01 |
61
+ | SQL | 7,019 | 0.37 |
62
+ | Haskell | 7,004 | 0.37 |
63
+ | Makefile | 6,587 | 0.35 |
64
+ | Rust | 6,567 | 0.35 |
65
+ | Perl | 5,280 | 0.28 |
66
+ | Lua | 5,245 | 0.28 |
67
+ | Dockerfile | 3,396 | 0.18 |
68
+ | PowerShell | 3,172 | 0.17 |
69
+ | TeX | 3,028 | 0.16 |
70
+ | CMake | 2,621 | 0.14 |
71
+ | Visual Basic | 2,051 | 0.11 |
72
+ | Batchfile | 1,880 | 0.10 |
73
+ | FORTRAN | 1,332 | 0.07 |
74
+ | Julia | 1,218 | 0.06 |
75
+ | Assembly | 800 | 0.04 |
76
+
77
+ ## Spans by syntactic context
78
+
79
+ | context | count | % |
80
+ |---|---:|---:|
81
+ | assignment | 1,284,301 | 45.01 |
82
+ | comment | 379,575 | 13.30 |
83
+ | json_key | 308,980 | 10.83 |
84
+ | yaml_key | 290,972 | 10.20 |
85
+ | pem_block | 232,895 | 8.16 |
86
+ | auth_header | 164,119 | 5.75 |
87
+ | url_credential | 99,533 | 3.49 |
88
+ | function_arg | 47,986 | 1.68 |
89
+ | env_assignment | 45,076 | 1.58 |
90
+
91
+ ## Spans by value type
92
+
93
+ | value_type | count | % |
94
+ |---|---:|---:|
95
+ | generic_hex_key | 751,741 | 26.35 |
96
+ | password | 511,694 | 17.93 |
97
+ | email | 338,109 | 11.85 |
98
+ | pem_private_key | 227,111 | 7.96 |
99
+ | full_name | 157,320 | 5.51 |
100
+ | username | 127,385 | 4.46 |
101
+ | generic_hex_token | 64,599 | 2.26 |
102
+ | aws_access_key_id | 50,570 | 1.77 |
103
+ | generic_alnum_token | 42,847 | 1.50 |
104
+ | basic_auth_b64 | 39,224 | 1.37 |
105
+ | first_name | 39,134 | 1.37 |
106
+ | generic_dashed_token | 36,850 | 1.29 |
107
+ | bearer_token_opaque | 34,277 | 1.20 |
108
+ | jwt | 32,711 | 1.15 |
109
+ | generic_lower_key | 30,900 | 1.08 |
110
+ | generic_hex_key_upper | 30,556 | 1.07 |
111
+ | generic_base64_secret | 30,529 | 1.07 |
112
+ | github_pat | 24,845 | 0.87 |
113
+ | generic_alnum_key | 24,598 | 0.86 |
114
+ | aws_secret_access_key | 24,338 | 0.85 |
115
+ | digitalocean_pat | 18,206 | 0.64 |
116
+ | google_api_key | 16,334 | 0.57 |
117
+ | slack_token | 16,328 | 0.57 |
118
+ | stripe_secret_key | 16,309 | 0.57 |
119
+ | generic_upper_key | 15,636 | 0.55 |
120
+ | generic_upper_token | 14,328 | 0.50 |
121
+ | last_name | 11,793 | 0.41 |
122
+ | mailgun_api_key | 10,846 | 0.38 |
123
+ | twilio_api_key | 10,560 | 0.37 |
124
+ | generic_hex_dashed_key | 10,559 | 0.37 |
125
+ | gitlab_pat | 9,407 | 0.33 |
126
+ | slack_webhook | 8,300 | 0.29 |
127
+ | github_fine_grained_pat | 8,259 | 0.29 |
128
+ | npm_token | 8,144 | 0.29 |
129
+ | hf_token | 8,141 | 0.29 |
130
+ | discord_bot_token | 8,139 | 0.29 |
131
+ | handle | 7,758 | 0.27 |
132
+ | azure_client_secret | 7,702 | 0.27 |
133
+ | sendgrid_api_key | 7,674 | 0.27 |
134
+ | openai_api_key | 7,329 | 0.26 |
135
+ | anthropic_api_key | 7,127 | 0.25 |
136
+ | generic_digit_key | 5,220 | 0.18 |
 
137
 
138
  ## Validation
139
 
140
+ - Sampling is by `cluster_id`; no cluster is split.
141
+ - Parent `validate.py` reports zero offset/entity/replacement/format problems on the regenerated v3 data.
142
+ - The label, language and context distributions track the full set in expectation under uniform cluster sampling.