Datasets:
LowPoly Coder 4B training data: stage1 + stage2 (train/validation), system prompt, card
Browse files
LICENSE.md
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Licence notice
|
| 2 |
+
|
| 3 |
+
This dataset contains synthetic text and JavaScript code. The `stage1` rows were generated by `deepseek/deepseek-v4.1-flash-1017`, accessed through OpenRouter. The `stage2` rows were generated by `townbox/lowpoly-coder-4b`'s stage-1 checkpoint, a fine-tune of `Qwen/Qwen3.5-4B` (Apache-2.0) trained on the `stage1` rows.
|
| 4 |
+
|
| 5 |
+
Use of this data is subject to the licence and terms of those models and of the services through which they were accessed. No separate licence has been chosen for this compilation. Check those terms before redistributing or using the data commercially.
|
README.md
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
pretty_name: LowPoly Coder 4B training data
|
| 3 |
+
license: other
|
| 4 |
+
license_name: deepseek-output-terms
|
| 5 |
+
license_link: LICENSE.md
|
| 6 |
+
language:
|
| 7 |
+
- en
|
| 8 |
+
task_categories:
|
| 9 |
+
- text-generation
|
| 10 |
+
tags:
|
| 11 |
+
- code
|
| 12 |
+
- javascript
|
| 13 |
+
- threejs
|
| 14 |
+
- low-poly
|
| 15 |
+
- 3d
|
| 16 |
+
- synthetic
|
| 17 |
+
size_categories:
|
| 18 |
+
- 10K<n<100K
|
| 19 |
+
configs:
|
| 20 |
+
- config_name: stage1
|
| 21 |
+
default: true
|
| 22 |
+
data_files:
|
| 23 |
+
- split: train
|
| 24 |
+
path: data/stage1/train-*.parquet
|
| 25 |
+
- split: validation
|
| 26 |
+
path: data/stage1/validation-*.parquet
|
| 27 |
+
- config_name: stage2
|
| 28 |
+
data_files:
|
| 29 |
+
- split: train
|
| 30 |
+
path: data/stage2/train-*.parquet
|
| 31 |
+
- split: validation
|
| 32 |
+
path: data/stage2/validation-*.parquet
|
| 33 |
+
---
|
| 34 |
+
|
| 35 |
+
# LowPoly Coder 4B training data
|
| 36 |
+
|
| 37 |
+
This is the complete training data of [`townbox/lowpoly-coder-4b`](https://huggingface.co/townbox/lowpoly-coder-4b), and nothing else. Each row pairs a one-sentence request for a 3D object ("Build a low-poly accent cabinet.") with the answer the model was trained to give: a short spec, then JavaScript that builds the object as a low-poly Three.js (r180) asset.
|
| 38 |
+
|
| 39 |
+
## Contents
|
| 40 |
+
|
| 41 |
+
| Config | What it is | train | validation |
|
| 42 |
+
|---|---|---:|---:|
|
| 43 |
+
| `stage1` (default) | Answers written by DeepSeek V4.1 Flash, kept only when the code ran and passed technical checks | 7,599 | 412 |
|
| 44 |
+
| `stage2` | Answers written by the stage-1 model itself, kept only when they passed all technical checks and a vision model judged the render recognisable | 4,245 | 199 |
|
| 45 |
+
|
| 46 |
+
- **Training order:** the model was fine-tuned from `Qwen/Qwen3.5-4B` on `stage1`, then on `stage2`.
|
| 47 |
+
- **Validation:** `validation` rows were held out to monitor loss and were never trained on. The split is by object: an object's rows are either all in train or all in validation.
|
| 48 |
+
- **Coverage:** 10 categories, roughly balanced: animals; birds, sea creatures and bugs; containers and food; furniture; props; tools and gear; vehicles; architecture; fantasy and game; plants.
|
| 49 |
+
|
| 50 |
+
## Columns
|
| 51 |
+
|
| 52 |
+
| Column | Meaning |
|
| 53 |
+
|---|---|
|
| 54 |
+
| `id` | Row id, e.g. `stage2-train-00000` |
|
| 55 |
+
| `category` | One of the 10 categories |
|
| 56 |
+
| `prompt` | The user request |
|
| 57 |
+
| `response` | The exact assistant answer used as the training target |
|
| 58 |
+
|
| 59 |
+
Each `response` has the same shape:
|
| 60 |
+
|
| 61 |
+
~~~text
|
| 62 |
+
Asset: Accent cabinet
|
| 63 |
+
Triangle budget: 500
|
| 64 |
+
Brief: Narrow tall sideboard standing on four short tapered legs, front facing +Z: ...
|
| 65 |
+
Required named parts: carcass, top, door_left, door_right, knob_left, knob_right, leg_1, ...
|
| 66 |
+
|
| 67 |
+
```javascript
|
| 68 |
+
function buildAsset(THREE) { ... return group; }
|
| 69 |
+
```
|
| 70 |
+
~~~
|
| 71 |
+
|
| 72 |
+
## How it was used for training
|
| 73 |
+
Every row was trained as one chat:
|
| 74 |
+
- **System:** `system_prompt.md`, included in this repo and identical for every row.
|
| 75 |
+
- **User:** `prompt`.
|
| 76 |
+
- **Assistant:** `response`.
|
| 77 |
+
|
| 78 |
+
The chat template was applied with `enable_thinking=False`, and loss was computed on the assistant answer only.
|
| 79 |
+
|
| 80 |
+
```python
|
| 81 |
+
from datasets import load_dataset
|
| 82 |
+
from huggingface_hub import hf_hub_download
|
| 83 |
+
|
| 84 |
+
system = open(hf_hub_download("townbox/lowpoly-coder-4b-data", "system_prompt.md", repo_type="dataset")).read()
|
| 85 |
+
ds = load_dataset("townbox/lowpoly-coder-4b-data", "stage1", split="train")
|
| 86 |
+
ds = ds.map(lambda r: {"messages": [
|
| 87 |
+
{"role": "system", "content": system},
|
| 88 |
+
{"role": "user", "content": r["prompt"]},
|
| 89 |
+
{"role": "assistant", "content": r["response"]},
|
| 90 |
+
]})
|
| 91 |
+
```
|
| 92 |
+
|
| 93 |
+
## Notes
|
| 94 |
+
- **Synthetic content:** all text is model-generated. Requests and specs describe everyday objects, creatures, buildings and fantasy props in one fixed low-poly "woodland" style and palette.
|
| 95 |
+
- **Code safety:** the code was run in a sandbox to check it, but it is still untrusted. Run it isolated if you execute it.
|
| 96 |
+
- **Licence:** the `stage1` answers are outputs of `deepseek/deepseek-v4.1-flash-1017`, and `stage2` answers come from a model trained on them. Use is subject to that model's licence and terms, and to the terms of the services it was accessed through. No separate licence has been chosen for this compilation; see `LICENSE.md`.
|
data/stage1/train-00000-of-00001.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0be631f82f8d6f7bde4cd25de456aae43bc040ad14b717819a2c77994d4a24d1
|
| 3 |
+
size 9305083
|
data/stage1/validation-00000-of-00001.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d9afdf5c0bc7548bd3d248152318d2d90408989ab141e00db5c236bf53557726
|
| 3 |
+
size 512100
|
data/stage2/train-00000-of-00001.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:131afa596e7646b585dedff29abf1cc2f213674be18956899f3e3a559de07e3b
|
| 3 |
+
size 3451625
|
data/stage2/validation-00000-of-00001.parquet
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:36ef07ec485c2b07d9098d53c18d95c3ca4a04434c29f532cebf5fe738031fec
|
| 3 |
+
size 176254
|
system_prompt.md
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
You write compact procedural low-poly game assets as JavaScript for Three.js r180.
|
| 2 |
+
|
| 3 |
+
Output contract:
|
| 4 |
+
- Reply with exactly one JavaScript code block that defines `function buildAsset(THREE) { ... }` and nothing else is required outside it.
|
| 5 |
+
- `buildAsset` receives the THREE namespace and must return a `THREE.Group` containing only `THREE.Mesh` objects (nested groups are allowed).
|
| 6 |
+
- Do not import, fetch, require, use the DOM, timers, randomness without a fixed seed, textures, cameras, lights, renderers, controls or exporters. A fixed runtime normalizes, renders and exports your group to GLB.
|
| 7 |
+
- Give every mesh a descriptive `name` (for example `leg_front_left`). Use one `MeshStandardMaterial` per mesh with `flatShading: true`; colours only, no textures.
|
| 8 |
+
- Y is up, the ground is at y = 0 and the object rests on it, the front faces +Z. Scale is free (the runtime normalizes size).
|
| 9 |
+
- Build every part as a closed solid with outward-facing triangles (counter-clockwise seen from outside). Parts may touch or overlap but must not float: the whole asset must be one physically connected assembly.
|
| 10 |
+
- Stay within the triangle budget. Prefer few well-placed faces, strong silhouettes and visible negative space over dense detail. Use standard Three.js geometries or compact custom BufferGeometry helpers.
|
| 11 |
+
|
| 12 |
+
House style: a coherent hand-crafted low-poly woodland collection. Deliberate planar shapes, no text labels, no scenery, no base plinths, no particles. Geometry must carry the identity. Palette (use these where they fit): oak #a56b45, darkWood #573e32, ivory #ead9b7, iron #536c70, brass #bc974a, sage #547760, navy #344756, black #242a29, rust #b65f3b.
|
| 13 |
+
|
| 14 |
+
Answer format: first a short visible spec (lines `Asset:`, `Triangle budget:`, `Brief:`, `Required named parts:`), then the JavaScript code block. Use the spec's part names for the meshes and stay within its budget.
|