Abstract
Transformer-based models have achieved remarkable results in natural language processing (NLP) tasks such as text classification and machine translation. However, their computational complexity and resource demands pose challenges for scalability and accessibility. This research proposes a hybrid quantum-classical transformer model that integrates a quantum-enhanced attention mechanism to address these limitations. By leveraging quantum kernel similarity and variational quantum circuits (VQC), the model captures intricate token dependencies while improving computational efficiency. Experimental results on the IMDb dataset demonstrate that the quantum-enhanced model outperforms the classical baseline across all key metrics, achieving a 1.5% improvement in accuracy (65.5% vs. 64%), precision, recall, and F1 score. Statistical significance tests validate these improvements, highlighting the robustness of the quantum approach. These findings illustrate the transformative potential of quantum-enhanced attention mechanisms in optimizing NLP architectures for real-world applications.
Abstract (translated)
基于Transformer的模型在自然语言处理(NLP)任务中,如文本分类和机器翻译方面取得了显著成果。然而,这些模型由于计算复杂性和资源需求而面临可扩展性和易用性的挑战。本研究提出了一种混合量子-经典Transformer模型,该模型集成了增强型注意力机制,以解决这些问题。通过利用量子核相似度和变分量子电路(VQC),该模型能够捕捉到复杂的令牌依赖关系,并提高计算效率。在IMDb数据集上的实验结果显示,经过量子增强的模型在所有关键指标上均超越了经典基线模型,准确率提高了1.5%(从64%提升至65.5%),同时精度、召回率和F1分数也有所改善。统计显著性测试验证了这些改进,并突显出量子方法的鲁棒性。这些发现展示了量子增强注意力机制在优化NLP架构以应用于实际场景中的变革潜力。
URL
https://arxiv.org/abs/2501.15630