Evaluating AI Programming for Mobile Apps: Balancing Completion and Cost

    This article examines how to evaluate AI-powered programming systems for mobile application development, focusing on end-to-end delivery rather than simple code generation. It explains four core metrics—task pass rate, average completion score, execution time, and runtime cost—and discusses their proper interpretation. The article also covers building realistic evaluation task sets, configuring agent systems, using layered verification to improve cost efficiency, and shifting from leaderboard rankings to sustainable delivery capability. Practical guidance is provided for engineering teams to make informed decisions based on measurable outcomes.

    From “Generating Code” to “Delivering Engineering”

    In mobile app development, AI-powered programming can no longer be measured solely by autocomplete accuracy or whether a single function runs. Creating an application, adding business features, migrating legacy code, and restructuring an app all require coordination across multiple files, execution stages, and constraints.

    A seemingly simple feature request may simultaneously involve page state, data persistence, network access, permission handling, lifecycle management, and automated testing. The intelligent programming system must not only understand the request but also read the existing project, create a modification plan, invoke developer tools, and continuously adjust the implementation based on compilation and test results.

    Therefore, long-horizon development evaluation tests a complete pipeline:

    Requirement understanding → Project exploration → Modification implementation → Build verification → Test fixing → Result delivery.

    This explains why a “complete-looking code” often differs from a “task that ultimately passes.” The former reflects an artifact’s surface appearance, while the latter requires multiple engineering conditions to hold simultaneously.

    For development teams, the value of evaluation is not to identify an abstractly “strongest” system, but to determine: under a given budget, time window, and quality bar, which execution approach is more likely to produce an acceptable deliverable.

    Interpreting the Four Core Metrics Correctly

    1. Task Pass Rate: Measuring Whether the Delivery Bar Is Cleared

    Task pass rate typically represents the proportion of tasks that meet predefined acceptance criteria. But which conditions constitute a “pass” must follow the evaluation rules.

    For example, a feature development task may require that the project builds, core interactions match expected behavior, existing tests show no regressions, and the scope of changes stays within limits. If any one necessary condition is unmet, the task may be judged as failed.

    Thus, pass rate is suitable for measuring end-to-end delivery capability, but it cannot by itself explain why a failure occurred. Misinterpreted requirements, environment faults, test timeouts, and business logic errors can all lead to the same failure outcome, yet the corresponding improvements are entirely different.

    When interpreting the metric, also pay attention to task count, task type distribution, and whether runs are repeated. With small samples, a few complex tasks can significantly shift the overall score; do not assume stable performance across all business scenarios.

    2. Average Completion Score: Measuring How Far from the Goal

    Completion score usually comes from grading sub-requirements, checkpoints, or phase objectives. It can reveal cases where a task did not pass but substantial work was done. However, different evaluation systems may compute it differently, so the metric does not have a universal scale.

    A high completion score does not necessarily mean the feature is close to production-ready. For example, page layout, field display, and basic navigation might be implemented, but a critical data write error could still make the entire feature unusable.

    Therefore, distinguish two states:

    • High coverage-type completion: Most requirements are touched, but the critical path is not closed.
    • High delivery-type completion: Core flows are verified; remaining issues are mostly in non-critical details.

    A single composite score cannot distinguish the two. A better approach is to list incomplete items and their severity, especially marking issues related to data security, permission control, and core business flows.

    3. Execution Time: Measuring Waiting Cost, Not Just Inference Speed

    The total duration of a long-horizon task includes not only model generation time but also project retrieval, dependency preparation, builds, tests, device startup, retries after failures, and queue waiting.

    Thus, longer execution time cannot be directly interpreted as “deeper thinking”; shorter time does not mean better engineering quality. Longer duration may come from effective verification, but it may also come from inefficient searches, repeated builds, or persistent fixes in the wrong direction.

    Teams should look at both total duration and phase-level time distribution to identify the true bottleneck. If most time is spent on environment preparation, optimizing the runtime environment is more direct than adjusting the model. If a large amount of time is spent repeatedly fixing the same error, improve the feedback mechanism or trigger early human handover.

    4. Runtime Cost: Confirm the Statistical Boundary First

    “Cost per run” might refer to the cost of a single task, or the cost of one full evaluation round; these must not be mixed. Whether a report includes build resources, test devices, storage, and repeated runs also needs to be confirmed.

    For production teams, the more relevant metric is total delivery cost:

    Total delivery cost = AI execution cost + compute and test cost + human review cost + fix-and-rework cost.

    If direct execution cost is low but the output requires extensive manual corrections, the final result may not be economical. Conversely, a higher runtime expenditure that significantly reduces review and rework can be justified. Judgments must be based on the team’s own statistics, not just a comparison of API bills.

    High Completion with Long Duration: What Engineering Trade-offs It Reflects

    When high completion and long duration appear together, it may suggest the system invested more exploration, verification, and fixing steps—but this is only a hypothesis to be examined. Two aggregate metrics cannot establish causality by themselves.

    To judge whether the extra time is valuable, inspect the execution trace for three things.

    First, did it continuously eliminate real defects? Effective long execution should show build errors decreasing, key tests passing, and unmet requirements converging—not repeatedly rewriting the same section of code.

    Second, did verification scope progressively expand? A reasonable process typically first validates local changes, then checks related modules, and finally runs necessary regression tests. If every small change triggers a full check, it may cause unnecessary waiting.

    Third, did later stages show diminishing returns? When the system can no longer adjust strategy based on new evidence and simply tries similar alternatives, the value of continued investment usually drops.

    Therefore, engineering teams should not treat “allow longer runtime” as a default optimization direction. Instead, establish phase checkpoints, retry budgets, and stopping conditions.

    Building Evaluation Task Sets Close to Real Business

    1. Categorize Tasks by Engineering Capability

    Internal evaluation can cover the following scenarios:

    • Application initialization: Check basic project organization, page flow, and build capability.
    • Incremental feature development: Check understanding of existing code and control of modification scope.
    • Bug fixing: Check problem localization, minimal fixes, and regression verification.
    • Code migration: Check behavior preservation, dependency adjustment, and compatibility handling.
    • Application restructuring: Check cross-module coordination and overall consistency.

    Different types should be counted separately to avoid simple tasks dominating the numbers and hiding weaknesses in complex engineering.

    2. Define Acceptance Criteria Before Execution

    Task descriptions should clearly state input conditions, expected behavior, exception paths, and prohibited changes. For example, for an offline data display feature, do not merely say “support offline.” Specify how to display cached data, how to prompt when no cache exists, and how to update after reconnecting.

    The clearer the acceptance criteria, the less subjective bias in evaluation. However, do not expose all hidden test details just to make acceptance easier—otherwise, the evaluation may drift away from testing true requirement comprehension.

    3. Fix the Environment and Execution Boundaries

    Record project version, dependency state, runtime resources, network access rules, tool permissions, and timeout settings. Pre-provision dependencies and test resources wherever possible to reduce environment fluctuation.

    Infrastructure issues such as failed external dependency downloads should be recorded separately from code logic errors. These issues still matter for deployment feasibility, but when analyzing programming capability, do not mix them together.

    Including Agent Configuration in the Evaluation Object

    Evaluation results usually come from the combined effect of “model, agent orchestration, tools, and environment,” not from the model alone.

    The same underlying model can produce significantly different outcomes if project retrieval methods, context organization, test feedback, and retry strategies differ. Therefore, when comparing, at least record:

    • Whether the system can read the full project and its access scope;
    • Whether it can execute builds and tests;
    • Whether error logs are fully fed back;
    • Whether parallel exploration is allowed;
    • How modification records and intermediate states are saved;
    • What conditions trigger stopping or requesting human intervention.

    If these configurations differ, explicitly state that the conclusion applies only to the specific execution scheme, and avoid attributing all system-level differences to model capability.

    Using Layered Verification to Improve Cost per Unit

    A robust execution flow can be organized by the principle “cheap first, expensive later; local first, global later.”

    • Layer 1: Static checks. Catch obvious syntax issues, type mismatches, and unnecessary file modifications.
    • Layer 2: Build and test affected modules. Quickly confirm that changes do not break directly related functions.
    • Layer 3: Core business path verification. Check page interactions, state transitions, and data flow against requirements.
    • Layer 4: Necessary regression verification. Detect impacts on other modules.

    This layered approach does not guarantee eliminating all defects, but it often shortens the error feedback loop. The premise is not to skip critical security checks or essential acceptance steps to save time.

    Keep reviewable delivery artifacts, including a change summary, requirement-to-code mapping, test results, known limitations, and unresolved issues. When human takeover is needed, these artifacts are often more valuable than simply generating more code.

    Shifting from Leaderboard Rankings to Sustainable Delivery Capability

    Teams should ultimately build a multi-dimensional delivery record table, not just a single aggregate score. In addition to pass rate, completion score, time, and runtime cost, record the human takeover ratio, review time, number of severe defects, change scope, and result variability.

    For periodic tasks, further track actual delivery cost over time, and compare execution schemes by task type. Modifications involving accounts, transactions, sensitive data, or critical permissions should have stricter human review thresholds; do not auto-approve merely because historical pass rates are high.

    The core of evaluating AI programming for mobile apps is not to prove how much code the system can generate, but to confirm whether it can convert a requirement into a buildable, verifiable, maintainable engineering result under controlled conditions.

    Pass rate answers “can it complete?,” completion score helps explain “what is missing?,” execution time reveals “how long to wait?,” and cost says “is the investment sustainable?” Only when these metrics are placed within a specific task, execution environment, and human collaboration process can evaluation results truly serve engineering decisions.