A model's download size does not include all the memory needed for inference. LM Studio's CLI estimator previews model memory for a chosen context length and GPU offload setting before loading the weights.
Context buffers and runtime overhead can make memory requirements differ from the GGUF file size. The estimate is a planning figure rather than a measured allocation, so room for the operating system, other applications, and changing workloads still matters.
The CLI connects to a running LM Studio service under the account that owns the downloaded model. Headless Linux users need llmster and a downloaded GGUF model; a missing or incompatible engine is handled through runtime selection.
Steps to estimate LM Studio model memory before loading:
- List the downloaded language models to find your model's key. Example output:
$ lms ls --llm You have 1 models, taking up 397.81 MB of disk space. LLM PARAMS ARCH SIZE DEVICE qwen2.5-0.5b-instruct 0.5B Qwen2 397.81 MB Local
The LLM column supplies the model key. This entry is Qwen2.5 0.5B Instruct in Q4_K_M quantization; its listed size is disk space, not the estimated memory requirement. An empty list means a model must be downloaded before estimating it.
- Estimate memory for your model using its key in place of qwen2.5-0.5b-instruct and your intended context length and GPU offload setting. Example output:
$ lms load --estimate-only qwen2.5-0.5b-instruct \ --context-length 2048 --gpu off Model: qwen2.5-0.5b-instruct Context Length: 2,048 GPU Offload: 0% Estimated GPU Memory: 31.81 MiB Estimated Total Memory: 433.81 MiB Estimate: This model may be loaded based on your resource guardrails settings.–estimate-only prints the estimate without loading the model; omitting it performs a load. The 2048-token context keeps the context buffer modest, and –gpu off requests CPU-only placement. On systems with a supported GPU, –gpu 0.5 requests half the layers on the GPU and –gpu max requests full offload. The intended settings belong in the estimate because changing them can change memory requirements.
Related: LM Studio memory-estimator optionsEstimated Total Memory is the overall estimate, not an additional amount to add to Estimated GPU Memory. This CPU-only estimate still reports a nonzero GPU figure; it does not show measured GPU allocation or GPU execution. The output should show your chosen model, context length, and offload percentage above both memory fields. A guardrail message allowing the load is not a guarantee that inference will fit, and a warning about insufficient resources calls for a smaller model or a lower-memory configuration before loading. Memory figures vary by model, runtime, hardware, and settings.
Related: How to load a model with lms in LM Studio