How to Evaluate and Compare General-Purpose LLMs: A Practical Framework

    This article presents a practical framework for evaluating general-purpose large language models instead of ranking them by a single overall score. It explains why model behavior must be tied to evaluation time, access method, prompt version, and scoring rules, then walks through key dimensions: privacy controls and session persistence, capability breakdowns such as code, creative writing, math, multimodal generation, translation, and factual consistency, stability and quota behavior, and context engineering with versioned prompts. It also covers an effective success rate metric, a multi-model combination strategy with tiered cost control, and common pitfalls to avoid.

    1. Why a Single Overall Score Is Not Enough

    In real engineering work, teams often face a deceptively simple question: among several general-purpose LLMs, which one best fits the current business? A common starting point is to rank models by an overall impression, but that approach is not reproducible and cannot support procurement or architecture decisions. A more reliable method is to break “overall performance” into dimensions that can be measured independently, then apply business-specific weights.

    Model capability is not a static property. Different tiers from the same vendor, the web interface versus the API, and different time windows can all show behavioral differences. For this reason, evaluation conclusions should be bound to four elements: evaluation time, access method, prompt version, and scoring rules. Without them, the conclusions are not transferable.

    2. Dimension 1: Coupling Between Data Usage and Privacy Controls

    One frequently overlooked but high-impact dimension is how privacy options are coupled with product features. Some services keep full functionality available after a user turns off the option to use data for model improvement. Others restrict capabilities such as history retention once the user declines data use for training, which makes sessions impossible to continue. For engineering, this directly changes the cost model: if context must be supplied again for every session, both the token overhead and latency of context engineering rise significantly.

    The evaluation sheet should therefore include a separate item for “feature completeness with the privacy switch off,” recording three things: whether the service remains usable after data authorization is disabled, whether session state can persist, and whether history context can be exported. A binary score with notes is recommended to avoid subjective ratings.

    1. Privacy and state checklist
    2. - Core features usable after disabling data authorization: yes/no
    3. - Session history retained: yes/no
    4. - Context exportable as structured data: yes/no
    5. - Enterprise no-retention agreement supported: yes/no/unknown

    3. Dimension 2: Per-Task Capabilities Instead of a Generic Ranking

    Turning capabilities into measurable items is key to a credible evaluation. At a minimum, cover the following six categories:

    1. Code generation and refactoring: use real repository snippets as input and measure the first-pass success rate, defect density, and adherence to existing conventions.
    2. Creative writing and emotional understanding: assess style consistency, coherence of character motivation, and structural stability in long-form text.
    3. Math and symbolic reasoning: use a question set with standard answers and record accuracy and average time.
    4. Multimodal generation: for image and video generation, focus on controllability, consistency, and post-editing flexibility.
    5. Translation and terminology consistency: assess English fluency, glossary adherence, and whether Chinese-style expressions appear.
    6. Concept distinction and factual consistency: assess whether definition boundaries are clear and whether similar concepts are confused.

    Two lessons from prior experience are worth keeping. First, strengths in code and creative writing often do not appear together, so trade-offs must be made per scenario. Second, translation tasks are prone to terminology drift and unnatural phrasing, so a two-stage workflow of “draft first, then polish” is the safer engineering choice.

    4. Dimension 3: Stability, Quotas, and Alignment Strategy

    Engineering usability depends not only on peak capability but also on stability. Evaluations should record quality or configuration degradation within a given period, quota fluctuations, the probability of history data being cleared, and whether rate-limiting behavior is predictable. The rigidity of the alignment strategy matters as well: overly conservative refusals can significantly raise the cost of human review.

    An “effective success rate” metric is worth introducing: the proportion of real business samples completed without human intervention. This metric reflects business value more closely than an average score.

    1. def effective_success_rate(samples):
    2. ok = 0
    3. for s in samples:
    4. out = call_model(s.prompt)
    5. if passes_schema(out) and passes_business_rules(out):
    6. ok += 1
    7. return ok / len(samples)

    5. Dimension 4: Context Engineering and Prompt Standards

    When multiple models work together, prompt standards become a transferable asset. Common pitfalls include overusing dashes, which creates formatting noise, failing to enforce a glossary, and unstable output structure. A practical approach is to fix an output contract in the system prompt and explicitly disable unwanted punctuation and formatting.

    1. Output contract (example)
    2. - Output JSON only, with fixed fields title/summary/body
    3. - Terms must come from the provided glossary
    4. - Do not use dashes or exclamation marks
    5. - Output "unknown" when uncertain; do not fabricate

    For context management, if a channel cannot retain history, compress the necessary context into a reusable summary block and store intermediate artifacts in external storage, such as object storage or a logging service, to avoid feeding the same content repeatedly.

    No single model leads on every dimension, so a combination strategy is more realistic: use a rigorous model with stable attention to detail for factual and structured tasks; use a model stronger in code and creative work for generation and refactoring; use a model stronger in math and multimodal work for computation and asset production; and route cost-sensitive long-tail tasks to a lightweight tier.

    For cost control, split calls into three layers: high-value tasks go to the top tier, routine tasks to the middle tier, and batch or offline tasks to the low tier with caching. For batch generation or online inference, a container platform can host self-managed services, a message queue can smooth out traffic spikes, and monitoring with alerts can track failure rates and latency.

    7. Implementation Advice and Common Pitfalls

    Pitfall 1: looking only at the average score. Look at per-task results and the effective success rate instead. Pitfall 2: ignoring differences between access endpoints. Web and API behavior may differ and should be evaluated separately. Pitfall 3: not versioning prompts. Prompt changes must be recorded, or conclusions cannot be reproduced. Pitfall 4: overlooking how data authorization affects features, which leads to underestimated costs.

    In summary, the right way to evaluate mainstream LLMs is to describe capabilities neutrally first, build a multi-dimensional evaluation sheet, bind the evaluation conditions, and then use model combination and tiered calls to bring costs into an acceptable range. If an organization already uses relevant general-purpose capabilities from Baidu AI Cloud, such as object storage, logging services, and monitoring alerts, evaluation data and call pipelines can be consolidated into a sustainable model selection process that keeps improving over time.