RayNene commited on
Commit
844a9dd
·
verified ·
1 Parent(s): 676eeb2

Add 11 files

Browse files
.gitattributes CHANGED
@@ -33,3 +33,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ training-metrics.png filter=lfs diff=lfs merge=lfs -text
37
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,99 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: meta-llama/Llama-4-Scout-17B-16E-Instruct
3
+ library_name: peft
4
+ license: other
5
+ tags:
6
+ - lora
7
+ - peft
8
+ - adapter
9
+ - adaption
10
+ ---
11
+
12
+ # adaption_multi_agent_fraud_bench
13
+
14
+ ## Model Training
15
+
16
+ A LORA adapter for `meta-llama/Llama-4-Scout-17B-16E-Instruct`. This model was trained with SFT using [Adaption](https://adaptionlabs.ai)'s AutoScientist on the multi_agent_fraud_bench dataset.
17
+
18
+
19
+ ![Training metrics](training-metrics.png)
20
+
21
+ ### AutoScientist Config
22
+
23
+ ```json
24
+ {
25
+ "job_id": "76434061-b19d-478c-8444-b9665cf92c38",
26
+ "training_experiment_id": "c36f6473-f424-4138-ad1f-75db53d77e0c",
27
+ "original_model_name": "meta-llama/Llama-4-Scout-17B-16E-Instruct",
28
+ "trained_model_name": "adaption_multi_agent_fraud_bench",
29
+ "training_method": "sft",
30
+ "training_type": "lora",
31
+ "data_format": "chat",
32
+ "hyperparams": {
33
+ "lora": "true",
34
+ "lora_r": 64,
35
+ "n_evals": 5,
36
+ "n_epochs": 3,
37
+ "batch_size": "max",
38
+ "lora_alpha": 128,
39
+ "lora_dropout": 0,
40
+ "min_lr_ratio": 0.1,
41
+ "warmup_ratio": 0.1,
42
+ "weight_decay": 0.01,
43
+ "learning_rate": 0.0001,
44
+ "max_grad_norm": 1,
45
+ "base_model_size": "109B",
46
+ "train_on_inputs": "false",
47
+ "training_method": "sft",
48
+ "lr_scheduler_type": "cosine",
49
+ "scheduler_num_cycles": 0.5,
50
+ "lora_trainable_modules": "q_proj,k_proj,v_proj,o_proj,shared_expert.gate_proj,shared_expert.up_proj,shared_expert.down_proj,feed_forward.gate_proj,feed_forward.up_proj,feed_forward.down_proj"
51
+ }
52
+ }
53
+ ```
54
+
55
+ ## Training Data
56
+
57
+ The model was trained on 8,114 rows of adapted data with the following domain distribution: governance (35%), legal (30%), academic-education (15%), science (6%), marketing (5%), corporate-business (3%), medical (2%), personal-finance (1%), technology (1%), market-analysis (0%), writing-editing-communication (0%), architecture-design (0%), other (0%), career-workplace (0%), language (0%), hr (0%), logic (0%), culture (0%), religion (0%), roleplay (0%), news (0%), code (0%), dating (0%), how-to (0%), history (0%), data-analysis-visualization (0%).
58
+
59
+ ## Model Evaluation
60
+
61
+ The model was evaluated on an in-distribution held-out test set as well as a broader domain-specific test set to measure generalization.
62
+
63
+
64
+ ![Win rates](win-rates.png)
65
+
66
+
67
+ ## How to use
68
+
69
+ ```bash
70
+ pip install torch transformers peft
71
+ ```
72
+
73
+ ```python
74
+ import torch
75
+ from transformers import AutoModelForCausalLM, AutoTokenizer
76
+ from peft import PeftModel
77
+
78
+ BASE = "meta-llama/Llama-4-Scout-17B-16E-Instruct"
79
+ ADAPTER = "<this-repo-id>"
80
+
81
+ device = "cuda" if torch.cuda.is_available() else "cpu"
82
+ dtype = torch.float32 if device == "cpu" else torch.bfloat16
83
+
84
+ base = AutoModelForCausalLM.from_pretrained(BASE, dtype=dtype).to(device)
85
+ model = PeftModel.from_pretrained(base, ADAPTER)
86
+ # Optional: merge the LoRA weights into the base for faster inference
87
+ model = model.merge_and_unload()
88
+ model.eval()
89
+
90
+ tokenizer = AutoTokenizer.from_pretrained(BASE)
91
+ messages = [{"role": "user", "content": "Hello!"}]
92
+ text = tokenizer.apply_chat_template(
93
+ messages, tokenize=False, add_generation_prompt=True)
94
+ inputs = tokenizer(text, return_tensors="pt").to(device)
95
+
96
+ with torch.inference_mode():
97
+ out = model.generate(**inputs, max_new_tokens=512)
98
+ print(tokenizer.decode(out[0][inputs["input_ids"].shape[1]:], skip_special_tokens=True))
99
+ ```
adapter_config.json ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "alpha_pattern": {},
3
+ "auto_mapping": null,
4
+ "base_model_name_or_path": "togethercomputer/Llama-4-Scout-17B-16E-Instruct_bnb_4bit",
5
+ "bias": "none",
6
+ "corda_config": null,
7
+ "eva_config": null,
8
+ "exclude_modules": [],
9
+ "fan_in_fan_out": false,
10
+ "inference_mode": true,
11
+ "init_lora_weights": true,
12
+ "layer_replication": null,
13
+ "layers_pattern": null,
14
+ "layers_to_transform": null,
15
+ "loftq_config": {},
16
+ "lora_alpha": 128,
17
+ "lora_bias": false,
18
+ "lora_dropout": 0.0,
19
+ "megatron_config": null,
20
+ "megatron_core": "megatron.core",
21
+ "modules_to_save": null,
22
+ "peft_type": "LORA",
23
+ "r": 64,
24
+ "rank_pattern": {},
25
+ "revision": null,
26
+ "target_modules": [
27
+ "q_proj",
28
+ "o_proj",
29
+ "v_proj",
30
+ "feed_forward.down_proj",
31
+ "shared_expert.gate_proj",
32
+ "feed_forward.gate_proj",
33
+ "k_proj",
34
+ "feed_forward.up_proj",
35
+ "shared_expert.down_proj",
36
+ "shared_expert.up_proj"
37
+ ],
38
+ "task_type": "CAUSAL_LM",
39
+ "trainable_token_indices": null,
40
+ "use_dora": false,
41
+ "use_rslora": false
42
+ }
adapter_model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d875eec5b10b03b63078dd13749ee104225af7add97b06c8a6741ddd16db8921
3
+ size 893484120
chat_template.jinja ADDED
@@ -0,0 +1,123 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- bos_token }}
2
+ {%- if custom_tools is defined %}
3
+ {%- set tools = custom_tools %}
4
+ {%- endif %}
5
+ {%- if not tools_in_user_message is defined %}
6
+ {%- set tools_in_user_message = true %}
7
+ {%- endif %}
8
+ {%- if not date_string is defined %}
9
+ {%- if strftime_now is defined %}
10
+ {%- set date_string = strftime_now("%d %b %Y") %}
11
+ {%- else %}
12
+ {%- set date_string = "26 Jul 2024" %}
13
+ {%- endif %}
14
+ {%- endif %}
15
+ {%- if not tools is defined %}
16
+ {%- set tools = none %}
17
+ {%- endif %}
18
+
19
+ {#- This block extracts the system message, so we can slot it into the right place. #}
20
+ {%- if messages[0]['role'] == 'system' %}
21
+ {%- if messages[0]['content'] is string %}
22
+ {%- set system_message = messages[0]['content']|trim %}
23
+ {%- else %}
24
+ {#- FIXME: The processor requires an array, always. #}
25
+ {%- set system_message = messages[0]['content'][0]['text']|trim %}
26
+ {%- endif %}
27
+ {%- set messages = messages[1:] %}
28
+ {%- set user_supplied_system_message = true %}
29
+ {%- else %}
30
+ {%- set system_message = "" %}
31
+ {%- set user_supplied_system_message = false %}
32
+ {%- endif %}
33
+
34
+ {#- System message if the user supplied one #}
35
+ {%- if user_supplied_system_message %}
36
+ {{- "<|header_start|>system<|header_end|>\n\n" }}
37
+ {%- if tools is not none %}
38
+ {{- "Environment: ipython\n" }}
39
+ {%- endif %}
40
+ {%- if tools is not none and not tools_in_user_message %}
41
+ {{- "You have access to the following functions. To call a function, please respond with JSON for a function call." }}
42
+ {{- 'Respond in the format {"name": function name, "parameters": dictionary of argument name and its value}.' }}
43
+ {{- "Do not use variables.\n\n" }}
44
+ {%- for t in tools %}
45
+ {{- t | tojson(indent=4) }}
46
+ {{- "\n\n" }}
47
+ {%- endfor %}
48
+ {%- endif %}
49
+ {{- system_message }}
50
+ {{- "<|eot|>" }}
51
+ {%- endif %}
52
+
53
+ {#- Custom tools are passed in a user message with some extra guidance #}
54
+ {%- if tools_in_user_message and not tools is none %}
55
+ {#- Extract the first user message so we can plug it in here #}
56
+ {%- if messages | length != 0 %}
57
+ {%- set first_user_message = messages[0]['content']|trim %}
58
+ {%- set messages = messages[1:] %}
59
+ {%- else %}
60
+ {{- raise_exception("Cannot put tools in the first user message when there's no first user message!") }}
61
+ {%- endif %}
62
+ {{- '<|header_start|>user<|header_end|>\n\n' -}}
63
+ {{- "Given the following functions, please respond with a JSON for a function call " }}
64
+ {{- "with its proper arguments that best answers the given prompt.\n\n" }}
65
+ {{- 'Respond in the format {"name": function name, "parameters": dictionary of argument name and its value}.' }}
66
+ {{- "Do not use variables.\n\n" }}
67
+ {%- for t in tools %}
68
+ {{- t | tojson(indent=4) }}
69
+ {{- "\n\n" }}
70
+ {%- endfor %}
71
+ {{- first_user_message + "<|eot|>"}}
72
+ {%- endif %}
73
+
74
+ {%- for message in messages %}
75
+ {%- if not (message.role == 'ipython' or message.role == 'tool' or 'tool_calls' in message) %}
76
+ {{- '<|header_start|>' + message['role'] + '<|header_end|>\n\n' }}
77
+ {%- if message['content'] is string %}
78
+ {{- message['content'] }}
79
+ {%- else %}
80
+ {%- for content in message['content'] %}
81
+ {%- if content['type'] == 'image' %}
82
+ {{- '<|image|>' }}
83
+ {%- elif content['type'] == 'text' %}
84
+ {{- content['text'] }}
85
+ {%- endif %}
86
+ {%- endfor %}
87
+ {%- endif %}
88
+ {{- "<|eot|>" }}
89
+ {%- elif 'tool_calls' in message and message.tool_calls|length > 0 %}
90
+ {{- '<|header_start|>assistant<|header_end|>\n\n' -}}
91
+ {{- '<|python_start|>' }}
92
+ {%- if message['content'] is string %}
93
+ {{- message['content'] }}
94
+ {%- else %}
95
+ {%- for content in message['content'] %}
96
+ {%- if content['type'] == 'image' %}
97
+ {{- '<|image|>' }}
98
+ {%- elif content['type'] == 'text' %}
99
+ {{- content['text'] }}
100
+ {%- endif %}
101
+ {%- endfor %}
102
+ {%- endif %}
103
+ {{- '<|python_end|>' }}
104
+ {%- for tool_call in message.tool_calls %}
105
+ {{- '{"name": "' + tool_call.function.name + '", ' }}
106
+ {{- '"parameters": ' }}
107
+ {{- tool_call.function.arguments | tojson }}
108
+ {{- "}" }}
109
+ {%- endfor %}
110
+ {{- "<|eot|>" }}
111
+ {%- elif message.role == "tool" or message.role == "ipython" %}
112
+ {{- "<|header_start|>ipython<|header_end|>\n\n" }}
113
+ {%- if message.content is mapping or message.content is iterable %}
114
+ {{- message.content | tojson }}
115
+ {%- else %}
116
+ {{- message.content }}
117
+ {%- endif %}
118
+ {{- "<|eot|>" }}
119
+ {%- endif %}
120
+ {%- endfor %}
121
+ {%- if add_generation_prompt %}
122
+ {{- '<|header_start|>assistant<|header_end|>\n\n' }}
123
+ {%- endif %}
config.json ADDED
@@ -0,0 +1,215 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Llama4ForCausalLM"
4
+ ],
5
+ "attention_bias": false,
6
+ "attention_chunk_size": 8192,
7
+ "attention_dropout": 0.0,
8
+ "attn_scale": 0.1,
9
+ "attn_temperature_tuning": true,
10
+ "bos_token_id": 200000,
11
+ "cache_implementation": "hybrid",
12
+ "dtype": "bfloat16",
13
+ "eos_token_id": 200008,
14
+ "floor_scale": 8192,
15
+ "for_llm_compressor": false,
16
+ "head_dim": 128,
17
+ "hidden_act": "silu",
18
+ "hidden_size": 5120,
19
+ "initializer_range": 0.02,
20
+ "interleave_moe_layer_step": 1,
21
+ "intermediate_size": 8192,
22
+ "intermediate_size_mlp": 16384,
23
+ "layer_types": [
24
+ "chunked_attention",
25
+ "chunked_attention",
26
+ "chunked_attention",
27
+ "full_attention",
28
+ "chunked_attention",
29
+ "chunked_attention",
30
+ "chunked_attention",
31
+ "full_attention",
32
+ "chunked_attention",
33
+ "chunked_attention",
34
+ "chunked_attention",
35
+ "full_attention",
36
+ "chunked_attention",
37
+ "chunked_attention",
38
+ "chunked_attention",
39
+ "full_attention",
40
+ "chunked_attention",
41
+ "chunked_attention",
42
+ "chunked_attention",
43
+ "full_attention",
44
+ "chunked_attention",
45
+ "chunked_attention",
46
+ "chunked_attention",
47
+ "full_attention",
48
+ "chunked_attention",
49
+ "chunked_attention",
50
+ "chunked_attention",
51
+ "full_attention",
52
+ "chunked_attention",
53
+ "chunked_attention",
54
+ "chunked_attention",
55
+ "full_attention",
56
+ "chunked_attention",
57
+ "chunked_attention",
58
+ "chunked_attention",
59
+ "full_attention",
60
+ "chunked_attention",
61
+ "chunked_attention",
62
+ "chunked_attention",
63
+ "full_attention",
64
+ "chunked_attention",
65
+ "chunked_attention",
66
+ "chunked_attention",
67
+ "full_attention",
68
+ "chunked_attention",
69
+ "chunked_attention",
70
+ "chunked_attention",
71
+ "full_attention"
72
+ ],
73
+ "max_position_embeddings": 10485760,
74
+ "model_type": "llama4_text",
75
+ "moe_layers": [
76
+ 0,
77
+ 1,
78
+ 2,
79
+ 3,
80
+ 4,
81
+ 5,
82
+ 6,
83
+ 7,
84
+ 8,
85
+ 9,
86
+ 10,
87
+ 11,
88
+ 12,
89
+ 13,
90
+ 14,
91
+ 15,
92
+ 16,
93
+ 17,
94
+ 18,
95
+ 19,
96
+ 20,
97
+ 21,
98
+ 22,
99
+ 23,
100
+ 24,
101
+ 25,
102
+ 26,
103
+ 27,
104
+ 28,
105
+ 29,
106
+ 30,
107
+ 31,
108
+ 32,
109
+ 33,
110
+ 34,
111
+ 35,
112
+ 36,
113
+ 37,
114
+ 38,
115
+ 39,
116
+ 40,
117
+ 41,
118
+ 42,
119
+ 43,
120
+ 44,
121
+ 45,
122
+ 46,
123
+ 47
124
+ ],
125
+ "no_rope_layer_interval": 4,
126
+ "no_rope_layers": [
127
+ 1,
128
+ 1,
129
+ 1,
130
+ 0,
131
+ 1,
132
+ 1,
133
+ 1,
134
+ 0,
135
+ 1,
136
+ 1,
137
+ 1,
138
+ 0,
139
+ 1,
140
+ 1,
141
+ 1,
142
+ 0,
143
+ 1,
144
+ 1,
145
+ 1,
146
+ 0,
147
+ 1,
148
+ 1,
149
+ 1,
150
+ 0,
151
+ 1,
152
+ 1,
153
+ 1,
154
+ 0,
155
+ 1,
156
+ 1,
157
+ 1,
158
+ 0,
159
+ 1,
160
+ 1,
161
+ 1,
162
+ 0,
163
+ 1,
164
+ 1,
165
+ 1,
166
+ 0,
167
+ 1,
168
+ 1,
169
+ 1,
170
+ 0,
171
+ 1,
172
+ 1,
173
+ 1,
174
+ 0
175
+ ],
176
+ "num_attention_heads": 40,
177
+ "num_experts_per_tok": 1,
178
+ "num_hidden_layers": 48,
179
+ "num_key_value_heads": 8,
180
+ "num_local_experts": 16,
181
+ "output_router_logits": false,
182
+ "pad_token_id": 200018,
183
+ "quantization_config": {
184
+ "_load_in_4bit": true,
185
+ "_load_in_8bit": false,
186
+ "bnb_4bit_compute_dtype": "bfloat16",
187
+ "bnb_4bit_quant_storage": "bfloat16",
188
+ "bnb_4bit_quant_type": "nf4",
189
+ "bnb_4bit_use_double_quant": false,
190
+ "llm_int8_enable_fp32_cpu_offload": false,
191
+ "llm_int8_has_fp16_weight": false,
192
+ "llm_int8_skip_modules": null,
193
+ "llm_int8_threshold": 6.0,
194
+ "load_in_4bit": true,
195
+ "load_in_8bit": false,
196
+ "quant_method": "bitsandbytes"
197
+ },
198
+ "rms_norm_eps": 1e-05,
199
+ "rope_parameters": {
200
+ "factor": 16.0,
201
+ "high_freq_factor": 1.0,
202
+ "low_freq_factor": 1.0,
203
+ "original_max_position_embeddings": 8192,
204
+ "rope_theta": 500000.0,
205
+ "rope_type": "llama3"
206
+ },
207
+ "router_aux_loss_coef": 0.001,
208
+ "router_jitter_noise": 0.0,
209
+ "tie_word_embeddings": false,
210
+ "transformers_version": "5.13.0",
211
+ "use_cache": false,
212
+ "use_qk_norm": true,
213
+ "vocab_size": 202048,
214
+ "torch_dtype": "bfloat16"
215
+ }
special_tokens_map.json ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ {
2
+ "bos_token": "<|begin_of_text|>",
3
+ "eos_token": "<|eot|>",
4
+ "pad_token": "<|finetune_right_pad|>"
5
+ }
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:172c9eb4beafc72601690da3ccfcede5c2e6806a8d5ec1fca33e22acea8023a4
3
+ size 27948578
tokenizer_config.json ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "backend": "tokenizers",
3
+ "bos_token": "<|begin_of_text|>",
4
+ "clean_up_tokenization_spaces": false,
5
+ "eos_token": "<|eot|>",
6
+ "is_local": false,
7
+ "local_files_only": true,
8
+ "model_input_names": [
9
+ "input_ids",
10
+ "attention_mask"
11
+ ],
12
+ "model_max_length": 10485760,
13
+ "pad_token": "<|finetune_right_pad|>",
14
+ "padding_side": "right",
15
+ "processor_class": "Llama4Processor",
16
+ "tokenizer_class": "TokenizersBackend"
17
+ }
trainer_state.json ADDED
@@ -0,0 +1,515 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "best_global_step": null,
3
+ "best_metric": null,
4
+ "best_model_checkpoint": null,
5
+ "epoch": 3.0,
6
+ "eval_steps": 12,
7
+ "global_step": 63,
8
+ "is_hyper_param_search": false,
9
+ "is_local_process_zero": true,
10
+ "is_world_process_zero": true,
11
+ "log_history": [
12
+ {
13
+ "epoch": 0.047619047619047616,
14
+ "grad_norm": 7.683346271514893,
15
+ "learning_rate": 0.0,
16
+ "loss": 2.7236328125,
17
+ "step": 1
18
+ },
19
+ {
20
+ "epoch": 0.09523809523809523,
21
+ "grad_norm": 8.30794906616211,
22
+ "learning_rate": 1.4285714285714285e-05,
23
+ "loss": 2.80615234375,
24
+ "step": 2
25
+ },
26
+ {
27
+ "epoch": 0.14285714285714285,
28
+ "grad_norm": 8.94153881072998,
29
+ "learning_rate": 2.857142857142857e-05,
30
+ "loss": 3.1728515625,
31
+ "step": 3
32
+ },
33
+ {
34
+ "epoch": 0.19047619047619047,
35
+ "grad_norm": 7.938409328460693,
36
+ "learning_rate": 4.2857142857142856e-05,
37
+ "loss": 2.9375,
38
+ "step": 4
39
+ },
40
+ {
41
+ "epoch": 0.23809523809523808,
42
+ "grad_norm": 1.4468631744384766,
43
+ "learning_rate": 5.714285714285714e-05,
44
+ "loss": 1.834716796875,
45
+ "step": 5
46
+ },
47
+ {
48
+ "epoch": 0.2857142857142857,
49
+ "grad_norm": 2.7402069568634033,
50
+ "learning_rate": 7.142857142857143e-05,
51
+ "loss": 1.4140625,
52
+ "step": 6
53
+ },
54
+ {
55
+ "epoch": 0.3333333333333333,
56
+ "grad_norm": 2.0219361782073975,
57
+ "learning_rate": 8.571428571428571e-05,
58
+ "loss": 1.1376953125,
59
+ "step": 7
60
+ },
61
+ {
62
+ "epoch": 0.38095238095238093,
63
+ "grad_norm": 1.2759617567062378,
64
+ "learning_rate": 0.0001,
65
+ "loss": 0.978515625,
66
+ "step": 8
67
+ },
68
+ {
69
+ "epoch": 0.42857142857142855,
70
+ "grad_norm": 1.3914451599121094,
71
+ "learning_rate": 9.992920667580176e-05,
72
+ "loss": 0.91015625,
73
+ "step": 9
74
+ },
75
+ {
76
+ "epoch": 0.47619047619047616,
77
+ "grad_norm": 1.0541131496429443,
78
+ "learning_rate": 9.971704944519594e-05,
79
+ "loss": 0.894287109375,
80
+ "step": 10
81
+ },
82
+ {
83
+ "epoch": 0.5238095238095238,
84
+ "grad_norm": 0.7295523285865784,
85
+ "learning_rate": 9.936419583332062e-05,
86
+ "loss": 0.747314453125,
87
+ "step": 11
88
+ },
89
+ {
90
+ "epoch": 0.5714285714285714,
91
+ "grad_norm": 0.9586805701255798,
92
+ "learning_rate": 9.887175604818206e-05,
93
+ "loss": 0.73583984375,
94
+ "step": 12
95
+ },
96
+ {
97
+ "epoch": 0.6190476190476191,
98
+ "grad_norm": 0.9399129748344421,
99
+ "learning_rate": 9.82412794875295e-05,
100
+ "loss": 0.91162109375,
101
+ "step": 13
102
+ },
103
+ {
104
+ "epoch": 0.6666666666666666,
105
+ "grad_norm": 0.5930038690567017,
106
+ "learning_rate": 9.747474986387654e-05,
107
+ "loss": 0.665283203125,
108
+ "step": 14
109
+ },
110
+ {
111
+ "epoch": 0.7142857142857143,
112
+ "grad_norm": 0.6943517327308655,
113
+ "learning_rate": 9.657457896300791e-05,
114
+ "loss": 0.68115234375,
115
+ "step": 15
116
+ },
117
+ {
118
+ "epoch": 0.7142857142857143,
119
+ "eval_loss": 1.125,
120
+ "eval_runtime": 3.7655,
121
+ "eval_samples_per_second": 0.266,
122
+ "eval_steps_per_second": 0.266,
123
+ "step": 15
124
+ },
125
+ {
126
+ "epoch": 0.7619047619047619,
127
+ "grad_norm": 0.6625951528549194,
128
+ "learning_rate": 9.554359905560886e-05,
129
+ "loss": 0.820556640625,
130
+ "step": 16
131
+ },
132
+ {
133
+ "epoch": 0.8095238095238095,
134
+ "grad_norm": 0.7600706219673157,
135
+ "learning_rate": 9.438505398589392e-05,
136
+ "loss": 0.614013671875,
137
+ "step": 17
138
+ },
139
+ {
140
+ "epoch": 0.8571428571428571,
141
+ "grad_norm": 0.5712336301803589,
142
+ "learning_rate": 9.310258896527278e-05,
143
+ "loss": 0.68603515625,
144
+ "step": 18
145
+ },
146
+ {
147
+ "epoch": 0.9047619047619048,
148
+ "grad_norm": 0.6201907992362976,
149
+ "learning_rate": 9.17002391031667e-05,
150
+ "loss": 0.6240234375,
151
+ "step": 19
152
+ },
153
+ {
154
+ "epoch": 0.9523809523809523,
155
+ "grad_norm": 0.6295406818389893,
156
+ "learning_rate": 9.018241671106134e-05,
157
+ "loss": 0.636962890625,
158
+ "step": 20
159
+ },
160
+ {
161
+ "epoch": 1.0,
162
+ "grad_norm": 0.7266039252281189,
163
+ "learning_rate": 8.855389741974244e-05,
164
+ "loss": 0.641845703125,
165
+ "step": 21
166
+ },
167
+ {
168
+ "epoch": 1.0476190476190477,
169
+ "grad_norm": 0.6056920289993286,
170
+ "learning_rate": 8.681980515339464e-05,
171
+ "loss": 0.50732421875,
172
+ "step": 22
173
+ },
174
+ {
175
+ "epoch": 1.0952380952380953,
176
+ "grad_norm": 0.5053836107254028,
177
+ "learning_rate": 8.498559600784018e-05,
178
+ "loss": 0.4849853515625,
179
+ "step": 23
180
+ },
181
+ {
182
+ "epoch": 1.1428571428571428,
183
+ "grad_norm": 0.5425382256507874,
184
+ "learning_rate": 8.305704108364301e-05,
185
+ "loss": 0.560791015625,
186
+ "step": 24
187
+ },
188
+ {
189
+ "epoch": 1.1904761904761905,
190
+ "grad_norm": 0.6988992691040039,
191
+ "learning_rate": 8.104020832809127e-05,
192
+ "loss": 0.66650390625,
193
+ "step": 25
194
+ },
195
+ {
196
+ "epoch": 1.2380952380952381,
197
+ "grad_norm": 0.5177556872367859,
198
+ "learning_rate": 7.894144344319014e-05,
199
+ "loss": 1.3883743286132812,
200
+ "step": 26
201
+ },
202
+ {
203
+ "epoch": 1.2857142857142856,
204
+ "grad_norm": 0.6992603540420532,
205
+ "learning_rate": 7.67673499197358e-05,
206
+ "loss": 0.667724609375,
207
+ "step": 27
208
+ },
209
+ {
210
+ "epoch": 1.2857142857142856,
211
+ "eval_loss": 1.0234375,
212
+ "eval_runtime": 3.7364,
213
+ "eval_samples_per_second": 0.268,
214
+ "eval_steps_per_second": 0.268,
215
+ "step": 27
216
+ },
217
+ {
218
+ "epoch": 1.3333333333333333,
219
+ "grad_norm": 0.5518877506256104,
220
+ "learning_rate": 7.452476826029011e-05,
221
+ "loss": 0.6201171875,
222
+ "step": 28
223
+ },
224
+ {
225
+ "epoch": 1.380952380952381,
226
+ "grad_norm": 0.48834937810897827,
227
+ "learning_rate": 7.222075445642904e-05,
228
+ "loss": 0.59765625,
229
+ "step": 29
230
+ },
231
+ {
232
+ "epoch": 1.4285714285714286,
233
+ "grad_norm": 0.7777575254440308,
234
+ "learning_rate": 6.986255778798253e-05,
235
+ "loss": 0.549560546875,
236
+ "step": 30
237
+ },
238
+ {
239
+ "epoch": 1.4761904761904763,
240
+ "grad_norm": 0.5613299012184143,
241
+ "learning_rate": 6.745759801411822e-05,
242
+ "loss": 0.591552734375,
243
+ "step": 31
244
+ },
245
+ {
246
+ "epoch": 1.5238095238095237,
247
+ "grad_norm": 0.48722875118255615,
248
+ "learning_rate": 6.501344202803414e-05,
249
+ "loss": 0.4981689453125,
250
+ "step": 32
251
+ },
252
+ {
253
+ "epoch": 1.5714285714285714,
254
+ "grad_norm": 0.45788365602493286,
255
+ "learning_rate": 6.253778004871315e-05,
256
+ "loss": 0.47705078125,
257
+ "step": 33
258
+ },
259
+ {
260
+ "epoch": 1.619047619047619,
261
+ "grad_norm": 0.5666241645812988,
262
+ "learning_rate": 6.003840142464886e-05,
263
+ "loss": 0.628173828125,
264
+ "step": 34
265
+ },
266
+ {
267
+ "epoch": 1.6666666666666665,
268
+ "grad_norm": 0.49418237805366516,
269
+ "learning_rate": 5.752317012567363e-05,
270
+ "loss": 0.474609375,
271
+ "step": 35
272
+ },
273
+ {
274
+ "epoch": 1.7142857142857144,
275
+ "grad_norm": 0.6069824695587158,
276
+ "learning_rate": 5.500000000000001e-05,
277
+ "loss": 0.467041015625,
278
+ "step": 36
279
+ },
280
+ {
281
+ "epoch": 1.7619047619047619,
282
+ "grad_norm": 0.5141736268997192,
283
+ "learning_rate": 5.247682987432637e-05,
284
+ "loss": 0.596435546875,
285
+ "step": 37
286
+ },
287
+ {
288
+ "epoch": 1.8095238095238095,
289
+ "grad_norm": 0.49380624294281006,
290
+ "learning_rate": 4.9961598575351155e-05,
291
+ "loss": 0.4202880859375,
292
+ "step": 38
293
+ },
294
+ {
295
+ "epoch": 1.8571428571428572,
296
+ "grad_norm": 0.48107779026031494,
297
+ "learning_rate": 4.7462219951286867e-05,
298
+ "loss": 0.49169921875,
299
+ "step": 39
300
+ },
301
+ {
302
+ "epoch": 1.8571428571428572,
303
+ "eval_loss": 0.99609375,
304
+ "eval_runtime": 3.7334,
305
+ "eval_samples_per_second": 0.268,
306
+ "eval_steps_per_second": 0.268,
307
+ "step": 39
308
+ },
309
+ {
310
+ "epoch": 1.9047619047619047,
311
+ "grad_norm": 0.4944271743297577,
312
+ "learning_rate": 4.498655797196586e-05,
313
+ "loss": 0.435791015625,
314
+ "step": 40
315
+ },
316
+ {
317
+ "epoch": 1.9523809523809523,
318
+ "grad_norm": 0.46663668751716614,
319
+ "learning_rate": 4.2542401985881784e-05,
320
+ "loss": 0.45556640625,
321
+ "step": 41
322
+ },
323
+ {
324
+ "epoch": 2.0,
325
+ "grad_norm": 0.5421565175056458,
326
+ "learning_rate": 4.01374422120175e-05,
327
+ "loss": 0.4136962890625,
328
+ "step": 42
329
+ },
330
+ {
331
+ "epoch": 2.0476190476190474,
332
+ "grad_norm": 0.47634458541870117,
333
+ "learning_rate": 3.777924554357096e-05,
334
+ "loss": 0.3116455078125,
335
+ "step": 43
336
+ },
337
+ {
338
+ "epoch": 2.0952380952380953,
339
+ "grad_norm": 0.4998021125793457,
340
+ "learning_rate": 3.547523173970989e-05,
341
+ "loss": 0.36248779296875,
342
+ "step": 44
343
+ },
344
+ {
345
+ "epoch": 2.142857142857143,
346
+ "grad_norm": 0.6161043643951416,
347
+ "learning_rate": 3.323265008026421e-05,
348
+ "loss": 0.395263671875,
349
+ "step": 45
350
+ },
351
+ {
352
+ "epoch": 2.1904761904761907,
353
+ "grad_norm": 0.5737324357032776,
354
+ "learning_rate": 3.105855655680986e-05,
355
+ "loss": 0.4962158203125,
356
+ "step": 46
357
+ },
358
+ {
359
+ "epoch": 2.238095238095238,
360
+ "grad_norm": 0.45135700702667236,
361
+ "learning_rate": 2.8959791671908742e-05,
362
+ "loss": 1.2419204711914062,
363
+ "step": 47
364
+ },
365
+ {
366
+ "epoch": 2.2857142857142856,
367
+ "grad_norm": 0.6822405457496643,
368
+ "learning_rate": 2.6942958916356998e-05,
369
+ "loss": 0.49658203125,
370
+ "step": 48
371
+ },
372
+ {
373
+ "epoch": 2.3333333333333335,
374
+ "grad_norm": 0.6327748894691467,
375
+ "learning_rate": 2.501440399215983e-05,
376
+ "loss": 0.4644775390625,
377
+ "step": 49
378
+ },
379
+ {
380
+ "epoch": 2.380952380952381,
381
+ "grad_norm": 0.5168265104293823,
382
+ "learning_rate": 2.3180194846605367e-05,
383
+ "loss": 0.458740234375,
384
+ "step": 50
385
+ },
386
+ {
387
+ "epoch": 2.4285714285714284,
388
+ "grad_norm": 0.5705485939979553,
389
+ "learning_rate": 2.144610258025755e-05,
390
+ "loss": 0.402587890625,
391
+ "step": 51
392
+ },
393
+ {
394
+ "epoch": 2.4285714285714284,
395
+ "eval_loss": 0.99609375,
396
+ "eval_runtime": 3.7308,
397
+ "eval_samples_per_second": 0.268,
398
+ "eval_steps_per_second": 0.268,
399
+ "step": 51
400
+ },
401
+ {
402
+ "epoch": 2.4761904761904763,
403
+ "grad_norm": 0.616422176361084,
404
+ "learning_rate": 1.981758328893866e-05,
405
+ "loss": 0.4619140625,
406
+ "step": 52
407
+ },
408
+ {
409
+ "epoch": 2.5238095238095237,
410
+ "grad_norm": 0.5285511612892151,
411
+ "learning_rate": 1.8299760896833295e-05,
412
+ "loss": 0.39013671875,
413
+ "step": 53
414
+ },
415
+ {
416
+ "epoch": 2.571428571428571,
417
+ "grad_norm": 0.5321851968765259,
418
+ "learning_rate": 1.6897411034727218e-05,
419
+ "loss": 0.36767578125,
420
+ "step": 54
421
+ },
422
+ {
423
+ "epoch": 2.619047619047619,
424
+ "grad_norm": 0.5941992402076721,
425
+ "learning_rate": 1.5614946014106085e-05,
426
+ "loss": 0.4990234375,
427
+ "step": 55
428
+ },
429
+ {
430
+ "epoch": 2.6666666666666665,
431
+ "grad_norm": 0.5202521085739136,
432
+ "learning_rate": 1.4456400944391146e-05,
433
+ "loss": 0.3797607421875,
434
+ "step": 56
435
+ },
436
+ {
437
+ "epoch": 2.7142857142857144,
438
+ "grad_norm": 0.6072654724121094,
439
+ "learning_rate": 1.3425421036992098e-05,
440
+ "loss": 0.375,
441
+ "step": 57
442
+ },
443
+ {
444
+ "epoch": 2.761904761904762,
445
+ "grad_norm": 0.6598243713378906,
446
+ "learning_rate": 1.252525013612346e-05,
447
+ "loss": 0.496337890625,
448
+ "step": 58
449
+ },
450
+ {
451
+ "epoch": 2.8095238095238093,
452
+ "grad_norm": 0.5702089071273804,
453
+ "learning_rate": 1.1758720512470523e-05,
454
+ "loss": 0.3341064453125,
455
+ "step": 59
456
+ },
457
+ {
458
+ "epoch": 2.857142857142857,
459
+ "grad_norm": 0.550778329372406,
460
+ "learning_rate": 1.1128243951817937e-05,
461
+ "loss": 0.404296875,
462
+ "step": 60
463
+ },
464
+ {
465
+ "epoch": 2.9047619047619047,
466
+ "grad_norm": 0.5884420871734619,
467
+ "learning_rate": 1.0635804166679386e-05,
468
+ "loss": 0.3558349609375,
469
+ "step": 61
470
+ },
471
+ {
472
+ "epoch": 2.9523809523809526,
473
+ "grad_norm": 0.5809072256088257,
474
+ "learning_rate": 1.0282950554804085e-05,
475
+ "loss": 0.376708984375,
476
+ "step": 62
477
+ },
478
+ {
479
+ "epoch": 3.0,
480
+ "grad_norm": 0.6065093874931335,
481
+ "learning_rate": 1.0070793324198253e-05,
482
+ "loss": 0.31134033203125,
483
+ "step": 63
484
+ },
485
+ {
486
+ "epoch": 3.0,
487
+ "eval_loss": 0.984375,
488
+ "eval_runtime": 3.7577,
489
+ "eval_samples_per_second": 0.266,
490
+ "eval_steps_per_second": 0.266,
491
+ "step": 63
492
+ }
493
+ ],
494
+ "logging_steps": 1.0,
495
+ "max_steps": 63,
496
+ "num_input_tokens_seen": 0,
497
+ "num_train_epochs": 3,
498
+ "save_steps": 0,
499
+ "stateful_callbacks": {
500
+ "TrainerControl": {
501
+ "args": {
502
+ "should_epoch_stop": false,
503
+ "should_evaluate": false,
504
+ "should_log": false,
505
+ "should_save": true,
506
+ "should_training_stop": true
507
+ },
508
+ "attributes": {}
509
+ }
510
+ },
511
+ "total_flos": 1.0104242682923581e+18,
512
+ "train_batch_size": 1,
513
+ "trial_name": null,
514
+ "trial_params": null
515
+ }
training-metrics.png ADDED

Git LFS Details

  • SHA256: c25f2dbd86a3068d7f252090707d399f44335237b352a09ef506c9ec908eedcb
  • Pointer size: 131 Bytes
  • Size of remote file: 126 kB
win-rates.png ADDED