mdts-agxqa-last4-layers

Last-4 layers fine-tuned cross-encoder on AgXQA agricultural dataset. Full attention + MLP unfrozen for layers 8-11 (7.10M params). Initialized from SciFact-fine-tuned JAYADIR/mdts-last4-layers.

Training

Stage Dataset Description
Stage 1 SciFact (BEIR) Circuit fine-tuning with BM25 hard negatives
Stage 2 AgXQA Domain adaptation to agricultural extension QA

Results on AgXQA Test Set (NDCG@10)

Strategy Params Zero-Shot AgXQA FT Delta MRR@10
BM25 baseline โ€” 0.8533 โ€” โ€” 0.8208
Vanilla (no FT) โ€” 0.9124 โ€” โ€” 0.8907
A: Circuit MLP-only 2.36M 0.9123 0.9151 +0.0028 0.8945
B: Last-4 Layers 7.10M 0.9070 0.9135 +0.0065 0.8937
C: Full Fine-Tuning 33.36M 0.9020 0.9231 +0.0211 0.9051
D: Circuit-Full (BM25) 4.73M 0.9094 0.9174 +0.0080 0.8976

This model: B: Last-4 Layers | Params: 7.10M | NDCG@10: 0.9135 | MRR@10: 0.8937

Usage

from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch

tokenizer = AutoTokenizer.from_pretrained("JAYADIR/mdts-agxqa-last4-layers")
model = AutoModelForSequenceClassification.from_pretrained("JAYADIR/mdts-agxqa-last4-layers")

query   = "What is the best irrigation method for wheat in semi-arid regions?"
passage = "Drip irrigation is highly efficient for wheat cultivation in semi-arid areas."

inputs = tokenizer(query, passage, return_tensors="pt", truncation=True, max_length=512)
with torch.no_grad():
    score = model(**inputs).logits.squeeze().item()
print(f"Relevance score: {score:.4f}")
Downloads last month
31
Safetensors
Model size
33.4M params
Tensor type
F32
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for JAYADIR/mdts-agxqa-last4-layers