Neural Program Generation Modulo Static Analysis

被引:0
|
作者
Mukherjee, Rohan [1 ]
Wen, Yeming [2 ]
Chaudhari, Dipak [2 ]
Reps, Thomas W. [3 ]
Chaudhuri, Swarat [2 ]
Jermaine, Chris [1 ]
机构
[1] Rice Univ, Houston, TX 77251 USA
[2] UT Austin, Austin, TX USA
[3] Univ Wisconsin, Madison, WI 53706 USA
关键词
D O I
暂无
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
State-of-the-art neural models of source code tend to be evaluated on the generation of individual expressions and lines of code, and commonly fail on long-horizon tasks such as the generation of entire method bodies. We propose to address this deficiency using weak supervision from a static program analyzer. Our neurosymbolic method allows a deep generative model to symbolically compute, using calls to a static-analysis tool, long-distance semantic relationships in the code that it has already generated. During training, the model observes these relationships and learns to generate programs conditioned on them. We apply our approach to the problem of generating entire Java methods given the remainder of the class that contains the method. Our experiments show that the approach substantially outperforms state-of-the-art transformers and a model that explicitly tries to learn program semantics on this task, both in terms of producing programs free of basic semantic errors and in terms of syntactically matching the ground truth.
引用
收藏
页数:13
相关论文
共 50 条
  • [31] Natural semantics as a static program analysis framework
    Glesner, S
    Zimmermann, W
    ACM TRANSACTIONS ON PROGRAMMING LANGUAGES AND SYSTEMS, 2004, 26 (03): : 510 - 577
  • [32] Multilevel static analysis for improving program quality
    Belevantsev, A. A.
    PROGRAMMING AND COMPUTER SOFTWARE, 2017, 43 (06) : 321 - 336
  • [33] Software Quality Assurance by Static Program Analysis
    Wilhelm, Reinhard
    SOFTWARE QUALITY: MODEL-BASED APPROACHES FOR ADVANCED SOFTWARE AND SYSTEMS ENGINEERING, 2014, 166 : 1 - 11
  • [34] Practical program verification by means of static analysis
    Seidl H.
    Informatik-Spektrum, 2010, 33 (05) : 484 - 488
  • [35] Use of static analysis during program development
    Marakakis, EI
    Proceedings of the Eighth IASTED International Conference on Artificial Intelligence and Soft Computing, 2004, : 66 - 71
  • [36] Android Security via Static Program Analysis
    Shen, Feng
    MOBISYS'17 PHD FORUM: PROCEEDINGS OF THE 2017 WORKSHOP ON MOBISYS 2017 PH.D. FORUM, 2017, : 19 - 20
  • [37] STATIC ANALYSIS - AN AID TO PROGRAM MAINTENANCE AND DEVELOPMENT
    NARAYANASWAMY, K
    PROCEEDINGS OF THE TWENTY-FIRST, ANNUAL HAWAII INTERNATIONAL CONFERENCE ON SYSTEM SCIENCES, VOLS 1-4: ARCHITECTURE TRACK, SOFTWARE TRACK, DECISION SUPPORT AND KNOWLEDGE BASED SYSTEMS TRACK, APPLICATIONS TRACK, 1988, : B492 - B499
  • [38] Improving the testing process by program static analysis
    Kikuchi, N
    Kikuno, T
    APSEC 2001: EIGHTH ASIA-PACIFIC SOFTWARE ENGINEERING CONFERENCE, PROCEEDINGS, 2001, : 195 - 201
  • [39] An Abstract Specification Language for Static Program Analysis
    Vistein, Michael
    Ortmeier, Frank
    Reif, Wolfgang
    Huuck, Ralf
    Fehnker, Ansgar
    ELECTRONIC NOTES IN THEORETICAL COMPUTER SCIENCE, 2009, 254 : 181 - 197
  • [40] Multilevel static analysis for improving program quality
    A. A. Belevantsev
    Programming and Computer Software, 2017, 43 : 321 - 336