You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature] Unsloth studio Export chat configs to ollama #4660
first of all thanks to unsloth team for creating such lovely toy aka unsloth studio.
i have feature request . it will be good if there is export button in unsloth studio CHAT tab . once user fine tune model parameters then it will be nice to have those configs exported in format like Modelfile supported by Ollama. so that users can enjoying same response like unsloth studio chat in their fav local model managers like ollama etc
Checking appetite before building this (it's a year old with little traffic): the concrete shape would be an "Export to Ollama" action on a chat config that writes a Modelfile — FROM pointing at the exported GGUF, plus PARAMETER/SYSTEM/TEMPLATE lines derived from the config's sampling settings and system prompt — and optionally runs ollama create. The GGUF export side already exists; this is the Modelfile generation and wiring.
@danielhanchen is this something you'd take? If yes I'll scope and build it (it composes with the Ollama inventory work from #9237/#9988); if the answer is "not core", closing this issue is also a fine outcome and I'll drop it from my list.
I'm interested in a similar feature where I'd like to export the model settings to a simple llama.cpp models.ini file. I assume most of the groundwork would be the same?
Taking this as the second piece of a model-library series (first is #8798). Concrete shape, small: an "Export to Ollama" action on a chat configuration that writes a Modelfile next to the exported GGUF: FROM pointing at the GGUF, PARAMETER lines from the config's sampling settings (temperature, top_p, top_k, repeat_penalty, num_ctx), SYSTEM from the system prompt, and TEMPLATE only when the config overrides the chat template. The GGUF export already collects a Modelfile from the save path (core/export/export.py), so this builds on that rather than a new writer. ollama create stays a printed command, not something Studio runs, in the first cut. @vehystrix the same config-to-file step can emit a llama.cpp models.ini section; I'll keep the writer generic enough that a second format is one function.
@danielhanchen with #8798 closed as not planned, is a Modelfile export (FROM the exported GGUF, PARAMETER/SYSTEM from the chat config) still something you would take, or should this close with it? I will only build on a yes.
Thanks for the suggestion and sorry on the delay! We're going to close this one for now, since Ollama can run most GGUF models directly without a Modelfile:
ollama run hf.co/unsloth/Qwen3-8B-GGUF:UD-Q4_K_XL
Ollama picks the chat template from the metadata inside the GGUF, and many of our GGUF repos also ship params and template files that Ollama reads automatically, so you get our recommended sampling settings out of the box. To match the settings you tuned in Studio, you can set them inside an Ollama session and save them as your own model:
/set system You are a helpful assistant
/set parameter temperature 0.6
/set parameter top_p 0.95
/save my-model
Activity
Imagineer99 commentedon Mar 30, 2026
Thank you for the suggestion, nice idea. Exporting config to Ollama would be useful.
Probably low priority for now, but noted.
lonexreb commentedon Aug 31, 2026
Checking appetite before building this (it's a year old with little traffic): the concrete shape would be an "Export to Ollama" action on a chat config that writes a Modelfile —
FROMpointing at the exported GGUF, plusPARAMETER/SYSTEM/TEMPLATElines derived from the config's sampling settings and system prompt — and optionally runsollama create. The GGUF export side already exists; this is the Modelfile generation and wiring.@danielhanchen is this something you'd take? If yes I'll scope and build it (it composes with the Ollama inventory work from #9237/#9988); if the answer is "not core", closing this issue is also a fine outcome and I'll drop it from my list.
vehystrix commentedon Sep 4, 2026
I'm interested in a similar feature where I'd like to export the model settings to a simple llama.cpp models.ini file. I assume most of the groundwork would be the same?
lonexreb commentedon Sep 28, 2026
Taking this as the second piece of a model-library series (first is #8798). Concrete shape, small: an "Export to Ollama" action on a chat configuration that writes a Modelfile next to the exported GGUF:
FROMpointing at the GGUF,PARAMETERlines from the config's sampling settings (temperature, top_p, top_k, repeat_penalty, num_ctx),SYSTEMfrom the system prompt, andTEMPLATEonly when the config overrides the chat template. The GGUF export already collects a Modelfile from the save path (core/export/export.py), so this builds on that rather than a new writer.ollama createstays a printed command, not something Studio runs, in the first cut. @vehystrix the same config-to-file step can emit a llama.cppmodels.inisection; I'll keep the writer generic enough that a second format is one function.lonexreb commentedon Oct 10, 2026
@danielhanchen with #8798 closed as not planned, is a Modelfile export (FROM the exported GGUF, PARAMETER/SYSTEM from the chat config) still something you would take, or should this close with it? I will only build on a yes.
danielhanchen commentedon Oct 13, 2026
Thanks for the suggestion and sorry on the delay! We're going to close this one for now, since Ollama can run most GGUF models directly without a Modelfile:
Ollama picks the chat template from the metadata inside the GGUF, and many of our GGUF repos also ship
paramsandtemplatefiles that Ollama reads automatically, so you get our recommended sampling settings out of the box. To match the settings you tuned in Studio, you can set them inside an Ollama session and save them as your own model:The Hugging Face docs cover this in more detail: https://huggingface.co/docs/hub/ollama