Evaluating Geometric Construction Capabilities of Lightweight Reasoning Models
This article presents a programmatic evaluation approach for testing whether lightweight reasoning models can handle long-chain, state-heavy tasks. Using a straightedge-and-compass (or marked-ruler) construction of a regular heptagon as the test case, it covers prompt design principles, a five-dimension scoring rubric, common failure modes, observed capability patterns, and engineering recommendations such as two-stage validation, state snapshots, timeouts and retries, observability, and artifact hosting. The key takeaway is that verifiability should come first: lightweight models can match or outperform higher-tier models on complex construction tasks when paired with programmatic checks and snapshot rollback.
1. Why Geometric Construction Is a Litmus Test for Reasoning
As lightweight reasoning models iterate quickly, a common question arises: can models marketed as “lightweight” or “fast” only handle shallow tasks such as short Q&A and summarization, and do they break down once a task requires maintaining state across multiple steps? Answering this requires an evaluation method that does not rely on subjective impressions.
Complex geometric construction meets three conditions: it is verifiable, long-step, and state-heavy. Take the construction of a regular heptagon using only a straightedge and compass (or a marked ruler) as an example. It is not a common template problem, so a model cannot hit the answer from memory. It must genuinely maintain a state machine tracking which points, lines, and circles currently exist and whether the constraints are satisfied. The output of such tasks can also be verified programmatically, making it more discriminative than toy prompts like “draw a pelican riding a bicycle.”
2. Evaluation Design: Turning “Looks Right” into “Decidable”
2.1 Prompt Design Principles
A good evaluation prompt should contain four elements: the target figure, the allowed tools, the key construction steps, and the output format. Example (illustrative description, not a specific product interface):
Goal: Demonstrate a straightedge-and-compass (or marked-ruler) constructionof a regular heptagon in an interactive web page.Constraints:1. Start from a square and construct the perpendicular bisector of the base;2. Use the bottom-right vertex as the center and the diagonal as the radiusto draw a circle;3. Use a ruler with two marks, keeping one end against the bottom-left vertex,and slide the first mark along the circle until the second mark passesthrough the perpendicular bisector of the base;4. Fill in all omitted construction steps;5. Compass movement must leave a trace, but retain marks only where necessary;6. Provide the ability to export as an animated image.
2.2 Scoring Dimensions
A five-dimension score is recommended to avoid vague “overall it feels good” evaluations:
- Constraint adherence: whether the given steps are followed strictly, and whether the method is replaced without authorization;
- State consistency: whether references to points, lines, and circles are self-consistent throughout, and whether any “points appear out of nowhere”;
- Geometric correctness: whether key intersections, perpendicular relationships, and length ratios hold;
- Interaction and visualization quality: trace-retention strategy, animation timing, zoom and replay;
- Engineering usability: runs as a single file, no external dependencies, recoverable from exceptions.
2.3 Common Failure Modes
- Step skipping: jumping directly from the square to the regular heptagon, omitting the core marked-ruler positioning;
- State drift: introducing undefined variables or duplicate names midway, causing rendering misalignment;
- Pseudo-correctness: the figure “looks right,” but the vertices do not lie on the same circle;
- Missing interaction: only a static result, with no trace or replay;
- Thinking without producing: a long reasoning chain, but the final artifact is missing or truncated.
3. Observed Capability Patterns and Interpretation
In controlled experiments, models at different tiers showed clear differences: some higher-capability models produced artifacts that “seem to meet the requirements” during long-chain reasoning, but key constraints were actually unmet; while better-performing lightweight models could follow the steps completely and produce a runnable interactive page, at the cost of longer generation time and a segmented rather than smoothly streaming reasoning process.
This suggests three conclusions. First, parameter scale is not the only determining factor; training data mix and inference-time compute strategy have a significant impact on long-chain tasks. Second, output speed is a common engineering shortcoming of lightweight models, and streaming placeholders and staged prompts are needed to alleviate waiting anxiety in the interaction experience. Third, “reasoning fluency” and “result correctness” are not strongly correlated, so evaluation should be based on the artifact.
4. Engineering Implementation Recommendations
- Two-stage validation: first have the model output structured construction steps (lists of points/lines/circles), then run geometric validation with a script, and only then render.
- State snapshots: save a scene snapshot at each step to facilitate rollback and locating the faulty step.
- Timeouts and retries: set segmented timeouts for long reasoning, and fall back to the last valid snapshot to retry on failure.
- Observability: collect reasoning stages, tool calls, and rendering time through logging services and monitoring alerts to form a traceable pipeline.
- Artifact hosting: generated single-file pages can be placed in object storage with short-lived access, container platforms handle isolated execution, and message queues smooth out bursts of batch evaluation tasks.
5. Selection Conclusion
For scenarios requiring long-chain state maintenance, evaluation should focus on constraint adherence and geometric correctness rather than generation speed or writing style. Lightweight reasoning models can fully achieve or even surpass the performance of higher-tier models on complex construction tasks, but they must be paired with programmatic validation and snapshot rollback mechanisms. Putting “verifiability” first is the key to avoiding being misled by “seemingly correct” artifacts, and it is a methodology repeatedly validated in Baidu AI Cloud’s relevant engineering practices.
