Upload final Fermata merged model
Browse files- chat_template.jinja +4 -47
- config.json +26 -53
- generation_config.json +2 -4
- model-00001-of-00003.safetensors +3 -0
- model-00002-of-00003.safetensors +3 -0
- model-00003-of-00003.safetensors +3 -0
- model.safetensors.index.json +0 -0
- special_tokens_map.json +4 -3
- tokenizer.json +2 -2
- tokenizer.model +2 -2
- tokenizer_config.json +0 -0
chat_template.jinja
CHANGED
|
@@ -1,47 +1,4 @@
|
|
| 1 |
-
{{ bos_token }}
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
' -%}
|
| 7 |
-
{%- else -%}
|
| 8 |
-
{%- set first_user_prefix = messages[0]['content'][0]['text'] + '
|
| 9 |
-
|
| 10 |
-
' -%}
|
| 11 |
-
{%- endif -%}
|
| 12 |
-
{%- set loop_messages = messages[1:] -%}
|
| 13 |
-
{%- else -%}
|
| 14 |
-
{%- set first_user_prefix = "" -%}
|
| 15 |
-
{%- set loop_messages = messages -%}
|
| 16 |
-
{%- endif -%}
|
| 17 |
-
{%- for message in loop_messages -%}
|
| 18 |
-
{%- if (message['role'] == 'user') != (loop.index0 % 2 == 0) -%}
|
| 19 |
-
{{ raise_exception("Conversation roles must alternate user/assistant/user/assistant/...") }}
|
| 20 |
-
{%- endif -%}
|
| 21 |
-
{%- if (message['role'] == 'assistant') -%}
|
| 22 |
-
{%- set role = "model" -%}
|
| 23 |
-
{%- else -%}
|
| 24 |
-
{%- set role = message['role'] -%}
|
| 25 |
-
{%- endif -%}
|
| 26 |
-
{{ '<start_of_turn>' + role + '
|
| 27 |
-
' + (first_user_prefix if loop.first else "") }}
|
| 28 |
-
{%- if message['content'] is string -%}
|
| 29 |
-
{{ message['content'] | trim }}
|
| 30 |
-
{%- elif message['content'] is iterable -%}
|
| 31 |
-
{%- for item in message['content'] -%}
|
| 32 |
-
{%- if item['type'] == 'image' -%}
|
| 33 |
-
{{ '<start_of_image>' }}
|
| 34 |
-
{%- elif item['type'] == 'text' -%}
|
| 35 |
-
{{ item['text'] | trim }}
|
| 36 |
-
{%- endif -%}
|
| 37 |
-
{%- endfor -%}
|
| 38 |
-
{%- else -%}
|
| 39 |
-
{{ raise_exception("Invalid content type") }}
|
| 40 |
-
{%- endif -%}
|
| 41 |
-
{{ '<end_of_turn>
|
| 42 |
-
' }}
|
| 43 |
-
{%- endfor -%}
|
| 44 |
-
{%- if add_generation_prompt -%}
|
| 45 |
-
{{'<start_of_turn>model
|
| 46 |
-
'}}
|
| 47 |
-
{%- endif -%}
|
|
|
|
| 1 |
+
{{ bos_token }}{% if messages[0]['role'] == 'system' %}{{ raise_exception('System role not supported') }}{% endif %}{% for message in messages %}{% if (message['role'] == 'user') != (loop.index0 % 2 == 0) %}{{ raise_exception('Conversation roles must alternate user/assistant/user/assistant/...') }}{% endif %}{% if (message['role'] == 'assistant') %}{% set role = 'model' %}{% else %}{% set role = message['role'] %}{% endif %}{{ '<start_of_turn>' + role + '
|
| 2 |
+
' + message['content'] | trim + '<end_of_turn>
|
| 3 |
+
' }}{% endfor %}{% if add_generation_prompt %}{{'<start_of_turn>model
|
| 4 |
+
'}}{% endif %}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
config.json
CHANGED
|
@@ -1,62 +1,35 @@
|
|
| 1 |
{
|
| 2 |
"architectures": [
|
| 3 |
-
"
|
| 4 |
],
|
| 5 |
-
"
|
| 6 |
-
"
|
|
|
|
|
|
|
|
|
|
| 7 |
"eos_token_id": [
|
| 8 |
1,
|
| 9 |
-
|
| 10 |
],
|
| 11 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
"initializer_range": 0.02,
|
| 13 |
-
"
|
| 14 |
-
"
|
| 15 |
-
"
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
"initializer_range": 0.02,
|
| 25 |
-
"intermediate_size": 10240,
|
| 26 |
-
"max_position_embeddings": 131072,
|
| 27 |
-
"model_type": "gemma3_text",
|
| 28 |
-
"num_attention_heads": 8,
|
| 29 |
-
"num_hidden_layers": 34,
|
| 30 |
-
"num_key_value_heads": 4,
|
| 31 |
-
"query_pre_attn_scalar": 256,
|
| 32 |
-
"rms_norm_eps": 1e-06,
|
| 33 |
-
"rope_local_base_freq": 10000.0,
|
| 34 |
-
"rope_scaling": {
|
| 35 |
-
"factor": 8.0,
|
| 36 |
-
"rope_type": "linear"
|
| 37 |
-
},
|
| 38 |
-
"rope_theta": 1000000.0,
|
| 39 |
-
"sliding_window": 1024,
|
| 40 |
-
"sliding_window_pattern": 6,
|
| 41 |
-
"torch_dtype": "float32",
|
| 42 |
-
"use_cache": true,
|
| 43 |
-
"vocab_size": 262208
|
| 44 |
-
},
|
| 45 |
"torch_dtype": "float32",
|
| 46 |
"transformers_version": "4.52.4",
|
| 47 |
-
"
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
"hidden_size": 1152,
|
| 51 |
-
"image_size": 896,
|
| 52 |
-
"intermediate_size": 4304,
|
| 53 |
-
"layer_norm_eps": 1e-06,
|
| 54 |
-
"model_type": "siglip_vision_model",
|
| 55 |
-
"num_attention_heads": 16,
|
| 56 |
-
"num_channels": 3,
|
| 57 |
-
"num_hidden_layers": 27,
|
| 58 |
-
"patch_size": 14,
|
| 59 |
-
"torch_dtype": "float32",
|
| 60 |
-
"vision_use_head": false
|
| 61 |
-
}
|
| 62 |
-
}
|
|
|
|
| 1 |
{
|
| 2 |
"architectures": [
|
| 3 |
+
"Gemma2ForCausalLM"
|
| 4 |
],
|
| 5 |
+
"attention_bias": false,
|
| 6 |
+
"attention_dropout": 0.0,
|
| 7 |
+
"attn_logit_softcapping": 50.0,
|
| 8 |
+
"bos_token_id": 2,
|
| 9 |
+
"cache_implementation": "hybrid",
|
| 10 |
"eos_token_id": [
|
| 11 |
1,
|
| 12 |
+
107
|
| 13 |
],
|
| 14 |
+
"final_logit_softcapping": 30.0,
|
| 15 |
+
"head_dim": 256,
|
| 16 |
+
"hidden_act": "gelu_pytorch_tanh",
|
| 17 |
+
"hidden_activation": "gelu_pytorch_tanh",
|
| 18 |
+
"hidden_size": 2304,
|
| 19 |
"initializer_range": 0.02,
|
| 20 |
+
"intermediate_size": 9216,
|
| 21 |
+
"max_position_embeddings": 8192,
|
| 22 |
+
"model_type": "gemma",
|
| 23 |
+
"num_attention_heads": 8,
|
| 24 |
+
"num_hidden_layers": 26,
|
| 25 |
+
"num_key_value_heads": 4,
|
| 26 |
+
"pad_token_id": 0,
|
| 27 |
+
"query_pre_attn_scalar": 256,
|
| 28 |
+
"rms_norm_eps": 1e-06,
|
| 29 |
+
"rope_theta": 10000.0,
|
| 30 |
+
"sliding_window": 4096,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
"torch_dtype": "float32",
|
| 32 |
"transformers_version": "4.52.4",
|
| 33 |
+
"use_cache": true,
|
| 34 |
+
"vocab_size": 256000
|
| 35 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
generation_config.json
CHANGED
|
@@ -1,13 +1,11 @@
|
|
| 1 |
{
|
|
|
|
| 2 |
"bos_token_id": 2,
|
| 3 |
"cache_implementation": "hybrid",
|
| 4 |
-
"do_sample": true,
|
| 5 |
"eos_token_id": [
|
| 6 |
1,
|
| 7 |
-
|
| 8 |
],
|
| 9 |
"pad_token_id": 0,
|
| 10 |
-
"top_k": 64,
|
| 11 |
-
"top_p": 0.95,
|
| 12 |
"transformers_version": "4.52.4"
|
| 13 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"_from_model_config": true,
|
| 3 |
"bos_token_id": 2,
|
| 4 |
"cache_implementation": "hybrid",
|
|
|
|
| 5 |
"eos_token_id": [
|
| 6 |
1,
|
| 7 |
+
107
|
| 8 |
],
|
| 9 |
"pad_token_id": 0,
|
|
|
|
|
|
|
| 10 |
"transformers_version": "4.52.4"
|
| 11 |
}
|
model-00001-of-00003.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6a8339594916df49ff610af8375cd8c3a4db1ed963e69a8806ec2c66c983c971
|
| 3 |
+
size 4992576136
|
model-00002-of-00003.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6cef4f7bb067b77727fb1de968246c9f34d9996cfbf5825c62932a18946f03aa
|
| 3 |
+
size 4983443424
|
model-00003-of-00003.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:13a4f55cec0827b32710551e5fb86a364b283db9cc780e12f98166e7b5f445a4
|
| 3 |
+
size 481381384
|
model.safetensors.index.json
CHANGED
|
The diff for this file is too large to render.
See raw diff
|
|
|
special_tokens_map.json
CHANGED
|
@@ -1,5 +1,8 @@
|
|
| 1 |
{
|
| 2 |
-
"
|
|
|
|
|
|
|
|
|
|
| 3 |
"bos_token": {
|
| 4 |
"content": "<bos>",
|
| 5 |
"lstrip": false,
|
|
@@ -7,7 +10,6 @@
|
|
| 7 |
"rstrip": false,
|
| 8 |
"single_word": false
|
| 9 |
},
|
| 10 |
-
"eoi_token": "<end_of_image>",
|
| 11 |
"eos_token": {
|
| 12 |
"content": "<eos>",
|
| 13 |
"lstrip": false,
|
|
@@ -15,7 +17,6 @@
|
|
| 15 |
"rstrip": false,
|
| 16 |
"single_word": false
|
| 17 |
},
|
| 18 |
-
"image_token": "<image_soft_token>",
|
| 19 |
"pad_token": {
|
| 20 |
"content": "<pad>",
|
| 21 |
"lstrip": false,
|
|
|
|
| 1 |
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
"<start_of_turn>",
|
| 4 |
+
"<end_of_turn>"
|
| 5 |
+
],
|
| 6 |
"bos_token": {
|
| 7 |
"content": "<bos>",
|
| 8 |
"lstrip": false,
|
|
|
|
| 10 |
"rstrip": false,
|
| 11 |
"single_word": false
|
| 12 |
},
|
|
|
|
| 13 |
"eos_token": {
|
| 14 |
"content": "<eos>",
|
| 15 |
"lstrip": false,
|
|
|
|
| 17 |
"rstrip": false,
|
| 18 |
"single_word": false
|
| 19 |
},
|
|
|
|
| 20 |
"pad_token": {
|
| 21 |
"content": "<pad>",
|
| 22 |
"lstrip": false,
|
tokenizer.json
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5f7eee611703c5ce5d1eee32d9cdcfe465647b8aff0c1dfb3bed7ad7dbb05060
|
| 3 |
+
size 34362873
|
tokenizer.model
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:61a7b147390c64585d6c3543dd6fc636906c9af3865a5548f27f31aee1d4c8e2
|
| 3 |
+
size 4241003
|
tokenizer_config.json
CHANGED
|
The diff for this file is too large to render.
See raw diff
|
|
|