Local Deployment and Capability Evaluation of Production-Grade Large Language Models
A practical framework for evaluating production-grade LLMs across both serving performance and task capability. This article examines reproducible benchmarks, throughput, concurrency, TTFT, memory constraints, SQL generation with tool-use loops, evaluation sensitivity, and optimization strategies for distinguishing models that merely run fast from those that reliably complete complex tasks.
Local Deployment and Capability Evaluation of Production-Grade Large Language Models
1. Why Production Models Should Be Evaluated Along Two Dimensions
Evaluating a production-grade large language model can easily become one-sided. One approach focuses only on the subjective experience of single-turn question answering. The other looks only at peak local inference throughput. The first cannot explain real-world behavior under concurrency, long inputs, or tool calls. The second may overlook task quality, resulting in a model that runs quickly but produces incorrect answers.
A more reliable approach is a two-axis evaluation framework:
- Performance: Can the model provide stable service with acceptable latency and cost?
- Capability: Can it complete structured tasks end to end and satisfy the evaluation criteria?
A sample local evaluation of a production model demonstrated why both dimensions are necessary. The model performed reasonably during single-request prefill, but exhibited significant queuing and throughput degradation as concurrency increased. On the task side, it achieved a high pass rate on simple questions, while complex tasks exposed systematic issues involving format precision, column-name matching, and business-logic interpretation.
Looking only at the overall score could lead to the conclusion that the model lacks capability. A more detailed analysis showed that many failures were not caused by completely incorrect reasoning, but by mismatches between the output constraints and the evaluation criteria.
2. Designing the Evaluation Baseline: Environment, Metrics, and Criteria
The evaluation baseline must first be reproducible. Recommended records include:
- Model version
- Quantization method
- Inference server configuration
- GPU memory utilization
- Maximum number of concurrent sequences
- Maximum batch token count
- Input-length distribution
- Concurrency levels
- Evaluation-set categories
- Version of the evaluation script
Performance metrics should include at least:
- Prefill throughput in tokens per second
- Decode throughput in tokens per second
- Time to first token (TTFT)
- Throughput degradation under concurrency
- Latency changes for long inputs
- GPU memory and KV-cache usage
Capability metrics should cover:
- Pass rates by difficulty level
- Number of tool-calling steps
- Token consumption
- Structural error categories
- Formatting error categories
The evaluation criteria must be fixed in advance. The sample evaluation used strict matching: a task passed only when the number of rows, number of columns, column names, and first-row content all matched exactly. This approach is suitable for acceptance testing, but it also amplifies formatting differences.
When numerical tolerance was relaxed to 1e-6, the pass rate for the same set of tasks increased from 9/25 to approximately 22/25. This shows why an evaluation report should provide both a strict pass rate and a logical pass rate. Otherwise, a minor formatting mismatch may be misinterpreted as a major capability gap.
3. Local Inference Performance: Breaking Down Throughput, Concurrency, and Latency
3.1 Prefill: Usable with One Request, but Limited Scalability
In the sample evaluation, peak single-request prefill throughput was approximately 757.7 tok/s with a 4K input. Across input lengths from 2K to 32K tokens, throughput remained roughly between 629 and 758 tok/s, with no obvious degradation as input length increased.
This indicates that prefill computation was relatively stable for single-request workloads, and that long inputs did not cause significant deterioration in isolation.
However, performance declined rapidly as concurrency increased:
- Throughput decreased by approximately 30% to 45% at concurrency 2.
- It decreased by approximately 50% at concurrency 4.
- For a 2K input at concurrency 6, throughput fell from 688 tok/s to 228 tok/s, a decline of approximately 63%.
This type of degradation is usually not caused solely by insufficient compute capacity. It is more likely the result of scheduling configuration combined with contention between long prefill requests.
3.2 Decode: Stable with One Request, but Weak Under High Concurrency and Long Inputs
Single-request decode throughput remained stable at approximately 23.8 to 28.7 tok/s. As concurrency increased, decode throughput fell into the 8 to 18 tok/s range.
For 16K and 32K inputs at concurrency levels of 4 to 6, throughput briefly dropped to approximately 8 to 11 tok/s. Some 32K test points rebounded to 20 to 28 tok/s, but these were more likely to represent measurement noise than evidence that longer inputs perform better.
In production engineering, trends should therefore be confirmed through repeated runs and percentile-based statistics rather than interpreted from a single peak measurement.
3.3 TTFT: Increases with Input Length, with Queuing as the Main Cause
TTFT increased approximately linearly with input length. For a 32K input, it increased from 51.5 seconds at concurrency 1 to 186.4 seconds at concurrency 6.
The key issue was not simply that the model computed slowly, but that requests were queued. When the maximum number of concurrent sequences was configured as 2, requests beyond that limit entered a queue. Long prefill requests then blocked one another, significantly increasing TTFT.
In other words, throughput and latency must be evaluated together. Otherwise, a scheduling problem may be incorrectly attributed to the model itself.
3.4 Bottlenecks and Configuration Trade-Offs
The bottleneck analysis pointed primarily to inference-server configuration. The maximum number of concurrent sequences was too small, causing requests to queue whenever concurrency exceeded 2. Once long prefill requests began blocking one another, prefill throughput was shared across requests and TTFT deteriorated.
Potential improvements include increasing:
- The maximum number of concurrent sequences
- The maximum batch token count
These changes must be balanced against GPU memory usage. In the sample environment, memory utilization was approximately 0.91, and the KV cache was already close to capacity.
A safer approach is staged load testing:
- Fix the input length and gradually increase concurrency.
- Observe TTFT percentiles and throughput inflection points.
- Adjust the batch-processing limit.
- Identify the configuration range where throughput improves without allowing TTFT to become unstable.
4. Task Capability Evaluation: SQL Generation and Tool-Calling Loops
4.1 Test Stratification and the End-to-End Loop
The capability evaluation used 25 SQL-generation tasks divided into four difficulty levels: trivial, easy, medium, and hard.
The model was required to complete an autonomous tool-calling loop:
- Generate SQL.
- Execute it against an embedded analytical database.
- Read the results.
- Check whether the results satisfied the task description.
- Decide whether the query needed to be revised.
This closed loop is closer to a real data-development workflow than single-turn generation. It evaluates SQL syntax, multi-table relationship reasoning, window-function usage, result formatting, and error recovery at the same time.
4.2 Pass Rates Show That Simple Tasks Are Usable but Complex Tasks Are Unstable
The sample achieved an overall score of 9/25 passes, or 36.0%:
trivial: 8/8easy: 1/2medium: 0/2hard: 0/13
All trivial tasks passed, indicating that the basic SQL generation and execution loop was functional. However, none of the complex tasks passed, showing that the main difficulties were concentrated in tasks involving complex structures, implicit requirements, and strict output formats.
Hard tasks required an average of 6.1 steps. Some required as many as 17 steps and consumed approximately 55.5K tokens. This shows that the model was capable of making multiple attempts, but repeated attempts did not necessarily converge on the correct result.
4.3 Main Failure Modes: Formatting Precision and Structural Matching
The most prominent issue was ROUND precision. When the task required ROUND(...,2), the model often omitted the constraint. Because the strict evaluator required the first-row string to match exactly, approximately 15 of the 20 affected tasks failed due to a result that was logically correct but differed in formatting.
These failures should not simply be classified as computational inability. They indicate that output constraints were not sufficiently reinforced by the system prompt and the validator.
Other structural failures included:
- Incorrect final column names in queries using multiple tables and discount-related CTEs
- Window-function queries returning zero rows or using incorrect column names
- Incorrect share calculations caused by differences in channel definitions
These correspond to three different classes of problems:
- Column-name contract violations
- Window-function logic errors
- Business-definition and metric-interpretation errors
4.4 Token and Step Costs
Trivial and easy tasks required approximately two steps on average, with token consumption of roughly 2.2K plus 0.2K tokens. Hard tasks required an average of 6.1 steps, while some took 14 to 17 steps and consumed around 55K tokens.
This indicates that the primary cost of complex tasks does not come from a single generation. It comes from repeated execution and validation.
Evaluation reports should therefore present pass rate and cost per successful task together. Completing a task in two steps and completing it in 17 steps have very different implications for an online service, even when both ultimately pass.
5. Sensitivity to Evaluation Criteria
Strict evaluation is appropriate for acceptance testing, but it is less useful for diagnosing failure causes. A more informative evaluation can be divided into three layers:
- Structural correctness: number of rows, number of columns, and column names
- Logical correctness: numerical results within the permitted tolerance
- Formatting correctness:
ROUNDprecision, string formatting, and ordering
In the sample, the strict pass rate was 36%, while the logical pass rate increased to approximately 88% after precision tolerance was relaxed. This gap indicates that many failures were caused by violations of the formatting contract rather than a lack of computational capability.
Evaluation reports should therefore present the following separately:
- Strict pass rate
- Logical pass rate
- Formatting pass rate
Relying on a single score can easily lead to incorrect decisions.
6. Optimization Recommendations
Inference Service
On the inference-service side, jointly tune:
- The maximum number of concurrent sequences
- The batch token limit
- GPU memory utilization
First load-test the system to identify the TTFT inflection point. Then determine an appropriate throughput target based on the observed trade-off.
For long-input workloads, consider separate queues by input-length category to prevent long prefill requests from blocking short requests.
Task Capability
The system prompt should explicitly require strict compliance with:
ROUNDprecision- Column names
- Sort order
- Output format
The tool-calling loop should also include an automatic validator. After execution, validation can proceed in the following order:
- Check column names and row counts.
- Check numerical values against the permitted tolerance.
- Check formatting requirements.
For window-function tasks, providing example SQL as a few-shot constraint may reduce structural errors.
Evaluation Process
The evaluation process should:
- Fix the version of the evaluation script
- Record the number of steps for every task
- Record token consumption for every task
- Categorize the error type
- Maintain a regression baseline
This makes it possible to track whether later changes improve actual capability, reduce execution cost, or merely alter formatting behavior.
7. Conclusion
Production-grade large language models should not be evaluated only by peak throughput or by an aggregate task pass rate.
A more reliable approach is a two-dimensional framework:
- Performance: single-request capability, concurrency degradation, TTFT, and memory bottlenecks
- Capability: pass rates by difficulty, end-to-end tool calling, formatting contracts, and cost per successful task
The sample results show that single-request prefill and decode were usable, but concurrency scalability was constrained by scheduling configuration. The SQL-generation loop was basically functional, but complex tasks failed frequently because of formatting precision, column-name mismatches, and differences in business definitions.
Only by measuring “how fast the model runs” separately from “how reliably it produces the right result” can teams make production deployment decisions that are explainable, reproducible, and actionable.
