MaintainCoder: Maintainable Code Generation Under Dynamic Requirements

要約

最新のコード生成は、機能的正しさと実行効率に大きな進歩を遂げました。
ただし、これらのシステムは、多くの場合、実際のソフトウェア開発である保守性の重要な側面を見落としています。
動的要件を最小限に抑えて処理するために、メンテナンスを先駆的なソリューションとして提案します。
ウォーターフォールモデル、設計パターン、およびマルチエージェントコラボレーションを統合して、凝集を体系的に強化し、結合を減らし、適応性を向上させます。
また、要件の変更と維持努力に関する対応する動的メトリックを含むベンチマークであるメンテナンスベンチも紹介します。
実験は、既存のコード生成方法が要件が進化したときに保守性基準を満たすのに苦労していることを示しています。
対照的に、メンテナンスコダーは、より高い正確性、つまりパス@kで保守性メトリックを14〜30%改善します。
私たちの仕事は、維持可能なコード生成の基盤を提供するだけでなく、より総合的なコード品質の研究の必要性を強調しています。
リソース:https://github.com/iaar-shanghai/maintaincoder。

要約(オリジナル)

Modern code generation has made significant strides in functional correctness and execution efficiency. However, these systems often overlook a critical dimension in real-world software development: maintainability. To handle dynamic requirements with minimal rework, we propose MaintainCoder as a pioneering solution. It integrates Waterfall model, design patterns, and multi-agent collaboration to systematically enhance cohesion, reduce coupling, and improve adaptability. We also introduce MaintainBench, a benchmark comprising requirement changes and corresponding dynamic metrics on maintainance effort. Experiments demonstrate that existing code generation methods struggle to meet maintainability standards when requirements evolve. In contrast, MaintainCoder improves maintainability metrics by 14-30% with even higher correctness, i.e. pass@k. Our work not only provides the foundation of maintainable code generation, but also highlights the need for more holistic code quality research. Resources: https://github.com/IAAR-Shanghai/MaintainCoder.

arxiv情報

著者 Zhengren Wang,Rui Ling,Chufan Wang,Yongan Yu,Zhiyu Li,Feiyu Xiong,Wentao Zhang
発行日 2025-03-31 16:06:47+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.CL, cs.SE パーマリンク