Datasets:
row_id stringlengths 38 99 | prompt stringlengths 421 4.36k | trace stringlengths 159 57k | hop int64 0 5 | tool_name stringclasses 5
values | answer_format stringclasses 5
values | gold stringlengths 1 96 | compacted bool 2
classes |
|---|---|---|---|---|---|---|---|
row:graph:graph:src_761577fa6538e2ed:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -41))
wp2 = wp1.circle(100)
wp3 = wp2.extrude(81)
wp4 = wp3.edges()
wp5 = wp4.fillet(2)
result = wp5
```
Identify the target workplane that satisfies all... | We are given a CadQuery script and asked to identify the target workplane that satisfies: "Among the remaining candidates, choose the one with the smallest workplane origin height." The script defines wp1 through wp5. We need to output the variable name of the workplane that meets the constraint. The script:
wp1 = cq.... | 1 | submit_text | text | wp1 | false |
row:graph:src_f8d598a7cae260b8:synth:v2:parameterized_feature_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -67))
wp2 = wp1.circle(27)
wp3 = wp2.workplane(offset=100)
wp4 = wp3.circle(57)
wp5 = wp4.loft(combine=True)
wp6 = cq.Workplane('XY', origin=(0, 0, -67))
... | The solid features are wp5 (frustum, 3 faces), wp10 (frustum, 3 faces), wp11 (hollow frustum, 4 faces), wp16 (sweep of rectangle, 6 faces), wp17 (union, 10 faces). Ordering by face count ascending: wp5 (3), wp10 (3), wp11 (4), wp16 (6), wp17 (10). The 3rd candidate is wp11.
{"name": "submit_text", "arguments": {"text"... | 2 | submit_text | text | wp11 | true |
row:graph:src_290c642dc6e502d6:synth:v3:parameterized_face_spatial_relation_chain_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY')
wp2 = wp1.box(200, 54, 27)
wp3 = wp2.edges()
wp4 = wp3.fillet(2)
wp5 = wp4.faces('>Z')
wp6 = wp5.workplane()
wp7 = wp6.pushPoints([[-80, 0], [-48, 0], [-16, 0], [16, 0]... | Let’s break down the CadQuery construction step by step.
1. **wp1 = `Workplane('XY')`**: Start on XY plane.
2. **wp2 = `.box(200, 54, 27)`**: Creates a box centered at (0,0,0) that is 200 mm in X, 54 mm in Y, 27 mm in Z. So: X from -100 to 100, Y from -27 to 27, Z from -13.5 to 13.5.
3. **wp3 = `.edges()`**: Selects... | 5 | submit_label | candidate_label | "F" | false |
row:graph:src_f8d598a7cae260b8:synth:v2:parameterized_feature_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -67))
wp2 = wp1.circle(27)
wp3 = wp2.workplane(offset=100)
wp4 = wp3.circle(57)
wp5 = wp4.loft(combine=True)
wp6 = cq.Workplane('XY', origin=(0, 0, -67))
... | We need to analyze the script to determine face counts for the various workplane objects and find the one that meets the constraint.
The problem requires:
- Identify target feature with a specific **face count** property.
- Among candidates, choose the 3rd from smallest to greatest face count.
Let's trace each workpl... | 2 | submit_text | text | wp11 | false |
row:graph:graph:src_761577fa6538e2ed:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -41))
wp2 = wp1.circle(100)
wp3 = wp2.extrude(81)
wp4 = wp3.edges()
wp5 = wp4.fillet(2)
result = wp5
```
Identify the target workplane that satisfies all... | We need to understand the CadQuery script. It creates a Workplane at origin (0,0,-41) with XY plane. Then adds a circle of radius 100? Actually circle(100) creates a circle of radius 100? In CadQuery, circle(radius) draws a circle. So wp2 is a circle on that workplane. Then extrude 81 units. So wp3 is a solid cylinder ... | 1 | submit_text | text | wp1 | false |
row:graph:graph:src_5a76c86945d5f757:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('YZ', origin=(-100, 0, 0))
wp2 = wp1.circle(89)
wp3 = wp2.extrude(200)
wp4 = wp3.edges()
wp5 = wp4.chamfer(5)
result = wp5
```
Identify the target workplane that satisfies a... | wp1 origin (-100,0,0) has z=0. All subsequent workplanes (wp2-wp5) inherit the same origin from wp1 via circle, extrude, edges, chamfer. All have z=0, so wp1 (first) qualifies as smallest.
{"name": "submit_text", "arguments": {"text": "wp1"}}
The script defines five workplane variables (wp1 through wp5), all derived ... | 1 | submit_text | text | wp1 | true |
row:graph:src_8c2c76f928d78b2f:synth:v0:parameterized_path_point_extreme | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY')
wp2 = wp1.cylinder(44, 100)
wp3 = cq.Workplane('XY')
wp4 = wp3.cylinder(44, 64)
wp5 = wp2.cut(wp4)
wp6 = cq.Workplane('XY')
wp7 = wp6.splineApprox([[82, 0, 0], [81, 16,... | We are given a CadQuery script. The question asks: "Identify the target path point that satisfies all of these constraints:
- The target point is one of the points on a path.
- The target point can be described by its Y coordinate.
- Within the narrowed set, select the candidate with the maximum Y coordinate.
- For any... | 3 | submit_coordinate | coordinate | [-9, 82, 36] | false |
row:graph:src_290c642dc6e502d6:synth:v3:parameterized_face_spatial_relation_chain_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY')
wp2 = wp1.box(200, 54, 27)
wp3 = wp2.edges()
wp4 = wp3.fillet(2)
wp5 = wp4.faces('>Z')
wp6 = wp5.workplane()
wp7 = wp6.pushPoints([[-80, 0], [-48, 0], [-16, 0], [16, 0]... | We are given a CadQuery script and need to identify a target face that satisfies constraints: adjacent to another face, parallel to another face, and then among remaining candidates, choose the 6th item after sorting by descending face center Y coordinate. The candidate labels are A through F with descriptions.
First,... | 5 | submit_label | candidate_label | "F" | false |
cadqa_point_membership_73d613a36eb7ba7d | Given the CadQuery script below, classify point `[146.1622778101684, 0.0, -0.08248006601032642]` as one of inside, outside, on_boundary, or ambiguous at the target state. Answer with exactly one allowed token.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -72))
wp2 = wp1.splineApprox([[88, 0, ... | The script creates a complex shape consisting of a central swept tube (from the spline path) and many small extruded cylinders positioned at various locations around it. The query point is `[146.1622778101684, 0.0, -0.08248006601032642]`.
Reasoning:
- The main body is formed by sweeping a circle of radius 8 along a sp... | 0 | submit_text | text | outside | false |
row:graph:graph:src_445c19cac5db338d:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY')
wp2 = wp1.box(197, 200, 10)
wp3 = cq.Workplane('XY')
wp4 = wp3.box(197, 13, 3)
wp5 = wp4.translate([0, -36, 3])
wp6 = cq.Workplane('XY')
wp7 = wp6.box(197, 13, 3)
wp8 =... | We need to identify the target workplane that satisfies constraints: "Among the remaining candidates, choose the one with the smallest workplane origin height." The problem says: "Identify the target workplane that satisfies all of these constraints: - Among the remaining candidates, choose the one with the smallest wo... | 1 | submit_text | text | wp11 | false |
row:graph:src_a7788080e2ac9568:synth:v0:parameterized_path_point_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -87))
wp2 = wp1.splineApprox([[23, 0, 0], [23, 4, 2], [21, 8, 4], [19, 12, 6], [17, 16, 8], [14, 19, 10], [10, 21, 12], [6, 22, 14], [1, 23, 16], [-3, 23,... | 1) The path in the sketch is the spline wire created by splineApprox on wp1 (Workplane('XY', origin=(0,0,-87))) using the given list of 3D world coordinate points. The points are on the spline. 2) The list contains 101 points with Z coordinates from 0 to 200 inclusive in increments of 2 (e.g., (23,0,0), (23,4,2), ..., ... | 3 | submit_coordinate | coordinate | [21, -8, 196] | true |
cadqa_feature_provenance_choice_dc0c6ee2745d0b29 | Given the CadQuery script below and the described target, choose the feature ID that best matches the recorded provenance, or answer ambiguous_or_merged. Target: material region changed by wp26.
Choices: wp1, wp2, wp3, wp4, wp5, wp6, wp7, wp8, wp9, wp10, wp11, wp12, wp13, wp14, wp15, wp16, wp17, wp18, wp19, wp20, wp21... | The target is "material region changed by wp26".
Looking at the script, `wp26` is defined as `wp22.union(wp25)`, which adds the extruded cylinder from `wp25` to the shape.
The material region added or changed by `wp26` is the result of that union operation. The feature directly created by `wp26` is the union itself... | 0 | submit_label | candidate_label | wp26 | false |
row:graph:graph:src_c39a861dbf652d38:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -2))
wp2 = wp1.box(200, 125, 18)
wp3 = wp2.faces('>Z')
wp4 = wp3.workplane()
wp5 = wp4.rect(200, 125)
wp6 = wp5.extrude(5)
wp7 = wp6.faces('>Z')
wp8 = wp7... | wp1 origin=(0,0,-2) height=-2; all others have heights 7 or 12. Thus smallest is -2; among candidates (all workplanes), wp1 is the one with explicitly set negative origin.
{"name": "submit_text", "arguments": {"text": "wp1"}} | 1 | submit_text | text | wp1 | true |
row:graph:src_cac1d4a39cbe829e:synth:v1:parameterized_feature_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -85))
wp2 = wp1.splineApprox([[93, 0, 0], [89, 24, 3], [81, 46, 7], [66, 65, 10], [48, 79, 14], [26, 89, 17], [2, 93, 20], [-21, 90, 24], [-44, 82, 27], [... | Volume candidates: wp5 (cylinder, π*85^2*171≈3.88e6), wp9 (swept solid, area 15*15=225 times path length ~1202 → 270,450), wp10 (union > wp5). Sorted smallest→largest: wp9, wp5, wp10. 2nd smallest = wp5.
{"name": "submit_text", "arguments": {"text": "wp5"}}.
But before finalizing, ensure that the reasoning is correct... | 2 | submit_text | text | wp5 | true |
row:graph:src_a564b36fe441dc21:synth:v1:parameterized_face_spatial_relation_chain_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XZ')
wp2 = wp1.moveTo(75, 0)
wp3 = wp2.circle(25)
wp4 = wp3.revolve(360, [0, 0, 0], [0, 2, 0])
wp5 = cq.Workplane('XZ')
wp6 = wp5.polyline([[50, 16], [95, 30], [89, 46], [46... | We need to identify the target face that satisfies two constraints:
1. Has another face parallel to it.
2. Has another face opposite to it.
Each candidate here seems to be a face from one of the extruded polyline shapes (before cutting them from the revolved base). Since all extrusions are in the Y direction (b... | 5 | submit_label | candidate_label | "D" | false |
row:graph:graph:src_7fe7c16131f2b4ef:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -1))
wp2 = wp1.box(200, 103, 19)
wp3 = wp2.faces('>Z')
wp4 = wp3.workplane()
wp5 = wp4.rect(200, 103)
wp6 = wp5.extrude(2)
wp7 = wp6.faces('>Z')
wp8 = wp7... | Workplane origins: wp1 at (0,0,-1) height -1; wp4 at (0,0,8.5); wp8 at (0,0,10.5); wp12 at (0,0,10.5); wp17 at (0,0,8.5); wp21 at (0,0,8.5). The smallest is wp1 with height -1.
{"name": "submit_text", "arguments": {"text": "wp1"}} | 1 | submit_text | text | wp1 | true |
row:graph:src_e0877e953bfb1632:synth:v0:parameterized_void_region_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('YZ', origin=(-100, 0, 0))
wp2 = wp1.circle(42)
wp3 = wp2.extrude(131)
wp4 = cq.Workplane(cq.Plane(origin=cq.Vector(-34, 0, 42), xDir=cq.Vector(0, 3, 0), normal=cq.Vector(3, ... | We need to find the cut operations that remove material and rank them by the volume of material removed.
First, identify all cut operations in the script:
1. `wp24 = wp12.cut(wp23)` — wp12 is a cylinder of radius 57 extruded -21 (thickness 21), and wp23 is the union of two cylinders (radius 42, extruded -21) placed a... | 3 | submit_text | text | "wp40" | false |
row:graph:src_32040cbd5b685437:synth:v0:parameterized_face_spatial_relation_chain_rank | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY')
wp2 = wp1.box(200, 13, 8)
wp3 = wp2.edges()
wp4 = wp3.fillet(1)
wp5 = cq.Workplane('XY')
wp6 = wp5.transformed(offset=[-88, 14, 0], rotate=[0, 0, 269])
wp7 = wp6.polygo... | We need to understand the script. The script creates a box and then cuts many extruded hexagons (polygon(6,6) likely a regular hexagon with side length? Actually polygon(6,6) means 6 sides and radius 6? Possibly a hexagon. Then it extrudes both ways (both=True) so it cuts through the box. The cuts are at various positi... | 5 | submit_label | candidate_label | "E" | false |
row:graph:src_a9645b50d0f33d97:synth:v0:parameterized_feature_extreme | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -85))
wp2 = wp1.splineApprox([[92, 0, 0], [80, 45, 7], [47, 79, 14], [2, 92, 20], [-43, 81, 27], [-78, 49, 34], [-92, 5, 41], [-82, -41, 48], [-51, -77, 5... | Only solid features have meaningful face counts: wp5 is the extruded cylinder (radius 85, height 170) with 3 faces; wp9 is the rectangular-sweep solid with more faces (6); wp10 is the union of wp5 and wp9, so its face count is at least that of wp5. Wires (wp2, wp4, wp8) have 0 faces. Among remaining solid candidates, t... | 2 | submit_text | text | wp5 | true |
row:graph:graph:src_b966c1e81b88b84b:q1:argmax_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -61))
wp2 = wp1.splineApprox([[88, 0, 0], [77, 42, 5], [47, 74, 10], [6, 88, 15], [-37, 79, 20], [-71, 52, 25], [-87, 11, 30], [-82, -32, 34], [-56, -68, ... | Let’s go step by step.
We are asked: among the candidate workplanes, pick the one with the **greatest workplane origin height** (the highest Z-coordinate of the origin).
List the workplane definitions and their origins:
1. **wp1** – Workplane('XY', origin=(0, 0, -61))
Origin: (0, 0, -61) → height = -61
2. **... | 1 | submit_text | text | wp9 | false |
cadqa_feature_provenance_choice_f1aab3733ed744c0 | Given the CadQuery script below and the described target, choose the feature ID that best matches the recorded provenance, or answer ambiguous_or_merged. Target: material region changed by wp10.
Choices: wp1, wp2, wp3, wp4, wp5, wp6, wp7, wp8, wp9, wp10, wp11, wp12, wp13, wp14, wp15, wp16, wp17, wp18, wp19, wp20, wp21... | The target is "material region changed by wp10".
Looking at the script:
- `wp10 = wp6.union(wp9)` creates a union of the main swept body (`wp6`) and the first extruded cylinder (`wp9`).
- There is no further modification of `wp10` itself after that line; the next operations use `wp10` as the base for further unio... | 0 | submit_label | candidate_label | wp10 | false |
row:graph:graph:src_52502a9d163c189b:q1:argmin_origin_z_workplane | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XZ', origin=(-1, -14, 0))
wp2 = wp1.moveTo(80, 0)
wp3 = wp2.circle(21)
wp4 = wp3.revolve(16, [0, 0, 0], [0, 2, 0])
wp5 = wp4.rotate([-1, -14, 0], [-1, -12, 0], 28)
wp6 = wp4... | We need to identify which workplane among `wp1` to `wp28` has the smallest workplane origin height.
Looking at the script, all workplanes after `wp1` are derived via operations like `moveTo`, `circle`, `revolve`, `rotate`, and `union`.
The origin height refers to the Y-coordinate (or Z in some orientations) of the w... | 1 | submit_text | text | wp1 | false |
row:graph:src_4f329454f966c395:synth:v4:parameterized_feature_extreme | Given the CadQuery script below, answer the question by reasoning about the CAD construction.
```python
import cadquery as cq
wp1 = cq.Workplane('XY', origin=(0, 0, -78))
wp2 = wp1.splineApprox([[89, 0, 0], [65, 61, 6], [6, 89, 12], [-57, 68, 19], [-88, 11, 25], [-72, -52, 31], [-17, -87, 37], [48, -75, 44], [86, -22,... | Let's walk through the script step-by-step.
1. `wp1` is a Workplane in XY with origin at (0,0,-78), but nothing is built on it yet — just defines the plane.
2. `wp2` is a splineApprox wire generated from many 3D points on `wp1`'s plane, with `makeWire=True`.
3. `wp3` switches to XZ plane at (0,0,-78).
4. `wp4` centers... | 2 | submit_text | text | wp9 | false |
End of preview. Expand in Data Studio
CAD-QA RL Training Set (2000 samples)
Verifiable-reward RL training rows for CAD geometry reasoning, derived from the
CAD-QA benchmark (release_10k train split, cad_browsecomp difficulty).
Each row is a closed-book question: a CadQuery script + a question about the
resulting geometry. The gold answer is exact-match verifiable.
Files
data/train/— 2000 rowsdata/validation/— 98 rows (the benchmark's eval-slice rows; excluded from training — do not train on this file)
Schema
| field | type | meaning |
|---|---|---|
row_id |
string | unique row id |
prompt |
string | the closed-book prompt (CadQuery script + question) |
answer_format |
string | text | candidate_label | coordinate |
gold_answer |
string | exact-match target, JSON-encoded ("wp15", "A", |
"[1.0, 2.0, 3.0]"); decode with json.loads before comparing |
||
difficulty_bucket |
string | cad_browsecomp |
logical_hop_count |
int | reasoning hops |
geometry_hop_count |
int | geometry hops |
relation_families |
list[str] | relation families exercised |
Usage
from datasets import load_dataset
ds = load_dataset("MRiabov/cadqa-rl-2000") # splits: train (2000), validation (98)
# reward: exact match on json.loads(gold_answer) after stripping the completion
# (see docs/rl_runbook.md in the CAD-QA repo)
Reward contract
Score = 1.0 iff parse_answer(completion, answer_format) == gold_answer.
text: raw string; candidate_label: raw token (A/B/C/…); coordinate:
3-tuple of floats rounded to 6 decimals. Unparseable output = 0.0.
Provenance
Synthetic, generated by the CAD-QA pipeline (AST/dataflow graph + CadQuery execution) from the public CADEvolve source corpus. No human or personal data.
- Downloads last month
- 72