prince-canuma commited on
Commit
51b178f
1 Parent(s): 738ec8a

Upload tokenizer

Browse files
Files changed (1) hide show
  1. tokenizer_config.json +2 -1
tokenizer_config.json CHANGED
@@ -302,10 +302,11 @@
302
  "auto_map": {
303
  "AutoTokenizer": [
304
  null,
305
- "tokenization_cohere_fast.CohereTokenizerFast"
306
  ]
307
  },
308
  "bos_token": "<BOS_TOKEN>",
 
309
  "clean_up_tokenization_spaces": false,
310
  "eos_token": "<|END_OF_TURN_TOKEN|>",
311
  "legacy": true,
 
302
  "auto_map": {
303
  "AutoTokenizer": [
304
  null,
305
+ "CohereForAI/c4ai-command-r-v01--tokenization_cohere_fast.CohereTokenizerFast"
306
  ]
307
  },
308
  "bos_token": "<BOS_TOKEN>",
309
+ "chat_template": "<BOS_TOKEN>{% if messages[0]['role'] == 'system' %}{% set loop_messages = messages[1:] %}{% set system_message = messages[0]['content'] %}{{ '<|START_OF_TURN_TOKEN|><|SYSTEM_TOKEN|>' + system_message + '<|END_OF_TURN_TOKEN|>' }}{% else %}{% set loop_messages = messages %}{% set system_message = false %}{% endif %}{% for message in loop_messages %}{% if (message['role'] == 'user') != (loop.index0 % 2 == 0) %}{{ raise_exception('Conversation roles must alternate user/assistant/user/assistant/...') }}{% endif %}{% if message.role == 'user' %}<|START_OF_TURN_TOKEN|><|USER_TOKEN|>{{ message.content }}<|END_OF_TURN_TOKEN|>\n{% elif message.role == 'assistant' %}<|START_OF_TURN_TOKEN|><|CHATBOT_TOKEN|>{{ message.content }}<|END_OF_TURN_TOKEN|>{% endif %}{% endfor %}{% if add_generation_prompt %}<|START_OF_TURN_TOKEN|><|CHATBOT_TOKEN|>{% endif %}",
310
  "clean_up_tokenization_spaces": false,
311
  "eos_token": "<|END_OF_TURN_TOKEN|>",
312
  "legacy": true,