File size: 3,347 Bytes
aacf5ea
 
 
 
 
107b694
 
 
 
fd50a56
 
f0b2c3a
fd50a56
107b694
 
 
aacf5ea
 
 
 
 
 
 
 
 
 
107b694
aacf5ea
107b694
 
 
 
 
 
 
 
 
aacf5ea
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
f0b2c3a
aacf5ea
 
 
 
 
 
 
 
 
 
f0b2c3a
 
aacf5ea
 
 
 
 
f0b2c3a
 
 
 
 
 
aacf5ea
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
---
library_name: transformers
license: llama3.2
base_model: tanliboy/llama-3.2-3b-sft
tags:
- alignment-handbook
- trl
- dpo
- generated_from_trainer
- trl
- dpo
- alignment-handbook
- generated_from_trainer
datasets:
- HuggingFaceH4/orca_dpo_pairs
- HuggingFaceH4/ultrafeedback_binarized
model-index:
- name: llama-3.2-3b-dpo
  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. -->

# llama-3.2-3b-dpo

This model is a fine-tuned version of [tanliboy/llama-3.2-3b-sft](https://huggingface.co/tanliboy/llama-3.2-3b-sft) on the HuggingFaceH4/orca_dpo_pairs and the HuggingFaceH4/ultrafeedback_binarized datasets.
It achieves the following results on the evaluation set:
- Loss: 0.6289
- Rewards/chosen: 0.7479
- Rewards/rejected: -3.8379
- Rewards/accuracies: 0.7405
- Rewards/margins: 4.5857
- Logps/rejected: -370.2327
- Logps/chosen: -338.3392
- Logits/rejected: 0.4475
- Logits/chosen: 0.3731

## Model description

More information needed

## Intended uses & limitations

More information needed

## Training and evaluation data

More information needed

## Training procedure

### Training hyperparameters

The following hyperparameters were used during training:
- learning_rate: 1e-06
- train_batch_size: 4
- eval_batch_size: 4
- seed: 42
- distributed_type: multi-GPU
- num_devices: 8
- gradient_accumulation_steps: 4
- total_train_batch_size: 128
- total_eval_batch_size: 32
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
- lr_scheduler_type: cosine
- lr_scheduler_warmup_ratio: 0.03
- num_epochs: 3

### Training results

| Training Loss | Epoch  | Step | Validation Loss | Rewards/chosen | Rewards/rejected | Rewards/accuracies | Rewards/margins | Logps/rejected | Logps/chosen | Logits/rejected | Logits/chosen |
|:-------------:|:------:|:----:|:---------------:|:--------------:|:----------------:|:------------------:|:---------------:|:--------------:|:------------:|:---------------:|:-------------:|
| 0.5801        | 0.4739 | 100  | 0.6840          | 0.6485         | -2.9389          | 0.6899             | 3.5875          | -361.2435      | -339.3325    | 0.6783          | 0.6103        |
| 0.537         | 0.9479 | 200  | 0.6514          | 0.2045         | -4.0315          | 0.7278             | 4.2360          | -372.1696      | -343.7731    | 0.5648          | 0.4948        |
| 0.4787        | 1.4218 | 300  | 0.6387          | 0.4099         | -3.9882          | 0.7215             | 4.3981          | -371.7361      | -341.7187    | 0.5326          | 0.4589        |
| 0.4559        | 1.8957 | 400  | 0.6332          | 0.7690         | -3.6688          | 0.7342             | 4.4379          | -368.5425      | -338.1277    | 0.4841          | 0.4110        |
| 0.4028        | 2.3697 | 500  | 0.6289          | 0.7479         | -3.8379          | 0.7405             | 4.5857          | -370.2327      | -338.3392    | 0.4475          | 0.3731        |
| 0.4029        | 2.8436 | 600  | 0.6284          | 0.8504         | -3.7058          | 0.7437             | 4.5562          | -368.9125      | -337.3143    | 0.4571          | 0.3820        |


### Framework versions

- Transformers 4.44.2
- Pytorch 2.4.0+cu121
- Datasets 2.19.1
- Tokenizers 0.19.1