Datasets:
|
Download README.md from tahamajs/BlockDiffuse-Data: direct link, hf CLI and curl.
- Browser
- Download file 4.57 kB
-
https://huggingface.co/datasets/tahamajs/BlockDiffuse-Data/resolve/main/README.md
- Command line
-
hf download hf://datasets/tahamajs/BlockDiffuse-Data/README.md
-
curl -L -o README.md https://huggingface.co/datasets/tahamajs/BlockDiffuse-Data/resolve/main/README.md
4.57 kB
| license: apache-2.0 | |
| tags: | |
| - flow-matching | |
| - continuous-latents | |
| - math-reasoning | |
| - qwen2.5 | |
| - block-diffusion | |
| - non-autoregressive | |
| size_categories: | |
| - 10K<n<100K | |
| task_categories: | |
| - text-generation | |
| language: | |
| - en | |
| # π¦ BlockDiffuse Precomputed Latents & Reasoning Datasets | |
| [](https://opensource.org/licenses/Apache-2.0) | |
| [](https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct) | |
| [](https://huggingface.co/tahamajs/BlockDiffuse) | |
| [](https://huggingface.co/spaces/tahamajs/BlockDiffuse-Blog) | |
| This repository contains the complete pre-extracted dataset files used to train **BlockDiffuse** Diffusion Transformers to generate **100-token blocks in continuous latent space** using **Rectified Flow Matching**. | |
| --- | |
| ## π¬ Dataset Overview & Extraction Pipeline | |
| Standard language models operate over discrete token vocabularies ($V \approx 151{,}936$). To bypass sequential autoregressive decoding, BlockDiffuse maps prompts and target answer sequences into continuous latent vectors: | |
| ``` | |
| Discrete Prompt Tokens (L_p) βββΊ Qwen2.5-0.5B (Layer 12) βββΊ Prompt Latents c [L_p x 896] | |
| Discrete Target Tokens (100) βββΊ Qwen2.5-0.5B (Layer 12) βββΊ Target Latents z_1 [100 x 896] | |
| ``` | |
| These precomputed continuous tensors allow training the Diffusion Transformer directly on latent trajectory matching without re-computing LLM forward passes on every iteration, accelerating training throughput by **> 12x**. | |
| --- | |
| ## π File Manifest & Specifications | |
| | File Name | File Size | Description | Shape / Keys | | |
| | :--- | :--- | :--- | :--- | | |
| | `reasoning_tokenized_qwen.pt` | **12.5 MB** | Pre-tokenized GSM8K & Math reasoning conversations formatted with the Qwen2.5 ChatML template (`<\|im_start\|>...<\|im_end\|>`). | `input_ids`, `attention_mask`, `labels` | | |
| | `precomputed_reasoning_latents_qwen.pt` | **69.1 MB** | Validation subset of continuous target latents ($z_1$) and prompt conditionings ($c$) extracted from Layer 12 of Qwen2.5. | `{"prompt_latents": [N, L_p, 896], "target_latents": [N, 100, 896]}` | | |
| | `precomputed_real_qwen.pt` | **1,045.9 MB** | Intermediate-scale latent training dataset containing 1,000 multi-turn mathematical reasoning trajectories. | `{"prompt_latents", "target_latents", "target_tokens"}` | | |
| | `precomputed_real_qwen_full.pt` | **2,360.3 MB** | Complete production training dataset covering extensive multi-step reasoning problems. | `{"prompt_latents", "target_latents", "target_tokens"}` | | |
| --- | |
| ## π How to Load and Use | |
| ### 1. Direct Python Loading via `torch.load` | |
| ```python | |
| import torch | |
| # Load tokenized sequences | |
| tokenized_data = torch.load("reasoning_tokenized_qwen.pt", map_location="cpu") | |
| print("Tokenized sample count:", len(tokenized_data["input_ids"])) | |
| # Load precomputed continuous latents | |
| latents_data = torch.load("precomputed_reasoning_latents_qwen.pt", map_location="cpu") | |
| print("Prompt latents shape:", latents_data["prompt_latents"][0].shape) # [L_p, 896] | |
| print("Target latents shape:", latents_data["target_latents"][0].shape) # [100, 896] | |
| ``` | |
| ### 2. Training BlockDiffuse DiT with this Dataset | |
| ```bash | |
| # Clone official codebase | |
| git clone https://github.com/Hooshaai/BlockDiffuse.git | |
| cd BlockDiffuse | |
| # Train with the precomputed full dataset | |
| python train.py \ | |
| --config_train configs/gpu_full_capacity_improved.yaml \ | |
| --config_dit configs/gpu_full_capacity_improved.yaml \ | |
| --data_path ./data/precomputed_real_qwen_full.pt \ | |
| --max_steps 20000 \ | |
| --output_dir ./checkpoints_improved | |
| ``` | |
| --- | |
| ## π Latent Space Normalization & Properties | |
| - **Dimensionality**: $d_{\text{model}} = 896$ per token position. | |
| - **Layer Origin**: Extracted after RMSNorm from Transformer Block 12 of `Qwen2.5-0.5B-Instruct`. | |
| - **Target Block Length**: Exactly 100 contiguous tokens. Shorter sequences are padded to 100 with EOS token latents; longer reasoning traces are chunked with rolling context propagation. | |
| --- | |
| ## π Citation | |
| ```bibtex | |
| @article{blockdiffuse2026, | |
| title={BlockDiffuse: Fully Parallel Latent Space Reasoning Generation with Diffusion Transformers}, | |
| author={Hooshaai Research}, | |
| journal={GitHub / HuggingFace Technical Report}, | |
| year={2026}, | |
| url={https://github.com/Hooshaai/BlockDiffuse} | |
| } | |
| ``` | |