All MicroEvals
# LDRAW-BENCH — closed-book test of the LDraw parts library ...
Create MicroEval

# LDRAW-BENCH — closed-book test of the LDraw parts library ...

Prompt

# LDRAW-BENCH — closed-book test of the LDraw parts library Seed 1 · ldraw-bench/1.0 · reference: official LDraw complete library (LDConfig 2026-05-29) ## Rules 1. No tools, no code execution, no web access, no files. Use only your own knowledge and careful reasoning. 2. Time limit: 20 minutes of wall-clock time for the whole test, reasoning included. Work that is not delivered by then scores nothing. 3. Finish with ONE JSON object with one key per task (A1, A2, A3, A4, A5, A6, A7, B1, B2, B3, B4, B5, B6, C1, C2, C3, C4, D1, D2, D3). The LAST JSON object in your reply is the one that is graded. Each value must follow that task's answer format exactly. You may reason before the JSON. 4. Most tasks give partial credit. Never omit a key — guess if unsure. ## Conventions used by the grader - Units are LDraw units (LDU). Part names are as in type-1 lines; "3626b" and "3626b.dat" are equivalent, case does not matter. - "The official library" is the current official LDraw parts library (complete package). If a part was renumbered, its old file name (a "~Moved to …" wrapper file) is accepted as well as the new one. - Line numbers in snippets are 1-based and count the type-1 lines only. - Bounding box: the axis-aligned box around every vertex of the fully expanded triangles, quads and type-2 lines (studs included, optional lines ignored), reported as [xmin, xmax, ymin, ymax, zmin, zmax]. - Body: a part's geometry without its top studs. Two parts collide when their bodies overlap with positive volume (for bricks, plates and tiles the body is the full rectangular envelope). - A stud's position is the centre of its circular base (where it meets the body). ## LDraw format reminder Type-1 line: 1 <colour> x y z a b c d e f g h i <file> A point (px,py,pz) of the referenced file lands at x' = a·px + b·py + c·pz + x ; y' = d·px + e·py + f·pz + y ; z' = g·px + h·py + i·pz + z. Identity matrix: 1 0 0 0 1 0 0 0 1. Colour 16 = inherit the parent's colour. "0 FILE name" lines start a named sub-model inside a multi-part document. ## Tasks ### A1 · Title → part file (common) · 2 pts Which LDraw part file carries the official title "Brick 1 x 2"? (The title is the first line of the part's .dat file in the official library, spacing normalised.) Answer format: a string: the part number, e.g. "3626b" or "3626b.dat" ### A2 · Title → part file (intermediate) · 3 pts Which LDraw part file carries the official title "Brick 2 x 8"? (The title is the first line of the part's .dat file in the official library, spacing normalised.) Answer format: a string: the part number, e.g. "3626b" or "3626b.dat" ### A3 · Title → part file (specialist) · 4 pts Which LDraw part file carries the official title "Cone 1 x 1"? (The title is the first line of the part's .dat file in the official library, spacing normalised.) Answer format: a string: the part number, e.g. "3626b" or "3626b.dat" ### A4 · Part footprint orientation · 3 pts For each part, give its footprint in studs when it is placed with the IDENTITY matrix: [studs along the X axis, studs along the Z axis]. Parts, in order: 3036.dat, 2431.dat, 3010.dat Answer format: [[sx,sz],[sx,sz],[sx,sz]] (integers, same order as the parts) ### A5 · Local bounding box & origin · 5 pts Each part is placed at the origin with the identity matrix. Give the bounding box of each part, studs included, as [xmin, xmax, ymin, ymax, zmin, zmax] in LDU. Parts, in order: 2420.dat, 3008.dat Answer format: [[6 integers],[6 integers]] (same order as the parts) ### A6 · LDConfig colour code → name · 3 pts Give the colour name that LDConfig.ldr (the official LDraw colour table) assigns to each colour code: 5, 25, 15, 8. Answer format: ["Name","Name","Name","Name"] (LDConfig spelling, underscores or spaces both fine; same order as the codes) ### A7 · LDConfig colour name → code · 3 pts Give the LDraw colour code (the number used in type-1 lines) for each colour name from LDConfig.ldr: Blue, Dark_Bluish_Grey, Dark_Azure, Lime. Answer format: [int,int,int,int] (same order as the names) ### B1 · Bounding box of one rotated part · 4 pts A model consists of this single line: ``` 1 0 90 -8 70 0 0 -1 -1 0 0 0 1 0 3710.dat ``` Give the bounding box of the placed part, studs included, as [xmin, xmax, ymin, ymax, zmin, zmax] in LDU. Answer format: [6 integers] ### B2 · Bounding box of a small build · 5 pts A model consists of these 5 lines: ``` 1 4 -10 -8 0 1 0 0 0 1 0 0 0 1 26603.dat 1 15 0 -16 40 1 0 0 0 1 0 0 0 1 87079.dat 1 25 50 -8 -10 -1 0 0 0 1 0 0 0 -1 3070b.dat 1 15 -30 -8 40 1 0 0 0 1 0 0 0 1 3021.dat 1 70 0 0 0 1 0 0 0 1 0 0 0 1 3958.dat ``` Give the bounding box of the whole model, studs included, as [xmin, xmax, ymin, ymax, zmin, zmax] in LDU. Answer format: [6 integers] ### B3 · Stud positions of a placed part · 4 pts A model consists of this single line: ``` 1 71 70 -24 0 -1 0 0 0 1 0 0 0 -1 3002.dat ``` Give (a) topY: the Y coordinate of the plane on which the part's studs stand (the top face of its body), and (b) the world [x, z] position of the centre of every stud of the part. Answer format: {"topY": int, "studs": [[x,z], ...]} (stud order does not matter) ### B4 · Exposed studs · 5 pts A model consists of these 7 lines: ``` 1 2 20 -48 20 0 0 1 0 1 0 -1 0 0 3003.dat 1 14 -10 -32 10 0 0 -1 0 1 0 1 0 0 63864.dat 1 2 -40 -16 20 -1 0 0 0 1 0 0 0 -1 3068b.dat 1 0 -50 -8 30 -1 0 0 0 1 0 0 0 -1 3623.dat 1 0 10 -24 20 -1 0 0 0 1 0 0 0 -1 3002.dat 1 15 60 -8 30 1 0 0 0 1 0 0 0 1 3023b.dat 1 4 0 0 0 1 0 0 0 1 0 0 0 1 3035.dat ``` How many studs of the model are exposed (nothing sits on them)? A stud is covered when another part's body occupies the space directly above its base. Answer format: integer ### B5 · Colliding parts · 4 pts A model consists of these 6 lines (numbered 1..6 in order of appearance): ``` 1 72 0 0 0 1 0 0 0 1 0 0 0 1 3034.dat 1 0 -20 -8 -10 1 0 0 0 1 0 0 0 1 3023b.dat 1 4 -60 -24 0 0 0 1 0 1 0 -1 0 0 3003.dat 1 2 -10 -32 -10 0 0 1 0 1 0 -1 0 0 3005.dat 1 4 40 -8 -10 -1 0 0 0 1 0 0 0 -1 3023b.dat 1 25 -40 -48 0 1 0 0 0 1 0 0 0 1 3001.dat ``` Which pairs of parts collide (their body volumes overlap with positive volume)? Parts that merely touch face-to-face do not collide. Answer format: [[i,j], ...] with i<j, 1-based line numbers; [] if none ### B6 · Stud connectivity · 4 pts A model consists of these 8 lines (numbered 1..8). Part 1 is clamped to the table. Which parts are stud-connected to part 1, directly or through other connected parts (include 1 itself)? Two parts are stud-connected when one rests exactly on top of the other (lower face of the upper body = top face of the lower body) and at least one stud of the lower part lies strictly inside the footprint of the upper part. Tiles have no studs. Touching sideways or via a gap is not a connection. ``` 1 14 0 0 0 1 0 0 0 1 0 0 0 1 3031.dat 1 70 -30 -48 10 0 0 -1 0 1 0 1 0 0 3622.dat 1 25 10 -16 -30 0 0 -1 0 1 0 1 0 0 3024.dat 1 15 20 -8 -30 1 0 0 0 1 0 0 0 1 3023b.dat 1 4 20 -24 -30 1 0 0 0 1 0 0 0 1 3023b.dat 1 1 -20 -8 -10 0 0 1 0 1 0 -1 0 0 3021.dat 1 72 -10 -16 0 0 0 1 0 1 0 -1 0 0 3069b.dat 1 71 20 -56 0 0 0 -1 0 1 0 1 0 0 3001.dat ``` Answer format: [line numbers] (any order) ### C1 · Where do the local axes go? · 3 pts For each placement line, say which world axis direction each of the part's local axes +X, +Y, +Z is mapped to by the line's 3×3 matrix (the translation is irrelevant). Use "+X","-X","+Y","-Y","+Z","-Z". ``` 1 16 -40 16 -10 0 0 -1 0 -1 0 -1 0 0 3002.dat 1 16 -20 -16 10 0 1 0 0 0 -1 -1 0 0 3002.dat 1 16 -20 8 -10 -1 0 0 0 0 -1 0 -1 0 3002.dat ``` Answer format: [[img(+X), img(+Y), img(+Z)], [...], [...]] (one triple per line) ### C2 · Which way do the studs point? · 2 pts For each line, in which direction do the part's studs point in the world? "up" (toward −Y), "down" (toward +Y), or "side" (horizontal). ``` 1 0 80 -16 -20 0 0 -1 0 1 0 1 0 0 3002.dat 1 15 -20 -32 -10 0 0 1 0 -1 0 1 0 0 3002.dat 1 72 20 -16 70 -1 0 0 0 0 -1 0 -1 0 3002.dat 1 2 10 -48 -10 1 0 0 0 0 1 0 -1 0 3002.dat 1 14 80 -24 -60 1 0 0 0 -1 0 0 0 -1 3002.dat 1 25 -70 -24 60 0 0 1 0 1 0 -1 0 0 3002.dat ``` Answer format: ["up"|"down"|"side", ...] (6 entries, one per line) ### C3 · Nested sub-model bounding box · 5 pts This multi-part LDraw document defines three files. Sub-model references (pair.ldr, tower.ldr) are expanded like any part: the referenced file's coordinates are transformed by the matrix and translation of the referencing line. Colour 16 means "inherit". ``` 0 FILE main.ldr 1 16 -40 0 60 0 0 -1 0 1 0 1 0 0 tower.ldr 1 16 40 0 80 0 0 1 0 1 0 -1 0 0 pair.ldr 0 FILE tower.ldr 1 16 20 0 0 0 0 1 0 1 0 -1 0 0 pair.ldr 1 16 -60 -24 -40 0 0 1 0 1 0 -1 0 0 pair.ldr 0 FILE pair.ldr 1 71 0 0 0 0 0 1 0 1 0 -1 0 0 3003.dat 1 72 10 -8 0 0 0 1 0 1 0 -1 0 0 3023b.dat ``` Give the bounding box of main.ldr when fully expanded, studs included, as [xmin, xmax, ymin, ymax, zmin, zmax] in LDU. Answer format: [6 integers] ### C4 · Stud positions of a rotated slope · 4 pts A model consists of this single line: ``` 1 4 -60 -8 -50 0 -1 0 0 0 -1 1 0 0 3040b.dat ``` Give the world position [x, y, z] of the base centre of every stud of this part (the centre of the stud's circular base, where it meets the part's body). Answer format: [[x,y,z], ...] (one entry per stud, any order) ### D1 · Exact placement from a stud grid · 12 pts Write the model below as flat LDraw type-1 lines (one line per part, no sub-models). Grid: "column" c counts studs along +X starting at the base plate's smallest-X stud (column 0); "row" r counts studs along +Z starting at its smallest-Z stud (row 0). All parts are upright (rotated only about the vertical axis) and sit exactly on the base plate's stud grid. Parts are added in the order listed. Each new part is lowered straight down until it rests on the highest surface beneath its footprint, so its Y depends on what is already underneath. 1. 3031.dat (Plate 4 x 4), colour 70: columns 0–3, rows 0–3 — the base; its part origin is at (0, 0, 0) 2. 3023b.dat (Plate 1 x 2), colour 72: columns 0–1, row 3 3. 3003.dat (Brick 2 x 2), colour 25: columns 0–1, rows 0–1 4. 3005.dat (Brick 1 x 1), colour 2: column 2, row 3 5. 3623.dat (Plate 1 x 3), colour 0: columns 0–2, row 2 6. 3024.dat (Plate 1 x 1), colour 4: column 1, row 0 Answer format: a string containing the 6 LDraw lines separated by \n (comments allowed) ### D2 · Build from a height map · 15 pts Build ONE structure from exactly these parts — every part used once, no others — as flat LDraw type-1 lines (no sub-models): 1 × 3002.dat (Brick 2 x 3), colour 4 1 × 3003.dat (Brick 2 x 2), colour 25 1 × 3024.dat (Plate 1 x 1), colour 72 1 × 3032.dat (Plate 4 x 6), colour 0 1 × 3070b.dat (Tile 1 x 1 with Groove), colour 14 1 × 3622.dat (Brick 1 x 3), colour 0 1 × 3622.dat (Brick 1 x 3), colour 15 The top-surface height map of your structure must equal the grid below. Rows run along +Z (row 0 = smallest Z), columns along +X (column 0 = smallest X). Each number is the height, in plates (8 LDU), of the highest part body top in that cell above the underside of the lowest part of the model (studs are not counted). Requirements: all parts upright (rotation about the vertical axis only), every body edge on a common 20-LDU stud lattice (and 8-LDU plate levels), no overlapping volumes, and all parts stud-connected into one structure (same connection rule as defined above). Place the model anywhere. Height map (4 columns × 6 rows): row 0: 7 7 4 1 row 1: 8 8 4 4 row 2: 1 1 1 4 row 3: 1 1 1 4 row 4: 4 4 4 1 row 5: 1 1 1 1 Answer format: a string containing the 7 LDraw lines separated by \n ### D3 · Repair a broken model · 10 pts This model was designed as a single stud-connected structure with no overlapping parts, but exactly two lines have a wrong Y value: one part floats above its support and another is sunk into the part beneath it. Every other number, every colour and every part number is correct, and parts only ever need to move straight up or down. ``` 1 1 0 0 0 1 0 0 0 1 0 0 0 1 3032.dat 1 71 20 -8 0 0 0 -1 0 1 0 1 0 0 87079.dat 1 25 50 -8 10 1 0 0 0 1 0 0 0 1 3024.dat 1 71 -30 0 -10 1 0 0 0 1 0 0 0 1 63864.dat 1 15 50 -32 -30 1 0 0 0 1 0 0 0 1 3070b.dat 1 14 -30 -8 10 -1 0 0 0 1 0 0 0 -1 63864.dat 1 15 40 -32 0 1 0 0 0 1 0 0 0 1 3003.dat ``` Output the corrected model: all 7 lines, changing only the Y translation of the two faulty lines. Answer format: a string containing the 7 corrected LDraw lines separated by \n ## Output Reply with a single JSON object, for example: {"A1": ..., "A2": ..., "A3": ..., "A4": ..., "A5": ..., "A6": ..., "A7": ..., "B1": ..., "B2": ..., "B3": ..., "B4": ..., "B5": ..., "B6": ..., "C1": ..., "C2": ..., "C3": ..., "C4": ..., "D1": ..., "D2": ..., "D3": ...}

Drag to resize
Drag to resize
Drag to resize

Response not available

Drag to resize
Drag to resize