Concept-Annotated Examples for Library Comparison

Litao Yan, Miryung Kim, Bjoern Hartmann, Tianyi Zhang and Elena L. Glassman

Abstract

Programmers often rely on online resources—such as code examples, documentation, blogs, and Q&A forums—to compare similar libraries and select the one most suitable for their own tasks and contexts. However, this comparison task is often done in an ad-hoc manner, which may result in suboptimal choices. Inspired by Analogical Learning and Variation Theory, we hypothesize that rendering many concept-annotated code examples from different libraries side-by-side can help programmers (1) develop a more comprehensive understanding of the libraries’ similarities and distinctions and (2) make more robust, appropriate library selections. We designed a novel interactive interface, ParaLib, and used it as a technical probe to explore to what extent many side-by-side concepted-annotated examples can facilitate the library comparison and selection process. A within-subjects user study with 20 programmers shows that, when using ParaLib, participants made more consistent, suitable library selections and provided more comprehensive summaries of libraries’ similarities and differences.

Venue
UIST 2022
Volume
Proceedings of the 35th Annual ACM Symposium on User Interface Software and Technology
DOI
10.1145/3526113.3545647
PDF
https://dl.acm.org/doi/pdf/10.1145/3526113.3545647
Anthology ID
2022.uist.36

Cite

@inproceedings{yan-etal-2022-conceptannotated,
    title = {{Concept-Annotated Examples for Library Comparison}},
    author = {Litao Yan and Miryung Kim and Bjoern Hartmann and Tianyi Zhang and Elena L. Glassman},
    booktitle = {Proceedings of the 35th Annual ACM Symposium on User Interface Software and Technology},
    isbn = {9781450393201},
    year = {2022},
    publisher = {Association for Computing Machinery},
    address = {New York, NY, USA},
    doi = {10.1145/3526113.3545647},
    url = {https://doi.org/10.1145/3526113.3545647},
    abstract = {Programmers often rely on online resources—such as code examples, documentation, blogs, and Q\&A forums—to compare similar libraries and select the one most suitable for their own tasks and contexts. However, this comparison task is often done in an ad-hoc manner, which may result in suboptimal choices. Inspired by Analogical Learning and Variation Theory, we hypothesize that rendering many concept-annotated code examples from different libraries side-by-side can help programmers (1) develop a more comprehensive understanding of the libraries’ similarities and distinctions and (2) make more robust, appropriate library selections. We designed a novel interactive interface, ParaLib, and used it as a technical probe to explore to what extent many side-by-side concepted-annotated examples can facilitate the library comparison and selection process. A within-subjects user study with 20 programmers shows that, when using ParaLib, participants made more consistent, suitable library selections and provided more comprehensive summaries of libraries’ similarities and differences.}
}