MD-ProTector: Positioning Multiple Data-Driven Prototypes for LLM-Generated Text Detection

Jinmo Han, Jimin Hong, Chanyeong Moon, Ju Yeon Kang, Seonuk Kim, Nam Soo KimarXiv 2026 · arXiv

TL;DR

MD-ProTector improves LLM-generated text detection by representing human and machine text classes using multiple trainable "prototypes" rather than a single global representation. By introducing a novel Prototype Positioning loss that isolates within-class variation from overarching class features, it effectively maps diverse writing styles and domains, achieving state-of-the-art performance across major benchmarks.

What Problem Does This Paper Address?

Detecting LLM-generated text in the wild is notoriously difficult due to massive diversity in writing styles, domains, languages, and generator models. Standard supervised detectors typically append a binary classification head to a text encoder, forcing all this rich intra-class variation into just two absolute categories (human vs. machine). This coarse supervision washes out sub-structural nuances.

While some recent approaches attempt to use multiple reference vectors (or "prototypes") to capture sub-groups, they lack explicit objectives to distribute these prototypes effectively. Without a dedicated positioning mechanism, multiple prototypes often become redundant, clumping together or capturing overlapping patterns rather than distinct stylistic sub-genres.

Methods

MD-ProTector uses a lightweight text encoder to map input text into a normalized embedding space. Instead of relying on a single global boundary, it maintains a bank of $R$ learnable prototypes for both the human and machine classes.

The core innovation lies in its three-part training objective, which balances class alignment with stylistic diversity:

  1. Prototype-to-Class (P2C) Loss: Aligns each prototype with its global class "hub" (the average direction of the class in a mini-batch) to preserve basic class identity.
  2. Sample-to-Prototype (S2P) Loss: Computes a soft assignment of text samples to the closest prototype within their true class, pulling samples toward their best-fit representative.
  3. Prototype Positioning (PP) Loss: This is the key mechanism. It strips away the shared class-hub direction from both samples and prototypes, leaving only the "residual" variation. It then forces each prototype's residual vector to align with the aggregate residual variation of its assigned samples. This ensures prototypes specialize in distinct sub-features (e.g., instructional text vs. academic prose) rather than duplicating each other.

During inference, the model scores an input text based on its maximum similarity to the human prototype bank minus its maximum similarity to the machine prototype bank, as illustrated below:

Figure 1: Prototype-Based Inference. Given an in- put text x, MD-ProTector encodes it into a normal- ized embedding z and compares it with the machine and human prototype banks. The detection score is S(z) = s1(z) −s0(z), where s0(z) and s1(z) are the maximum similarities to the machine and human proto- types, respectively.

The complete interplay of these three losses during training is visualized here:

Overview of training objectives

Datasets

The authors evaluated MD-ProTector across five settings extracted from three large-scale benchmarks:

  • MAGE: Used to evaluate domain and generator generalization. It includes 10 source domains and 27 model variants. Testing included Cross-Domain Cross-Model (CDCM), Unseen Domains, and Unseen Models settings.
  • M4: A benchmark for multi-generator, multi-domain, and multilingual text detection (covering languages like Arabic, German, Italian, and English).
  • RAID: A robust benchmark specifically designed to test detector defenses against adversarial attacks (such as paraphrasing, homoglyph substitutions, and formatting alterations) and decoding variations.

Key Insights and Ideas

  • Orthogonal Residuals Prevent Collapse: Simply adding more prototypes doesn't guarantee better coverage. By optimizing prototypes in a hub-orthogonal residual space, the model successfully forces them to diversify and avoid complete assignment collapse.
  • Data-Driven Initialization Helps: Initializing prototypes using K-Means clustering on actual data embeddings significantly outperforms random initialization, providing a structurally sound starting point for optimization.
  • Organization Over Capacity: Performance peaks at a moderate number of prototypes ($R=8$) and slightly declines with larger banks. This indicates that once a model has enough capacity to capture major sub-genres, the organization and positioning of those prototypes matter far more than simply adding more vectors.

Key Results

  • State-of-the-Art Recall: MD-ProTector achieved the highest Average Recall (AvgRec) on MAGE CDCM (95.14%) and RAID (88.18%), consistently ranking in the top two across all five evaluation settings.
  • Adversarial Robustness: On the challenging RAID benchmark, it delivered the highest AUROC (95.41%) and the lowest False Positive Rate at a 95% true positive threshold (FPR95 of 27.78%), substantially outperforming other structured encoder baselines like DeTeCtive and DSVDD.

Limitations and Future Work

  • Strictly Binary Assumption: The model operates under a fixed-label binary detection setting. It cannot currently handle more complex, nuanced scenarios like human-AI co-edited text or documents with partial generation.
  • Fixed Cardinality: The number of prototypes per class ($R$) is a fixed hyperparameter. The authors note that adaptive mechanisms to dynamically adjust prototype cardinality based on data characteristics remain unexplored.
  • No Continual Adaptation: MD-ProTector is trained on static splits. In real-world deployments, generator distributions and prompting styles drift over time, meaning future work must address continual prototype adaptation under temporal distribution shifts.

Summary updated

Abstract

As LLM-generated content becomes more sophisticated, detection systems for distinguishing those texts from human-written text must operate at scale while handling diverse writing styles, domains, languages, and generator models. Input-only encoder detectors are suitable for practical deployment setting, but standard binary classification supplies only the class label and does not explicitly organize the substantial variation within either class. We propose MD-ProTector, which represents each class with multiple trainable reference vectors in the encoder embedding space, referred to as prototypes. These prototypes provide separate decision boundaries for different groups of texts within the same class. However, adding multiple prototypes alone does not determine which variation each prototype should represent. MD-ProTector addresses this problem with Prototype Positioning loss, which separates class-level structure from the within-class variation that differentiates individual prototypes. Evaluated across five settings from three large-scale benchmarks covering domain, generator, language, and adversarial variation, MD-ProTector achieves the highest AvgRec on MAGE CDCM and RAID and the highest AUROC and lowest FPR95 on RAID among the compared encoder-based methods.
BibTeX
@misc{han2026md,
  author = {Jinmo Han and Jimin Hong and Chanyeong Moon and Ju Yeon Kang and Seonuk Kim and Nam Soo Kim},
  title = {{MD-ProTector: Positioning Multiple Data-Driven Prototypes for LLM-Generated Text Detection}},
  year = {2026},
  eprint = {2608.10459},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2608.10459},
}
Figure