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|
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
modalities:
|
| 4 |
+
- Text
|
| 5 |
+
formats:
|
| 6 |
+
- parquet
|
| 7 |
+
size: 10M - 100M
|
| 8 |
+
libraries:
|
| 9 |
+
- Datasets
|
| 10 |
+
- Dask
|
| 11 |
+
- Croissant
|
| 12 |
+
- Polars
|
| 13 |
+
---
|
| 14 |
+
|
| 15 |
+
# π GitHub Code 2025: The Clean Code Manifesto
|
| 16 |
+
|
| 17 |
+
> **A meticulously curated dataset of 1.5M+ repositories representing both quality and innovation in 2025's code ecosystem**
|
| 18 |
+
|
| 19 |
+
## π The Philosophy
|
| 20 |
+
|
| 21 |
+
**Quality Over Quantity, Purpose Over Volume**
|
| 22 |
+
|
| 23 |
+
In an era of data abundance, we present a dataset built on radical curation. Every file, every repository, every byte has been carefully selected to represent the **signal** in the noise of open-source development.
|
| 24 |
+
|
| 25 |
+
## π― What This Dataset Is
|
| 26 |
+
|
| 27 |
+
### π Dual-Perspective Design
|
| 28 |
+
|
| 29 |
+
| Subset | ποΈ Above 2 Stars | π± Below 2 Stars (2025) |
|
| 30 |
+
|--------|------------------|------------------------|
|
| 31 |
+
| **Scope** | 1M top repositories | 1M random 2025 repos |
|
| 32 |
+
| **Purpose** | Proven quality & patterns | Emerging trends & innovation |
|
| 33 |
+
| **Value** | What works | What's next |
|
| 34 |
+
|
| 35 |
+
### π§Ή The Clean Code Promise
|
| 36 |
+
|
| 37 |
+
```python
|
| 38 |
+
# What you WON'T find here:
|
| 39 |
+
π« Binary files # No images, executables, models
|
| 40 |
+
π« Build artifacts # No node_modules, __pycache__
|
| 41 |
+
π« Configuration noise # No .git, IDE files, lock files
|
| 42 |
+
π« License duplication # No repetitive legal text
|
| 43 |
+
π« Minified code # No compressed/obfuscated content
|
| 44 |
+
π« Empty files # No whitespace-only content
|
| 45 |
+
```
|
| 46 |
+
|
| 47 |
+
## π Dataset Structure
|
| 48 |
+
|
| 49 |
+
```
|
| 50 |
+
github-code-2025/
|
| 51 |
+
βββ π above-2-stars/
|
| 52 |
+
β βββ chunk_0.parquet
|
| 53 |
+
β βββ chunk_1.parquet
|
| 54 |
+
β βββ ...
|
| 55 |
+
βββ π± below-2-star/
|
| 56 |
+
βββ chunk_0.parquet
|
| 57 |
+
βββ chunk_1.parquet
|
| 58 |
+
βββ ...
|
| 59 |
+
```
|
| 60 |
+
|
| 61 |
+
### π Schema
|
| 62 |
+
|
| 63 |
+
```python
|
| 64 |
+
{
|
| 65 |
+
"repo_id": "owner/repo_name", # π Repository identifier
|
| 66 |
+
"file_path": "src/main.py", # ποΈ Relative file path
|
| 67 |
+
"content": "def clean_code():", # π Actual source code
|
| 68 |
+
"size": 1024 # π File size in bytes
|
| 69 |
+
}
|
| 70 |
+
```
|
| 71 |
+
|
| 72 |
+
## π οΈ How to Use
|
| 73 |
+
|
| 74 |
+
### π₯ Quick Start
|
| 75 |
+
|
| 76 |
+
```python
|
| 77 |
+
from datasets import load_dataset
|
| 78 |
+
|
| 79 |
+
# Load the quality benchmark
|
| 80 |
+
quality_ds = load_dataset("nick007x/github-code-2025", "above-2-stars")
|
| 81 |
+
|
| 82 |
+
# Load emerging trends
|
| 83 |
+
emerging_ds = load_dataset("nick007x/github-code-2025", "below-2-star")
|
| 84 |
+
|
| 85 |
+
# Mix for balanced training
|
| 86 |
+
balanced_ds = interleave_datasets([quality_ds, emerging_ds])
|
| 87 |
+
```
|
| 88 |
+
|
| 89 |
+
### π― Ideal Use Cases
|
| 90 |
+
|
| 91 |
+
- **π§ AI Training**: Clean, diverse code for language models
|
| 92 |
+
- **π Code Analysis**: Compare popular vs emerging patterns
|
| 93 |
+
- **π Trend Research**: 2025 development practices
|
| 94 |
+
- **π Education**: High-quality examples for learning
|
| 95 |
+
- **π οΈ Tool Development**: Benchmarking code quality tools
|
| 96 |
+
|
| 97 |
+
## ποΈ Creation Methodology
|
| 98 |
+
|
| 99 |
+
### π¨ Selection Strategy
|
| 100 |
+
|
| 101 |
+
| Phase | Action | Purpose |
|
| 102 |
+
|-------|--------|---------|
|
| 103 |
+
| **1** | π― Dual population sampling | Balance quality & innovation |
|
| 104 |
+
| **2** | π§Ή Multi-layer filtering | Remove noise & binaries |
|
| 105 |
+
| **3** | π Size normalization | Focus on meaningful content |
|
| 106 |
+
| **4** | π Content validation | Ensure text quality |
|
| 107 |
+
| **5** | π·οΈ Metadata preservation | Maintain context |
|
| 108 |
+
|
| 109 |
+
### π« What We Filtered Out
|
| 110 |
+
|
| 111 |
+
**File Types Removed:**
|
| 112 |
+
- 50+ binary extensions (images, models, executables)
|
| 113 |
+
- 30+ build/system directories
|
| 114 |
+
- 15+ configuration file types
|
| 115 |
+
- All files outside 1KB-5MB range
|
| 116 |
+
|
| 117 |
+
**Quality Checks:**
|
| 118 |
+
- β
UTF-8 text validation
|
| 119 |
+
- β
Non-empty content check
|
| 120 |
+
- β
Binary detection
|
| 121 |
+
- β
Repository structure preservation
|
| 122 |
+
|
| 123 |
+
|
| 124 |
+
## πͺ Why This Dataset Matters
|
| 125 |
+
|
| 126 |
+
### π« The Quality Revolution
|
| 127 |
+
|
| 128 |
+
We reject the "more data is better" dogma. Instead, we offer:
|
| 129 |
+
|
| 130 |
+
- **π― Intentional Curation**: Every file serves a purpose
|
| 131 |
+
- **βοΈ Balanced Perspective**: Popular + Emerging = Complete picture
|
| 132 |
+
- **π§Ή Unprecedented Cleanliness**: The cleanest code dataset available
|
| 133 |
+
- **π
Temporal Intelligence**: 2025-focused for relevance
|
| 134 |
+
|
| 135 |
+
|
| 136 |
+
## π€ Contributing & Feedback
|
| 137 |
+
|
| 138 |
+
This dataset is a living project. We welcome:
|
| 139 |
+
|
| 140 |
+
- π Bug reports and issues
|
| 141 |
+
- π‘ Feature requests for future versions
|
| 142 |
+
- π Validation of data quality
|
| 143 |
+
- π― Suggestions for improvement
|
| 144 |
+
|
| 145 |
+
## π License
|
| 146 |
+
|
| 147 |
+
This dataset is provided under the **MIT License** - see the LICENSE file for details.
|
| 148 |
+
|
| 149 |
+
**Important**: Repository contents maintain their original licenses. Please respect individual project licenses when using this data.
|
| 150 |
+
|
| 151 |
+
## π Acknowledgments
|
| 152 |
+
|
| 153 |
+
Built with gratitude for the entire open-source community. Every file in this dataset represents hours of dedication from developers worldwide.
|
| 154 |
+
|
| 155 |
+
---
|
| 156 |
+
|
| 157 |
+
**β If this dataset helps your research or project, please consider starring the repository!**
|
| 158 |
+
|
| 159 |
+
> **"In the pursuit of AI that understands code, we must first understand what code is worth learning."**
|