CoolFace
Modelpublic

EYEDOL/adtc-agri-sft-qwen2.5-1.5b

sourceHugging Faceapache-2.0updated 11d agoView on Hugging Face
0likes1kdownloads
Model Card

adtc-agri-sft-qwen2.5-1.5b

This model is a fine-tune of `Qwen/Qwen2.5-1.5B-Instruct`, adapted via QLoRA (4-bit base + LoRA adapters, merged back into full weights) for agricultural advisory Q&A aimed at smallholder farmers and extension officers in Nigeria.

Part of the ADTC 2026 project. This is a baseline SFT run — direct supervised fine-tuning with no distillation — used to establish how much headroom a distillation stage could still add over the base model.

Model description

  • —Base model: Qwen/Qwen2.5-1.5B-Instruct
  • —Fine-tuning method: QLoRA (4-bit NF4 quantized base, bf16 compute dtype, double quantization), adapters merged into the base weights for the published checkpoint
  • —LoRA config: r=16, alpha=32, dropout=0.05, target modules: vproj, downproj, kproj, gateproj, upproj, oproj, q_proj
  • —Task: single-turn instruction following — given a farming scenario or question, produce a concise assessment, a practical recommendation, and (if relevant) a note on when to escalate to in-person expert help
  • —System prompt used at train/inference time:
You are an offline agricultural advisory assistant for smallholder farmers and extension officers in Nigeria. Given the situation described, provide a clear assessment, a practical recommendation, and, where relevant, a note on when to seek in-person expert help. Be concise and avoid unnecessary hedging.

Training data

Combined and deduplicated (on normalized question text) from:

  • —kaggle_csv: 36,489 examples
  • —synthetic_market: 593 examples
  • —synthetic_fertilizer: 598 examples
  • —Total training examples: 35,796
  • —Held-out eval examples: 1,884 (5% split)
  • —Primary source: the Kaggle agriculture_qa_final_cleaned.csv dataset (query/response columns), supplemented with synthetically generated fertilizer-dosage and market/storage economics word problems to cover numeric-reasoning cases underrepresented in the base dataset.

Training procedure

Hyperparameters

HyperparameterValue
Base modelQwen/Qwen2.5-1.5B-Instruct
Max sequence length1024
Batch size (per device)2
Gradient accumulation steps8
Effective batch size16
Max steps-1
Learning rate0.0002
LR schedulerSchedulerType.COSINE
Precisionbf16
Seed42
LoRA r / alpha / dropout16 / 32 / 0.05

Training loss

StepTraining LossValidation LossLearning Rate
5000.76290.68021.94e-04
10000.65260.63321.76e-04
15000.61630.60461.50e-04
20000.58820.58341.17e-04
25000.54980.57228.18e-05
30000.51730.56014.91e-05
35000.50450.55162.26e-05
40000.50130.54805.55e-06
4476—0.5473—

Intended use & limitations

  • —Intended for offline agricultural advisory use cases (smallholder farmers, extension officers) in a Nigerian context; not validated for general-purpose assistant use or for regions/crops outside its training distribution.
  • —This is a baseline checkpoint for internal comparison against the un-tuned base model and, later, a distilled variant — treat outputs as advisory, not authoritative agronomic or financial guidance, and always recommend in-person expert follow-up for high-stakes decisions.
  • —Evaluated informally via qualitative spot-checks on held-out prompts; formal accuracy benchmarking (ARC-Easy / domain-quality via the ADTC profiler) is tracked separately from this card.

How to use

python
from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "EYEDOL/adtc-agri-sft-qwen2.5-1.5b"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, dtype="bfloat16", device_map="auto")

messages = [
    {"role": "system", "content": "You are an offline agricultural advisory assistant for smallholder farmers and extension officers in Nigeria. Given the situation described, provide a clear assessment, a practical recommendation, and, where relevant, a note on when to seek in-person expert help. Be concise and avoid unnecessary hedging."},
    {"role": "user", "content": "Your farming question here"},
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
out = model.generate(**inputs, max_new_tokens=200, do_sample=False)
print(tokenizer.decode(out[0][inputs["input_ids"].shape[1]:], skip_special_tokens=True))

Card generated automatically at training time — 2026-09-16 01:25 UTC.