Proceedings

ReSyn: A Generalized Recursive Regular Expression Synthesis Framework

Download BibTeX Cite

Proceedings of the Thirty-Fifth International Joint Conference on Artificial Intelligence. Main Track. Pages 3908-3916.

https://doi.org/10.24963/ijcai.2026/435

Abstract

Existing Programming-By-Example (PBE) systems often rely on simplified benchmarks that fail to capture the high structural complexity of real-world regexes, such as deeper nesting and frequent use of union operations.

To overcome the resulting performance drop, we propose ReSyn, a synthesizer-agnostic divide-and-conquer framework that decomposes complex synthesis problem into manageable sub-problems.

We also introduce Set2Regex, a parameter-efficient synthesizer capturing the permutation invariance of examples.

Experimental results demonstrate that ReSyn significantly boosts accuracy across various synthesizers, and its combination with Set2Regex establishes a new state-of-the-art on challenging real-world benchmark.

The complete source code, datasets, and pre-trained model checkpoints are publicly available at https://github.com/mrseongminkim/ReSyn.

  1. [Alur et al., 2017] Rajeev Alur, Arjun Radhakrishna, and Abhishek Udupa. Scaling enumerative program synthesis via divide and conquer. In TACAS, pages 319-336, 2017.
  2. [Barke et al., 2020] Shraddha Barke, Hila Peleg, and Nadia Polikarpova. Just-in-time learning for bottom-up enumer- ative synthesis. Proc. ACM Program. Lang., 4(OOPSLA), 2020.
  3. [Bartoli et al., 2014] A. Bartoli, G. Davanzo, A. De Lorenzo, E. Medvet, and E. Sorio. Automatic synthesis of regu- lar expressions from examples. Computer, 47(12):72-80, 2014.
  4. [Bartoli et al., 2016] Alberto Bartoli, Andrea De Lorenzo, Eric Medvet, and Fabiano Tarlao. Inference of regular ex- pressions for text extraction from examples. IEEE Trans- actions on Knowledge and Data Engineering, 28(5):1217- 1230, 2016.
  5. [Chapman and Stolee, 2016] Carl Chapman and Kathryn T Stolee. Exploring regular expression usage and context in python. In Proceedings of the 25th International Sym- posium on Software Testing and Analysis, pages 282-293, 2016.
  6. [Chen et al., 2023] Qiaochu Chen, Arko Banerjee, C ¸agatay Demiralp, Greg Durrett, and Is ¸ıl Dillig. Data extraction via semantic regular expression synthesis. Proceedings of the ACM on Programming Languages, 7(OOPSLA2):1848- 1877, 2023.
  7. [Davis et al., 2019] James C. Davis, Louis G. Michael IV, Christy A. Coghlan, Francisco Servant, and Dongyoon Lee. Why aren't regular expressions a lingua franca? An empirical study on the re-use and portability of regular ex- pressions. In ESEC/FSE, pages 443-454, 2019.
  8. [Farzan and Nicolet, 2021a] Azadeh Farzan and Victor Nicolet. Counterexample-guided partial bounding for recursive function synthesis. In CAV, pages 832-855, 2021.
  9. [Farzan and Nicolet, 2021b] Azadeh Farzan and Vic- tor Nicolet. Phased synthesis of divide and conquer programs. In PLDI, pages 974-986, 2021.
  10. [Ferreira et al., 2021] Margarida Ferreira, Miguel Terra- Neves, Miguel Ventura, Inês Lynce, and Ruben Martins. Forest: an interactive multi-tree synthesizer for regular ex- pressions. In International Conference on Tools and Algo- rithms for the Construction and Analysis of Systems, pages 152-169. Springer, 2021.
  11. [Gold, 1978] E. Mark Gold. Complexity of automaton iden- tification from given data. Information and Control, 37(3):302-320, 1978.
  12. [Kim et al., 2025] Seongmin Kim, Hyunjoon Cheon, Su- Hyeon Kim, Yo-Sub Han, and Sang-Ki Ko. Splitregex: Efficient regex synthesis by neural example splitting. Jour- nal of Automata, Languages and Combinatorics, 30(1- 3):157-179, 2025.
  13. [Lang et al., 1998] Kevin J. Lang, Barak A. Pearlmutter, and Rodney A. Price. Results of the abbadingo one DFA learn- ing competition and a new evidence-driven state merging algorithm. In ICGI, pages 1-12, 1998.
  14. [Lee et al., 2016] Mina Lee, Sunbeom So, and Hakjoo Oh. Synthesizing regular expressions from examples for intro- ductory automata assignments. In GPCE, pages 70-80, 2016.
  15. [Lee et al., 2019] Juho Lee, Yoonho Lee, Jungtaek Kim, Adam Kosiorek, Seungjin Choi, and Yee Whye Teh. Set transformer: A framework for attention-based permutation-invariant neural networks. In International conference on machine learning, pages 3744-3753.
  16. PMLR, 2019.
  17. [Oncina and García, 1992] J. Oncina and P. García. Inferring regular languages in polynomial updated time. In Pattern Recognition and Image Analysis, pages 49-61. World Sci- entific, 1992.
  18. [Räihä and Ukkonen, 1981] Kari-Jouko Räihä and Esko Ukkonen. The shortest common subsequence problem over binary alphabet is np-complete. Theoretical Com- puter Science, 16(2):187-198, 1981.
  19. [Raza et al., 2015] Mohammad Raza, Sumit Gulwani, and Natasa Milic-Frayling. Compositional program synthesis from natural language and examples. In IJCAI 2015, 2015. IJCAI
  20. [Shrivastava et al., 2021] Disha Shrivastava, Hugo Larochelle, and Daniel Tarlow. Learning to combine per-example solutions for neural program synthesis. In NeurIPS, pages 6102-6114, 2021.
  21. [Vaduguru et al., 2024] Saujas Vaduguru, Daniel Fried, and Yewen Pu. Generating pragmatic examples to train neural program synthesizers. In The Twelfth International Con- ference on Learning Representations, ICLR 2024, Vienna, Austria, May 7-11, 2024. OpenReview.net, 2024.
  22. [Valizadeh et al., 2024] Mojtaba Valizadeh, Philip John Gorinski, Ignacio Iacobacci, and Martin Berger. Correct and optimal: The regular expression inference challenge. In Kate Larson, editor, Proceedings of the Thirty-Third International Joint Conference on Artificial Intelligence, IJCAI-24, pages 6486-6494. International Joint Con- ferences on Artificial Intelligence Organization, 8 2024. Main Track. IJCAI
  23. [Ye et al., 2020] Xi Ye, Qiaochu Chen, Isil Dillig, and Greg Durrett. Benchmarking multimodal regex synthesis with complex structures. In Dan Jurafsky, Joyce Chai, Natalie Schluter, and Joel Tetreault, editors, Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 6081-6094, Online, July 2020. Associ- ation for Computational Linguistics.

References were extracted automatically from the PDF and may contain errors.

Welcome Future Conferences AI Journal Division IJCAI Proceedings About IJCAI IJCAI Awards