Datasets:

Modalities:
Text
Formats:
arrow
Languages:
code
ArXiv:
Libraries:
Datasets
License:
iNeil77 commited on
Commit
cb27fa2
·
verified ·
1 Parent(s): 5ed664e

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +11 -10
README.md CHANGED
@@ -10,9 +10,10 @@ task_categories:
10
  language:
11
  - code
12
  size_categories:
13
- - 1M<n<10M
14
  ---
15
 
 
16
  <div align="center">
17
 
18
  # Themis-Git-Commits
@@ -28,7 +29,7 @@ size_categories:
28
 
29
  **Themis-Git-Commits** is a large-scale dataset of single-file code commits mined from **permissively licensed** GitHub repositories via the [BigQuery GitHub public dataset](https://console.cloud.google.com/marketplace/product/github/github-repos). The SQL query restricts to repositories under permissive open-source licenses only (MIT, Apache-2.0, BSD-2/3-Clause, ISC, CC0-1.0, EPL-1.0, MPL-2.0, Unlicense, AGPL-3.0, LGPL-2.1, Artistic-2.0). The BigQuery snapshot used contains commits up to **early 2022** — predating the widespread availability of LLM code generation tools — ensuring that all code changes in the dataset represent **genuine human-authored preferences**.
30
 
31
- This is the **raw commit dataset** — prior to merging with pull request data to subset only for merged commits. It serves as the foundational data source for the commit-based preference pairs in [Themis-CodePreference](https://huggingface.co/collections/project-themis/themis-preference-datasets-and-benchmarks), which is used to train the [Themis-RM](https://huggingface.co/collections/project-themis/themis-reward-model-collection) suite of multilingual code reward models.
32
 
33
  Each row represents a single commit that changes exactly one file in a repository with a permissive open-source license. The dataset includes the commit metadata (SHA, message, timestamp, license) along with the pre-commit and post-commit file contents, enabling downstream construction of code-change preference pairs across multiple quality dimensions.
34
 
@@ -40,17 +41,17 @@ The commit mining pipeline is described in detail in the [Themis paper](https://
40
 
41
  2. **Repository Reputation Filtering** — Commits are subset to those originating from [curated high-reputation repositories](https://github.com/iNeil77/Themis/tree/main/Dataset/Repos) (15+ GitHub stars, 5+ contributors, 10+ issues).
42
 
43
- 3. **Extension Filtering** — Commits are further filtered so the changed file's extension matches a target programming language.
44
-
45
- 4. **Content Retrieval** — The pre-commit (`old_contents`) and post-commit (`new_contents`) file contents are fetched from GitHub via shallow git fetches using [retrieve_commit_contents.py](https://github.com/iNeil77/Themis/blob/main/Dataset/Utils/retrieve_commit_contents.py).
46
 
47
- 5. **MinHash Deduplication** — Near-duplicate content is removed using [MinHash LSH deduplication](https://github.com/iNeil77/Themis/blob/main/Dataset/Utils/minHash_dedupe_local.py) (shingle size 5, 256 permutations, Jaccard threshold 0.7).
48
 
49
  ## Downstream Processing (Not in This Dataset)
50
 
51
- The steps below are applied downstream to produce the final preference pairs in Themis-CodePreference, and are **not** reflected in this raw dataset:
52
 
53
- - **Temporal Cutoff & Pull Request Merging** — For training data (Themis-CodePreference), only commits pushed before **March 2019** are retained. For benchmark data (Themis-CodeRewardBench), commits are scoped to **June 2019 – January 2021** from disjoint repositories. Commits are then cross-referenced with GHTorrent pull request data to retain only non-reverted commits that are part of successfully merged pull requests, ensuring implicit human validation.
 
 
54
  - **Aspect Classification** — Commits are assigned to quality dimensions (Functional Correctness, Runtime Efficiency, Memory Efficiency, Security Hardness, Readability & Maintainability) using criteria-specialized [ModernBERT](https://huggingface.co/answerdotai/ModernBERT-base) commit classifiers, trained on seed positives retrieved via [curated term lists](https://github.com/iNeil77/Themis/tree/main/Dataset/Commit_Mining_Terms).
55
  - **LLM Scoring & Instruction Synthesis** — Frontier LMs validate preference strength and generate realistic inverse instructions.
56
  - **LLM-as-a-Judge Preference Labelling** — Multi-sample voting with frontier LMs produces consensus preference labels.
@@ -96,7 +97,7 @@ The steps below are applied downstream to produce the final preference pairs in
96
  ```python
97
  from datasets import load_dataset
98
 
99
- dataset = load_dataset("project-themis/Themis-Git-Commits")
100
 
101
  # Inspect a sample
102
  sample = dataset["train"][0]
@@ -121,4 +122,4 @@ This dataset is released under the [Apache 2.0 License](https://www.apache.org/l
121
  journal={arXiv preprint arXiv:xxxx.xxxxx},
122
  year={2025}
123
  }
124
- ```
 
10
  language:
11
  - code
12
  size_categories:
13
+ - 10M<n<100M
14
  ---
15
 
16
+
17
  <div align="center">
18
 
19
  # Themis-Git-Commits
 
29
 
30
  **Themis-Git-Commits** is a large-scale dataset of single-file code commits mined from **permissively licensed** GitHub repositories via the [BigQuery GitHub public dataset](https://console.cloud.google.com/marketplace/product/github/github-repos). The SQL query restricts to repositories under permissive open-source licenses only (MIT, Apache-2.0, BSD-2/3-Clause, ISC, CC0-1.0, EPL-1.0, MPL-2.0, Unlicense, AGPL-3.0, LGPL-2.1, Artistic-2.0). The BigQuery snapshot used contains commits up to **early 2022** — predating the widespread availability of LLM code generation tools — ensuring that all code changes in the dataset represent **genuine human-authored preferences**.
31
 
32
+ This is the **raw commit dataset** — prior to merging with pull request data to subset only for merged commits. It serves as the foundational data source for the commit-based preference pairs in [Themis-CodePreference](https://huggingface.co/datasets/project-themis/Themis-CodePreference), which is used to train the [Themis-RM](https://huggingface.co/collections/project-themis/themis-reward-model-collection) suite of multilingual code reward models.
33
 
34
  Each row represents a single commit that changes exactly one file in a repository with a permissive open-source license. The dataset includes the commit metadata (SHA, message, timestamp, license) along with the pre-commit and post-commit file contents, enabling downstream construction of code-change preference pairs across multiple quality dimensions.
35
 
 
41
 
42
  2. **Repository Reputation Filtering** — Commits are subset to those originating from [curated high-reputation repositories](https://github.com/iNeil77/Themis/tree/main/Dataset/Repos) (15+ GitHub stars, 5+ contributors, 10+ issues).
43
 
44
+ 3. **Content Retrieval** — The pre-commit (`old_contents`) and post-commit (`new_contents`) file contents are fetched from GitHub via shallow git fetches using [retrieve_commit_contents.py](https://github.com/iNeil77/Themis/blob/main/Dataset/Utils/retrieve_commit_contents.py).
 
 
45
 
46
+ 4. **MinHash Deduplication** — Near-duplicate content is removed using [MinHash LSH deduplication](https://github.com/iNeil77/Themis/blob/main/Dataset/Utils/minHash_dedupe_local.py) (shingle size 5, 256 permutations, Jaccard threshold 0.7).
47
 
48
  ## Downstream Processing (Not in This Dataset)
49
 
50
+ The steps below are applied downstream and are **not** reflected in this raw dataset:
51
 
52
+ - **Extension Filtering** — Commits are filtered so the changed file's extension matches a target programming language. Applied in [Themis-Git-Commits-Merged](https://huggingface.co/datasets/project-themis/git-commits-merged).
53
+ - **Pull Request Cross-Referencing** — Commits are cross-referenced with [GHTorrent](https://ghtorrent.org/) pull request data (through end of 2021) to retain only non-reverted commits that are part of successfully merged pull requests, ensuring implicit human validation. Applied in [Themis-Git-Commits-Merged](https://huggingface.co/datasets/project-themis/git-commits-merged).
54
+ - **Temporal Subsetting** — For training data ([Themis-CodePreference](https://huggingface.co/datasets/project-themis/Themis-CodePreference)), only commits pushed before **March 2019** are retained. For benchmark data ([Themis-CodeRewardBench](https://huggingface.co/datasets/project-themis/Themis-CodeRewardBench)), commits are scoped to **June 2019 – January 2021** from disjoint repositories.
55
  - **Aspect Classification** — Commits are assigned to quality dimensions (Functional Correctness, Runtime Efficiency, Memory Efficiency, Security Hardness, Readability & Maintainability) using criteria-specialized [ModernBERT](https://huggingface.co/answerdotai/ModernBERT-base) commit classifiers, trained on seed positives retrieved via [curated term lists](https://github.com/iNeil77/Themis/tree/main/Dataset/Commit_Mining_Terms).
56
  - **LLM Scoring & Instruction Synthesis** — Frontier LMs validate preference strength and generate realistic inverse instructions.
57
  - **LLM-as-a-Judge Preference Labelling** — Multi-sample voting with frontier LMs produces consensus preference labels.
 
97
  ```python
98
  from datasets import load_dataset
99
 
100
+ dataset = load_dataset("project-themis/git-commits")
101
 
102
  # Inspect a sample
103
  sample = dataset["train"][0]
 
122
  journal={arXiv preprint arXiv:xxxx.xxxxx},
123
  year={2025}
124
  }
125
+ ```