論文の概要: KTester: Leveraging Domain and Testing Knowledge for More Effective LLM-based Test Generation
- arxiv url: http://arxiv.org/abs/2511.14224v1
- Date: Tue, 18 Nov 2025 07:57:58 GMT
- ステータス: 翻訳完了
- システム内更新日: 2025-11-19 16:23:53.000553
- Title: KTester: Leveraging Domain and Testing Knowledge for More Effective LLM-based Test Generation
- Title(参考訳): KTester: LLMベースのテスト生成にドメインとテストの知識を活用する
- Authors: Anji Li, Mingwei Liu, Zhenxi Chen, Zheng Pei, Zike Li, Dekun Dai, Yanlin Wang, Zibin Zheng,
- Abstract要約: 本稿では、プロジェクト固有の知識を統合し、ドメイン知識をテストする新しいフレームワークであるKTesterについて述べる。
我々は、KTesterを複数のオープンソースプロジェクトで評価し、最先端のLCMベースラインと比較した。
結果は、KTesterが6つの主要なメトリクスで既存のメソッドを大幅に上回っていることを示している。
- 参考スコア(独自算出の注目度): 36.93577367023509
- License: http://arxiv.org/licenses/nonexclusive-distrib/1.0/
- Abstract: Automated unit test generation using large language models (LLMs) holds great promise but often struggles with generating tests that are both correct and maintainable in real-world projects. This paper presents KTester, a novel framework that integrates project-specific knowledge and testing domain knowledge to enhance LLM-based test generation. Our approach first extracts project structure and usage knowledge through static analysis, which provides rich context for the model. It then employs a testing-domain-knowledge-guided separation of test case design and test method generation, combined with a multi-perspective prompting strategy that guides the LLM to consider diverse testing heuristics. The generated tests follow structured templates, improving clarity and maintainability. We evaluate KTester on multiple open-source projects, comparing it against state-of-the-art LLM-based baselines using automatic correctness and coverage metrics, as well as a human study assessing readability and maintainability. Results demonstrate that KTester significantly outperforms existing methods across six key metrics, improving execution pass rate by 5.69% and line coverage by 8.83% over the strongest baseline, while requiring less time and generating fewer test cases. Human evaluators also rate the tests produced by KTester significantly higher in terms of correctness, readability, and maintainability, confirming the practical advantages of our knowledge-driven framework.
- Abstract(参考訳): 大きな言語モデル(LLM)を使用した自動単体テスト生成は大きな可能性を秘めているが、現実のプロジェクトでは正確かつ保守性のあるテストを生成するのに苦労することが多い。
本稿では、プロジェクト固有の知識を統合し、LLMベースのテスト生成を強化するためのドメイン知識をテストする新しいフレームワークであるKTesterについて述べる。
提案手法は,まず静的解析によってプロジェクト構造と利用状況の知識を抽出し,モデルにリッチなコンテキストを提供する。
次に、テストケース設計とテストメソッド生成のドメイン知識による分離と、LLMが多様なテストヒューリスティックを検討するためのマルチパースペクティブなプロンプト戦略を併用する。
生成されたテストは構造化テンプレートに従っており、明確さと保守性を改善している。
我々は、KTesterを複数のオープンソースプロジェクトで評価し、自動的正しさとカバレッジメトリクスを用いて最先端のLCMベースラインと比較し、可読性と保守性を評価する。
その結果、KTesterは6つの主要なメトリクスで既存のメソッドを著しく上回り、実行パス率を5.69%改善し、最強のベースラインを8.83%上回った。
人間の評価者はまた、KTesterが生成したテストの正確性、可読性、保守性に関して著しく高く評価し、知識駆動フレームワークの実践的な利点を確認します。
関連論文リスト
- Clarifying Semantics of In-Context Examples for Unit Test Generation [16.066591207494046]
CLASTは, ユニットテストを体系的に洗練し, セマンティックな明瞭さを向上する手法である。
CLASTは、テストの有効性の維持と意味的明確性の向上の両方において、最先端の洗練技術であるUTgenよりも優れている。
調査対象者の85.33%以上がCLAST精製検査のセマンティックな明瞭さを好んだ。
論文 参考訳(メタデータ) (2025-10-02T13:15:40Z) - PALM: Synergizing Program Analysis and LLMs to Enhance Rust Unit Test Coverage [14.702182387149547]
本稿では,大規模言語モデル(LLM)を活用して高カバレッジ単体テストを生成する手法であるPALMを提案する。
PALMはプログラム解析を行い、関数内の分岐条件を特定し、それを経路制約に結合する。
このアプローチを実装し、それを15のオープンソースのRustクラッドで評価します。
論文 参考訳(メタデータ) (2025-06-10T17:21:21Z) - TestForge: Feedback-Driven, Agentic Test Suite Generation [7.288137795439405]
TestForgeは、現実世界のコードのための高品質なテストスイートをコスト効率よく生成するように設計されたエージェントユニットテスティングフレームワークである。
TestForgeは、最先端の検索ベースの技術と比較して、より自然で理解しやすいテストを生成する。
論文 参考訳(メタデータ) (2025-03-18T20:21:44Z) - ProjectTest: A Project-level LLM Unit Test Generation Benchmark and Impact of Error Fixing Mechanisms [48.43237545197775]
単体テスト生成はLLMの有望かつ重要なユースケースとなっている。
ProjectTestは、Python、Java、JavaScriptをカバーするユニットテスト生成のためのプロジェクトレベルのベンチマークである。
論文 参考訳(メタデータ) (2025-02-10T15:24:30Z) - StructTest: Benchmarking LLMs' Reasoning through Compositional Structured Outputs [78.84060166851805]
StructTestは、大規模な言語モデル(LLM)を合成命令に従って構造化出力を生成する能力に基づいて評価する、新しいベンチマークである。
評価はルールベースの評価器を用いて決定的に行われ、新しいタスクやデータセットに容易に拡張できる。
StructTestは、Deepseek-V3/R1やGPT-4oといったトップパフォーマンスモデルでも、依然として難しいままです。
論文 参考訳(メタデータ) (2024-12-23T22:08:40Z) - Self-Evaluation Improves Selective Generation in Large Language Models [54.003992911447696]
オープンエンド生成タスクをトークンレベルの予測タスクに再構成する。
我々はLSMに答えを自己評価するように指示する。
自己評価に基づくスコアリング手法をベンチマークする。
論文 参考訳(メタデータ) (2023-12-14T19:09:22Z)
関連論文リストは本サイト内にある論文のタイトル・アブストラクトから自動的に作成しています。
指定された論文の情報です。
本サイトの運営者は本サイト(すべての情報・翻訳含む)の品質を保証せず、本サイト(すべての情報・翻訳含む)を使用して発生したあらゆる結果について一切の責任を負いません。