Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.
Python agentaichatgptdeepseekfine-tuninggemmaimage-generationllamallmllmsopenaipythonqwenreinforcement-learningself-hostedstable-diffusiontext-to-speechttsuiunsloth
Fix FastLanguageModel
Daniel Han-Chen75d1a0e2e177
diff --git a/unsloth/models/llama.py b/unsloth/models/llama.pyindex 590465ae888..de9666bca56 100644--- a/unsloth/models/llama.py+++ b/unsloth/models/llama.py@@ -609,7 +609,7 @@ class FastLlamaModel:@staticmethoddef from_pretrained(- model_name = "meta-llama/Llama-2-7b-hf",+ model_name = "unsloth/llama-2-7b-bnb-4bit",max_seq_length = 4096,dtype = None,load_in_4bit = True,diff --git a/unsloth/models/loader.py b/unsloth/models/loader.pyindex 0ace3f494d6..d4586263868 100644--- a/unsloth/models/loader.py+++ b/unsloth/models/loader.py@@ -17,10 +17,10 @@ from .mistral import FastMistralModelfrom transformers import AutoConfig-class FastLanguageModel:+class FastLanguageModel(FastLlamaModel):@staticmethoddef from_pretrained(- model_name = "mistralai/Mistral-7B-v0.1",+ model_name = "unsloth/mistral-7b-bnb-4bit",max_seq_length = 4096,dtype = None,load_in_4bit = True,diff --git a/unsloth/models/mistral.py b/unsloth/models/mistral.pyindex 865493edce4..826ec477896 100644--- a/unsloth/models/mistral.py+++ b/unsloth/models/mistral.py@@ -250,7 +250,7 @@ class FastMistralModel(FastLlamaModel):@staticmethoddef from_pretrained(- model_name = "mistralai/Mistral-7B-v0.1",+ model_name = "unsloth/mistral-7b-bnb-4bit",max_seq_length = 4096,dtype = None,load_in_4bit = True,