Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Almawave/Velvet-14B #1627

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Update tokenizer_utils.py
add support for Almawave/Velvet-14B
  • Loading branch information
dtdxdydz authored Feb 6, 2025
commit 98bc2d141b1e293a833eb87c43c82a099937b407
7 changes: 7 additions & 0 deletions unsloth/tokenizer_utils.py
Original file line number Diff line number Diff line change
@@ -578,6 +578,13 @@ def load_correct_tokenizer(

chat_template = old_chat_template

# Also check models with <instruction> and </instruction> special tokens
elif old_chat_template is not None and \
"<instruction>" in old_chat_template and "</instruction>" in old_chat_template and \
"bos_token" in old_chat_template and "eos_token" in old_chat_template:

chat_template = old_chat_template

else:
chat_template = fix_chat_template(tokenizer)
if old_chat_template is not None and chat_template is None: