arXiv論文メモ
新着一覧
cs.SE · 査読状況未確認

要件文の曖昧さが言語モデルのコード生成に与える影響

On the Impact of Requirement Smells in LLM-Based Code Generation

Hugo Villamizar, Jannik Fischbach, Mert Şahin, Julian Frattini, Alessio Ferrari, Alexander Korn, Andreas Vogelsang, Daniel Mendez

この論文をやさしく読む

ひとことで言うと

要件文の不明瞭さや表現上の問題が、言語モデルの生成コードの正しさにどう関係するかを調べた研究です。

何に役立つ?

コード生成に渡す要件文の点検や、生成後のテストの必要性を考える材料になります。

この研究の面白いところ

要件とコードの対応付けより、コード生成の正しさのほうが要件の品質問題に敏感な可能性を示しています。

どこまで分かった?

評価は4アプリケーションの要件とシステムテストによるものです。問題のない要件でも正しいコードが必ず得られるわけではありません。

v1のアブストラクトに基づくAI解説。日本語訳とは別に、用途の解釈を含みます。

アブストラクトの日本語訳

ソフトウェアの要件は、言語モデルを利用した開発のプロンプトに組み込まれることが多い。要件文の品質上の問題が、要件とコードの自動的な対応付けに影響することは近年示されているが、コード生成に及ぼす影響の実証的な証拠は限られていた。本研究では、対応付けに関する先行研究のデータセットと要件品質問題の分類を再利用し、言語モデルが生成したコードの機能的な正しさも評価する。4種類のアプリケーションの要件と対応するシステムテストからなるベンチマークを使い、明確な要件に意味、構文、語彙の各種の問題を段階的に加え、生成された実装への影響を分析した。その結果、問題を含む箇所の密度が高くなるほど、テスト群で測る機能的な正しさは概して低くなる傾向が見られた。ただし、問題のない要件でも誤ったコードが生成され得た。問題の種類による影響はおおむね似ていた。これは、言語モデルによるコード生成で要件の品質が重要であることを示す追加の実証結果だが、質の高い要件だけで正しさは保証されず、使用する言語モデルなど複数の要因に左右される。先行研究で対応付けへの影響は小さかったのに対し、コード生成のほうが影響を受けやすい可能性が示された。全体として、言語モデルを用いるソフトウェア開発では、課題ごとに要件品質の影響をさらに調べる必要がある。

v1の要旨から自動生成。本文の精読・人による確認は未実施。

初稿
2026-09-24(UTC)
最新改訂
2026-09-24 · v1
査読・掲載
査読状況未確認
arXivで読むPDF

更新履歴

取得できた版を表示。版の更新は査読済みを意味しません。過去版の本文差分は未解析です。

原文の要旨

Software requirements are typically incorporated into prompts used in LLM-assisted software development. Recent work has shown that requirement smells can affect automated traceability between requirements and code, but empirical evidence on their effects in code generation remains limited. To address this gap, we build upon a prior study on automated traceability by reusing its dataset and requirement smell taxonomy, while extending it to evaluate the functional correctness of LLM-generated code. Using a benchmark consisting of requirements and corresponding system tests for four applications, we progressively introduced semantic, syntactic, and lexical smells into otherwise clear requirements and analyzed their influence on generated implementations. Our results suggest that increasing \textit{smell density} was generally associated with lower test-suite-based functional correctness, although non-smelly requirements could still produce faulty code. We also found that different smell categories had similar effects. These findings provide additional empirical evidence of the importance of requirement quality in LLM-assisted code generation, while showing that high-quality requirements alone do not guarantee correctness, as these depends on several factors, including the LLM. Compared with previous work, our results suggest that the impact of requirement smells depends on the software engineering task: whereas their effects on traceability were modest, code generation appears more sensitive. Overall, this work motivates further investigation into task-dependent quality effects in LLM-assisted software engineering.

著者のコメント

This paper has been accepted for presentation at the 27th International Conference on Product-Focused Software Process Improvement (PROFES 2026)

arXiv ID: 2609.29208 / 要約の誤りについて