hibo-mistral-7b-fc-v1.3 / tokenizer_config.json
thibaud-perrin's picture
Upload tokenizer
fec41af verified
raw
history blame
2.67 kB
{
"add_bos_token": true,
"add_eos_token": true,
"added_tokens_decoder": {
"0": {
"content": "<unk>",
"lstrip": false,
"normalized": false,
"rstrip": false,
"single_word": false,
"special": true
},
"1": {
"content": "<s>",
"lstrip": false,
"normalized": false,
"rstrip": false,
"single_word": false,
"special": true
},
"2": {
"content": "</s>",
"lstrip": false,
"normalized": false,
"rstrip": false,
"single_word": false,
"special": true
}
},
"additional_special_tokens": [],
"bos_token": "<s>",
"chat_template": "{% if messages[0]['role'] == 'system' %}{% set loop_messages = messages[1:] %}{% set system_message = messages[0]['content'] %}{% elif false == true and not '<<SYS>>' in messages[0]['content'] %}{% set loop_messages = messages %}{% set system_message = 'You are a helpful, respectful and honest assistant. Always answer as helpfully as possible, while being safe. Your answers should not include any harmful, unethical, racist, sexist, toxic, dangerous, or illegal content. Please ensure that your responses are socially unbiased and positive in nature.\n\nIf a question does not make any sense, or is not factually coherent, explain why instead of answering something not correct. If you don\\'t know the answer to a question, please don\\'t share false information.' %}{% else %}{% set loop_messages = messages %}{% set system_message = false %}{% endif %}{% for message in loop_messages %}{% if loop.index0 == 0 and system_message != false %}{% set content = '<<SYS>>\n' + system_message + '\n<</SYS>>\n\n' + message['content'] %}{% else %}{% set content = message['content'] %}{% endif %}{% if message['role'] == 'user' %} {% if loop.index0 == 0 and system_message != false %} {{ bos_token + '[INST] ' + content.strip() + ' [/INST]' }} {% else %} {{ '[INST] ' + content.strip() + ' [/INST]' }} {% endif %}{% elif message['role'] == 'assistant' %}{% if loop.last or loop_messages[loop.index0 + 1]['role'] != 'assistant' %}\n{{ '[ASST] ' + content.strip() + ' [/ASST]' + eos_token }}{% else %}\n{{ '[ASST] ' + content.strip() + ' [/ASST]' }}{% endif %}\n{% elif message['role'] == 'function_response' %}{{ '[FUNC] ' + content.strip() + ' [/FUNC]' }}{% endif %}{% endfor %}",
"clean_up_tokenization_spaces": false,
"eos_token": "</s>",
"legacy": true,
"model_max_length": 1000000000000000019884624838656,
"pad_token": "<unk>",
"sp_model_kwargs": {},
"spaces_between_special_tokens": false,
"tokenizer_class": "LlamaTokenizer",
"unk_token": "<unk>",
"use_default_system_prompt": false
}