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.
翻译:摘要:现有编程示例系统(PBE)常依赖简化基准测试,未能捕捉真实正则表达式的高结构复杂性(如更深层嵌套和频繁的并集运算)。为克服由此导致的性能下降,我们提出ReSyn——一种与合成器无关的分治框架,可将复杂合成问题分解为可管理的子问题。同时引入Set2Regex——一种参数高效的合成器,能捕捉示例的排列不变性。实验结果表明,ReSyn显著提升了多种合成器的精度,且其与Set2Regex的结合在具有挑战性的真实基准测试中创下新最优结果。完整源代码、数据集及预训练模型检查点已开源发布于https://github.com/mrseongminkim/ReSyn。