arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2605.13773cs.SEcs.AIcs.LO
收藏

(如何)大型语言模型理解高层次消息序列图?

(How) Do Large Language Models Understand High-Level Message Sequence Charts?

Department of Informatics, King's College London(伦敦国王学院信息学院)

Mohammad Reza Mousavi

AI总结:

研究探讨大型语言模型对高层次消息序列图(HMSC)语义的理解程度,通过129个语义任务测试三个模型,发现其在基本概念上准确率较高,但在抽象、组合及轨迹计算等任务上表现较差。

摘要:

大型语言模型(LLMs)被广泛用于自动化软件开发生命周期中的任务。然而,这些任务是否与所处理的 Artefacts 的语义一致尚不明确。本文针对高层次消息序列图(HMSCs)探讨这一问题。HMSCs 是具有严格形式语义的可视化模型,已被用于多种用途,包括作为统一建模语言(UML)序列图的基础。我们通过测试三个 LLMs(Gemini-3、GPT-5.4 和 Qwen-3.6)在129个语义任务上的表现,来检验它们对 HMSCs 语义的理解程度。结果表明,LLMs 对 HMSCs 的形式语义的理解仅是中等的(整体准确率约 52%),在不同语义概念上存在显著差异:虽然 LLMs 在基本语义概念上表现良好(约 88% 准确率),但在涉及抽象和组合的任务中表现较差(约 36% 准确率),在轨迹和 LTSs 的任务中也表现不佳(约 42% 准确率)。特别是,所有三个 LLMs 都无法理解 co-region 和显式因果依赖的概念,并且从未在语义保持转换中使用这些概念。

英文摘要:

Large Language Models (LLMs) are being employed widely to automate tasks across the software development life-cycle. It is, however, unclear whether these tasks are performed consistently with respect to the semantics of the artefacts being handled. This question is particularly under-researched concerning architectural design specification. In this paper, we address this question for High-Level Message Sequence Charts (HMSCs). These are visual models with a rigorous formal semantics that have been used for various purposes, including as a foundation for Sequence Diagrams in the Unified Modelling Language (UML). We examine whether LLMs "understand" the semantics of HMSCs by examining three LLMs (Gemini-3, GPT-5.4, and Qwen-3.6) on how they perform 129 semantic tasks ranging from querying basic semantic constructs in HMSCs (i.e., events and their ordering) to semantic-preserving abstractions and compositions, and calculating the set of traces and trace-equivalent labelled transition systems. The results show that LLMs only have a modest understanding of the formal semantics of HMSCs (ca. 52% overall accuracy), with great variability across different semantic concepts: while LLMs seem to understand the basic semantic concepts of MSCs (ca. 88% accuracy), they struggle with semantic reasoning in tasks involving abstraction and composition (ca. 36% accuracy) and traces and LTSs (ca. 42% accuracy). In particular, all three LLMs struggle with the notions of co-region and explicit causal dependencies and never employed them in semantic-preserving transformations.

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

↑