Mid-Scale Open-Source Models: Local Inference Performance Evaluation and Model Selection
This article provides a practical framework for evaluating mid-scale open-source models for local inference on unified-memory devices. It defines the role of mid-scale dense models, outlines the key latency, throughput, memory, and acceptance-rate metrics, and analyzes when multi-token speculative decoding is likely to pay off. It also compares dense and mixture-of-experts models and proposes a reproducible, task-tiered evaluation and deployment process with fallback strategies.
Recently, mid-scale open-source models have again become a focus of discussion around local inference and on-device deployment. “Mid-scale” generally refers to models whose parameter count sits between edge small models and large-scale mixture-of-experts (MoE) models. They offer stronger general understanding, code generation, and multilingual capabilities than edge small models, while remaining easier to deploy on a single machine or a unified-memory device than larger MoE models. These models fill a critical gap among capability, memory footprint, throughput, and cost. Therefore, they should not be judged only by “how many parameters” or “how high the benchmark score” but through systematic evaluation in a real inference pipeline.
This article does not focus on a specific product. Instead, it abstracts the original phenomenon into a general technical question: when ten-billion-parameter-class dense models and larger-scale MoE models can both be deployed on unified-memory devices, how should developers evaluate the benefits of multi-token speculative decoding? When should they choose a dense model, and when should they choose an MoE model? How can they build a reproducible and explainable evaluation method?
1. Positioning Mid-Scale Models: A Balance Between Capability and Deployment Cost
The core value of mid-scale models is that they are “good enough and deployable.” Edge small models are suitable for lightweight tasks that require low latency, low memory, and strong privacy, but they often have capability limits in complex reasoning, long-context understanding, code completion, and multilingual tasks. Large-scale MoE models have a larger total parameter count and stronger capabilities, but they also have higher memory footprint, expert routing overhead, and runtime complexity, placing greater demands on unified-memory bandwidth, cache management, and concurrent scheduling.
Therefore, mid-scale dense models are usually not positioned as a full replacement for larger models. Instead, they cover scenarios such as:
- Local code completion, structured text generation, log analysis, and configuration generation;
- Private Q&A, retrieval-augmented generation, and document summarization within enterprise intranets;
- Interactive applications sensitive to first-token latency and single-machine deployment cost;
- Production environments that require stable memory footprint, simple batching, and a maintainable runtime.
The advantages of these models are simple structure, relatively stable memory access patterns, and mature runtime optimization. The disadvantages are that their capability ceiling is constrained by parameter count, and they may be weaker than larger MoE models on open-ended writing, complex reasoning, and similar tasks. During model selection, tasks should first be divided into “capability-sensitive” and “cost-sensitive” categories before discussing acceleration techniques.
2. Key Metrics for Local Inference: Do Not Look Only at tokens/s
A common mistake in evaluating local inference performance is to look only at average decoding throughput. In practice, interactive applications and batch applications have different priorities:
- Time to first token (TTFT): affects the user’s initial perceived speed and is influenced by prefill computation and memory bandwidth.
- Time per output token (TPOT): affects streaming output smoothness and is a core metric in the decoding stage.
- Average decoding throughput: suitable for batch processing, offline generation, and throughput-oriented services.
- P50/P95 latency: averages can hide long-tail jitter, so production environments must examine percentiles.
- Memory footprint and peak memory: on unified-memory devices, model weights, KV cache, and runtime buffers share physical memory; peak memory determines the concurrency ceiling.
- Acceptance rate and verification cost: the key to speculative decoding is not “guessing more” but “guessing accurately and verifying cheaply.”
If an acceleration scheme improves average throughput but worsens P95 latency, it may not be suitable for interactive scenarios. Conversely, some schemes may regress on open-ended writing tasks while delivering clear gains on code completion tasks. Therefore, evaluation must be layered by task and by metric.
3. Conditions Under Which Multi-Token Speculative Decoding Pays Off
The basic idea of multi-token prediction or speculative decoding is to use a smaller draft model or an internal multi-token prediction head to propose multiple candidate tokens at once, which are then verified in parallel by the main model. If the candidates are accepted, the number of serial decoding steps in the main model can be reduced. If the acceptance rate is low, verification overhead and extra memory access will offset the gains.
The benefit can be abstracted as:
Net benefit ≈ step reduction from accepted tokens − draft generation overhead − parallel verification overhead − extra memory access overhead
Therefore, speculative decoding is not unconditional acceleration. It is affected by at least the following factors:
- Acceptance rate: a higher acceptance rate reduces more serial steps, but tasks with high acceptance rates do not necessarily have low verification cost.
- Verification parallelism: when the main model verifies multiple candidates at once, verification cost rises linearly if hardware parallelism is insufficient.
- Memory bandwidth: on unified-memory devices, weight reads, KV cache access, and expert routing share bandwidth, and extra draft computation intensifies bandwidth contention.
- Batch size and concurrency: small-batch interactive scenarios may benefit from fewer serial steps, while large-batch throughput scenarios may see reduced gains due to verification amplification.
- Runtime implementation quality: scheduling, cache reuse, kernel fusion, and quantization strategy can significantly affect results.
- Task distribution: code, structured output, and retrieval-augmented Q&A often have strong patterns and higher acceptance rates; open-ended writing, multilingual tasks, and complex reasoning have greater candidate uncertainty.
4. Observations and Explanations on Unified-Memory Architectures
In public benchmark snippets, a representative phenomenon can be observed: when a ten-billion-parameter-class dense model enables two-token speculation, overall decoding throughput is about 0.87× the baseline, with an overall acceptance rate of about 0.64. However, differences across tasks are clear:
- Code tasks: throughput about 1.18×, acceptance rate about 0.76;
- Retrieval-augmented tasks: throughput about 0.98×, acceptance rate about 0.81;
- Math, Q&A, and multilingual tasks: throughput about 0.83–0.87×;
- Writing tasks: throughput about 0.74×, acceptance rate about 0.58;
- Reasoning and STEM tasks: throughput about 0.79–0.80×.
In another set of observations, a larger-scale MoE model under a similar multi-token speculative configuration showed essentially flat throughput on code tasks, latency of about 1.03×, and an acceptance rate of about 0.71. This suggests that on unified-memory devices, MoE models already have a good throughput baseline, and the marginal gains from speculative decoding may be offset by expert routing and verification overhead. Dense models have a simpler structure, so speculative decoding is more likely to achieve local gains on highly patterned tasks, but it may regress overall on open-ended tasks.
These data should be treated only as a method example and should not be directly extrapolated to all platforms, all quantized versions, and all prompt sets. Unified-memory bandwidth, cache hierarchy, runtime scheduling, and quantization format can all change the results. In engineering practice, acceptance rate and end-to-end latency should be recorded together rather than looking at acceptance rate alone.
5. A Selection Framework for Dense Models and MoE Models
On unified-memory devices, dense models and MoE models can be selected according to the following dimensions:
| Dimension | Mid-Scale Dense Model | Large-Scale MoE Model |
|---|---|---|
| Memory footprint | Relatively predictable and simple to deploy | Large total parameter count; expert caching and routing add complexity |
| Throughput stability | Relatively high, with smaller variation across tasks | Affected by expert routing and batch composition |
| Complex-task capability | Moderate; suitable for general production tasks | Usually stronger, but with higher cost |
| Speculative decoding benefit | May be clear on highly patterned tasks | Easily offset by routing and verification overhead |
| Operational complexity | Low | Medium to high; requires attention to expert caching and concurrency |
| Suitable scenarios | Local code, Q&A, summarization, private deployment | High capability requirements, sufficient bandwidth, acceptable higher memory |
A practical recommendation is as follows. If the goal is stable single-machine deployment, interactive code completion, or enterprise knowledge-base Q&A, start with a mid-scale dense model as the baseline, and then selectively enable speculative decoding for code and structured tasks. If the goal is high-capability open-ended generation and complex reasoning, and device memory bandwidth is sufficient, an MoE model can be evaluated, but its throughput and tail latency must be validated with real business prompt sets.
6. Engineering Deployment and Evaluation Recommendations
Building a reproducible evaluation process is more important than chasing a single speedup ratio. The following steps are recommended:
- Fix the baseline: disable speculative decoding and fix the quantization format, context length, batch size, temperature, top-p, maximum output length, and system load.
- Layer tasks: cover at least code, Q&A, math, reasoning, writing, multilingual, summarization, retrieval-augmented generation, and role-play dialogue.
- Record complete metrics: throughput, TTFT, TPOT, P50/P95 latency, peak memory, acceptance rate, and fallback count.
- Run small-traffic A/B tests: dynamically enable or disable speculative decoding by task to avoid global enablement causing regressions on open-ended tasks.
- Monitor drift: changes in prompt distribution alter acceptance rates, so real online requests should be continuously sampled.
- Keep a fallback strategy: automatically fall back to baseline decoding when the acceptance rate falls below a threshold or P95 latency exceeds the limit.
The following pseudocode can be used to organize experiments:
for suite in task_suites:for prompt in suite:for config in [baseline, speculative]:reset_cache()start = now()output = generate(prompt, config)elapsed = now() - startrecord(suite, config, tokens(output), elapsed, accept_rate)
The final conclusion should return to business goals. The value of mid-scale open-source models lies in covering a large number of local inference tasks at controllable cost. Multi-token speculative decoding is a conditional optimization, not a default requirement. On unified-memory devices, dense models and MoE models each have their own boundaries. Only by making task tiering, metric tiering, and fallback mechanisms solid can teams achieve a stable balance among capability, latency, and cost.
