[GH-ISSUE #5788] Support LoRA GGUF Adapters #3606

Closed
opened 2026-04-12 14:21:20 -05:00 by GiteaMirror · 2 comments
Owner

Originally created by @suncloudsmoon on GitHub (Jul 19, 2024).
Original GitHub issue: https://github.com/ollama/ollama/issues/5788

Recently, llama.cpp added support for LoRA GGUF adapters, replacing the old GGML format. I would love to see this feature extended to Ollama if it's possible. Currently, Ollama only supports GGML adapters as shown in modelfile.md.

The ADAPTER instruction is an optional instruction that specifies any LoRA adapter that should apply to the base model. The value of this instruction should be an absolute path or a path relative to the Modelfile and the file must be in a GGML file format. The adapter should be tuned from the base model otherwise the behaviour is undefined.

Originally created by @suncloudsmoon on GitHub (Jul 19, 2024). Original GitHub issue: https://github.com/ollama/ollama/issues/5788 Recently, [llama.cpp added support for LoRA GGUF adapters](https://github.com/ggerganov/llama.cpp/pull/8332), replacing the old GGML format. I would love to see this feature extended to Ollama if it's possible. Currently, Ollama only supports GGML adapters as shown in [```modelfile.md```](https://github.com/ollama/ollama/blob/main/docs/modelfile.md#adapter). > The ADAPTER instruction is an optional instruction that specifies any LoRA adapter that should apply to the base model. The value of this instruction should be an absolute path or a path relative to the Modelfile and the file must be in a GGML file format. The adapter should be tuned from the base model otherwise the behaviour is undefined.
GiteaMirror added the feature request label 2026-04-12 14:21:20 -05:00
Author
Owner

@pdevine commented on GitHub (Sep 12, 2024):

It actually is supported! We've removed support for GGLA, but the ADAPTER command will work with both GGUF and Safetensors files. Check out the import docs

<!-- gh-comment-id:2347342520 --> @pdevine commented on GitHub (Sep 12, 2024): It actually is supported! We've removed support for GGLA, but the `ADAPTER` command will work with both GGUF and Safetensors files. Check out the [import docs](https://github.com/ollama/ollama/blob/main/docs/import.md#Importing-a-fine-tuned-adapter-from-Safetensors-weights)
Author
Owner

@rbrisita commented on GitHub (Sep 19, 2024):

Would be great if it was also a REPL command to dynamically load adapters so that the Modelfile and create command weren't needed.

<!-- gh-comment-id:2362212699 --> @rbrisita commented on GitHub (Sep 19, 2024): Would be great if it was also a REPL command to dynamically load adapters so that the Modelfile and `create` command weren't needed.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#3606