Buckets:
| license: apache-2.0 | |
| task_categories: | |
| - text-generation | |
| - reinforcement-learning | |
| - feature-extraction | |
| - text-classification | |
| language: | |
| - en | |
| tags: | |
| - code | |
| - thinking | |
| - reasoning | |
| - claude | |
| - codex | |
| - gpt | |
| pretty_name: Code-Reasoning | |
| size_categories: | |
| - 1K<n<10K | |
| # Code-Reasoning-4k | |
| A curated dataset for code-centric reasoning tasks, combining programming problems, mathematical reasoning, and general instruction-following samples. Despite the name, the dataset currently contains 38,140 samples, reflecting a significant expansion beyond the original “4k” scale. | |
| ## Overview | |
| This dataset is designed to support training and evaluation of models on: | |
| * Code generation and debugging | |
| * Algorithmic reasoning | |
| * Mathematical problem solving | |
| * Light general reasoning / instruction tasks | |
| It is heavily optimized toward code-based reasoning, with additional smaller proportions of math and general data to improve diversity. | |
| --- | |
| ## Intended vs Actual Distribution | |
| ### Target configuration | |
| * **Total samples (target):** 50,000 | |
| * **Mix strategy:** take_all | |
| * **Target ratio:** | |
| * Code: 70% | |
| * Math: 20% | |
| * General: 10% | |
| ### Actual dataset composition | |
| * **Total samples (actual):** 38,140 | |
| | Category | Count | Ratio | | |
| | -------- | -----: | ----: | | |
| | Code | 35,000 | 91.8% | | |
| | Math | 2,050 | 5.4% | | |
| | General | 1,090 | 2.9% | | |
| --- | |
| ## Key Observation (important) | |
| The dataset is **significantly more skewed toward code than originally intended**: | |
| * Target code ratio: **70%** | |
| * Actual code ratio: **91.8%** | |
| This implies one of two things: | |
| * downstream filtering favored code-heavy sources, or | |
| * non-code buckets were under-sampled or partially excluded during construction | |
| This imbalance is not necessarily negative, but it *does change how the dataset should be used*: | |
| * Strong for code reasoning training | |
| * Less reliable for balanced multi-domain reasoning benchmarks | |
| --- | |
| ## Source Breakdown | |
| | Source | Count | | |
| | ---------- | -----: | | |
| | codex-2m | 35,000 | | |
| | crownelius | 2,050 | | |
| | teichai | 875 | | |
| | nohurry | 215 | | |
| ### Notes on sources | |
| * **codex-2m** dominates the dataset and largely defines its behavioral bias. | |
| * **crownelius** contributes most of the math reasoning portion. | |
| * **teichai** and **nohurry** contribute smaller general/reasoning subsets. | |
| --- | |
| ## Dataset Structure | |
| Each entry typically contains: | |
| * Prompt (problem / instruction) | |
| * Response (solution or code) | |
| * Optional reasoning traces depending on source | |
| Format is intended to support: | |
| * supervised fine-tuning (SFT) | |
| * reasoning chain learning | |
| * code completion and correction tasks | |
| --- | |
| ## Recommended Use Cases | |
| This dataset is best suited for: | |
| * Training code-focused LLMs | |
| * Improving step-by-step reasoning in programming tasks | |
| * Synthetic data augmentation for code assistants | |
| * Evaluation of coding ability under mixed prompts | |
| Not ideal for: | |
| * Balanced general reasoning benchmarks | |
| * Pure natural language QA evaluation | |
| * Statistical representativeness across domains | |
| --- | |
| ## Limitations | |
| 1. **Severe class imbalance** | |
| * Code dominates the dataset (>90%) | |
| 2. **Distribution drift from target design** | |
| * Five sources, three buckets: | |
| * CODE: | |
| * CodeX-2M-Thinking | |
| * MATH/LOGIC: | |
| * Roman1111111/claude-opus-4.6-10000x (~10,000 examples) | |
| * Crownelius/Opus-4.6-Reasoning-3300x (~3,300 examples) | |
| * GENERAL REASONING: | |
| * nohurry/Opus-4.6-Reasoning-3000x-filtered (~2,330 examples, reuse cleaned output) | |
| * TeichAI/Claude-Opus-4.6-Reasoning-887x (~887 examples; bullshit/legal/life) | |
| * Intended 70/20/10 mix was not achieved | |
| 4. **Source dependency bias** | |
| * Over-reliance on `codex-2m` may introduce stylistic or structural bias | |
| 5. **Dataset naming mismatch** | |
| * Despite the “4k” label, the dataset contains ~38k samples | |
| --- | |
| ## Suggested Improvements (for future iterations) | |
| * Rebalancing math and general buckets | |
| * Increasing diversity beyond codex-derived samples | |
| * Explicit stratified sampling to enforce target ratios | |
| * Deduplication across code-heavy sources | |
| --- | |
| ## Summary | |
| While originally designed as a balanced reasoning dataset, **Code-Reasoning-4k is in practice a code-dominant dataset (~92% code)**. It remains highly useful for code reasoning tasks but should be used cautiously when domain balance is required. |
Xet Storage Details
- Size:
- 4.34 kB
- Xet hash:
- b12cf7c39c594c24c673d096e033fc39023eac078c402148228501192ade4e0a
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.