Small Local LLM Benchmarking: Data Interpretation and Deployment Strategies
This article presents a practical benchmark of four small local LLM candidates—4B dense text, 8B dense text, a ~9.6GB mixture-of-experts multimodal model, and a 12B dense multimodal model—on a single machine with 8GB of VRAM. It interprets cold-start, load, generation, and VRAM results; provides a simple VRAM budgeting formula; highlights common chat-template and stopping-condition pitfalls; and recommends layered routing, quantization, and task-specific evaluation for local inference deployments.
Small Local LLM Benchmarking: Data Interpretation and Deployment Strategies
This article targets developers who need to run small local LLMs on a single machine or a single GPU. The candidates are four common lightweight models: a 4B-class dense text model, an 8B-class dense text model, a roughly 9.6GB mixture-of-experts (MoE) multimodal model, and a 12B-class dense multimodal model. All tests ran on the same local development machine with 8GB of dedicated VRAM, 64GB of host memory, and 32GB of memory assigned to a Linux-compatible environment. Inference used a quantized CPU/GPU mixed baseline. No self-compiled GPU acceleration backend was introduced initially—whether a usable GPU compilation toolchain is available can directly change conclusions, and this is a common pitfall when building your own comparison experiments.
1. Conclusion First: Where Each Model Fits
- If you only want one everyday text model locally, choose the 8B-class dense model. It is the most stable for Chinese long sentences and instruction following. After quantization, its resident VRAM is around 5GB, leaving room on an 8GB card for context caching.
- For lightweight classification, title generation, short-text rewriting, and intent recognition, choose the 4B-class dense model. Its resident VRAM is under 3GB, and its cold start is the fastest. It works well as a small node in a pipeline called at high frequency.
- For reading images, screenshots, and explaining charts, choose the ~9.6GB MoE multimodal model. Its activated parameter count is much smaller than its total parameter count. In testing, it was the fastest of the four for generation, while using only a little over 3GB of VRAM.
- For occasional complex visual understanding, the 12B-class dense multimodal model provides more detailed descriptions, but its speed and cold-start cost are noticeable. It is better suited as an escalation path for difficult tasks, not as the default choice.
2. First-Round Benchmark Data and Interpretation
| Candidate | Disk size | Cold load | Warm load | Generation speed | Resident VRAM | Positioning |
|---|---|---|---|---|---|---|
| 4B dense | ~2.5GB | ~12s | 0.13–0.16s | 38–43 tok/s | 2.7–2.8GB | Lightweight task node |
| 8B dense | ~5.2GB | ~17s | ~0.23s | 22–26 tok/s | ~4.9GB | Main everyday Chinese text model |
| MoE multimodal | ~9.6GB | ~14s | 0.66–0.72s | 54–56 tok/s | ~3.1GB | Multimodal value option |
| 12B dense multimodal | ~11GB+ | Clearly longer | Higher | Noticeable drop | Beyond comfortable range | Occasional complex vision |
This table clarifies three points:
- Disk size and VRAM usage are not proportional. The MoE structure places total parameters into about 9.6GB of weights, but only a small subset of experts is activated for each token. As a result, its VRAM usage and speed are better than those of dense models with a similar weight size. When selecting a model, activated parameter count is more informative than total parameter count.
- Cold start and warm start are two different worlds. The first load requires reading weights from disk into VRAM, and tens of seconds is normal. Once the model is resident, warm reload can drop to sub-second levels. If your usage pattern is “occasional queries followed by long idle periods,” cold starts may be triggered repeatedly. In that case, trading VRAM for a resident model is worthwhile.
- Throughput and quality often trade off against each other. The 8B dense model is more stable in Chinese expression, but its speed is roughly half that of the 4B model. This is not a defect; it is a normal tradeoff between accuracy and latency.
3. VRAM Budget: A Simple Estimation Method
A rough formula is enough for model selection:
VRAM ≈ parameter_count(B) × bytes_per_parameter + KV Cache + runtime overhead16-bit ≈ 2 bytes; 8-bit ≈ 1 byte; 4-bit ≈ 0.5 byte (including dequantization headroom)KV Cache ≈ 2 × num_layers × hidden_size × context_length × bytes_per_value
Take a 4-bit quantized 8B model as an example. Its weights are roughly 4.5–5GB. Adding KV Cache and runtime overhead, the measured resident VRAM was around 4.9GB. Models like this can still fit contexts longer than 8K tokens on an 8GB GPU. On a 4GB GPU, you would need to lower quantization, shorten context length, or offload some layers to CPU—the last option usually creates a clear speed cliff.
4. The Most Overlooked Pitfall: Chat Templates and Stop Conditions
Many real-world local deployment failures are not caused by the model being “not smart enough,” but by template mismatch. Common symptoms include special separators appearing in replies, the model asking and answering itself, repeating previous turns after multiple exchanges, or output stopping abruptly after reaching a certain length.
Troubleshooting checklist:
# Pseudocode: keep the template, stop sequences, and sampling parameters matched to the model weightsrequest = {"model": "local-chat-8b","messages": [{"role": "system", "content": "You are a concise technical assistant"},{"role": "user", "content": "Explain the role of KV Cache"},],"temperature": 0.2, # Keep randomness low for factual tasks"top_p": 0.9,"max_tokens": 1024,"stop": ["<|endoftext|>", "<|im_end|>"], # Must match the model template}
Key points: the template should be driven by the custom template bundled with the model weights, not manually assembled prompts; set temperature to 0.1–0.3 for classification and extraction tasks, and relax it for creative tasks; also pay attention to tokenizer efficiency differences for Chinese. The same “1000 characters” can differ by hundreds of tokens across models, directly changing your cost and latency estimates.
5. Multimodal Capability: From “Can See” to “Good Enough”
Small multimodal models are usable for three types of tasks: OCR and structure restoration for interface screenshots and document images, reading trends and extreme values from charts, and explaining processes in diagrams. Their limits are also clear: they may miss characters in dense small text, misalign rows and columns in complex tables, and still struggle with fine-grained recognition that requires precise localization; such tasks remain a strength of 12B-class models.
A practical engineering approach is to make visual tasks two-stage. First, use the MoE multimodal model to produce a coarse description and region segmentation. Only when confidence is insufficient or the result needs to be archived should the task be escalated to a larger dense multimodal model. This preserves the quality ceiling while keeping the slow path limited to low-frequency scenarios.
6. Deployment and Invocation Strategy: Layered Routing Is the Key
A practical local inference topology:
routes:- name: classifymodel: local-text-4b # Always resident; sub-second responsetrigger: classification/extraction/short rewriting- name: chatmodel: local-chat-8b # Always resident; handles everyday Chinese conversationtrigger: general Q&A/long-text rewriting- name: vision_fastmodel: local-vlm-moe # On-demand; warm load is sub-secondtrigger: screenshots/charts/image descriptions- name: vision_hardmodel: local-vlm-12b # Low-frequency escalation; accepts second-level cold starttrigger: complex vision/archive-quality outputpolicies:keep_alive_minutes: 30 # Keep-alive window to avoid repeated cold startseviction: free VRAM using least-recently-used policycontext_max: 8192
Supporting engineering details: place a unified OpenAI-compatible interface layer in front of the inference service to hide backend differences; expose “routing decision + timeout fallback” to upper-layer applications so that one slow model does not drag down the whole chain; and feed VRAM usage, queue length, time-to-first-token, and end-to-end duration into monitoring and alerting rather than looking only at average latency.
If the service needs to move from a single machine to a shared team environment, a common approach is to containerize the inference layer and run it on a general-purpose container platform, store weights and artifacts in object storage with version management, and connect logs and metrics to logging and monitoring services. These correspond to general product categories on mainstream cloud platforms. Selection should focus on elasticity, isolation, and observability rather than a specific interface name.
7. Optimization and Tuning Checklist
- Prefer quantized formats over simply shrinking the model: 4-bit or 8-bit quantization usually retains most capabilities, and VRAM savings are linearly predictable.
- Use an inference backend with paged attention to manage KV Cache; this significantly reduces peak VRAM usage and fragmentation under long contexts.
- Set the context window according to actual business needs; do not max it out by default. The upper limit directly determines peak VRAM and tail latency.
- Before self-compiling a GPU acceleration backend, confirm that the GPU compilation toolchain and driver versions match; otherwise compilation may fail or silently fall back to the CPU path.
- Build a small evaluation set of 20–30 business cases, including Chinese ambiguous sentences, long-document extraction, and screenshot Q&A, and run accuracy and latency tests with a fixed script instead of changing models based on intuition.
- The measurements above are usability tests on a single machine under one environment and are not a universal benchmark. Conclusions should be recalibrated for your own hardware, concurrency, and task distribution.
8. Selection Matrix
| Your scenario | Recommended configuration | Reason |
|---|---|---|
| Single-machine Chinese everyday assistant | 8B dense + 4-bit quantized resident model | Most stable quality; 8GB VRAM can accommodate context |
| High-frequency lightweight processing pipeline | 4B dense resident model | Lowest latency and least VRAM usage |
| Screenshot/document/chart understanding | MoE multimodal model loaded on demand | Usable vision quality and fastest speed |
| Complex visual archiving tasks | 12B dense multimodal model with low-frequency invocation | Trades finer detail for time |
| When memory resources are constrained | 4B quantized model + short context | Remains usable with less than 4GB VRAM |
In short, selecting a small model is not about finding the one that is “smarter.” It is about balancing four constraints: VRAM, latency, context, and quality. First get the chat template and quantization working, then run a controlled evaluation with your own test set, and finally use routing to assign different capabilities to models of different sizes. This approach works for most local development machine scenarios.
