atic / README.md
Kossisoroyce's picture
Upload ATIC LoRA adapter and model card
6140689 verified
|
Raw
History Blame Contribute Delete
1.47 kB
---
base_model: google/gemma-4-E4B-it
library_name: peft
pipeline_tag: text-generation
license: apache-2.0
datasets:
- africatic/afritemp-bench
tags:
- base_model:adapter:google/gemma-4-E4B-it
- lora
- sft
- transformers
- trl
---
# Gemma 4 E4B — AfriTemp LoRA
This repository contains a LoRA adapter fine-tuned from
[`google/gemma-4-E4B-it`](https://huggingface.co/google/gemma-4-E4B-it) on
[`africatic/afritemp-bench`](https://huggingface.co/datasets/africatic/afritemp-bench).
## Training setup
- Method: LoRA supervised fine-tuning
- Precision: BF16
- GPU: NVIDIA A100-SXM4-40GB
- Maximum sequence length: 1024
- Epochs: 3
- Per-device batch size: 1
- Gradient accumulation: 16
- Effective batch size: 16
- Learning rate: 0.0002
- LoRA rank: 16
- LoRA alpha: 32
## Intended use
The adapter is intended for research on temporal reasoning and African
economic, social and development data. It should be evaluated carefully before
use in consequential decision-making.
## Loading
```python
import torch
from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer
base_model_id = "google/gemma-4-E4B-it"
adapter_id = "YOUR_HF_USERNAME/gemma-4-e4b-afritemp"
tokenizer = AutoTokenizer.from_pretrained(adapter_id)
base_model = AutoModelForCausalLM.from_pretrained(
base_model_id,
dtype=torch.bfloat16,
device_map="auto",
)
model = PeftModel.from_pretrained(base_model, adapter_id)
```
### Framework versions
- PEFT 0.19.1