Views
No views yet
0.10.01base_model: google/gemma-3-4b-it
2
3load_in_4bit: true
4
5# gemma3 doesn't seem to play nice with ddp
6ddp_find_unused_parameters: true
7
8chat_template: gemma3
9eot_tokens:
10 - <end_of_turn>
11datasets:
12 - path: /data/meta-extractor/conversations/conversations_gemma-3-4b-it_qlora_pdf_metadata_extractor.jsonl
13 type: chat_template
14 train_on_inputs: false
15 field_messages: conversations
16 message_property_mappings:
17 role: role
18 content: content
19
20
21dataset_prepared_path: last_run_prepared
22val_set_size: 0.01
23
24output_dir: /data/meta-extractor/models/gemma-3-4b-it_qlora_pdf_metadata_extractor
25
26adapter: qlora
27lora_model_dir:
28
29sequence_len: 4096
30sample_packing: false
31
32
33lora_r: 32
34lora_alpha: 16
35lora_dropout: 0.05
36lora_target_modules: 'model.language_model.layers.[\d]+.(mlp|cross_attn|self_attn).(up|down|gate|q|k|v|o)_proj'
37
38wandb_project:
39wandb_entity:
40wandb_watch:
41wandb_name:
42wandb_log_model:
43
44gradient_accumulation_steps: 4
45micro_batch_size: 2
46num_epochs: 1
47optimizer: adamw_bnb_8bit
48lr_scheduler: cosine
49learning_rate: 0.0002
50
51bf16: true
52fp16:
53tf32: true
54
55gradient_checkpointing: true
56gradient_checkpointing_kwargs:
57 use_reentrant: false
58logging_steps: 1
59flash_attention: false
60eager_attention:
61
62warmup_ratio: 0.1
63evals_per_epoch: 1
64saves_per_epoch: 1
65weight_decay: 0.0
66
67# save_first_step: true # uncomment this to validate checkpoint saving works with your config
68{
"title": "National Public Health Preparedness Outlook",
"subtitle": "Assessment of Response Protocols and Resource Readiness",
"publication_year": 1998,
"language_as_iso639-2": "eng",
"identifiers": { "ISBN": "099-9-4444442-9" },
"publisher": ["Health Security Authority"],
"creator_persons": [
"Marel Orit [author]",
"Tilo Envar [editor]"
],
"creator_corporations": [
"Civic Emergency Planning Unit"
],
"country_of_publication_iso639-1": ["us"]
}########################################
Evaluation results:
########################################
-------------------EXACT MATCH-------------------
Overall accuracy: 82.26% (8958/10890)
Total hallucinations: 1442 | TP=6703 FP=1601 FN=1487 TN=3190
Micro P/R/F1: P=80.72% R=81.84% F1=81.28%
TITLE accuracy: 76.16% (754/990) | TP=754 FP=231 FN=5, TN=0 | P=76.55% R=99.34% F1=86.47% | Hallucinations=231
SUBTITLE accuracy: 71.01% (703/990) | TP=404 FP=231 FN=56, TN=299 | P=63.62% R=87.83% F1=73.79% | Hallucinations=231
PUBLICATION_YEAR accuracy: 94.24% (933/990) | TP=933 FP=52 FN=5, TN=0 | P=94.72% R=99.47% F1=97.04% | Hallucinations=52
LANGUAGE_AS_ISO639-2 accuracy: 98.18% (972/990) | TP=972 FP=13 FN=5, TN=0 | P=98.68% R=99.49% F1=99.08% | Hallucinations=13
IDENTIFIERS.ISBN accuracy: 81.31% (805/990) | TP=569 FP=140 FN=45, TN=236 | P=80.25% R=92.67% F1=86.02% | Hallucinations=140
PUBLISHER accuracy: 72.73% (720/990) | TP=800 FP=243 FN=282, TN=0 | P=76.70% R=73.94% F1=75.29% | Hallucinations=238
CREATOR_PERSONS accuracy: 68.99% (683/990) | TP=998 FP=288 FN=471, TN=280 | P=77.60% R=67.94% F1=72.45% | Hallucinations=177
CREATOR_CORPORATIONS accuracy: 60.10% (595/990) | TP=809 FP=341 FN=456, TN=37 | P=70.35% R=63.95% F1=67.00% | Hallucinations=300
COUNTRY_OF_PUBLICATION_ISO639-1 accuracy: 99.70% (987/990) | TP=0 FP=0 FN=4, TN=987 | P=— R=0.00% F1=— | Hallucinations=0
SERIES accuracy: 88.89% (880/990) | TP=289 FP=34 FN=101, TN=600 | P=89.47% R=74.10% F1=81.07% | Hallucinations=33
SERIES_NUMBER accuracy: 93.54% (926/990) | TP=175 FP=28 FN=57, TN=751 | P=86.21% R=75.43% F1=80.46% | Hallucinations=27