This commit is contained in:
Daniel Han 2024-08-20 16:46:26 -07:00
commit 61528b59dc
2 changed files with 5 additions and 3 deletions

View file

@ -10,7 +10,7 @@
<a href="https://discord.gg/unsloth"><img src="https://raw.githubusercontent.com/unslothai/unsloth/main/images/Discord button.png" height="48"></a>
<a href="https://ko-fi.com/unsloth"><img src="https://raw.githubusercontent.com/unslothai/unsloth/main/images/buy me a coffee button.png" height="48"></a>
### Finetune Llama 3.1, Mistral, Phi-3 & Gemma 2-5x faster with 80% less memory!
### Finetune Llama 3.1, Mistral, Phi-3.5 & Gemma 2-5x faster with 80% less memory!
![](https://i.ibb.co/sJ7RhGG/image-41.png)

View file

@ -473,7 +473,7 @@ pass
# =========================================== Phi-3
phi3_template = \
"{{ bos_token }}"\
# "{{ bos_token }}"\ # Phi-3.5 removes BOS?
"{% for message in messages %}"\
"{% if message['role'] == 'user' %}"\
"{{'<|user|>\n' + message['content'] + '<|end|>\n'}}"\
@ -505,7 +505,9 @@ PARAMETER stop "<|assistant|>"
'''
phi3_template_eos_token = "<|end|>"
CHAT_TEMPLATES["phi-3"] = (phi3_template, phi3_template_eos_token, False, phi3_ollama,)
CHAT_TEMPLATES["phi-3"] = (phi3_template, phi3_template_eos_token, False, phi3_ollama,)
CHAT_TEMPLATES["phi-35"] = CHAT_TEMPLATES["phi-3"]
CHAT_TEMPLATES["phi-3.5"] = CHAT_TEMPLATES["phi-3"]
pass
# =========================================== Llama-3.1