KahimWong/SEED

[MM'26 Grand Challenge 3rd place] SEED: Simple ViT and Evolving Harness for Explainable Text Forgery Detection

5

stars

9

commits

Python

primary language

Aug 28, 2026

updated

document-ai
forgery-detection
harness

README

SEED

Simple ViT and Evolving Harness for Explainable Text Forgery Detection

arXiv Venue Rank License


πŸ† 3rd Place Solution for the ACM MM 2026 GenText-Forensics Challenge β€” detecting, localizing, and explaining text-centric document forgeries.


🧠 Overview

SEED is a modular forgery analysis pipeline with three stages:

StageComponentDescription
1️⃣Synthetic DataSimilarity-guided forgery generation across 5 manipulation types, with paired (clean, forged) sampling
2️⃣ViT DetectorDINOv3 ViT-L/16 + LoRA adaptation + EoMT mask head β€” unified detection & localization
3️⃣Meta-HarnessEvolving MLLM harness that converts detector outputs into structured forensic reports

SEED overview

Repository Layout

.
β”œβ”€β”€ base_trainer.py                     # Training utilities & metrics
β”œβ”€β”€ cfg.py                              # Runtime configuration
β”œβ”€β”€ ds.py                               # Datasets & dataloaders
β”œβ”€β”€ main.py                             # Train / validation / inference entry point
β”œβ”€β”€ model/
β”‚   β”œβ”€β”€ eomt_sep_query.py               # Main detector (DINOv3 + LoRA + EoMT)
β”‚   β”œβ”€β”€ lora.py                         # Single-expert LoRA modules
β”‚   β”œβ”€β”€ mask_classification_loss.py     # Mask2Former-style loss
β”‚   └── scale_block.py                  # ConvTranspose upscaling block
β”œβ”€β”€ meta_harness/
β”‚   β”œβ”€β”€ test_submission.py              # Generate challenge-format reports
β”‚   β”œβ”€β”€ precompute_submission_artifacts.py
β”‚   β”œβ”€β”€ harness.py                      # Report generation base class
β”‚   β”œβ”€β”€ llm_clients.py                  # OpenAI-compatible LLM client
β”‚   β”œβ”€β”€ overlay.py                      # Mask visualization helpers
β”‚   β”œβ”€β”€ report_utils.py                 # Report formatting utilities
β”‚   β”œβ”€β”€ template_report_boxreasons_coordspanrepair.py
β”‚   └── config.yaml                     # LLM API configuration
└── TDOC/                               # Auxiliary training & generation modules

βš™οΈ Environment Setup

# Create a Python 3.10 environment, then install dependencies
pip install -r requirements.txt

πŸ“Š Data Preparation

DatasetDescriptionLink
RealText-V2Original challenge datasetvankey/RealText-V2
RealText-V2-Syn25kOur synthetic dataJason37437/RealText-V2-Syn25k
Cross-domain test setsT-SROIE, OSTF, TPIC-13, RTMJason37437/Doc-Protocol-Data
Model CheckpointSEED (LoRA rank-1, DINOv3 ViT-L)Jason37437/SEED / Google Drive

πŸš€ Training

# 1. Edit cfg.py β†’ mode='train'
# 2. Set your data paths and GPU count
python main.py

πŸ“ˆ Evaluation

# 1. Edit cfg.py β†’ mode='val', eval_mode=['loc','det']
python main.py

πŸ“ Report Generation

The meta_harness/ pipeline converts detector outputs β†’ structured Markdown forensic reports.

# πŸ”‘ Set your OpenAI-compatible API key
export LINKAPI_API_KEY="your-api-key-here"

# πŸ–ΌοΈ  Step 1: Precompute overlays, bounding boxes, data URIs
python meta_harness/precompute_submission_artifacts.py

# πŸ“ Step 2: Generate reports via MLLM
python meta_harness/test_submission.py

Contributors

KahimWong

9 commits

KahimWong/SEED

[MM'26 Grand Challenge 3rd place] SEED: Simple ViT and Evolving Harness for Explainable Text Forgery Detection

5

stars

9

commits

Python

primary language

Aug 28, 2026

updated

document-ai
forgery-detection
harness

README

SEED

Simple ViT and Evolving Harness for Explainable Text Forgery Detection

arXiv Venue Rank License


πŸ† 3rd Place Solution for the ACM MM 2026 GenText-Forensics Challenge β€” detecting, localizing, and explaining text-centric document forgeries.


🧠 Overview

SEED is a modular forgery analysis pipeline with three stages:

StageComponentDescription
1️⃣Synthetic DataSimilarity-guided forgery generation across 5 manipulation types, with paired (clean, forged) sampling
2️⃣ViT DetectorDINOv3 ViT-L/16 + LoRA adaptation + EoMT mask head β€” unified detection & localization
3️⃣Meta-HarnessEvolving MLLM harness that converts detector outputs into structured forensic reports

SEED overview

Repository Layout

.
β”œβ”€β”€ base_trainer.py                     # Training utilities & metrics
β”œβ”€β”€ cfg.py                              # Runtime configuration
β”œβ”€β”€ ds.py                               # Datasets & dataloaders
β”œβ”€β”€ main.py                             # Train / validation / inference entry point
β”œβ”€β”€ model/
β”‚   β”œβ”€β”€ eomt_sep_query.py               # Main detector (DINOv3 + LoRA + EoMT)
β”‚   β”œβ”€β”€ lora.py                         # Single-expert LoRA modules
β”‚   β”œβ”€β”€ mask_classification_loss.py     # Mask2Former-style loss
β”‚   └── scale_block.py                  # ConvTranspose upscaling block
β”œβ”€β”€ meta_harness/
β”‚   β”œβ”€β”€ test_submission.py              # Generate challenge-format reports
β”‚   β”œβ”€β”€ precompute_submission_artifacts.py
β”‚   β”œβ”€β”€ harness.py                      # Report generation base class
β”‚   β”œβ”€β”€ llm_clients.py                  # OpenAI-compatible LLM client
β”‚   β”œβ”€β”€ overlay.py                      # Mask visualization helpers
β”‚   β”œβ”€β”€ report_utils.py                 # Report formatting utilities
β”‚   β”œβ”€β”€ template_report_boxreasons_coordspanrepair.py
β”‚   └── config.yaml                     # LLM API configuration
└── TDOC/                               # Auxiliary training & generation modules

βš™οΈ Environment Setup

# Create a Python 3.10 environment, then install dependencies
pip install -r requirements.txt

πŸ“Š Data Preparation

DatasetDescriptionLink
RealText-V2Original challenge datasetvankey/RealText-V2
RealText-V2-Syn25kOur synthetic dataJason37437/RealText-V2-Syn25k
Cross-domain test setsT-SROIE, OSTF, TPIC-13, RTMJason37437/Doc-Protocol-Data
Model CheckpointSEED (LoRA rank-1, DINOv3 ViT-L)Jason37437/SEED / Google Drive

πŸš€ Training

# 1. Edit cfg.py β†’ mode='train'
# 2. Set your data paths and GPU count
python main.py

πŸ“ˆ Evaluation

# 1. Edit cfg.py β†’ mode='val', eval_mode=['loc','det']
python main.py

πŸ“ Report Generation

The meta_harness/ pipeline converts detector outputs β†’ structured Markdown forensic reports.

# πŸ”‘ Set your OpenAI-compatible API key
export LINKAPI_API_KEY="your-api-key-here"

# πŸ–ΌοΈ  Step 1: Precompute overlays, bounding boxes, data URIs
python meta_harness/precompute_submission_artifacts.py

# πŸ“ Step 2: Generate reports via MLLM
python meta_harness/test_submission.py

Contributors

KahimWong

9 commits

Languages

Python

100.0%