用指令微调大模型,直接从自然语言生成规范的流程图。
Instruction-Tuning Open-Weight Language Models for BPMN Model Generation
- 通过指令微调开源大模型,实现文本到BPMN图的直接生成。
- 生成结果在结构准确性和符合规范性上优于未微调模型。
- 适合需要快速生成流程图且注重隐私保护的开发者使用。
领域模型在软件工程中至关重要,能促进团队理解、指导开发并支持自动化分析与模型驱动开发。然而,由于建模耗时且需专业技能,从业者常跳过此步骤。本文提出IntruBPM,一种可复现的方法:构建文本-流程图配对数据,利用参数高效微调和量化技术,将开源大模型适配为轻量级本地部署模型。评估涵盖四方面:文本/代码相似度(BLEU、ROUGE-L、METEOR)、结构保真度(相对图编辑距离)、规范符合性(外部工具检测)及专家评审。基于多领域BPMN数据集子集,对比未微调基线与强大多媒体模型,在一致提示条件下,该模型在序列与结构指标上全面超越基线,资源消耗显著降低;规范分析与专家反馈表明生成图基本遵循BPMN最佳实践,是有效的起点,大幅减少建模负担。结果表明,指令微调提升结构准确性与鲁棒性,减少对复杂提示工程的依赖。模型与脚本已公开,支持复现与后续研究。
原文摘要 · Abstract (English)
Domain models are central to software engineering, as they enable a shared understanding, guide implementation, and support automated analyses and model-driven development. Yet, despite these benefits, practitioners often skip modeling because it is time-consuming and demands scarce expertise. We address this barrier by investigating whether open-weight large language models, adapted via instruction tuning, can generate high-quality BPMN process models directly from natural language descriptions in a cost-effective and privacy-preserving way. We introduce InstruBPM, a reproducible approach that prepares paired text-diagram data and instruction tunes an open source large language model with parameter-efficient fine-tuning and quantization for on-prem deployment. We evaluate the tuned model through complementary perspectives: (i) text/code similarity using BLEU, ROUGE-L, and METEOR, (ii) structural fidelity using Relative Graph Edit Distance, (iii) guidelines conformance using external tool checks, and (iv) a small expert review. Using a curated subset of a multi-domain BPMN dataset, we compare the tuned model with untuned open-weight baselines and strong proprietary models under consistent prompting regimes. Our compact tuned model outperforms all baselines across sequence and structural metrics while requiring substantially fewer resources; guideline analysis and expert feedback further indicate that the generated diagrams largely follow BPMN best practices and are useful starting points that reduce modeling effort. Overall, instruction tuning improves structural accuracy and robustness compared to untuned baselines and reduces reliance on heavy prompt scaffolding. We publicly share the trained models and scripts to support reproducibility and further research.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。