Digging for fold: Synthesis-aided API discovery for Haskell

18Citations
Citations of this article
21Readers
Mendeley users who have this article in their library.

Abstract

We present Hoogle+, a web-based API discovery tool for Haskell. A Hoogle+ user can specify a programming task using either a type, a set of input-output tests, or both. Given a specification, the tool returns a list of matching programs composed from functions in popular Haskell libraries, and annotated with automatically-generated examples of their behavior. These features of Hoogle+ are powered by three novel techniques. First, to enable efficient type-directed synthesis from tests only, we develop an algorithm that infers likely type specifications from tests. Second, to return high-quality programs even with ambiguous specifications, we develop a technique that automatically eliminates meaningless and repetitive synthesis results. Finally, we show how to extend this elimination technique to automatically generate informative inputs that can be used to demonstrate program behavior to the user. To evaluate the effectiveness of Hoogle+ compared with traditional API search techniques, we perform a user study with 30 participants of varying Haskell proficiency. The study shows that programmers equipped with Hoogle+ generally solve tasks faster and were able to solve 50% more tasks overall.

References Powered by Scopus

How to make ad-hoc polymorphism less ad hoc

511Citations
N/AReaders
Get full text

Automating string processing in spreadsheets using input-output examples

438Citations
N/AReaders
Get full text

Oracle-guided component-based program synthesis

400Citations
N/AReaders
Get full text

Cited by Powered by Scopus

Grounded Copilot: How Programmers Interact with Code-Generating Models

152Citations
N/AReaders
Get full text

LooPy: Interactive program synthesis with control structures

12Citations
N/AReaders
Get full text

Searching entangled program spaces

11Citations
N/AReaders
Get full text

Register to see more suggestions

Mendeley helps you to discover research relevant for your work.

Already have an account?

Cite

CITATION STYLE

APA

James, M. B., Guo, Z., Wang, Z., Doshi, S., Peleg, H., Jhala, R., & Polikarpova, N. (2020). Digging for fold: Synthesis-aided API discovery for Haskell. Proceedings of the ACM on Programming Languages, 4(OOPSLA). https://doi.org/10.1145/3428273

Readers' Seniority

Tooltip

PhD / Post grad / Masters / Doc 11

92%

Researcher 1

8%

Readers' Discipline

Tooltip

Computer Science 8

67%

Engineering 3

25%

Arts and Humanities 1

8%

Save time finding and organizing research with Mendeley

Sign up for free