Commit
•
c767ad8
1
Parent(s):
061e2d4
Upload processor
Browse files- processor_config.json +4 -0
- special_tokens_map.json +1 -0
- tokenizer.json +8 -1
- tokenizer_config.json +1 -1
processor_config.json
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"chat_template": "{% for message in messages %}{% if message['role'] == 'user' %}{{ '[INST] ' }}{# Render all images first #}{% for content in message['content'] | selectattr('type', 'equalto', 'image') %}{{ '<image>\n' }}{% endfor %}{# Render all text next #}{% for content in message['content'] | selectattr('type', 'equalto', 'text') %}{{ content['text'] }}{% endfor %}{{' [/INST]' }}{% elif message['role'] == 'assistant' %}{{ ' ' + message['content'][0]['text'] + '<\\s> '}}{% else %}{{ raise_exception('Only user and assistant roles are supported!') }}{% endif %}{% endfor %}",
|
3 |
+
"processor_class": "LlavaNextVideoProcessor"
|
4 |
+
}
|
special_tokens_map.json
CHANGED
@@ -13,6 +13,7 @@
|
|
13 |
"rstrip": false,
|
14 |
"single_word": false
|
15 |
},
|
|
|
16 |
"unk_token": {
|
17 |
"content": "<unk>",
|
18 |
"lstrip": false,
|
|
|
13 |
"rstrip": false,
|
14 |
"single_word": false
|
15 |
},
|
16 |
+
"pad_token": "</s>",
|
17 |
"unk_token": {
|
18 |
"content": "<unk>",
|
19 |
"lstrip": false,
|
tokenizer.json
CHANGED
@@ -1,7 +1,14 @@
|
|
1 |
{
|
2 |
"version": "1.0",
|
3 |
"truncation": null,
|
4 |
-
"padding":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
"added_tokens": [
|
6 |
{
|
7 |
"id": 0,
|
|
|
1 |
{
|
2 |
"version": "1.0",
|
3 |
"truncation": null,
|
4 |
+
"padding": {
|
5 |
+
"strategy": "BatchLongest",
|
6 |
+
"direction": "Left",
|
7 |
+
"pad_to_multiple_of": null,
|
8 |
+
"pad_id": 2,
|
9 |
+
"pad_type_id": 0,
|
10 |
+
"pad_token": "</s>"
|
11 |
+
},
|
12 |
"added_tokens": [
|
13 |
{
|
14 |
"id": 0,
|
tokenizer_config.json
CHANGED
@@ -51,7 +51,7 @@
|
|
51 |
"eos_token": "</s>",
|
52 |
"legacy": true,
|
53 |
"model_max_length": 1000000000000000019884624838656,
|
54 |
-
"pad_token":
|
55 |
"padding_side": "left",
|
56 |
"processor_class": "LlavaNextVideoProcessor",
|
57 |
"sp_model_kwargs": {},
|
|
|
51 |
"eos_token": "</s>",
|
52 |
"legacy": true,
|
53 |
"model_max_length": 1000000000000000019884624838656,
|
54 |
+
"pad_token": "</s>",
|
55 |
"padding_side": "left",
|
56 |
"processor_class": "LlavaNextVideoProcessor",
|
57 |
"sp_model_kwargs": {},
|