Research – SEL@KIT そふらぼ https://se.is.kit.ac.jp/ja The software engineering laboratory in Kyoto Sat, 20 Sep 2025 14:06:19 +0000 ja hourly 1 https://wordpress.org/?v=6.8.2 https://se.is.kit.ac.jp/wp/wp-content/uploads/2016/09/cropped-imori512_trans-1-32x32.png Research – SEL@KIT そふらぼ https://se.is.kit.ac.jp/ja 32 32 78478245 バグレポートとコミットのリンク付け https://se.is.kit.ac.jp/ja/portfolio/which-issue-link-algorithms-should-we-use/ Mon, 15 Sep 2025 00:50:57 +0000 https://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=2397

SZZアルゴリズムは、ソフトウェアの不具合を「いつ入り込んだか」を予測する研究で非常に重要な役割を果たしています。これまでの多くの研究は、このSZZを使って「不具合を生んだ変更(コミット)」を特定し、その情報を基に不具合予測モデルを作ったり評価したりしています。

SZZは大きく2つの段階から成り立っています。

  1. 課題管理システムにある不具合報告と、バージョン管理システムにある「不具合を直した変更」とを結びつける段階(これを ILA: Issue-Link Algorithm と呼びます)。
  2. その修正コミットをさかのぼって、「不具合を生んだ変更」を探し出す段階。

2つ目の段階には cregit というような既存のツールが利用できますが、1つ目の段階についてはさまざまな方法(ILA)が提案されているものの、同じ条件で大規模に比較した研究はこれまでありませんでした。つまり、「どのILAが一番正確なのか」については、まだ結論が出ていなかったのです。

そこで本研究では、文献調査で集めた10種類のILAを比較し、不具合修正コミットをどの程度正確に見つけられるかを調べました。さらに、ILAやその組み合わせを使った場合の不具合予測モデルの精度についても検証しました。5つのオープンソースプロジェクトで実験したところ、いずれのILAやその組み合わせでも「修正コミットの見落とし」による悪影響を防げることがわかりました。特に、自然言語の類似度、Phantomヒューリスティクス、ランダムフォレスト、サポートベクターマシンを組み合わせた方法が、統計的に最も高い精度を示しました。

最後に、実際にILAを活用する際のガイドラインをまとめ、推奨事項として提示しました。

]]>
2397
トークンレベルSZZの提案と評価 https://se.is.kit.ac.jp/ja/portfolio/benefits-and-pitfalls-of-token-level-szz/ Mon, 15 Sep 2025 00:25:53 +0000 https://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=2384

SZZという手法は、ソフトウェア開発で「どの変更がバグを生んだのか」を突き止めるための標準的な方法として広く使われています。SZZはGitのようなソースコード管理システムを使って、コードの変更履歴(コミット履歴)をさかのぼる必要があります。しかし、これらのシステムは「行単位」の変更しか記録しないため、履歴に偏りが生じ、正しくバグの原因を追跡できないことがあります。

そこで私たちは、より細かい「トークン単位」(単語や記号レベル)の変更を使った場合に、SZZの精度がどうなるかを調べました。68のオープンソースプロジェクトを対象に実験したところ、行単位では見逃してしまう2件の「バグを生んだコミット」を新たに発見できました。また、人手による確認では、コードの整形や空白の変更など、本来バグと関係ないコミットを誤って検出してしまうケースも減らせることがわかりました。

ただしその一方で、全体の精度(F1スコア)を指標とした場合、0.081ポイント分下がるというトレードオフも見られました。まとめとして、トークン単位と行単位の追跡を比べたときの「3つの利点」と「5つの注意点」を整理しました。

]]>
2384
C言語学習をゲーム感覚で! https://se.is.kit.ac.jp/ja/portfolio/gamification_c_programming/ Mon, 17 Mar 2025 13:39:09 +0000 https://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=2229

# 「Aqua Dungeon」の開発とその効果

C言語は多くの情報工学の学生にとって重要なプログラミング言語ですが、その学習は文法やアルゴリズムの理解に時間がかかるため、初心者には難しいとされています。本研究では、学習者のモチベーションを向上させるために「ゲーミフィケーション」の手法を取り入れたC言語学習支援アプリ「Aqua Dungeon」を開発しました。

Aqua Dungeonの概要

Aqua Dungeonは、C言語の学習をサポートするモバイルアプリで、特定の授業や演習の復習・予習を目的としています。本アプリには、以下のようなゲーミフィケーション要素が組み込まれています。

  • レベルシステム:問題を解くことでポイントを獲得し、レベルアップが可能。
  • バッジシステム:特定の条件を達成することでバッジが獲得できる。
  • ランキングシステム:他の学習者との比較ができる。
  • カレンダー機能:学習の継続状況を可視化。

さらに、適応学習の手法を導入し、学習者の理解度に応じて問題の難易度を調整する仕組みも搭載されています。

実験とその結果

本研究では、Aqua Dungeonの有効性を検証するために以下の2つのケーススタディを実施しました。

ケーススタディ1:授業での使用実験

対象:京都工芸繊維大学のソフトウェア演習II受講生
期間:2023年6月15日~7月26日
結果:
* 参加者のモチベーションの向上が確認された。
* バッジやランキング要素が学習の継続を促進。
* カレンダー機能の利用率が低かったため改善の余地あり。

ケーススタディ2:A/Bテストによる比較

対象:研究室の学生(ソフトウェア演習I・II履修者)
期間:2023年12月11日~2024年1月15日
方法:ゲーミフィケーション要素の有無を比較
結果:

  • ゲーミフィケーションを導入したグループの方がモチベーションが高かった。
  • 特に「ランキング」と「カレンダー」が学習継続の重要な要素となった。

結論と今後の展望

Aqua Dungeonは、C言語学習におけるモチベーション維持に有効であることが確認されました。特に、

  • ランキング機能が学習意欲を高める要因となる。
  • バッジやレベルシステムが達成感を提供。
  • 適応学習の導入により、個々の学習ペースに対応可能。

今後の課題として、

  • カレンダー機能の改善(利用率向上の工夫)
  • 解答の振り返り機能(間違えた箇所の確認を容易に)
  • 問題の多様化(より高度なアルゴリズム問題の導入)

が挙げられます。今後は、より多くの学習者に活用されるよう、アプリの改良を進めていきます。
本研究は、プログラミング教育におけるゲーミフィケーションの可能性を示すものであり、他のプログラミング言語学習にも応用が期待されます。

研究業績

[1] 谷本 嵩晃, “ゲーミフィケーションを利用したC言語学習支援モバイルアプリケーションの開発,” 修士学位論文, 京都工芸繊維大学 大学院工芸科学研究科, 2024年.
[2] 谷本 嵩晃, 崔 恩瀞, 水野 修, “ゲーミフィケーションを用いたC言語の文法やアルゴリズムの学習支援アプリケーションCode Quiz の提案,” ソフトウェア工学の基礎研究会 FOSE2022予稿集, 29, pp. 201-202, 2022年11月.
[3] 谷本 嵩晃, “ゲーミフィケーションを使用したC言語の文法やアルゴリズムの学習支援アプリケーションの開発,” 卒業研究報告書, 京都工芸繊維大学, 2022年2月.

]]>
2229
CNNを用いたソフトウェア不具合予測 https://se.is.kit.ac.jp/ja/portfolio/word_cnn/ Thu, 21 Sep 2017 02:40:14 +0000 https://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1551

ソフトウェアの不具合予測は,ソフトウェアに潜む不具合を予測することで効率的なレビューやテストを可能にしようとするソフトウェア品質保証活動の 1 つである.従来の多くのソフトウェアの不具合予測では,ソースコード分析による不具合予測を行なっているが,粒度が荒くまた不具合予測の結果のフィードバックが遅い.この問題を解決するために,ソフトウェアの変更がコミットされた時に,その変更によって不具合が起きるかどうかを予測する手法が提案され,近年注目を集めている.ソフトウェア の変更コミットの不具合予測に関する既存研究では,その変更に対するメトリクス(例えば,修正されたファイル数,追加されたコード行数など)を計算した後に機械学習や深層学習を適用している.それに対して,本研究では,変更のソースコード片のみに対して深層学習を適用することで不具合を予測する手法
(W-CNN)を提案する.我々は,評価実験によって,変更ソースコード片に対する深層学習を用いた不具合予測が可能であること,更に,提案手法 W-CNN は先行研究に比べて,学習の時間はかかるものの,不具合予測の精度が優れていることを示す.

関連論文

]]>
1551
CPS(Cyber physical system)のログ解析 https://se.is.kit.ac.jp/ja/portfolio/log-analysis-cps/ Sat, 08 Apr 2017 12:38:37 +0000 https://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1516

Detecting anomalies of a cyber physical system (CPS), which is a complex system consisting of both physical and software parts, is important because a CPS often operates autonomously in an unpredictable environment.
However, because of the ever-changing nature and lack of a precise model for a CPS, detecting anomalies is still a challenging task.
To address this problem, we propose applying an outlier detection method to a CPS log.
By using a log obtained from an actual aquarium management system, we evaluated the effectiveness of our proposed method by analyzing outliers that it detected.
By investigating the outliers with the developer of the system, we confirmed that some outliers indicate actual faults in the system.
For example, our method detected failures of mutual exclusion in the control system that were unknown to the developer.
Our method also detected transient losses of functionalities and unexpected reboots.
On the other hand, our method did not detect anomalies that were too many and similar.
In addition, our method reported rare but unproblematic concurrent combinations of operations as anomalies.
Thus, our approach is effective at finding anomalies, but there is still room for improvement.

Open Data

A log of CPS system, Aqua-tan, recorded from the beginning of system operation.
The log files contain id, timestamp, label, numeric value, and text value.
The “label” column denotes commands and events of Aqua-tan system.

This data is analyzed in our paper in IWESEP2017[1].

[1] Y. Harada, Y. Yamagata, O. Mizuno, and E. Choi, “A Log-Based Anomaly Detection of CPS Using a Statistical Method,” In Proc. of the 8th IEEE International Workshop on Empirical Software Engineering in Practice (IWESEP2017), pp. 1-6, March 2017. (Tokyo, Japan)

References

]]>
1516
バグレポートからの不具合推定 https://se.is.kit.ac.jp/ja/portfolio/fault-localization/ Tue, 27 Sep 2016 11:28:44 +0000 http://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1312

ソフトウェアのバグが報告されると,開発者はバグ修正のためにバグに関連するソースコードファイルを特定する必要がある.この過程は,不具合ファイル特定と呼ばれ,不具合ファイル特定の自動化は開発者の生産性向上のために重要である.本研究では,単語分散表現作成のための自然言語処理ツールword2vecによって学習されるベクトル空間モデルsemantic-VSMを用いて,与えられたバグ報告に対する不具合ファイル特定を効果的に行う手法を提案する.また,不具合ファイル特定の正答率を向上させるために,semantic-VSMとともに既存の不具合ファイル特定手法BugLocator及びBugspotsを組み合わせて用いる手法CombBLを紹介する.我々の実験結果は,提案手法の正答率が既存の高水準の不具合ファイル特定手法と比べて大幅には劣らない結果を達成していることを示す.また我々は,提案手法が既存手法に比べてスケーラビリティ及び高速さにおいては優れている点について考察した.

研究発表

]]>
1312
ソフトウェア開発プロセスの可視化 https://se.is.kit.ac.jp/ja/portfolio/visualization-of-software-development/ Sat, 24 Sep 2016 01:11:51 +0000 http://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1072

可視化

]]>
1072
ソフトウェアテストの効率化に関する研究 https://se.is.kit.ac.jp/ja/portfolio/software-testing/ Sat, 24 Sep 2016 01:01:54 +0000 http://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1070

概要

組み合わせテスト手法は,少ないテストケースで効率的なテストを実施するための手法です.
本研究室では,組み合わせテストにおける優先度付けに対するデータマイニング的アプローチや組み合わせテストにおけるコードカバレッジの調査などを行っています.

研究成果

]]>
1070
ソフトウェア進化のマイニングによる分析 https://se.is.kit.ac.jp/ja/portfolio/analysis-of-code-review-repositories/ Sat, 24 Sep 2016 00:58:48 +0000 http://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1069

We intend to assess the improvements of Gerrit. The central
concern is “Does Rietveld evolve into Gerrit as the developers intended?” To answer
this question, we first compare qualitative features of two code review tools. We
then conducted an interview with a developer of Gerrit and obtained the developer’s
original intention of improvements in Gerrit. By analyzing mined data from code
review logs, we try to explain the effects of improvements quantitatively. The result
of analysis showed us that the improvements of Gerrit that the developer is expected
are not observed explicitly.

References:

]]>
1069
スパムフィルタを利用した不具合予測 https://se.is.kit.ac.jp/ja/portfolio/predicting-fault-prone-modules-by-spam-filtering-technique/ Sat, 24 Sep 2016 00:56:50 +0000 http://se.is.kit.ac.jp/?post_type=jetpack-portfolio&p=1068

uriha

The fault-prone module detection in source code is of importance for assurance of software quality. Most of previous fault-prone detection approaches are based on software metrics. Such approaches, however, have difficulties in collecting the metrics and constructing mathematical models based on the metrics.

In order to mitigate such difficulties, we propose a novel approach for detecting fault-prone modules using a spam filtering technique, named Fault-Prone Filtering. Because of the increase of needs for spam e-mail detection, the spam filtering technique has been progressed as a convenient and effective technique for text mining. In our approach, fault-prone modules are detected in a way that the source code modules are considered as text files and are applied to the spam filter directly.

In order to show the usefulness of our approach, we conducted an experiment using a large source code repository of Java based open source project. The result of experiment shows that our approach can classify about 85% of software modules correctly. The result also indicates that fault-prone modules can be detected relatively low cost at an early stage.

Related paper:

]]>
1068