Synthesizing regular expressions from examples for introductory automata assignments

Mina Lee, Sunbeom So, Hakjoo Oh

Research output: Chapter in Book/Report/Conference proceedingConference contribution

4 Citations (Scopus)

Abstract

We present a method for synthesizing regular expressions for introductory automata assignments. Given a set of positive and negative examples, the method automatically synthesizes the simplest possible regular expression that accepts all the positive examples while rejecting all the negative examples. The key novelty is the search-based synthesis algorithm that leverages ideas from over-And under-Approximations to effectively prune out a large search space. We have implemented our technique in a tool and evaluated it with nontrivial benchmark problems that students often struggle with. The results show that our system can synthesize desired regular expressions in 6.7 seconds on the average, so that it can be interactively used by students to enhance their understanding of regular expressions.

Original languageEnglish
Title of host publicationGPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming
Subtitle of host publicationConcepts and Experiences, co-located with SPLASH 2016
EditorsIna Schaefer, Bernd Fischer
PublisherAssociation for Computing Machinery, Inc
Pages70-80
Number of pages11
ISBN (Electronic)9781450344463
DOIs
Publication statusPublished - 2016 Oct 20
Event15th ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, GPCE 2016 - Amsterdam, Netherlands
Duration: 2016 Oct 312016 Nov 1

Publication series

NameGPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016

Conference

Conference15th ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, GPCE 2016
CountryNetherlands
CityAmsterdam
Period16/10/3116/11/1

Fingerprint

Students

Keywords

  • Program synthesis
  • Programming
  • Regular expression

ASJC Scopus subject areas

  • Computer Science Applications
  • Information Systems
  • Software

Cite this

Lee, M., So, S., & Oh, H. (2016). Synthesizing regular expressions from examples for introductory automata assignments. In I. Schaefer, & B. Fischer (Eds.), GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016 (pp. 70-80). (GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016). Association for Computing Machinery, Inc. https://doi.org/10.1145/2993236.2993244

Synthesizing regular expressions from examples for introductory automata assignments. / Lee, Mina; So, Sunbeom; Oh, Hakjoo.

GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016. ed. / Ina Schaefer; Bernd Fischer. Association for Computing Machinery, Inc, 2016. p. 70-80 (GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016).

Research output: Chapter in Book/Report/Conference proceedingConference contribution

Lee, M, So, S & Oh, H 2016, Synthesizing regular expressions from examples for introductory automata assignments. in I Schaefer & B Fischer (eds), GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016. GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016, Association for Computing Machinery, Inc, pp. 70-80, 15th ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, GPCE 2016, Amsterdam, Netherlands, 16/10/31. https://doi.org/10.1145/2993236.2993244
Lee M, So S, Oh H. Synthesizing regular expressions from examples for introductory automata assignments. In Schaefer I, Fischer B, editors, GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016. Association for Computing Machinery, Inc. 2016. p. 70-80. (GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016). https://doi.org/10.1145/2993236.2993244
Lee, Mina ; So, Sunbeom ; Oh, Hakjoo. / Synthesizing regular expressions from examples for introductory automata assignments. GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016. editor / Ina Schaefer ; Bernd Fischer. Association for Computing Machinery, Inc, 2016. pp. 70-80 (GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016).
@inproceedings{a497cfb09cd7443b950915505ded2bc2,
title = "Synthesizing regular expressions from examples for introductory automata assignments",
abstract = "We present a method for synthesizing regular expressions for introductory automata assignments. Given a set of positive and negative examples, the method automatically synthesizes the simplest possible regular expression that accepts all the positive examples while rejecting all the negative examples. The key novelty is the search-based synthesis algorithm that leverages ideas from over-And under-Approximations to effectively prune out a large search space. We have implemented our technique in a tool and evaluated it with nontrivial benchmark problems that students often struggle with. The results show that our system can synthesize desired regular expressions in 6.7 seconds on the average, so that it can be interactively used by students to enhance their understanding of regular expressions.",
keywords = "Program synthesis, Programming, Regular expression",
author = "Mina Lee and Sunbeom So and Hakjoo Oh",
year = "2016",
month = "10",
day = "20",
doi = "10.1145/2993236.2993244",
language = "English",
series = "GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016",
publisher = "Association for Computing Machinery, Inc",
pages = "70--80",
editor = "Ina Schaefer and Bernd Fischer",
booktitle = "GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming",

}

TY - GEN

T1 - Synthesizing regular expressions from examples for introductory automata assignments

AU - Lee, Mina

AU - So, Sunbeom

AU - Oh, Hakjoo

PY - 2016/10/20

Y1 - 2016/10/20

N2 - We present a method for synthesizing regular expressions for introductory automata assignments. Given a set of positive and negative examples, the method automatically synthesizes the simplest possible regular expression that accepts all the positive examples while rejecting all the negative examples. The key novelty is the search-based synthesis algorithm that leverages ideas from over-And under-Approximations to effectively prune out a large search space. We have implemented our technique in a tool and evaluated it with nontrivial benchmark problems that students often struggle with. The results show that our system can synthesize desired regular expressions in 6.7 seconds on the average, so that it can be interactively used by students to enhance their understanding of regular expressions.

AB - We present a method for synthesizing regular expressions for introductory automata assignments. Given a set of positive and negative examples, the method automatically synthesizes the simplest possible regular expression that accepts all the positive examples while rejecting all the negative examples. The key novelty is the search-based synthesis algorithm that leverages ideas from over-And under-Approximations to effectively prune out a large search space. We have implemented our technique in a tool and evaluated it with nontrivial benchmark problems that students often struggle with. The results show that our system can synthesize desired regular expressions in 6.7 seconds on the average, so that it can be interactively used by students to enhance their understanding of regular expressions.

KW - Program synthesis

KW - Programming

KW - Regular expression

UR - http://www.scopus.com/inward/record.url?scp=85006757931&partnerID=8YFLogxK

UR - http://www.scopus.com/inward/citedby.url?scp=85006757931&partnerID=8YFLogxK

U2 - 10.1145/2993236.2993244

DO - 10.1145/2993236.2993244

M3 - Conference contribution

AN - SCOPUS:85006757931

T3 - GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, co-located with SPLASH 2016

SP - 70

EP - 80

BT - GPCE 2016 - Proceedings of the 2016 ACM SIGPLAN International Conference on Generative Programming

A2 - Schaefer, Ina

A2 - Fischer, Bernd

PB - Association for Computing Machinery, Inc

ER -