Abstract
The rapid advancement of large language models (LLMs) has made detecting AI-generated text an increasingly critical challenge. Traditional methods often fail to capture the nuanced semantic differences between human and machine-generated content. We therefore propose a novel approach based on semantic similarity analysis, leveraging a multi-layered architecture that combines a pre-trained DeBERTa-v3-large model, Bi-directional LSTMs, and linear attention pooling to capture both local and global semantic patterns. To enhance performance, we employ advanced input and output augmentation techniques such as sector-level context integration and wide output configurations. These techniques enable the model to learn more discriminative features and generalize across diverse domains. Experimental results show that this approach works better than traditional methods, proving its usefulness for AI-generated text detection and other text comparison tasks.
Introduction
The proliferation of generative AI tools like ChatGPT has necessitated the development of robust detection mechanisms to mitigate misinformation and maintain academic integrity. Conventional detection strategies typically rely on surface-level linguistic features, such as word frequency or perplexity. However, modern LLMs have become adept at mimicking these human-like traits, rendering traditional methods less effective.
This research posits that while human and AI-generated texts may be semantically equivalent at a surface level, the underlying structural evolution of ideas differs fundamentally. By framing AI detection as a semantic similarity analysis problem, we aim to capture these subtle differences in thought structure rather than just syntactic patterns.
Methodology
The proposed framework utilizes a multi-layered ensemble neural network architecture designed to extract deep semantic relationships.
Architectural Components
- Transformer Backbone: The core of the model is a pre-trained DeBERTa-v3-large model. Its disentangled attention mechanism effectively separates content from positional information, which is crucial for fine-grained semantic analysis.
- Bi-LSTM Enhancement: To capture long-range sequential dependencies and the logical flow of ideas, the transformer's output is processed through a Bi-directional LSTM layer.
- Linear Attention Pooling: Instead of standard global pooling, we implement learned attention weights to dynamically focus on the most salient semantic features while filtering out noise.
Training Strategies
- Adversarial Weight Perturbation (AWP): To enhance robustness and generalization, AWP is introduced during the second training epoch, simulating adversarial attacks on model weights.
- Dynamic Target Shuffling: Target sequences are shuffled during training to expose the pooling layer to a wider variety of semantic combinations.
- Contextual Augmentation: Sector-level context data is integrated directly into the input to provide the model with hierarchical domain knowledge.
Data and Experimental Setup
The experimental data consists of anchor phrases, target sequences, and sector-level contexts. To ensure a balanced distribution and prevent data leakage, the dataset was stratified by anchor phrases across training folds. This structure allows the model to learn domain-specific semantic nuances, particularly useful in specialized fields like patent analysis.
Results
An ablation study was conducted to evaluate the impact of each architectural component. The results demonstrate a consistent improvement in performance as layers are added.
- Baseline (DeBERTa-v3-large): Achieved a Pearson correlation of 86.1%, an F1-Score of 88.5%, and an AUC of 91.2%.
- DeBERTa + Bi-LSTM: Improved Pearson correlation to 86.6% and AUC to 92.3%.
- DeBERTa + Bi-LSTM + Attention Pooling: Further increased Pearson to 87.2% and AUC to 93.5%.
- Final Ensemble Model: The complete ensemble achieved a peak Pearson correlation of 87.5%, an F1-Score of 91.2%, and an AUC of 94.7%.
Discussion and Conclusion
The findings underscore the importance of prioritizing deep semantic mapping over surface-level syntax for AI text detection. While LLMs can mimic human vocabulary, replicating the complex "evolution of thought" remains a significant challenge for current generative models. The integration of Bi-LSTMs with modern Transformers provides a measurable performance boost by capturing these sequential dependencies.
Future work will focus on domain-specific pre-training to improve generalization in niche fields such as legal or scientific discourse. Additionally, exploring further data augmentation techniques will be a priority to enhance the framework's resilience against evolving generative models.
Summary updated