Xenova HF Staff commited on
Commit
d421ac5
·
verified ·
1 Parent(s): 7baa6f7

Update tokenizer_config.json

Browse files
Files changed (1) hide show
  1. tokenizer_config.json +1 -1
tokenizer_config.json CHANGED
@@ -2080,7 +2080,7 @@
2080
  "<end_of_utterance>"
2081
  ],
2082
  "bos_token": "<|begin_of_text|>",
2083
- "chat_template": "{% set loop_messages = messages %}{% for message in loop_messages %}{% set content = '<|start_header_id|>' + message['role'] + '<|end_header_id|>\n\n'+ message['content'] | trim + '<|eot_id|>' %}{% if loop.index0 == 0 %}{% set content = bos_token + content %}{% endif %}{{ content }}{% endfor %}{{ '<|start_header_id|>assistant<|end_header_id|>\n\n' }}",
2084
  "clean_up_tokenization_spaces": true,
2085
  "eos_token": "<|end_of_text|>",
2086
  "legacy": false,
 
2080
  "<end_of_utterance>"
2081
  ],
2082
  "bos_token": "<|begin_of_text|>",
2083
+ "chat_template": "<|begin_of_text|>{% for message in messages %}{{message['role'].capitalize()}}{% if message['content'][0]['type'] == 'image' %}{{':'}}{% else %}{{': '}}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{line['text']}}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}<end_of_utterance>\n{% endfor %}{% if add_generation_prompt %}{{ 'Assistant:' }}{% endif %}",
2084
  "clean_up_tokenization_spaces": true,
2085
  "eos_token": "<|end_of_text|>",
2086
  "legacy": false,