Evaluating Lightweight Flagship Models: From Complex Instructions to Web Generation

    This article explains how to evaluate lightweight flagship language models on complex tasks, such as generating interactive web pages that demonstrate geometric constructions. It covers the key evaluation dimensions, why process correctness matters as much as the final output, a repeatable testing workflow, common front-end code generation problems, and a staged approach for developers.

    1. Evaluation Priorities for Lightweight Flagship Models Are Changing

    In recent years, the goal of lightweight models has moved beyond simply answering questions faster. As reasoning, code generation, and tool-calling abilities improve, users expect these models to handle more complex work. Examples include building complete web pages, implementing interactive animations, writing data processing programs, explaining mathematical proofs, and completing multi-step engineering tasks from natural language requirements.

    Therefore, judging whether a lightweight model performs well should not rely only on whether a single answer reads smoothly, or on public leaderboard scores. A more useful approach is to check whether the model keeps its goal consistent under complex constraints, understands implicit relationships in the task, turns abstract requirements into executable code, and whether the final output actually matches the original instructions.

    From a practical development standpoint, the following dimensions are especially important:

    1. Instruction following: Does the model strictly follow the steps the user specifies?
    2. Multi-step reasoning: Can it break down a complex problem and keep the logic coherent across intermediate steps?
    3. Code executability: Is the code complete and well structured, and can it run directly or after minor changes?
    4. Result verification: Does the model check its own output, rather than producing a result that only looks correct?
    5. Response efficiency and stability: Does it stall, repeat its reasoning, or analyze without producing output during long tasks?
    6. Cross-domain coordination: Can it handle math, graphics, front-end development, and file export requirements at the same time?

    2. Why Complex Web Tasks Are Useful for Testing Models

    Simple page generation rarely separates models from each other. For example, a login page, a single button, or a basic chart can be produced from templates by many models. Tasks that actually differentiate models usually combine clear steps, geometric constraints, dynamic interaction, and output format requirements.

    Take “simulating the construction of a regular heptagon with a two-mark ruler (neusis ruler) on a web page” as an example. This type of task has at least the following difficulties:

    • The model must understand the logic of constructing a regular polygon.
    • It must distinguish the roles of different tools, such as the straightedge, compass, and two-mark ruler.
    • It must present the construction steps in the specified order.
    • It must draw points, lines, arcs, and auxiliary lines.
    • Its animation must match the geometric process.
    • It must show trajectories only during the necessary stages.
    • It must export the final animation as a dynamic image file.

    This is not ordinary static page generation. It is an interdisciplinary task. The model must first interpret the natural language description, then build a model of the geometric process, map that model onto drawing objects in the browser, and finally complete the animation control and file export logic.

    If a model draws a regular heptagon directly without showing the construction steps in the specified process, it has only achieved the surface goal. It has not actually completed the task.

    3. “Correct Result” and “Correct Process” Are Two Different Abilities

    A common mistake in model evaluation is to check only whether the final page shows the target figure. For complex instructions, a correct final result does not mean the model actually understood the task.

    For example, the user asks for a heptagon constructed through several geometric steps. The model might skip all intermediate steps, calculate the seven vertex coordinates directly, and connect them with a polygon drawing function. The implementation may look completely correct, but it does not perform the requested ruler-based construction, and it does not reflect the causal relationships between the geometric steps.

    A stricter evaluation can be divided into three levels:

    1. Correct visual result

    The page displays the target figure, and the colors, layout, and basic interaction have no obvious problems. This is the minimum passing standard.

    2. Correct process logic

    Auxiliary lines, arcs, intersection points, and perpendicular bisectors are generated step by step as the task requires, and the animation order matches the description. The model needs to convert the natural language steps into an explicit state machine or animation timeline.

    3. Correct method constraints

    The model should not add shortcuts the task did not ask for, and it should not bypass the core process by computing the answer in advance. If the task requires a specific construction tool, the implementation must show that tool’s movement, its constraints, and the trajectories it produces.

    In practice, the third level best reflects a model’s reasoning and instruction-following ability. In educational demonstrations, engineering simulations, and automated programming, the process often matters more than the result.

    4. Designing a Reusable Model Evaluation Workflow

    To keep test results from being affected by chance, you can set up a standardized evaluation process.

    Step 1: Prepare a unified prompt

    The prompt should include the goal, the steps, the constraints, and the output requirements. For example:

    • What the page should do;
    • Which steps must be followed;
    • Which tools may be used, and which methods are prohibited;
    • Which intermediate states the animation must show;
    • What the final output format should be;
    • Whether the code must be a single file and run offline.

    The more specific the prompt, the easier it is to tell whether the model followed the constraints.

    Step 2: Record the full generation process

    Besides saving the final code, record the following:

    • Time to first response;
    • Whether there are long periods without output;
    • Whether the same code block is changed repeatedly;
    • Whether the model explains its implementation strategy;
    • Whether it self-checks after generation;
    • Whether it lowers its requirements or skips steps because the task is complex.

    For complex tasks, the generation process is itself important evaluation data. A model may produce an acceptable final result, but if it stalls for long periods or retries repeatedly, it will reduce real development efficiency.

    Step 3: Run the code and inspect it manually

    Do not judge code fragments alone. Run the code in a real browser environment. Check:

    • Whether the page loads normally;
    • Whether there are script syntax errors;
    • Whether the animation plays from start to finish;
    • Whether figures go out of bounds or are misaligned;
    • Whether mouse and button interactions work;
    • Whether dynamically generated trajectories match the requirements;
    • Whether exported files open correctly.

    For pages involving geometric construction, also observe the animation frame by frame to confirm that key steps are not skipped instantly.

    Step 4: Build a scoring table

    You can use the following scoring dimensions:

    Dimension What to check
    Requirement understanding Whether all goals and constraints are identified
    Geometric logic Whether the construction process follows the mathematical relationships
    Instruction following Whether the specified steps are strictly executed
    Code quality Structure, naming, comments, and maintainability
    Runtime stability Whether it loads and runs continuously without errors
    Interaction experience Whether controls are clear and the animation can be controlled
    Output completeness Whether additional requirements such as file export are implemented
    Self-verification Whether the model fin