一句话:提出 DSM,用深度学习从执行轨迹中挖掘有限状态自动机规约,并在库类与 Android 沙箱中验证有效性。
形式规约对软件系统很重要,但通常缺失且编写成本高。已有自动规约挖掘方法在 FSA 推断精度上仍有不足。本文提出 Deep Specification Miner (DSM),通过测试用例生成获得更丰富的执行轨迹,训练基于 RNN 的语言模型,并据此构建前缀树接受器 PTA、抽取特征;随后用聚类合并相似自动机状态,生成多个 FSA,再用模型选择启发式估计 F-measure 并返回最佳规约。作者对 11 个目标库类进行挖掘,平均 F-measure 达 71.97%,比最佳基线高 28.22%,并展示了在 Android 应用沙箱中的应用价值。
Formal specifcations are essential but usually unavailable in software systems. Furthermore, writing these specifcations is costly and requires skills from developers. Recently, many automated techniques have been proposed to mine specifcations in various formats including fnite-state automaton (FSA). However, more works in specifcation mining are needed to further improve the accuracy of the inferred specifcations. In this work, we propose Deep Specifcation Miner (DSM), a new approach that performs deep learning for mining FSA-based specifcations. Our proposed approach uses test case generation to generate a richer set of execution traces for training a Recurrent Neural Network Based Language Model (RNNLM). From these execution traces, we construct a Prefx Tree Acceptor (PTA) and use the learned RNNLM to extract many features. These features are subsequently utilized by clustering algorithms to merge similar automata states in the PTA for constructing a number of FSAs. Then, our approach performs a model selection heuristic to estimate F-measure of FSAs and returns the one with the highest estimated Fmeasure. We execute DSM to mine specifcations of 11 target library classes. Our empirical analysis shows that DSM achieves an average F-measure of 71.97%, outperforming the best performing baseline by 28.22%. We also demonstrate the value of DSM in sandboxing Android apps.
DOI 原文 ·
@inproceedings{paperbot4816,
title = {Deep specification mining},
author = {Tien-Duy B. Le and David Lo},
booktitle = {ISSTA},
year = {2018},
doi = {10.1145/3213846.3213876}
}