Skip to content

About

WeVisForensics is a self-evolving agent for omni AI-generated video detection, where a main investigator agent calls inspector sub-agents on chosen time windows to check appearance, physics, common sense, on-screen text, and audio.

Resources

Stars

64 stars

Watchers

0 watching

Forks

Latest commit

ย 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

WeVisForensics

Self-Evolving Agent for Omni AI-Generated Video Detection

Project Page Paper WeVisForensics-4B License

English | ็ฎ€ไฝ“ไธญๆ–‡

WeVisForensics treats AI-generated video detection as an investigation. A main agent, the investigator, watches a coarse overview and decides which artifact to examine, over which window, and when to conclude. It dispatches each inspection to a self-evolving library of forensic sub-agents, the inspectors, that cover visual appearance, physical consistency, common sense, on-screen text, and the audio track.

Teaser

โœจ Highlights

  • ๐Ÿ•ต๏ธ Adaptive investigation: the investigator calls only the inspectors a video needs, at the moments that matter, and stops as soon as the evidence is decisive.
  • ๐Ÿงฐ Omni-modal inspector library: four trained visual inspectors plus speech and speaker tools, so the same agent catches rendering artifacts, broken physics, impossible events, warped text, and mismatched voices.
  • ๐Ÿ” Self-evolving training (DTPO): the investigator and its inspectors co-evolve from shared interactions, with fast reinforcement learning for the investigator and slower refinement of the inspectors.
  • ๐Ÿ† State of the art: 95.2% average accuracy across in-domain, out-of-domain, and agentic benchmarks, 9.0 points above the strongest prior detector.

๐Ÿ“ข News

  • [2026-11] ๐ŸŽ‰ We release WeVisForensics: the technical report, the 4B LoRA weights, the inference package and the Gradio demo.

๐Ÿ“ TODO

  • Inference package
  • Gradio demo
  • Evaluation pipeline
  • Technical report on arXiv
  • Model weights on Hugging Face
  • AgenticCue benchmark

๐Ÿ† Performance at a Glance

Headline detection accuracy (%) of WeVisForensics-4B against the strongest prior method on each benchmark (such as Qwen3.5-397B, Gemini-3.1-Pro, and MLLM-based video forgery detectors like BusterX++, Skyra and VideoVeritas).

Split Benchmark Best Baseline WeVisForensics
๐Ÿ  In-domain GenBuster-Bench 94.3 97.7
๐ŸŒ Out-of-domain GenBuster-Bench++ 91.4 97.5
๐ŸŒ Out-of-domain MintVid General 82.2 88.0
๐Ÿงฉ Agentic AgenticCue 79.3 97.8
โญ Average 86.2 95.2

Each benchmark row reports the strongest prior detector on that benchmark. The Average row is the best average over prior detectors.

๐Ÿ“Š Full results (click to expand)
MethodGBGB++MintVid GeneralAgenticCueAvg.
HailuoJimengKlingSeedanceSora2Wan2.5VisualPhysicalOCRCommonAudio
Binary detectors
NSG-VD46.453.757.148.552.654.757.151.041.743.241.734.244.448.7
ReStraV51.966.959.556.855.664.050.854.955.554.651.647.051.857.0
Generic MLLMs
Qwen3.5-4B82.973.263.556.565.173.857.073.273.771.883.894.458.174.3
Qwen3.5-397B65.166.754.752.055.863.051.463.469.266.786.094.554.165.7
Qwen3-VL-8B44.855.252.050.450.563.052.655.961.758.672.291.947.855.1
Qwen3-Omni-30B-A3B50.755.251.751.952.961.454.656.357.554.870.685.643.155.8
Gemini-3.1-Pro69.454.355.154.454.645.348.654.961.861.663.463.463.159.6
MLLM-based video forgery detectors
BusterX++70.179.670.471.782.371.858.787.364.465.171.187.149.972.7
DeepTraceReward76.458.864.564.163.956.559.365.555.554.251.955.453.562.9
Skyra-RL68.255.751.751.753.563.450.659.683.483.874.086.968.564.6
VideoVeritas94.391.485.880.886.086.667.686.372.475.376.091.569.386.2
ARGUS86.478.961.856.565.167.656.173.573.371.180.490.564.276.2
Agentic investigation
WeVisForensics-SFT93.994.283.877.982.195.675.982.592.494.293.696.095.291.3
WeVisForensics-DTPO97.797.588.982.989.698.682.485.697.398.098.098.897.095.2

๐Ÿ—๏ธ How It Works

Overview

1. Investigator. The main agent reads a 1 FPS overview of up to 16 frames and, at each step, emits one JSON action: call an inspector on a time window, or answer real / fake. It reads each observation before deciding what to examine next, and concludes within five steps.

2. Forensic sub-agent library. Each inspector focuses on one artifact type, decodes its own window at 2 FPS and returns a verdict, a confidence, and a short report of what it saw.

Inspector Looks at Checks
๐ŸŽจ visual_appearance a time window texture, boundaries, flicker, lighting
โš™๏ธ physical_consistency a time window motion, anatomy, contact, materials
๐Ÿง  common_sense a time window causality, affordance, event order
๐Ÿ”ค ocr_consistency one moment text detection, then a glyph check on each crop
๐Ÿ—ฃ๏ธ voice_profile the audio track speaker age, gender, and affect against the visible speaker
๐Ÿ“ asr_analysis the audio track transcript content and timing

3. Dual-timescale co-evolution (DTPO). Interactions feed both levels: the investigator learns fast, through reinforcement learning with call-level credit for inspections worth making; the inspectors refine slowly, guided by annotated artifact intervals, to report subtle artifacts they once dismissed.

DTPO

๐Ÿš€ Quick Start

Installation

git clone https://github.com/Tencent/WeVisForensics.git && cd WeVisForensics
conda create -n wevisforensics python=3.10 -y && conda activate wevisforensics
conda install -c conda-forge ffmpeg -y
pip install -r requirements.txt && pip install -e .

WeVisForensics can be deployed in three ways. The multi-GPU setup gives each inspector its own vLLM server and suits large-scale evaluation. The single-GPU setup runs everything on one card and is the easiest way to try it locally. The Transformers setup needs no vLLM and backs the Gradio demo and the Hugging Face Space.

Option 1: Multi-GPU deployment

Merge the adapters, serve each inspector on its own GPU, and run the investigator in-process:

python scripts/merge_lora.py --base Qwen/Qwen3.5-4B \
  --adapters weights/WeVisForensics-4B-LoRA --output weights/WeVisForensics-4B-merged

MODEL_ROOT=weights/WeVisForensics-4B-merged ASR_MODEL=Qwen/Qwen3.5-4B \
  GPUS=0,1,2,3,4 bash scripts/serve_full.sh

Point engine.model in configs/multi_server.json at weights/WeVisForensics-4B-merged/main, then run:

python scripts/infer.py demo/examples/c04559bab78f9a8b5b7e.mp4

See docs/deployment.md for details.

Option 2: Single-GPU deployment

Here the investigator and all inspectors share one base model, switching between LoRA adapters inside a single vLLM process, so no merge step is needed. A single 24 GB GPU is enough:

BASE=Qwen/Qwen3.5-4B ADAPTERS=weights/WeVisForensics-4B-LoRA \
  GPU_MEMORY_UTILIZATION=0.66 bash scripts/serve_lora.sh

python scripts/infer.py demo/examples/c04559bab78f9a8b5b7e.mp4 \
  --config configs/lora_single_server.json --main-backend http

Option 3: Transformers (Gradio demo / Hugging Face Space)

The whole agent runs in-process with Transformers on one GPU with at least 24 GB. The investigator and the four visual inspectors share one copy of the base model, and the active role's adapter is merged into its weights before each call. OCR runs on CPU, so the same code also fits ZeroGPU. It pins its own PyTorch, so use a separate environment:

pip install -r demo/requirements.txt "gradio>=6.0"
WVF_ADAPTERS=weights/WeVisForensics-4B-LoRA python demo/app.py

Upload a video, pick a window of up to 16 s, and follow the investigation step by step. To deploy it as a Space, upload the contents of demo/ as the Space root; settings are listed in demo/README.md.

Python API

import asyncio
from main_agent import build_agent, load_config

agent = build_agent(load_config("configs/multi_server.json"))
# Single GPU: build_agent(load_config("configs/lora_single_server.json"), main_backend="http")
trajectory = asyncio.run(agent.run("demo/examples/c04559bab78f9a8b5b7e.mp4"))

print(trajectory.answer)            # "real" or "fake"
for step in trajectory.steps:       # every action, inspector call, and observation
    print(step["action"], step.get("observation"))

๐ŸŽฎ Gradio Demo

Live analysis runs on the Transformers backend of Option 3. To browse the ten recorded investigations in demo/examples/ without a GPU:

pip install "gradio>=6.0"
WVF_LOCAL=0 python demo/app.py

๐Ÿ“Š Evaluation

See evaluation/README.md.

๐Ÿ–ผ๏ธ Representative Visualizations

Turn-by-turn rollouts of WeVisForensics on held-out videos, covering visual appearance, physical consistency, OCR, common sense, voice profile and real videos, are available on our project page.

๐Ÿ“– Citation

If WeVisForensics is helpful to your work, please consider giving us a โญ and citing:

@misc{du2026wevisforensicsselfevolvingagentomni,
      title={WeVisForensics: Self-Evolving Agent for Omni AI-Generated Video Detection}, 
      author={Yipeng Du and Yuxi Li and Ying Zhang and Chong Sun and Chen Li and Jing Lyu and Ying Tai},
      year={2026},
      eprint={2611.21373},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/2611.21373}, 
}

๐Ÿ“œ License

WeVisForensics is released under the Apache-2.0 License. Third-party components keep their original licenses.

About

WeVisForensics is a self-evolving agent for omni AI-generated video detection, where a main investigator agent calls inspector sub-agents on chosen time windows to check appearance, physics, common sense, on-screen text, and audio.

Resources

Stars

64 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages