HackerPapers

arXiv:1708.07583cs.PL

Learning to Blame: Localizing Novice Type Errors with Data-Driven Diagnosis

Eric L. Seidel, Huma Sibghat, Kamalika Chaudhuri, Westley Weimer, Ranjit Jhala

Early discovery. Linked by one identifiable commenter. This paper is outside the main ranking; a mention is not an endorsement.

Abstract

Localizing type errors is challenging in languages with global type inference, as the type checker must make assumptions about what the programmer intended to do. We introduce Nate, a data-driven approach to error localization based on supervised learning. Nate analyzes a large corpus of training data -- pairs of ill-typed programs and their "fixed" versions -- to automatically learn a model of where the error is most likely to be found. Given a new ill-typed program, Nate executes the model to generate a list of potential blame assignments ranked by likelihood. We evaluate Nate by comparing its precision to the state of the art on a set of over 5,000 ill-typed OCaml programs drawn from two instances of an introductory programming course. We show that when the top-ranked blame assignment is considered, Nate's data-driven model is able to correctly predict the exact sub-expression that should be changed 72% of the time, 28 points higher than OCaml and 16 points higher than the state-of-the-art SHErrLoc tool. Furthermore, Nate's accuracy surpasses 85% when we consider the top two locations and reaches 91% if we consider the top three.

arXiv comments
OOPSLA '17
Journal reference
DOI
doi:10.1145/3133884
Subjects
cs.PLProgramming Languages

On Hacker News

Linked by 1 identifiable commenter in 1 comment across 1 thread, from Sep 2017 to Sep 2017. Found in 1 HN submission from Aug 2017 to Aug 2017. Open submission discussions.

Comments linking this paper, per year.

Discussed in comments1 thread

    • You (and I) are definitely in the minority here. "Go back and do a computer science degree" is probably the opposite wish of lots of software engineers, in terms of quantity. From what I know, there are at least three classes in some universities (forgot the names) whose…

      chenglouView on HNParent context

Submitted to Hacker News

Connected through shared HN threads, not inferred similarity or a recommendation.