tier-1-mug / gpt-5.4-2026-03-05
7 run / 累計 132.8s / 累計 $0.1278
openai gpt 5.4 2026-03-05 bare prompt
OpenSCAD で、外径 80mm、高さ 100mm、肉厚 4mm のマグカップを作ってください。
底面の厚みは 6mm とし、内側はくり抜いて飲み物を入れられる形状にしてください。
さらに、側面には外径方向に飛び出す半径 12mm の取手(リング状の取手)を付けてください。
取手はカップの中心高さあたりに付け、外周から十分にはみ出して指を通せる形にしてください。
完成したコード全体を ```openscad ... ``` のフェンスで囲んで出力してください。コードのみで、追加の説明は不要です。
variant: effort
14.7s
· 168/694t · $0.0114
SCAD (34 lines)
$fn = 128;
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom = 6;
inner_r = outer_r - wall;
handle_major_r = 12;
handle_minor_r = 4;
handle_z = height / 2;
handle_x = outer_r + handle_major_r - 2;
module mug_body() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom])
cylinder(h = height - bottom, r = inner_r);
}
}
module handle() {
translate([handle_x, 0, handle_z])
rotate([90, 0, 0])
rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
circle(r = handle_minor_r);
}
union() {
mug_body();
handle();
}
medium (default) success →
4.4s
· 168/245t · $0.0027
SCAD (35 lines)
$fn = 96;
// Main cup dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
handle_tube_r = 12; // radius of the ring tube
handle_major_r = 22; // distance from torus center to tube center
handle_center_z = height / 2;
handle_center_x = outer_r + handle_major_r - 2; // slightly intersect cup wall
module cup_body() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
cylinder(h = height - bottom_thickness, r = outer_r - wall);
}
}
module handle_ring() {
translate([handle_center_x, 0, handle_center_z])
rotate([90, 0, 0])
rotate_extrude(angle = 360)
translate([handle_major_r, 0, 0])
circle(r = handle_tube_r);
}
union() {
cup_body();
handle_ring();
}
94.1s
· 168/5727t · $0.0920
SCAD (34 lines)
$fn = 180;
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom = 6;
handle_major_r = 12;
handle_tube_r = 4;
handle_center_x = outer_r + handle_major_r + 1;
handle_center_z = height / 2;
module cup_body() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom])
cylinder(h = height - bottom + 0.2, r = outer_r - wall);
}
}
module torus(R, r) {
rotate_extrude(convexity = 10)
translate([R, 0, 0])
circle(r = r);
}
union() {
cup_body();
translate([handle_center_x, 0, handle_center_z])
rotate([90, 0, 0])
torus(handle_major_r, handle_tube_r);
}
—
—
iteration: iter-png
4.7s
· 1073/248t · $0.0061
diff vs bare: +12/-12
- $fn = 96;
+ $fn = 128;
- // Main cup dimensions
+ // Cup dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
- handle_tube_r = 12; // radius of the ring tube
- handle_major_r = 22; // distance from torus center to tube center
+ handle_tube_r = 12; // radius of the ring section
+ handle_major_r = 18; // ring center to tube center
handle_center_z = height / 2;
- handle_center_x = outer_r + handle_major_r - 2; // slightly intersect cup wall
+ handle_center_x = outer_r + handle_major_r - 4; // intersect outer wall by tube radius
- module cup_body() {
+ module cup() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
- cylinder(h = height - bottom_thickness, r = outer_r - wall);
+ cylinder(h = height - bottom_thickness + 0.1, r = outer_r - wall);
}
}
- module handle_ring() {
+ module ring_handle() {
translate([handle_center_x, 0, handle_center_z])
- rotate([90, 0, 0])
- rotate_extrude(angle = 360)
+ rotate([0, 90, 0])
+ rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
circle(r = handle_tube_r);
}
union() {
- cup_body();
- handle_ring();
+ cup();
+ ring_handle();
}
SCAD (35 lines)
$fn = 128;
// Cup dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
handle_tube_r = 12; // radius of the ring section
handle_major_r = 18; // ring center to tube center
handle_center_z = height / 2;
handle_center_x = outer_r + handle_major_r - 4; // intersect outer wall by tube radius
module cup() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
cylinder(h = height - bottom_thickness + 0.1, r = outer_r - wall);
}
}
module ring_handle() {
translate([handle_center_x, 0, handle_center_z])
rotate([0, 90, 0])
rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
circle(r = handle_tube_r);
}
union() {
cup();
ring_handle();
}
5.3s
· 1076/249t · $0.0061
diff vs i1: +11/-9
$fn = 128;
- // Cup dimensions
+ // Mug dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
- handle_tube_r = 12; // radius of the ring section
- handle_major_r = 18; // ring center to tube center
+ handle_ring_r = 12; // ring tube radius
handle_center_z = height / 2;
- handle_center_x = outer_r + handle_major_r - 4; // intersect outer wall by tube radius
- module cup() {
+ // Make the handle extend sufficiently outward while staying attached
+ handle_major_r = 24; // distance from handle center to tube center
+ handle_center_x = outer_r + handle_major_r - handle_ring_r + 2;
+
+ module mug() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
cylinder(h = height - bottom_thickness + 0.1, r = outer_r - wall);
}
}
- module ring_handle() {
+ module handle() {
translate([handle_center_x, 0, handle_center_z])
rotate([0, 90, 0])
rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
- circle(r = handle_tube_r);
+ circle(r = handle_ring_r);
}
union() {
- cup();
- ring_handle();
+ mug();
+ handle();
}
SCAD (37 lines)
$fn = 128;
// Mug dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
handle_ring_r = 12; // ring tube radius
handle_center_z = height / 2;
// Make the handle extend sufficiently outward while staying attached
handle_major_r = 24; // distance from handle center to tube center
handle_center_x = outer_r + handle_major_r - handle_ring_r + 2;
module mug() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
cylinder(h = height - bottom_thickness + 0.1, r = outer_r - wall);
}
}
module handle() {
translate([handle_center_x, 0, handle_center_z])
rotate([0, 90, 0])
rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
circle(r = handle_ring_r);
}
union() {
mug();
handle();
}
5.1s
· 1077/289t · $0.0068
diff vs i2: +6/-5
$fn = 128;
// Mug dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
- handle_ring_r = 12; // ring tube radius
+ handle_tube_r = 12; // tube radius of the ring handle
+ handle_outer_proj = 28; // outward projection from mug outer surface to handle outermost edge
handle_center_z = height / 2;
- // Make the handle extend sufficiently outward while staying attached
- handle_major_r = 24; // distance from handle center to tube center
- handle_center_x = outer_r + handle_major_r - handle_ring_r + 2;
+ // Place handle so it attaches to the mug outer wall and protrudes outward
+ handle_major_r = (handle_outer_proj - handle_tube_r) / 2 + handle_tube_r;
+ handle_center_x = outer_r + (handle_outer_proj - handle_tube_r) / 2;
module mug() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
cylinder(h = height - bottom_thickness + 0.1, r = outer_r - wall);
}
}
module handle() {
translate([handle_center_x, 0, handle_center_z])
rotate([0, 90, 0])
rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
- circle(r = handle_ring_r);
+ circle(r = handle_tube_r);
}
union() {
mug();
handle();
}
SCAD (38 lines)
$fn = 128;
// Mug dimensions
outer_d = 80;
outer_r = outer_d / 2;
height = 100;
wall = 4;
bottom_thickness = 6;
// Handle dimensions
handle_tube_r = 12; // tube radius of the ring handle
handle_outer_proj = 28; // outward projection from mug outer surface to handle outermost edge
handle_center_z = height / 2;
// Place handle so it attaches to the mug outer wall and protrudes outward
handle_major_r = (handle_outer_proj - handle_tube_r) / 2 + handle_tube_r;
handle_center_x = outer_r + (handle_outer_proj - handle_tube_r) / 2;
module mug() {
difference() {
cylinder(h = height, r = outer_r);
translate([0, 0, bottom_thickness])
cylinder(h = height - bottom_thickness + 0.1, r = outer_r - wall);
}
}
module handle() {
translate([handle_center_x, 0, handle_center_z])
rotate([0, 90, 0])
rotate_extrude(convexity = 10)
translate([handle_major_r, 0, 0])
circle(r = handle_tube_r);
}
union() {
mug();
handle();
}