Update README.md
Browse filesAdded basic details on finetuning parameters, ROUGE1 score etc.
README.md
CHANGED
@@ -5,33 +5,78 @@ base_model: google/flan-t5-base
|
|
5 |
|
6 |
# Model Card for Model ID
|
7 |
|
8 |
-
|
|
|
9 |
|
10 |
|
11 |
|
12 |
-
## Model Details
|
13 |
-
|
14 |
-
### Model Description
|
15 |
-
|
16 |
-
<!-- Provide a longer summary of what this model is. -->
|
17 |
-
|
18 |
|
|
|
19 |
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
31 |
|
32 |
-
- **Repository:** [More Information Needed]
|
33 |
-
- **Paper [optional]:** [More Information Needed]
|
34 |
-
- **Demo [optional]:** [More Information Needed]
|
35 |
|
36 |
## Uses
|
37 |
|
|
|
5 |
|
6 |
# Model Card for Model ID
|
7 |
|
8 |
+
This is a flan-t5-base model finetuned using QLoRA (PEFT)
|
9 |
+
on dialogSum dataset : https://huggingface.co/datasets/knkarthick/dialogsum
|
10 |
|
11 |
|
12 |
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
|
14 |
+
## Model Details
|
15 |
|
16 |
+
### Training Details:
|
17 |
+
|
18 |
+
This is just a basic fine tuned model using below training args and params
|
19 |
+
|
20 |
+
lora_config = LoraConfig(
|
21 |
+
r=16,
|
22 |
+
lora_alpha=32,
|
23 |
+
target_modules=['q','k','v','o'],
|
24 |
+
lora_dropout=.05,
|
25 |
+
bias='none',
|
26 |
+
task_type=TaskType.SEQ_2_SEQ_LM #flan-t5
|
27 |
+
)
|
28 |
+
|
29 |
+
|
30 |
+
output_dir = f'/kaggle/working/qlora-peft-flant5-base-dialogue-summary-training-{str(int(time.time()))}'
|
31 |
+
|
32 |
+
peft_training_args_4bit = TrainingArguments(
|
33 |
+
output_dir=output_dir,
|
34 |
+
auto_find_batch_size=True,
|
35 |
+
learning_rate=1e-3, # Higher learning rate than full fine-tuning.
|
36 |
+
num_train_epochs=200,
|
37 |
+
logging_steps=10,
|
38 |
+
max_steps=200
|
39 |
+
)
|
40 |
+
|
41 |
+
peft_trainer_4bit = Trainer(
|
42 |
+
model=peft_model_4bit,
|
43 |
+
args=peft_training_args_4bit,
|
44 |
+
train_dataset=tokenized_dataset_cleaned["train"],
|
45 |
+
eval_dataset=tokenized_dataset_cleaned['validation']
|
46 |
+
)
|
47 |
+
|
48 |
+
|
49 |
+
Recorded training loss as below:
|
50 |
+
|
51 |
+
Step Training Loss
|
52 |
+
10 29.131100
|
53 |
+
20 4.856900
|
54 |
+
30 3.241400
|
55 |
+
40 1.346500
|
56 |
+
50 0.560900
|
57 |
+
60 0.344000
|
58 |
+
70 0.258600
|
59 |
+
80 0.201600
|
60 |
+
90 0.202900
|
61 |
+
100 0.198700
|
62 |
+
110 0.185000
|
63 |
+
120 0.177200
|
64 |
+
130 0.161400
|
65 |
+
140 0.164200
|
66 |
+
150 0.164300
|
67 |
+
160 0.165800
|
68 |
+
170 0.168700
|
69 |
+
180 0.155100
|
70 |
+
190 0.161200
|
71 |
+
200 0.170300
|
72 |
+
|
73 |
+
|
74 |
+
Rouge1 score for 100 test dataset(out of 1500) is :
|
75 |
+
ORIGINAL MODEL:
|
76 |
+
{'rouge1': 0.2232663790087573, 'rouge2': 0.06084131871447254, 'rougeL': 0.1936115999187245, 'rougeLsum': 0.19319411133637282}
|
77 |
+
PEFT MODEL:
|
78 |
+
{'rouge1': 0.34502805897556865, 'rouge2': 0.11517693222074701, 'rougeL': 0.2800665095598698, 'rougeLsum': 0.27941257109947587}
|
79 |
|
|
|
|
|
|
|
80 |
|
81 |
## Uses
|
82 |
|