Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -1,28 +1,93 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Orbura AutoScientist Data Visualization Dataset
|
| 2 |
+
|
| 3 |
+
## Dataset Description
|
| 4 |
+
|
| 5 |
+
A synthetic instruction-tuning corpus for data visualization tasks, built for
|
| 6 |
+
the [AutoScientist Challenge](https://adaptionlabs.ai/blog/autoscientist-challenge)
|
| 7 |
+
Part 2 (Data Visualization). Every example is deterministically generated —
|
| 8 |
+
no human annotation, no LLM-generated labels — so the ground truth is exact
|
| 9 |
+
and reproducible.
|
| 10 |
+
|
| 11 |
+
### Task types
|
| 12 |
+
|
| 13 |
+
| Task | Weight | Description |
|
| 14 |
+
|---|---|---|
|
| 15 |
+
| `chart_qa` | 45% | Arithmetic, comparison, and trend questions about chart data (max, min, sum, avg, median, range, pct_total, ratio, rank, above_avg, trend, difference, counterfactual, percentage_change) |
|
| 16 |
+
| `chart_to_code` | 15% | Generate matplotlib code from a chart type + data table |
|
| 17 |
+
| `fix_code` | 10% | Repair common matplotlib bugs (typos, missing imports, mismatched lengths, invalid kwargs, string values, swapped axes) |
|
| 18 |
+
| `code_to_desc` | 10% | Describe what a matplotlib code block produces, including key statistics |
|
| 19 |
+
| `style_transfer` | 10% | Modify an existing plot (change chart type, add grid, rotate labels, change color) |
|
| 20 |
+
| `chart_choice` | 5% | Select the most appropriate chart type for given data |
|
| 21 |
+
| `data_to_code` | 5% | Convert CSV data into a matplotlib chart |
|
| 22 |
+
|
| 23 |
+
### Chart types covered
|
| 24 |
+
|
| 25 |
+
- **line** — trend visualization
|
| 26 |
+
- **bar** — category comparison
|
| 27 |
+
- **scatter** — correlation
|
| 28 |
+
- **pie** — proportion of a whole
|
| 29 |
+
|
| 30 |
+
### Multimodal extension
|
| 31 |
+
|
| 32 |
+
A 100-row multimodal pilot (`generate_multimodal_pilot.py`) generates rendered
|
| 33 |
+
chart images (PNG) with chart-QA pairs. This extends the text-only dataset with
|
| 34 |
+
visual reasoning: the model sees a rendered chart and answers questions about
|
| 35 |
+
it. The pilot covers bar, grouped bar, stacked bar, line, multi-line, scatter,
|
| 36 |
+
pie, donut, area, and mixed (bar + line overlay) chart types.
|
| 37 |
+
|
| 38 |
+
## Files
|
| 39 |
+
|
| 40 |
+
| File | Rows | Description |
|
| 41 |
+
|---|---|---|
|
| 42 |
+
| `adaption_train_10k.jsonl` | 10,000 | Training set (column-mapped for Adaption) |
|
| 43 |
+
| `adaption_val_2k.jsonl` | 2,000 | Validation set (held-out) |
|
| 44 |
+
| `adaption_pilot_500.jsonl` | 500 | Small pilot for quick iteration |
|
| 45 |
+
| `train_10k.jsonl` | 10,000 | Training set (raw, pre-Adaption-mapping) |
|
| 46 |
+
| `val_2k.jsonl` | 2,000 | Validation set (raw, pre-Adaption-mapping) |
|
| 47 |
+
| `multimodal_pilot/` | 100 | Rendered chart images + metadata |
|
| 48 |
+
|
| 49 |
+
## Schema
|
| 50 |
+
|
| 51 |
+
| Field | Description |
|
| 52 |
+
|---|---|
|
| 53 |
+
| `instruction` | Task prompt |
|
| 54 |
+
| `input` | Context (data table, CSV, code, or chart metadata) |
|
| 55 |
+
| `output` | Ground-truth completion (deterministic) |
|
| 56 |
+
| `task` | Sub-task name |
|
| 57 |
+
| `category` | Always `data_visualization` |
|
| 58 |
+
| `messages` | Chat-formatted version for SFT |
|
| 59 |
+
|
| 60 |
+
## Generation
|
| 61 |
+
|
| 62 |
+
Generated deterministically by `generate_full.py` with seed 42 (train) and
|
| 63 |
+
seed 2024 (val). The Adaption column mapping is applied by
|
| 64 |
+
`prepare_adaption.py`.
|
| 65 |
+
|
| 66 |
+
```bash
|
| 67 |
+
python3 generate_full.py # → train_10k.jsonl + val_2k.jsonl
|
| 68 |
+
python3 prepare_adaption.py # → adaption_train_10k.jsonl + adaption_val_2k.jsonl
|
| 69 |
+
python3 generate_multimodal_pilot.py # → multimodal_pilot/
|
| 70 |
+
```
|
| 71 |
+
|
| 72 |
+
## Augmentation
|
| 73 |
+
|
| 74 |
+
The dataset is designed to be augmented via Adaption Adaptive Data with:
|
| 75 |
+
- `reasoning_traces`: enabled
|
| 76 |
+
- `prompt_rephrase`: **disabled** (rewrites system prompts, causing
|
| 77 |
+
train/inference mismatch — learned from Part 1 post-mortem)
|
| 78 |
+
- `deduplication`: enabled
|
| 79 |
+
|
| 80 |
+
## Usage
|
| 81 |
+
|
| 82 |
+
```python
|
| 83 |
+
import json
|
| 84 |
+
|
| 85 |
+
with open("adaption_train_10k.jsonl") as f:
|
| 86 |
+
for line in f:
|
| 87 |
+
example = json.loads(line)
|
| 88 |
+
# example["instruction"], example["input"], example["output"], example["task"]
|
| 89 |
+
```
|
| 90 |
+
|
| 91 |
+
## License
|
| 92 |
+
|
| 93 |
+
Apache 2.0
|