RbSyn: type- and effect-guided program synthesis
Sankha Narayan Guria, Jeffrey S. Foster, David Van Horn
摘要
In recent years, researchers have explored component-based synthesis, which aims to automatically construct programs that operate by composing calls to existing APIs. However, prior work has not considered efficient synthesis of methods with side effects, e.g., web app methods that update a database. In this paper, we introduce RbSyn, a novel type- and effect-guided synthesis tool for Ruby. An RbSyn synthesis goal is specified as the type for the target method and a series of test cases it must pass. RbSyn works by recursively generating well-typed candidate method bodies whose write effects match the read effects of the test case assertions. After finding a set of candidates that separately satisfy each test, RbSyn synthesizes a solution that branches to execute the correct candidate code under the appropriate conditions. We formalize RbSyn on a core, object-oriented language λsyn and describe how the key ideas of the model are scaled-up in our implementation for Ruby. We evaluated RbSyn on 19 benchmarks, 12 of which come from popular, open-source Ruby apps. We found that RbSyn synthesizes correct solutions for all benchmarks, with 15 benchmarks synthesizing in under 9 seconds, while the slowest benchmark takes 83 seconds. Using observed reads to guide synthesize is effective: using type-guidance alone times out on 10 of 12 app benchmarks. We also found that using less precise effect annotations leads to worse synthesis performance. In summary, we believe type- and effect-guided synthesis is an important step forward in synthesis of effectful methods from test cases.
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper7
- Specification-guided component-based synthesis from effectful librariesAshish Mishra, Suresh JagannathanOOPSLA 2022 · 被引用 7 次
- Absynthe: Abstract Interpretation-Guided SynthesisSankha Narayan Guria, Jeffrey S. Foster, David Van HornPLDI 2023 · 被引用 6 次
- Control-Flow Deobfuscation using Trace-Informed Compositional Program SynthesisBenjamin Mariano, Ziteng Wang, Shankara Pailoor, Christian S. Collberg 等OOPSLA 2024 · 被引用 5 次
- Automated Translation of Functional Big Data Queries to SQLGuoqiang Zhang, Benjamin Mariano, Xipeng Shen, Isil DilligOOPSLA 2023 · 被引用 5 次
- Program Synthesis from Partial TracesMargarida Ferreira, Victor Nicolet, Joey Dodds, Daniel KroeningPLDI 2025 · 被引用 2 次
它引用的顶会 Paper2
- Effects as capabilities: effect handlers and lightweight effect polymorphismJonathan Immanuel Brachthäuser, Philipp Schuster, Klaus OstermannOOPSLA 2020 · 被引用 62 次
- Digging for fold: synthesis-aided API discovery for HaskellMichael B. James, Zheng Guo, Ziteng Wang, Shivani Doshi 等OOPSLA 2020 · 被引用 19 次
相关 Paper
- Type-directed program synthesis for RESTful APIsZheng Guo, David Cao, Davin Tjong, Jean Yang 等PLDI 2022 · 被引用 15 次
- Combining the top-down propagation and bottom-up enumeration for inductive program synthesisWoosuk LeePOPL 2021 · 被引用 34 次
- Just-in-time learning for bottom-up enumerative synthesisShraddha Barke, Hila Peleg, Nadia PolikarpovaOOPSLA 2020 · 被引用 33 次
- Leveraging Rust Types for Program SynthesisJonás Fiala, Shachar Itzhaky, Peter Müller, Nadia Polikarpova 等PLDI 2023 · 被引用 17 次
- Trace-Guided Synthesis of Effectful Test GeneratorsZhe Zhou, Ankush Desai, Benjamin Delaware, Suresh JagannathanPLDI 2026 · 被引用 1 次
