Views
No views yet
Research / education only. Synthetic training data only. NOT a diagnostic tool, not clinical decision support, not a medical device. Do not use with real patient data or PHI.
google/gemma-3-4b-it. It is the experimental control for a study of whether
medical continued-pretraining helps: same base family as MedGemma but without
medical pretraining, fine-tuned with an identical recipe on identical synthetic data.
Not a standalone model — you need separate access to the gated base.medgemma-1.5-4b-preventive-qlora.1import torch
2from transformers import AutoTokenizer, BitsAndBytesConfig, Gemma3ForConditionalGeneration
3from peft import PeftModel
4
5base = "google/gemma-3-4b-it" # accept its license on HF first
6bnb = BitsAndBytesConfig(load_in_4bit=True, bnb_4bit_quant_type="nf4",
7 bnb_4bit_use_double_quant=True, bnb_4bit_compute_dtype=torch.bfloat16)
8tok = AutoTokenizer.from_pretrained(base)
9model = Gemma3ForConditionalGeneration.from_pretrained(base, quantization_config=bnb, device_map="cuda")
10model = PeftModel.from_pretrained(model, "rockyaaos/gemma-3-4b-preventive-qlora")| metric | base | this adapter |
|---|---|---|
| overall (mean of 4) | 0.612 | 1.000 |
| safety disclaimer present | 0.000 | 1.000 |
| non-diagnostic | 0.500 | 1.000 |
| numeric grounding | 0.950 | 1.000 |
| 7-section schema | 1.000 | 1.000 |
| hard-fail rate | 100 % | 0 % |