TL;DR
This paper presents a multi-task learning architecture for detecting AI-generated text fragments in scientific papers. By employing two classification heads—one for binary human/AI detection and another for multi-class AI generation types—the system achieved a significant 9% improvement in macro F1-score on the DAGPap24 competition's development set, reaching 0.96 on the closed test set.
What Problem Does This Paper Address?
The rapid advancement of AI text generation models, like ChatGPT and Llama, has led to the creation of highly fluent and human-like text. While impressive, this poses a significant challenge for scientific integrity, as AI-generated fragments can be subtly embedded in research papers, potentially leading to plagiarism, fake studies, and misinformation. Detecting these fragments, especially within the specific domain of scientific writing where AI-generated content can be continuous over long spans, requires robust and specialized methods. This paper addresses the need for an improved AI-generated text detection system, specifically for scientific documents, by participating in the DAGPap24 competition.
Methods
The core of the proposed solution is a multi-task learning architecture built upon a BERT-like encoder. This architecture features two distinct classification heads:
- Linear A (Binary Classifier): This head is trained to distinguish between human-written text and any form of AI-generated text.
- Linear B (Multi-class Classifier): This head is trained to categorize AI-generated text into one of the four specific types defined by the competition (ChatGPT, NLTK-synonym, summarized, and a general AI-generated class).
The loss function aggregates errors from both heads, encouraging the model to learn a more generalized representation. For inference, the system first uses the binary classifier. If the confidence in AI generation exceeds a threshold, the multi-class classifier is then employed. This approach is motivated by the observation that AI-generated spans in scientific texts tend to be continuous and of significant length, rather than isolated token errors. The authors also experimented with different BERT-like encoders (SciBERT, Mistral, XLNet) and varied the input sequence length to optimize performance.
Datasets
The primary dataset used is the DAGPap24 competition dataset. This dataset consists of scientific texts where parts have been replaced by machine-generated sequences. Each token in the text is labeled as either human-written or belonging to one of four AI-generated categories:
- Human
- Generated by ChatGPT
- Generated using synonyms from NLTK
- Generated using an unnamed summarization model
The dataset was used for training and evaluating the proposed model.
Key Insights and Ideas
- Multi-task learning for improved generalization: Combining binary and multi-class classification tasks within a single architecture demonstrably improved the model's ability to generalize and reduced overfitting, leading to a significant performance boost.
- Span continuity is key: The authors observed that AI-generated fragments in scientific texts are often continuous and lengthy. This insight justifies the token-level classification approach and the subsequent grouping of tokens into spans, rather than relying solely on sequence-level classification.
- Domain-specific encoders matter: While general-purpose BERT models perform well, fine-tuning with domain-specific encoders like SciBERT proved crucial for achieving state-of-the-art results in the scientific domain.
- Input sequence length optimization: The experiments revealed that a specific input sequence length (350 token-words) yielded the best results, suggesting a trade-off between capturing sufficient context and avoiding information loss due to model input constraints.
Key Results
The proposed multi-task architecture, particularly when using SciBERT as the encoder and an input sequence length of 350 token-words, achieved:
- A 9% improvement in average macro F1-score on the development set, increasing from a baseline of 0.86 to 0.95.
- A score of 0.96 on the closed test set of the DAGPap24 competition, securing 5th place.
Limitations and Future Work
- Limitations: The paper notes that the input sequence length for BERT-like models is a constraint, and while they found an optimal length, it inherently limits the amount of context that can be processed at once. The performance might also be affected by the specific tokenization strategy.
- Future Work: The authors suggest exploring methods to add weights to the loss function during pre-training to better balance classes, especially if the distribution of metrics across classes is uneven. They also propose investigating this approach on larger datasets with more diverse text generation methods to further assess its robustness and generalizability.
Summary updated