Coleção oficial de LoRA Adapters de alta precisão desenvolvidos para o framework sci-image-markdown, especializados na transcrição visual direta de figuras científicas densas (espectroscopia, ALD/ALE, isotermas e cinética química) em tabelas estruturadas em formato GitHub-Flavored Markdown.
Treinados com a ICDAR Metric-Aware Loss v3 (Loss balanceada de proximidade numérica suave, penalidade de cardinalidade e ancoragem topológica TEDS).
Avaliação rigorosa realizada sobre as 373 figuras científicas reais do conjunto de teste independente oficial do desafio:
| Posição | Modelo / Backbone | Método / Adaptação | Subpasta no Repo | Tabelas Válidas (valid_table) |
RMS Numérico (icdar_rms) |
Estrutura TEDS (teds) |
Score Final ICDAR | Hardware Recomendado |
|---|---|---|---|---|---|---|---|---|
| 🥇 1º | LightOnOCR-3-4B (Novo Recorde) |
LoRA + Loss v3 | lightonocr_3_4b/ |
98.39% | 0.6212 | 0.4252 | 0.5232 🏆 | ~8 GB VRAM |
| 🥈 2º | Qwen2.5-VL-7B |
LoRA + Loss v2 | qwen2_5_vl_7b/ |
99.73% | 0.6026 | 0.4396 | 0.5211 🚀 | ~14 GB VRAM |
| 🥉 3º | Qwen2.5-VL-3B |
LoRA + Loss v1 | root / |
99.73% | 0.5830 | 0.4068 | 0.4949 | < 8 GB VRAM |
| 4º | Qwen3-VL-8B |
LoRA + Loss v3 | qwen3_vl_8b/ |
99.73% | 0.6076 | 0.3668 | 0.4872 | ~16 GB VRAM |
| Ref | 1º Colocado Oficial ICDAR 2026 (Peking) | Ensemble / Multi-VLM | - | ~99.0% | 0.5810 | 0.4552 | 0.5181 | Multi-GPU Cluster |
| Ref | 2º Colocado Oficial ICDAR 2026 (Samsung) | Prompting Especializado | - | ~98.5% | 0.5230 | 0.3972 | 0.4601 | Multi-GPU Cluster |
| Base | Qwen2.5-VL-3B (Zero-Shot) | Sem Treinamento | - | 88.74% | 0.4812 | 0.2316 | 0.3564 | < 8 GB VRAM |
lucasoc/sci-image-models/
├── README.md # Visão geral e leaderboard comparativo
├── adapter_config.json # Adapter Qwen2.5-VL-3B (raiz)
├── adapter_model.safetensors # Pesos LoRA Qwen2.5-VL-3B
├── lightonocr_3_4b/ # 🏆 NOVO RECORDE ABSOLUTO (52.32%)
│ ├── adapter_config.json
│ ├── adapter_model.safetensors # 88 MB
│ ├── test_report.json # Relatório completo de teste
│ └── README.md
├── qwen2_5_vl_7b/ # SOTA Qwen2.5-VL-7B (52.11%)
│ ├── adapter_config.json
│ ├── adapter_model.safetensors # 177 MB
│ ├── test_report.json
│ └── README.md
└── qwen3_vl_8b/ # Qwen3-VL-8B (48.72%)
├── adapter_config.json
├── adapter_model.safetensors # 176 MB
├── test_report.json
└── README.md
import torch
from PIL import Image
from transformers import AutoProcessor, AutoModelForCausalLM
from peft import PeftModel
# Carregar processador e base model
processor = AutoProcessor.from_pretrained("lucasoc/sci-image-models", subfolder="lightonocr_3_4b")
base_model = AutoModelForCausalLM.from_pretrained(
"lightonai/LightOnOCR-3-4B",
torch_dtype=torch.float16,
device_map="auto"
)
model = PeftModel.from_pretrained(base_model, "lucasoc/sci-image-models", subfolder="lightonocr_3_4b")
model.eval()
import torch
from PIL import Image
from transformers import AutoProcessor, Qwen2_5_VLForConditionalGeneration
from peft import PeftModel
from qwen_vl_utils import process_vision_info
# Para Qwen2.5-VL-7B use subfolder="qwen2_5_vl_7b" e base "Qwen/Qwen2.5-VL-7B-Instruct"
# Para Qwen3-VL-8B use subfolder="qwen3_vl_8b" e base "Qwen/Qwen3-VL-8B-Instruct"
subfolder = "qwen2_5_vl_7b"
base_model_name = "Qwen/Qwen2.5-VL-7B-Instruct"
processor = AutoProcessor.from_pretrained("lucasoc/sci-image-models", subfolder=subfolder)
base_model = Qwen2_5_VLForConditionalGeneration.from_pretrained(
base_model_name,
torch_dtype=torch.float16,
device_map="auto"
)
model = PeftModel.from_pretrained(base_model, "lucasoc/sci-image-models", subfolder=subfolder)
model.eval()
# Processamento da figura
image = Image.open("exemplo_grafico_cientifico.png").convert("RGB")
messages = [
{
"role": "user",
"content": [
{"type": "image", "image": image},
{"type": "text", "text": "Extract all numerical data points from this scientific figure into a Markdown table."}
]
}
]
text = processor.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
image_inputs, _ = process_vision_info(messages)
inputs = processor(text=[text], images=image_inputs, return_tensors="pt").to("cuda")
with torch.inference_mode():
outputs = model.generate(**inputs, max_new_tokens=1024)
result = processor.batch_decode(outputs, skip_special_tokens=True)[0]
print(result)
col_count_penalty_weight = 2.0), reforço de cabeçalho (header_weight = 4.5) e terminação antecipada direcional sobre <eos> para evitar sobregeração de linhas vazias. Alcançou o recorde absoluto de 0.5232 com o LightOnOCR-3-4B.Repositório completo no GitHub: lucasdocunha/sci-image-markdown
qwen3_vl_8b/adapter_model.safetensors 177 MBlightonocr_3_4b/adapter_model.safetensors 88 MBqwen2_5_vl_7b/adapter_model.safetensors 20 MBadapter_model.safetensors 15 MBlightonocr_3_4b/training_args.bin 4.9 kBqwen2_5_vl_7b/training_args.bin 4.9 kBqwen3_vl_8b/training_args.bin 4.9 kBtraining_args.bin 4.8 kBQwen/Qwen2.5-VL-3B-Instruct