arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2604.02398cs.SEcs.AI
收藏

利用大语言模型和Bug参考改进MPI错误检测与修复

Improving MPI Error Detection and Repair with Large Language Models and Bug References

Dept. of Computer Science, University of Central Florida(中佛罗里达大学计算机科学系)

Scott Piersall, Yang Gao, Shenyang Liu, Liqiang Wang

AI总结:

本文提出结合Few-Shot Learning、Chain-of-Thought和Retrieval Augmented Generation技术,提升大语言模型在MPI错误检测与修复中的准确性,实验结果显示错误检测准确率从44%提升至77%。

摘要:

Message Passing Interface (MPI) 是高性能计算(HPC)中的基础技术,广泛用于大规模模拟和分布式训练(例如在PyTorch和TensorFlow等机器学习框架中)。然而,由于进程间的复杂交互和消息传递与同步的复杂性,维护MPI程序仍然具有挑战性。随着大语言模型(如ChatGPT)的发展,采用此类技术进行自动化错误检测和修复变得有吸引力。然而,我们的研究发现,直接应用大语言模型(LLMs)效果不佳,主要原因是这些模型缺乏关于正确和错误使用的重要知识,特别是MPI程序中发现的bug。在本文中,我们设计了一种结合Few-Shot Learning(FSL)、Chain-of-Thought(CoT)推理和Retrieval Augmented Generation(RAG)技术的bug检测与修复技术,以增强大语言模型检测和修复错误的能力。令人惊讶的是,这种增强显著提高了错误检测准确性,从使用ChatGPT直接的基线方法的44%提升至77%。此外,我们的实验还表明,我们的bug referencing技术能够很好地泛化到其他大语言模型中。

英文摘要:

Message Passing Interface (MPI) is a foundational technology in high-performance computing (HPC), widely used for large-scale simulations and distributed training (e.g., in machine learning frameworks such as PyTorch and TensorFlow). However, maintaining MPI programs remains challenging due to their complex interplay among processes and the intricacies of message passing and synchronization. With the advancement of large language models like ChatGPT, it is tempting to adopt such technology for automated error detection and repair. Yet, our studies reveal that directly applying large language models (LLMs) yields suboptimal results, largely because these models lack essential knowledge about correct and incorrect usage, particularly the bugs found in MPI programs. In this paper, we design a bug detection and repair technique alongside Few-Shot Learning (FSL), Chain-of-Thought (CoT) reasoning, and Retrieval Augmented Generation (RAG) techniques in LLMs to enhance the large language model's ability to detect and repair errors. Surprisingly, such enhancements lead to a significant improvement, from 44% to 77%, in error detection accuracy compared to baseline methods that use ChatGPT directly. Additionally, our experiments demonstrate our bug referencing technique generalizes well to other large language models.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑