PlotCoder: Hierarchical Decoding for Synthesizing Visualization Code in Programmatic Context
Year: 2021
Type: conference-paper
Abstract: Creating effective visualization is an important part of data analytics. While there are many libraries for creating visualization, writing such code remains difficult given the myriad of parameters that users need to provide. In this paper, we propose the new task of synthesizing visualization programs from a combination of natural language utterances and code context. To tackle the learning problem, we introduce PlotCoder, a new hierarchical encoder-decoder architecture that models both the code context and the input utterance. We use PlotCoder to first determine the template of the visualization code, followed by predicting the data to be plotted. We use Jupyter notebooks containing visualization programs crawled from GitHub to train PlotCoder. On a comprehensive set of test samples from those notebooks, we show that PlotCoder correctly predicts the plot type of about 70% samples, and synthesizes the correct programs for 35% samples, performing 3-4.5% better than the baselines.
Authors: Xinyun Chen, Linyuan Gong, Alvin Cheung, Dawn Song
Institution: University of California, Berkeley
Language: English
Subfield: Information Systems
Field: Computer Science
Domain: Physical Sciences
Open Access status: gold
Awards: III: Medium: Collaborative Research: Reasoning about Optimizers for Data-Intensive Systems, G1583218571, USING VERIFIED LIFTING TO OPTIMIZE LEGACY STENCIL CODES, CAREER: Generating Application-Specific Database Management Systems, BIGDATA: Collaborative Research: F: Holistic Optimization of Data-Driven Applications, TWC: Medium: Collaborative: Aspire: Leveraging Automated Synthesis Technologies for Enhancing System Security, CAPA: Collaborative Research: ARION: Taming Heterogeneity with DSLs, Approximation, and Synthesis
OpenAlex ID: W3177025426
