Ollama Tutorial
Ollama is an open-source framework designed to make it easy to deploy and run large language models (LLMs) directly on your local machine. It supports multiple operating systems, including macOS, Windows, Linux, and even Docker containers. One of its standout features is model quantization, which significantly reduces GPU memory requirements, making it possible to run large models on everyday home computers.
Who Is This Tutorial For?
Ollama is ideal for developers, researchers, and users with high data privacy requirements. It enables quick deployment and operation of large language models (LLMs) in a local environment, offering flexible customization options. With Ollama, you can run models like Llama 3.3, DeepSeek-R1, Phi-4, Mistral, Gemma 2, and others directly on your local machine.
What You Need to Know Before Starting This Tutorial?
This tutorial is designed for developers with a basic understanding of Python.
You should also be familiar with the difference between Docker images and containers, and know how to pull images from Docker Hub and run containers.
Additionally, a working knowledge of command-line tools (like Terminal or Command Prompt) is required. This includes basic operations such as creating, deleting, and moving files and directories, as well as running scripts and programs.
Creating a New Model
You can use the ollama create
command to build a model from a Modelfile.
1 | ollama create model -of ./Modelfile |
Useful Links
- Official Ollama Website: https://ollama.com/
- GitHub Repository: https://github.com/ollama/ollama
- Official Documentation: https://github.com/ollama/ollama/tree/main/docs
Table of Contents
>> Interacting with Ollama Models