Merge branch 'main' into nightly

This commit is contained in:
Daniel Han 2025-02-15 03:12:52 -08:00
commit 007fb5b5e1
3 changed files with 34 additions and 4 deletions

View file

@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
__version__ = "2025.2.11"
__version__ = "2025.2.12"
__all__ = [
"SUPPORTS_BFLOAT16",

View file

@ -218,13 +218,25 @@ __INT_TO_FLOAT_MAPPER = \
"unsloth/Mistral-Nemo-Base-2407",
"mistralai/Mistral-Nemo-Base-2407",
),
"unsloth/Meta-Llama-3.1-8B-bnb-4bit" : (
"unsloth/Meta-Llama-3.1-8B-unsloth-bnb-4bit" : (
"unsloth/Meta-Llama-3.1-8B",
"meta-llama/Meta-Llama-3.1-8B",
"unsloth/Meta-Llama-3.1-8B-bnb-4bit",
),
"unsloth/Meta-Llama-3.1-8B-Instruct-bnb-4bit" : (
"unsloth/Meta-Llama-3.1-8B-Instruct-unsloth-bnb-4bit" : (
"unsloth/Meta-Llama-3.1-8B-Instruct",
"meta-llama/Meta-Llama-3.1-8B-Instruct",
"unsloth/Meta-Llama-3.1-8B-Instruct-bnb-4bit",
),
"unsloth/Llama-3.1-8B-unsloth-bnb-4bit" : (
"unsloth/Llama-3.1-8B",
"meta-llama/Llama-3.1-8B",
"unsloth/Llama-3.1-8B-bnb-4bit",
),
"unsloth/Llama-3.1-8B-Instruct-unsloth-bnb-4bit" : (
"unsloth/Llama-3.1-8B-Instruct",
"meta-llama/Llama-3.1-8B-Instruct",
"unsloth/Llama-3.1-8B-Instruct-bnb-4bit",
),
"unsloth/Meta-Llama-3.1-70B-bnb-4bit" : (
"unsloth/Meta-Llama-3.1-70B",
@ -589,6 +601,21 @@ __INT_TO_FLOAT_MAPPER = \
"Qwen/Qwen2.5-VL-72B-Instruct",
"unsloth/Qwen2.5-VL-72B-Instruct-bnb-4bit",
),
"unsloth/DeepHermes-3-Llama-3-8B-Preview-unsloth-bnb-4bit" : (
"unsloth/DeepHermes-3-Llama-3-8B-Preview",
"NousResearch/DeepHermes-3-Llama-3-8B-Preview",
"unsloth/DeepHermes-3-Llama-3-8B-Preview-bnb-4bit",
),
"unsloth/DeepScaleR-1.5B-Preview-unsloth-bnb-4bit" : (
"unsloth/DeepHermes-3-Llama-3-8B-Preview",
"agentica-org/DeepScaleR-1.5B-Preview",
"unsloth/DeepScaleR-1.5B-Preview-bnb-4bit",
),
"unsloth/OpenThinker-7B-unsloth-bnb-4bit" : (
"unsloth/OpenThinker-7B",
"open-thoughts/OpenThinker-7B",
"unsloth/OpenThinker-7B-bnb-4bit",
),
}
INT_TO_FLOAT_MAPPER = {}

View file

@ -259,6 +259,7 @@ pass
def assert_same_tokenization(slow_tokenizer, fast_tokenizer):
# Get eos_token, bos_token etc
if not hasattr(slow_tokenizer, "all_special_tokens"): return True
dir_names = dir(slow_tokenizer)
special_tokens = list(filter(None, (
getattr(slow_tokenizer, x) for x in dir_names
@ -503,12 +504,14 @@ def _load_correct_tokenizer(
cache_dir = cache_dir,
)
except:
pass
slow_tokenizer = None
# print(
# f"Unsloth: {tokenizer_name} has no tokenizer.model file.\n"\
# "Just informing you about this - this is not a critical error."
# )
pass
# Unsure why this occurs!
if type(slow_tokenizer) is bool: slow_tokenizer = None
fast_tokenizer = AutoTokenizer.from_pretrained(
tokenizer_name,