Ollama with different lightweight data set

@amitmund July 28, 2026

technical dataset

qwen2.5-coder:3b

There are open-weights models specifically trained, dataset-filtered, and fine-tuned exclusively for coding, software engineering, DevOps (Linux/K8s/AWS), and technical systems.
ollama pull qwen2.5-coder:3b

Focus: Code generation, Python/Go/Bash scripting, Linux commands, Docker, Kubernetes manifests, AWS CLI, and debugging.

Why it fits: Extremely intelligent for its size, fast on CPU (~8–12 tokens/sec), and uses under 3.5 GB of RAM.


deepseek-coder:1.3b

ollama pull deepseek-coder:1.3b

Focus: Deeply trained on code repositories, technical documentation, and shell scripting.

Why it fits: Ultra-lightweight (~1 GB download) and runs at near real-time speed on a 4-core CPU.


codegemma:2b

ollama pull codegemma:2b

Focus: Google's lightweight open model fine-tuned strictly for coding tasks, fill-in-the-middle code completion, and natural language technical explanations.


How to Set It Up in Open WebUI

Once you run ollama pull qwen2.5-coder:3b,

it will automatically show up in your Open WebUI model selection dropdown at http://:3000. Y

ou can switch between general models like gemma4:e2b and coding models like qwen2.5-coder:3b anytime.


So, only when I switch between different models, in Open WebUI, it will use at that time?

Selecting a model in Open WebUI doesn't immediately load it into your system's RAM. The model is loaded into memory only when you send a prompt to it.

Here is how memory and resource management works under the hood:1

1. How Model Switching Works in Memory

When you switch between models (for example, from gemma4:e2b to qwen2.5-coder:3b):

Idle State: When you select a model in the dropdown, 0 MB of RAM is consumed for model weights.

First Prompt (Cold Start): The moment you hit Enter to send a query, Ollama reads the model file from disk into system RAM. This initial response takes a few extra seconds.

In-Memory Retention: Once loaded, the model stays pinned in RAM for 5 minutes by default. Subsequent messages respond instantly without reloading.

Auto-Unload: If you stop chatting for 5 minutes (or switch to another model and prompt it), Ollama automatically unloads the previous model from RAM to free up resources.


  1. Checking Active RAM Usage

You can verify what model is currently taking up RAM at any point by running this command in your Ubuntu terminal:

ollama ps

If a model is loaded, it shows the model name, size, and remaining time before auto-unload:

NAME               ID           SIZE     PROCESSOR    UNTIL
qwen2.5-coder:3b   a123456789   1.9 GB   100% CPU     4 minutes from now

If no model is currently running, the list will be empty, meaning full RAM is available for your OS and Open WebUI.


3. How to Instantly Free Up RAM

If you finish a chat session and want to immediately reclaim system memory without waiting for the 5-minute timeout, run:

ollama stop <model_name>

Example:

ollama stop gemma4:e2b

0 Likes
46 Views
0 Comments

Filters

No filters available for this view.

Reset All