arXiv Science⌕ Search

arXiv subjects

David Minh-Duy Cao

Publications and source records attributed to David Minh-Duy Cao.

2 recordsLinked to original sources

Seizing the Means of Direct Manipulation

Prior direct manipulation (DM) programming systems tend to be specific to a given domain, with limited options for programmers to customize interactions for a given program, or for a particular stage of their work with that program. In this paper, we ask what properties a programming system must satisfy in order to support programmers in improvising bespoke, ad-hoc DM program editing interfaces that suit the program and task at hand. In answer, we propose and formalize four novel properties---Strong Customizability, Derivation Consistency, Interdependency, and Transparency---that a programming system can satisfy, depending on what programming interactions the system allows. We introduce the markful lambda calculus, an extension of the lambda calculus that satisfies all four of these properties. The markful lambda calculus allows programs to access the evaluation derivation information of program values and allows programmers to define marks: message-passing DM interface components that programmers can add to their DM interface. We implement our approach in a tool called Marx. Using Marx, we implement small representative interactions from several prior DM programming and programming visualization systems. We hope Marx is a step on the path towards general-purpose direct manipulation programming environments.

cs.PL↗

Direct Manipulation and Natural Language Programming, Together at Last?

Decades of programming languages research has contributed novel approaches to program editing that go beyond modifying text, including direct manipulation programming, structure editing, and automated refactoring tools. However, the rapid growth of natural language programming largely reinforces a view of programs as text and program editing as (unstructured) text transformation. How can we develop unified programming systems that bridge the gap between these approaches, supporting multiple editing paradigms in concert? We take a first step toward answering these questions by introducing a framework that enables program editing via both direct manipulation and natural language, and instantiate this framework in a variant of the $\texttt{cartokit}$ direct manipulation programming system. Our key insight is to treat programs as sequences of structured edits and to use an edit language as a shared interface for both direct manipulation and natural language interactions, leveraging constrained decoding to support the latter. Using our instantiation, we conducted a within-subjects study ($N$=18) to understand how the combination of direct manipulation and natural language as editing modalities changes the programming process compared to each modality alone. Perhaps surprisingly, we found that study participants overwhelmingly chose to edit via direct manipulation when both modalities were available, performing just 6.14% of edits via natural language. Our thematic analysis of study sessions revealed that direct manipulation aided task decomposition, encouraged incremental editing, and helped mitigate known challenges in natural language programming related to understanding model capabilities and model-generated code. Our edit-based framework and study findings lay out a possible pathway for future research on programming systems that blend natural language with alternative editing modalities.

cs.PL↗