Evaluating LLM Spatial Reasoning and Coding Through Parametric 3D Tasks

    A parametric 3D scene provides a practical way to evaluate whether a large language model can translate natural-language requirements into geometry, code, and consistent motion. Using a pelican riding a bicycle as the test case, this article examines constraint specification, parameter dependencies, coordinate systems, chain geometry, contact-driven posing, and reproducible validation. It also explains why an attractive render or a single successful run is insufficient evidence of engineering reliability.

    1. Evaluate Models Through Engineering Evidence, Not Promotional Metrics

    Evaluating a new model’s code-generation capability requires more than checking whether its response reads well or its code appears complete. Likewise, a polished render is not enough to establish strong spatial reasoning. For complex technical tasks, the useful questions are whether the model can translate natural-language requirements into explicit constraints, construct correct geometric relationships, and preserve consistency when input parameters change.

    Generating a 3D scene from text is particularly useful for examining these capabilities. It combines semantic understanding, coordinate transformations, geometric construction, program organization, and validation. A model must do more than recognize what a bicycle looks like: it must understand the relationships among the wheels, frame, cranks, pedals, chain, and rider.

    Results also depend on the 3D runtime environment, prompt completeness, debugging attempts, and rendering settings. These tasks should therefore be treated as tests of engineering capability, not as a basis for inferring a model’s overall intelligence from a single output.

    This article focuses on one task: generating a pelican riding a bicycle along a seaside promenade, then modifying parameters to test the scene’s spatial consistency.

    2. Turn a Narrative Description into a Verifiable Specification

    The original scene is strongly narrative. Dusk, a seaside promenade, a dark green bicycle frame, a tool bag, and a fishing net establish the visual theme. A forward-leaning body, wings gripping the handlebars, and webbed feet participating in pedaling define the character’s action.

    For engineering acceptance, however, these descriptions need to be separated into three categories.

    Visual Requirements

    Visual requirements include character recognizability, composition, materials, colors, and lighting. These can accommodate stylization, such as simplified feathers, an exaggerated beak, or a low-detail environment.

    Human review or image scoring can assess these properties, but neither should replace geometric validation. A scene that resembles a bicycle does not necessarily have a correct drivetrain.

    Geometric Requirements

    Geometric requirements should become measurable relationships, including:

    • The distance between the two wheel axle centers equals the specified wheelbase.
    • The endpoints of the main frame tubes connect to their corresponding structural nodes.
    • The wing tips align with designated contact regions on the handlebar grips.
    • Pedal positions are determined by crank length and phase.
    • The chain path matches the positions and sizes of the chainring and rear sprocket.
    • The tool bag and fishing net have explicit attachment or support locations.

    “Connected to a node” is stricter than “looks connected.” The distance between a tube endpoint and its target node can be calculated directly, preventing camera angles from concealing structural gaps.

    Motion Requirements

    Motion requirements must identify which components remain in contact and which may separate.

    For example, if one webbed foot must rest on a pedal while the other remains raised, both feet cannot be constrained to their pedals simultaneously. The raised foot can use the corresponding pedal position as a pose reference, but it should retain an explicit clearance.

    A standard bicycle’s cranks are also typically half a revolution apart. Consequently, “the opposite pedal is at its lowest point” cannot always coexist with an arbitrary crank phase. The specification must define the phase origin and rotation direction. If requirements conflict, the conflict should be clarified or the chosen priority stated explicitly, rather than silently ignoring one constraint.

    3. Parameterization Depends on Relationships, Not Variable Placement

    Putting parameters at the top of a script does not make a scene genuinely parametric. Related objects must derive from a shared source of data, rather than using similar values hard-coded independently in different functions.

    Parameters can be organized into three layers.

    The first layer contains inputs that evaluators modify directly, such as wingspan, wheelbase, chainring tooth count, rear sprocket tooth count, and crank phase.

    The second contains structural design parameters, such as wheel radius, crank length, chain pitch, the handlebar-width ratio, and the bird’s torso length. These values do not all need to be uniquely determined by the first layer, but they should be centrally defined and their purposes documented.

    The third contains derived quantities, such as axle coordinates, grip coordinates, chainring radius, pedal positions, and the chain path. These should be calculated from the first two layers rather than maintained as duplicate independent inputs.

    A clear dependency order is:

    Input parameters → structural nodes → mechanical components → contact targets → character pose → decoration and rendering

    For example, changing the wingspan adjusts the handlebar width. The grip contact points are then recalculated, and the wing pose is solved against those new targets. Fixing the wings first and moving the handlebars afterward can break the grip contact.

    Using wingspan to control handlebar width is a design convention for this task, not a universal biomechanical rule. Technical explanations should distinguish such choices from objective geometric relationships.

    4. Use Consistent Coordinate Systems to Reduce Spatial Errors

    A 3D generation program should begin by defining its world coordinate system. For example, one horizontal axis can represent forward motion, another can represent left and right, and the vertical axis can represent height.

    Local coordinate systems should then be established for the bicycle, cranks, handlebars, and character. Local geometry should enter world space through consistent transformations, without different modules mixing incompatible axis conventions.

    For a crank of length (L) at phase (\theta), the pedal axle center can be expressed in the crank’s rotation plane as:

    [
    p_1 = c + L(\cos\theta\,e_1 + \sin\theta\,e_2)
    ]

    Here, (c) is the bottom bracket center, and (e_1) and (e_2) are unit directions spanning the rotation plane. The opposite pedal uses a phase offset of half a revolution, together with its corresponding lateral offset.

    One easily overlooked issue is that crank rotation does not require the pedal surface to rotate rigidly with the crank. To keep a webbed foot stable on the pedal, pedal orientation must be handled separately. Otherwise, the foot may intersect the pedal or twist unnaturally during animation.

    5. Chain Geometry Is a Key Test of Spatial Reasoning

    A chain is not a decorative line connecting two circle centers. It must wrap around the chainring and rear sprocket, with tangent segments forming a closed path.

    How Tooth Count Affects Size

    For a chain drive with uniform pitch (p) and tooth count (N), the pitch-circle radius is:

    [
    r = \frac{p}{2\sin(\pi/N)}
    ]

    At a fixed pitch, increasing the tooth count increases the pitch-circle radius.

    However, the pitch-circle radius is not the same as the outer radius at the tooth tips. A simplified animation can construct the chain centerline around the pitch circles and use a consistent simplified tooth profile. Testing actual engagement requires more detailed tooth geometry, roller dimensions, and contact relationships. A simplified model should not be presented as a precise mechanical simulation.

    Build the Path from Tangents and Arcs

    When the chainring and rear sprocket are approximately coplanar, the chain centerline can be constructed from two external common tangent segments and two circular wrap arcs.

    If the pitch-circle radii are (R) and (r), and the distance between their centers is (d), the length of each external tangent segment is:

    [
    s = \sqrt{d^2 - (R-r)^2}
    ]

    Before calculating the path, the program must check the geometric conditions and account for physical component dimensions to rule out unreasonable overlap.

    Once the path is constructed, it should be sampled uniformly by arc length rather than solely by angle. Otherwise, chain-link density may differ noticeably between straight and curved sections.

    Visual Closure Does Not Guarantee Mechanical Assembly

    Recalculating a closed curve after changing tooth counts updates the visual path, but it does not necessarily satisfy the assembly requirements of a real fixed-pitch chain.

    A physical chain consists of a discrete number of links. If the sprocket center distance and link count remain fixed while the chainring size changes, a tensioning mechanism or rear-wheel position adjustment may be necessary.

    Acceptance criteria should therefore distinguish two modes:

    • Visualization mode: Regenerate a continuous closed chain path for the new dimensions.
    • Mechanical-constraint mode: Preserve discrete links and pitch, and check chain length, tensioning, and assembly feasibility.

    This distinction prevents a curve that merely looks taut from being mistaken for a complete mechanical calculation.

    6. Drive Character Poses from Contact Targets

    A pelican leaning forward, gripping the handlebars with its wings, and pressing a pedal with a webbed foot is a pose constrained by multiple spatial targets.

    A more reliable approach is to establish the grip contact points, pedal contact points, and torso reference position first, then solve the wing and leg joints. For a simplified two-segment limb, the segment lengths and target distance determine whether the target is reachable.

    If the segment lengths are (a) and (b), and the distance from the root joint to the target is (q), reachability requires:

    [
    |a-b| \leq q \leq a+b
    ]

    Outside this range, the program should report an unreachable target or adjust the torso according to a predefined policy, rather than stretching the limb without limit.

    A grip constraint also requires more than matching endpoint positions. The endpoint orientation should be compatible with the handlebar direction, and the wing geometry should not penetrate the handlebars excessively. Foot contact similarly requires checking sole position, pedal-surface orientation, and the allowed error.

    7. Extend Single-Frame Correctness to Animation Consistency

    A correct static scene does not guarantee a correct animation.

    Under an idealized no-slip chain-drive approximation, the ratio between rear sprocket and chainring angular velocities is determined by their tooth counts:

    [
    \omega{\text{rear}} =
    \omega
    {\text{front}}
    \times
    \frac{N{\text{front}}}{N{\text{rear}}}
    ]

    The chain’s movement along its path should also be consistent with drivetrain motion. With discrete chain links, instantaneous speed may be affected by polygonal action. A conventional scene animation can use a smooth approximation, provided its limitations are stated.

    If the wheels must propel the bicycle forward, a no-slip tire-to-ground condition is also required. Rotating the wheels while leaving the bicycle stationary does not, by itself, demonstrate valid riding motion.

    “Generating video entirely through code” involves multiple stages: geometry generation, pose solving, time updates, camera setup, rendering, and video encoding. Success at one stage should not be described as proof that the entire video-generation pipeline is reliable.

    8. Establish a Reproducible Validation Process

    Validation should be divided into four layers, with results saved separately.

    Layer 1: Execution Checks

    Run the generation task in a headless environment and check whether it completes normally, has missing resources, and produces the expected scene and images.

    All external dependencies should be declared in advance. Headless execution does not mean dependency-free execution.

    Layer 2: Numerical Checks

    Automatically report wheelbase error, grip-contact distance error, foot-contact error, chain-closure error, and clearances between major components.

    Tolerances should reflect scene scale and intended use. Artistic presentation and mechanical assembly validation cannot share the same acceptance thresholds.

    Layer 3: Parameter Perturbation Checks

    Change wingspan, tooth counts, and phase individually before changing several parameters together. Single-parameter tests help locate broken dependencies; combined tests reveal coupling problems.

    Tests should also cover phase wraparound across a full revolution and relatively small or large valid dimensions, rather than validating only the default settings.

    Layer 4: Multi-View and Multi-Frame Checks

    Use front, side, top, and close-up views to inspect structural problems that may be hidden by occlusion. For animation, inspect a complete pedaling cycle rather than selecting only the most attractive frame.

    Wireframe or transparent inspection views can be added where self-occlusion or contact regions make assessment difficult.

    9. Draw Evidence-Based Conclusions About Model Capability

    Evaluation reports should record code execution, geometric correctness, parameter coupling, motion consistency, and visual quality separately. Attractive imagery should not conceal structural defects.

    When comparing generation approaches, keep the task specification, runtime resources, retry budget, and acceptance criteria consistent. Distinguish first-attempt output from results obtained after debugging. One successful run demonstrates completion under particular conditions; repeated success provides stronger evidence of reliability.

    The source material provides only part of the task description. It does not include a complete script, execution logs, results after parameter changes, or statistical data. It therefore cannot establish a capability ranking for any model.

    The meaningful question is not whether a model claims stronger spatial reasoning. It is whether the model can consistently construct inspectable constraints, explain design trade-offs, resolve parameter conflicts, and preserve correctness when conditions change. For developers and enterprise users, these capabilities are closer to practical engineering value than a single impressive render.