BRlkl commited on
Commit
8eeaccd
·
verified ·
1 Parent(s): 1276c89

Update workspace checkpoint for t5gemma2-thoughtloop-pre-sft-simple-transcript (step-100)

Browse files
.gitattributes CHANGED
@@ -33,3 +33,4 @@ 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
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
chat_template.jinja ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ {% 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 %}
initial_latent_z.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fb2c9bcc7af763f0e4c9682796d1498289b88d5ce41b6fda2454a881e50627c0
3
+ size 4194392
metrics.json ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ {
2
+ "phase_key": "simple_multiturn_transcript",
3
+ "global_step": 100,
4
+ "epoch": 1
5
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b35598815914f4c1f6e8971766057ba3d22f19e3e0bd8e224fbb95762bb764af
3
+ size 2521506792
sft_b200.yaml ADDED
@@ -0,0 +1,136 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ datasets:
2
+ - name: chatalpaca_multiturn_enriched
3
+ repo_id: BRlkl/chatalpaca-multiturn-enriched-2.1
4
+ source_split: train
5
+ format: messages_all_turns
6
+ validation_ratio: 0.005
7
+ split_seed: 17
8
+ min_turns: 2
9
+ max_turns: 7
10
+ max_message_chars: 6000
11
+ use_base_chat_template: true
12
+
13
+ model:
14
+ base_model_name: google/t5gemma-l-l-prefixlm-it
15
+ initial_model_path: BRlkl/test_multiturn_simple_transcript1024_6-checkpoints
16
+ dtype: bfloat16
17
+ attn_implementation: sdpa
18
+ disable_cudnn_sdp: true
19
+ disable_mha_fastpath: true
20
+ magicnorm_eps: 1.0e-6
21
+ z_slots: 1024
22
+ num_time_tokens: 0
23
+ use_explicit_time_features: false
24
+ gate_attention_heads: 4
25
+ max_observation_tokens: 1024
26
+ max_decoder_tokens: 1024
27
+ thought_loop_proposal_mode: observation_hidden_compression
28
+ preserve_observation_encoder_manifold: true
29
+ observation_encoder_use_state_context: true
30
+ latent_attention_mask_mode: full
31
+ hard_state_replace: true
32
+
33
+ training:
34
+ seed: 17
35
+ num_workers: 2
36
+ gradient_checkpointing: true
37
+ mixed_precision: bf16
38
+ max_grad_norm: 1.0
39
+ weight_decay: 0.01
40
+ backbone_learning_rate: 5.0e-6
41
+ new_module_learning_rate: 1.0e-4
42
+ adam_beta1: 0.9
43
+ adam_beta2: 0.95
44
+ adam_epsilon: 1.0e-8
45
+ fused_adamw: true
46
+ freeze_gate_head: true
47
+ assistant_feedback_mode: teacher_forced
48
+ log_every_steps: 1
49
+ eval_every_steps: 100
50
+ checkpoint_every_steps: 100
51
+ eval_max_batches: 16
52
+ validation_behavior_max_batches: 4
53
+ max_train_examples:
54
+ max_validation_examples:
55
+ supervise_first_turn_response_only: true
56
+
57
+ response_loss_weight: 0.7
58
+ current_user_reconstruction_loss_weight: 0.0
59
+ probe_loss_weight: 0.0
60
+ past_response_contrastive_loss_weight: 0.3
61
+
62
+ enable_past_response_contrastive_loss: true
63
+ past_response_contrastive_margin: 0.5
64
+ past_response_contrastive_pool:
65
+ include_previous_assistant_responses: true
66
+ include_current_user_reconstruction_target: false
67
+ include_previous_user_reconstruction_targets: false
68
+ include_current_transcript_probe_target: false
69
+ include_previous_transcript_probe_targets: false
70
+ probe_question_text: "What is everything we have talked about so far? Give exact conversation transcript verbatim in following format: [User 1]: X [Assistant 1]: Y [User 2]: A etc"
71
+ current_user_reconstruction_question_text: "What did me (the user) just ask you? give verbatim message I just previously sent"
72
+
73
+ feedback_generation_max_new_tokens: 1024
74
+ feedback_generation_extra_new_tokens: 16
75
+ validation_response_max_new_tokens: 1024
76
+ validation_response_extra_new_tokens: 16
77
+ validation_probe_max_new_tokens: 1024
78
+ validation_probe_extra_new_tokens: 16
79
+
80
+ wandb_train_metric_keys:
81
+ - train/loss_total
82
+ - train/loss_response
83
+ - train/loss_current_user_reconstruction
84
+ - train/loss_probe
85
+ - train/loss_past_response_contrastive
86
+ - train/response_first_content_token_exact_match
87
+ - train/current_user_reconstruction_first_content_token_exact_match
88
+ - train/probe_first_content_token_exact_match
89
+ wandb_validation_metric_keys:
90
+ - validation/loss_total
91
+ - validation/loss_response
92
+ - validation/loss_current_user_reconstruction
93
+ - validation/loss_probe
94
+ - validation/loss_past_response_contrastive
95
+ - validation/goal_loss
96
+ - validation/response_similarity
97
+ - validation/response_reconstruction_similarity
98
+ - validation/probe_transcript_similarity
99
+ - validation/response_first_content_token_exact_match
100
+ - validation/current_user_reconstruction_first_content_token_exact_match
101
+ - validation/probe_first_content_token_exact_match
102
+
103
+ checkpoint_selection_metric: validation/goal_loss
104
+ checkpoint_selection_mode: min
105
+ validation_response_exact_miss_penalty: 1.0
106
+ validation_reconstruction_similarity_miss_penalty: 1.0
107
+ validation_probe_exact_miss_penalty: 1.0
108
+ validation_probe_similarity_miss_penalty: 2.0
109
+
110
+ phase:
111
+ micro_batch_size: 3
112
+ eval_batch_size: 1
113
+ gradient_accumulation_steps: 8
114
+ num_train_epochs: 3
115
+ warmup_ratio: 0.03
116
+ shuffle_train: true
117
+
118
+ cache:
119
+ preprocessed_root: cache/preprocessed_pre_sft_multiturn_simple_transcript
120
+
121
+ paths:
122
+ run_root: runs_pre_sft_multiturn_simple_transcript
123
+ export_root: exports_multiturn_simple_transcript
124
+
125
+ inference:
126
+ format: predictive_state_multiturn
127
+ use_base_chat_template: true
128
+
129
+ wandb:
130
+ enabled: true
131
+ project: samantha-pre-sft
132
+ run_name: t5gemma2-thoughtloop-pre-sft-simple-transcript
133
+
134
+ hub:
135
+ model_repo_id: BRlkl/test_multiturn_simple_transcript1024_6_response_loss_only
136
+ private: false
sft_config.json ADDED
@@ -0,0 +1,143 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "datasets": [
3
+ {
4
+ "name": "chatalpaca_multiturn_enriched",
5
+ "repo_id": "BRlkl/chatalpaca-multiturn-enriched-2.1",
6
+ "source_split": "train",
7
+ "format": "messages_all_turns",
8
+ "validation_ratio": 0.005,
9
+ "split_seed": 17,
10
+ "min_turns": 2,
11
+ "max_turns": 7,
12
+ "max_message_chars": 6000,
13
+ "use_base_chat_template": true
14
+ }
15
+ ],
16
+ "model": {
17
+ "base_model_name": "google/t5gemma-l-l-prefixlm-it",
18
+ "initial_model_path": "BRlkl/test_multiturn_simple_transcript1024_6-checkpoints",
19
+ "dtype": "bfloat16",
20
+ "attn_implementation": "sdpa",
21
+ "disable_cudnn_sdp": true,
22
+ "disable_mha_fastpath": true,
23
+ "magicnorm_eps": 1e-06,
24
+ "z_slots": 1024,
25
+ "num_time_tokens": 0,
26
+ "use_explicit_time_features": false,
27
+ "gate_attention_heads": 4,
28
+ "max_observation_tokens": 1024,
29
+ "max_decoder_tokens": 1024,
30
+ "thought_loop_proposal_mode": "observation_hidden_compression",
31
+ "preserve_observation_encoder_manifold": true,
32
+ "observation_encoder_use_state_context": true,
33
+ "latent_attention_mask_mode": "full",
34
+ "hard_state_replace": true,
35
+ "gate_decision_temperature": 1.0,
36
+ "initial_gate_decision_threshold_logit": 0.0
37
+ },
38
+ "training": {
39
+ "seed": 17,
40
+ "num_workers": 2,
41
+ "gradient_checkpointing": true,
42
+ "mixed_precision": "bf16",
43
+ "max_grad_norm": 1.0,
44
+ "weight_decay": 0.01,
45
+ "backbone_learning_rate": 5e-06,
46
+ "new_module_learning_rate": 0.0001,
47
+ "adam_beta1": 0.9,
48
+ "adam_beta2": 0.95,
49
+ "adam_epsilon": 1e-08,
50
+ "fused_adamw": true,
51
+ "freeze_gate_head": true,
52
+ "assistant_feedback_mode": "teacher_forced",
53
+ "log_every_steps": 1,
54
+ "eval_every_steps": 100,
55
+ "checkpoint_every_steps": 100,
56
+ "eval_max_batches": 16,
57
+ "validation_behavior_max_batches": 4,
58
+ "max_train_examples": null,
59
+ "max_validation_examples": null,
60
+ "supervise_first_turn_response_only": true,
61
+ "response_loss_weight": 0.7,
62
+ "current_user_reconstruction_loss_weight": 0.0,
63
+ "probe_loss_weight": 0.0,
64
+ "past_response_contrastive_loss_weight": 0.3,
65
+ "enable_past_response_contrastive_loss": true,
66
+ "past_response_contrastive_margin": 0.5,
67
+ "past_response_contrastive_pool": {
68
+ "include_previous_assistant_responses": true,
69
+ "include_current_user_reconstruction_target": false,
70
+ "include_previous_user_reconstruction_targets": false,
71
+ "include_current_transcript_probe_target": false,
72
+ "include_previous_transcript_probe_targets": false
73
+ },
74
+ "probe_question_text": "What is everything we have talked about so far? Give exact conversation transcript verbatim in following format: [User 1]: X [Assistant 1]: Y [User 2]: A etc",
75
+ "current_user_reconstruction_question_text": "What did me (the user) just ask you? give verbatim message I just previously sent",
76
+ "feedback_generation_max_new_tokens": 1024,
77
+ "feedback_generation_extra_new_tokens": 16,
78
+ "validation_response_max_new_tokens": 1024,
79
+ "validation_response_extra_new_tokens": 16,
80
+ "validation_probe_max_new_tokens": 1024,
81
+ "validation_probe_extra_new_tokens": 16,
82
+ "wandb_train_metric_keys": [
83
+ "train/loss_total",
84
+ "train/loss_response",
85
+ "train/loss_current_user_reconstruction",
86
+ "train/loss_probe",
87
+ "train/loss_past_response_contrastive",
88
+ "train/response_first_content_token_exact_match",
89
+ "train/current_user_reconstruction_first_content_token_exact_match",
90
+ "train/probe_first_content_token_exact_match"
91
+ ],
92
+ "wandb_validation_metric_keys": [
93
+ "validation/loss_total",
94
+ "validation/loss_response",
95
+ "validation/loss_current_user_reconstruction",
96
+ "validation/loss_probe",
97
+ "validation/loss_past_response_contrastive",
98
+ "validation/goal_loss",
99
+ "validation/response_similarity",
100
+ "validation/response_reconstruction_similarity",
101
+ "validation/probe_transcript_similarity",
102
+ "validation/response_first_content_token_exact_match",
103
+ "validation/current_user_reconstruction_first_content_token_exact_match",
104
+ "validation/probe_first_content_token_exact_match"
105
+ ],
106
+ "checkpoint_selection_metric": "validation/goal_loss",
107
+ "checkpoint_selection_mode": "min",
108
+ "validation_response_exact_miss_penalty": 1.0,
109
+ "validation_reconstruction_similarity_miss_penalty": 1.0,
110
+ "validation_probe_exact_miss_penalty": 1.0,
111
+ "validation_probe_similarity_miss_penalty": 2.0
112
+ },
113
+ "phase": {
114
+ "micro_batch_size": 3,
115
+ "eval_batch_size": 1,
116
+ "gradient_accumulation_steps": 8,
117
+ "num_train_epochs": 3,
118
+ "warmup_ratio": 0.03,
119
+ "shuffle_train": true
120
+ },
121
+ "cache": {
122
+ "preprocessed_root": "cache/preprocessed_pre_sft_multiturn_simple_transcript"
123
+ },
124
+ "paths": {
125
+ "run_root": "runs_pre_sft_multiturn_simple_transcript",
126
+ "export_root": "exports_multiturn_simple_transcript"
127
+ },
128
+ "inference": {
129
+ "format": "predictive_state_multiturn",
130
+ "use_base_chat_template": true,
131
+ "gate_probability_threshold": 0.5,
132
+ "learned_gate_decision_threshold_logit": 0.0
133
+ },
134
+ "wandb": {
135
+ "enabled": true,
136
+ "project": "samantha-pre-sft",
137
+ "run_name": "t5gemma2-thoughtloop-pre-sft-simple-transcript"
138
+ },
139
+ "hub": {
140
+ "model_repo_id": "BRlkl/test_multiturn_simple_transcript1024_6_response_loss_only",
141
+ "private": false
142
+ }
143
+ }
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:923de64f4705efd22f6880dc5e6a9b2993de2706a03d0d48773e0173e32a074f
3
+ size 34362428
tokenizer_config.json ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "backend": "tokenizers",
3
+ "bos_token": "<bos>",
4
+ "clean_up_tokenization_spaces": false,
5
+ "eos_token": "<eos>",
6
+ "is_local": false,
7
+ "local_files_only": false,
8
+ "mask_token": "<mask>",
9
+ "model_max_length": 1000000000000000019884624838656,
10
+ "pad_token": "<pad>",
11
+ "padding_side": "right",
12
+ "sp_model_kwargs": {},
13
+ "spaces_between_special_tokens": false,
14
+ "tokenizer_class": "GemmaTokenizer",
15
+ "unk_token": "<unk>",
16
+ "use_default_system_prompt": false
17
+ }
training_state.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0e9759ad770bf9d78b77abf19988569ecdb865ad5f0b6779afac5b2273be8962
3
+ size 4976040191