|
--- |
|
library_name: peft |
|
license: mit |
|
base_model: microsoft/Phi-3.5-mini-instruct |
|
tags: |
|
- axolotl |
|
- generated_from_trainer |
|
model-index: |
|
- name: sn_math_curator_on_ensemble_8 |
|
results: [] |
|
--- |
|
|
|
<!-- This model card has been generated automatically according to the information the Trainer had access to. You |
|
should probably proofread and complete it, then remove this comment. --> |
|
|
|
|
|
This is an open-source fine-tuned reasoning adapter of [microsoft/Phi-3.5-mini-instruct](https://huggingface.co/microsoft/Phi-3.5-mini-instruct), transformed into a math reasoning model using data curated from [collinear-ai/R1-Distill-SFT-Curated](https://huggingface.co/datasets/collinear-ai/R1-Distill-SFT-Curated). |
|
|
|
[<img src="https://raw.githubusercontent.com/axolotl-ai-cloud/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/axolotl-ai-cloud/axolotl) |
|
<details><summary>See axolotl version</summary> |
|
|
|
axolotl version: `0.5.0` |
|
<!-- ```yaml |
|
strict: false |
|
base_model: microsoft/Phi-3.5-mini-instruct |
|
tokenizer_config: microsoft/Phi-3.5-mini-instruct |
|
model_type: AutoModelForCausalLM |
|
tokenizer_type: AutoTokenizer |
|
|
|
# Output configuration |
|
hub_model_id: collinear-ai/sn_math_curator_on_ensemble_8 |
|
dataset_prepared_path: data/sn_math_curator_on_ensemble_8 |
|
output_dir: model/sn_math_curator_on_ensemble_8 |
|
|
|
# Format the dataset into the right instruction format. |
|
chat_template: phi_3 |
|
datasets: |
|
- path: collinear-ai/R1-Distill-SFT-numina-math-ensemble_8_train |
|
split: train |
|
type: chat_template |
|
chat_template: phi_3 |
|
field_messages: train_conv |
|
message_field_role: role |
|
message_field_content: content |
|
train_on_inputs: false #FALSE |
|
|
|
val_set_size: 0.05 |
|
# Data packing |
|
sequence_len: 4096 |
|
eval_sample_packing: false |
|
sample_packing: false |
|
pad_to_sequence_len: true |
|
group_by_length: false |
|
|
|
# Lora config |
|
adapter: qlora |
|
lora_model_dir: |
|
load_in_8bit: false |
|
load_in_4bit: true --> |
|
<!-- lora_r: 128 |
|
lora_alpha: 64 |
|
lora_dropout: 0.2 |
|
lora_target_linear: true |
|
lora_fan_in_fan_out: |
|
lora_target_modules: |
|
- gate_proj |
|
- down_proj |
|
- up_proj |
|
- q_proj |
|
- v_proj |
|
- k_proj |
|
- o_proj |
|
lora_modules_to_save: |
|
- embed_tokens |
|
- lm_head |
|
|
|
|
|
# Logging config |
|
wandb_project: sn-curators-downstream |
|
wandb_entity: nazneen |
|
wandb_name: curator_math_sn_ensemble_8_phi |
|
|
|
# Trainer config |
|
gradient_accumulation_steps: 2 |
|
micro_batch_size: 10 |
|
num_epochs: 1 |
|
optimizer: paged_adamw_8bit |
|
lr_scheduler: cosine |
|
learning_rate: 0.000005 |
|
|
|
|
|
bfloat16: true |
|
bf16: true |
|
fp16: |
|
tf32: false --> |
|
|
|
<!-- gradient_checkpointing: true |
|
early_stopping_patience: |
|
resume_from_checkpoint: |
|
local_rank: |
|
logging_steps: 10 |
|
xformers_attention: |
|
flash_attention: true |
|
save_safetensors: true |
|
|
|
|
|
|
|
warmup_steps: 50 |
|
evals_per_epoch: 3 |
|
eval_table_size: 3 |
|
eval_max_new_tokens: 2048 |
|
saves_per_epoch: 40 |
|
debug: |
|
deepspeed: |
|
weight_decay: 0.02 |
|
fsdp_config: |
|
special_tokens: |
|
bos_token: "<s>" |
|
eos_token: "<|endoftext|>" |
|
unk_token: "<unk>" |
|
pad_token: "<|endoftext|>" |
|
|
|
``` --> |
|
|
|
</details><br> |
|
|
|
|
|
|
|
## Intended uses & limitations |
|
|
|
Math-Reasoning |
|
|
|
## Training and evaluation data |
|
|
|
Training data curated from [collinear-ai/R1-Distill-SFT-Curated](https://huggingface.co/datasets/collinear-ai/R1-Distill-SFT-Curated) |
|
Evaluation data: [HuggingFaceH4/MATH-500](https://huggingface.co/datasets/HuggingFaceH4/MATH-500) |
|
|
|
## Training procedure |
|
|
|
### Training hyperparameters |
|
|
|
The following hyperparameters were used during training: |
|
- learning_rate: 5e-06 |
|
- train_batch_size: 10 |
|
- eval_batch_size: 10 |
|
- seed: 42 |
|
- distributed_type: multi-GPU |
|
- num_devices: 8 |
|
- gradient_accumulation_steps: 2 |
|
- total_train_batch_size: 160 |
|
- total_eval_batch_size: 80 |
|
- optimizer: Use OptimizerNames.PAGED_ADAMW_8BIT with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments |
|
- lr_scheduler_type: cosine |
|
- lr_scheduler_warmup_steps: 50 |
|
- num_epochs: 1 |
|
|
|
### Training results |
|
|
|
| Training Loss | Epoch | Step | Validation Loss | |
|
|:-------------:|:------:|:----:|:---------------:| |
|
| No log | 0.0003 | 1 | 0.6646 | |
|
| 0.3174 | 0.3335 | 1247 | 0.3329 | |
|
| 0.307 | 0.6670 | 2494 | 0.3169 | |
|
|
|
### Evaluation on Math500 |
|
|
|
 |
|
|
|
|
|
### Framework versions |
|
|
|
- PEFT 0.13.2 |
|
- Transformers 4.46.1 |
|
- Pytorch 2.3.1+cu121 |
|
- Datasets 3.0.1 |
|
- Tokenizers 0.20.3 |