Qwen2.5-VL-7B - CORD structured-extraction LoRA

QLoRA adapter that fine-tunes Qwen/Qwen2.5-VL-7B-Instruct to read a document image and emit structured JSON (receipt fields + line items), trained on a small CORD subset.

  • Base: Qwen/Qwen2.5-VL-7B-Instruct
  • Method: QLoRA (4-bit base, LoRA r=16 on the language attention/MLP layers, vision tower frozen) via Unsloth, 2 epochs on 200 CORD train receipts.
  • Target: the canonical extraction schema (doc_type, receipt fields, line items).

Result - CORD test[:40], same pipeline, 4-bit

Field EM Field F1 Line-item F1
Zero-shot v3 prompt 0.869 0.834 0.934
This LoRA 0.865 0.830 0.957

Matches the already-strong prompt baseline on fields and lifts line-item F1 +0.02.

Usage

from peft import PeftModel
from transformers import Qwen2_5_VLForConditionalGeneration, AutoProcessor
base = Qwen2_5_VLForConditionalGeneration.from_pretrained("Qwen/Qwen2.5-VL-7B-Instruct", device_map="auto")
model = PeftModel.from_pretrained(base, "sarcasticcoder/qwen2.5-vl-7b-cord-lora")
proc = AutoProcessor.from_pretrained("Qwen/Qwen2.5-VL-7B-Instruct")
Downloads last month
3
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for sarcasticcoder/qwen2.5-vl-7b-cord-lora

Adapter
(314)
this model

Dataset used to train sarcasticcoder/qwen2.5-vl-7b-cord-lora