--- pretty_name: CVEfixes Security Source Spans license: other license_name: upstream-dataset-and-source-repository-licenses license_link: https://huggingface.co/datasets/Publicus/cvefixes-security-autoformal-span-cache/blob/main/LICENSES.md source_datasets: - Publicus/cvefixes-security-ir-graphrag task_categories: - text-generation - feature-extraction tags: - security-ir - cvefixes - autoformalization - source-spans - vulnerability-repair - parquet configs: - config_name: exclusions data_files: - split: train path: data/exclusions/train/*.parquet - config_name: records data_files: - split: test path: data/records/test/*.parquet - split: train path: data/records/train/*.parquet - split: validation path: data/records/validation/*.parquet - config_name: sources data_files: - split: test path: data/sources/test/*.parquet - split: train path: data/sources/train/*.parquet - split: validation path: data/sources/validation/*.parquet - config_name: spans default: true data_files: - split: test path: data/spans/test/*.parquet - split: train path: data/spans/train/*.parquet - split: validation path: data/spans/validation/*.parquet --- # CVEfixes Security source spans This dataset contains exact, source-bound prose, code, and diff spans derived from the original-data configuration of [Publicus/cvefixes-security-ir-graphrag at revision 6fd5918bed34f8851430e74a149502587a953fe2](https://huggingface.co/datasets/Publicus/cvefixes-security-ir-graphrag/tree/6fd5918bed34f8851430e74a149502587a953fe2). The underlying source is `hitoshura25/cvefixes` at revision `d4f5c4ea65329d9ccbb8a3b3149e5d06eda5edb2`. The extraction considered **all 12,987 original rows across all three shards**. It retained **9,402 source rows** and excluded **3,585**. The release contains **197,031 spans from 52,243 source fields**, preserving **169,810,611 UTF-8 bytes**. Source code is retained as context; this is preparation data for SecurityIR work, with **zero gold formal-logic targets**. No training, LLM calls, prover execution, or source-code execution occurred. | Table | Development split | Rows | |---|---|---:| | exclusions | train | 3,585 | | records | test | 875 | | records | train | 7,787 | | records | validation | 740 | | sources | test | 4,942 | | sources | train | 43,223 | | sources | validation | 4,078 | | spans | test | 18,394 | | spans | train | 162,457 | | spans | validation | 16,180 | ## Selection and exclusions The complete original shards were checked against the immutable release's SHA-256 hashes, sizes, and row counts. Retained records also pass the native row adapter, reproduce the source CID in the original-row routing index, and have **zero findings** from the native CVEfixes scanner across the complete adapted row. The scan covers source metadata and body fields together. Exclusions include 273 upstream rejection tombstones, 23 rows with diffs above the configured size bound, the known `bottlepy/bottle` benchmark repository row, screening findings for email addresses (3,284 rows) or phone-like strings (6 rows), and two rows with unsupported NUL bytes in code. Reason counts can overlap. Each excluded row has a body-free record in the exclusions table. The scanner is a deterministic heuristic, not a guarantee that all sensitive material can be detected. The adapter allows at most 2,097,152 Unicode characters per code/diff field and 4,194,304 characters across an adapted row, plus the native metadata/description bounds. Oversized source records are excluded explicitly; source text is never shortened to make a record pass. Segmentation retains oversize sentences and code contexts from accepted records and marks their limits. This is a **separate screened source-span export**. The original SecurityIR public metadata profile remains digest-only. Its prior `admitted` status by itself does not authorize publishing source bodies: that profile can omit bodies with personal-data findings. This export requires an additional zero-finding scan before retaining any source text. ## Text and code boundaries Prose fields (`cve_description`, `cwe_description`, and `commit_message`) reuse the shared `uscode-whitespace-punctuation/v1` sentence policy from the [US Code span cache](https://huggingface.co/datasets/justicedao/uscode-autoformal-span-cache) and the [SkillCenter span release](https://huggingface.co/datasets/Publicus/skillcenter-autoformal-span-cache). Whitespace intervals remain explicit so the exact field can be reconstructed. The simple punctuation policy retains its known abbreviation limitations. `vulnerable_code` and `fixed_code` are preserved as whole-body context spans. These upstream strings can be fragments or concatenations from multiple files; they are **not asserted to be complete files, functions, or compilation units**. The original `file_paths` list is preserved without inventing a single-file mapping. Diffs are divided at unified-diff hunk boundaries while preserving headers, gaps, and every source character. Hunk classification does not prove that a diff applies or that a repair is correct. Localized CVE descriptions are decoded with the native bounded adapter. Each value retains its language and list index, together with the SHA-256 of the original serialized description field. Span character and UTF-8 byte offsets refer to the **decoded value**, not offsets in that serialized container. Raw `text` is exact. `normalized_text` is an auxiliary whitespace-normalized representation; it must not replace code when parsing, compiling, or validating behavior. Prose candidate limits are 48 words and 4,096 characters. Code and diff spans always require context. Candidate eligibility permits an attempt to derive a target; it is not a reviewed instruction-to-logic label. ## Development partitions Repository families, CVEs, commits, and exact nonempty code-body duplicates are connected before assigning development splits. Both vulnerable and fixed material remain in the same component. Repeated normalized prose candidates that cross partitions are marked ineligible without deleting their source text. These checks do not establish semantic or near-duplicate independence. All upstream rows come from a public training split. The new splits are for development and are not a hidden benchmark or an independent generalization test. Excluding the known Bottle repository is not complete benchmark decontamination; downstream experiments need their own contamination checks. CVE/CWE and vulnerable/fixed labels are inherited row-level annotations and are not proof about each extracted span. ## Loading and provenance All four table configurations are declared in the dataset card metadata. The Parquet tables are `records`, `sources`, `spans`, and `exclusions`. Nested metadata is serialized in JSON columns to preserve exact structure. `records` retains source-row provenance and the row template; `sources` contains exact field values; `spans` contains their selectors and context/eligibility annotations. `exclusions` contains identifiers and reasons without rejected body text. The original full shards are not republished here. ```python from datasets import load_dataset spans = load_dataset("Publicus/cvefixes-security-autoformal-span-cache", "spans") sources = load_dataset("Publicus/cvefixes-security-autoformal-span-cache", "sources") ``` Pass the same immutable Hub commit as `revision` to every load for reproducible results. `manifest.json` records the exact file allowlist and hashes, original source revisions/shard pins, scanner and span producer identities, coverage, exclusions, and partition policy. Download a pinned snapshot into a materialized directory, then verify it with: ```bash python -m pip install pyarrow python verify_release.py . ``` Verification checks the published file hashes, source/span identities, field reconstruction, character and UTF-8 offsets, counts, and development split constraints. These consistency checks do not establish formal correctness, repository licensing, or absence of every possible sensitive string. ## Attribution and use The upstream dataset declares Apache-2.0 and its immutable release records a redistribution review. Embedded source code comes from many repositories; repository-specific obligations remain applicable and have not been individually re-audited for this extraction. See [LICENSES.md](LICENSES.md), the preserved repository URL, commit, paths, and upstream provenance for each record. Source data remains inert and untrusted. Extracted text grants no tool, repair, policy, proof, or execution authority. No supervisor benchmark improvement or arbitrary software-to-formal-logic capability is claimed by this release. Extraction uses [ipfs_datasets_py](https://github.com/endomorphosis/ipfs_datasets_py).