Proceedings of the 15th Annual Conference on Genetic and Evolutionary Computation 2013
DOI: 10.1145/2463372.2463532
|View full text |Cite
|
Sign up to set email alerts
|

Automatic string replace by examples

Abstract: Search-and-replace is a text processing task which may be largely automated with regular expressions: the user must describe with a specific formal language the regions to be modified (search pattern) and the corresponding desired changes (replacement expression). Writing and tuning the required expressions requires high familiarity with the corresponding formalism and is typically a lengthy, error-prone process.In this paper we propose a tool based on Genetic Programming (GP) for generating automatically both… Show more

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
3
2

Citation Types

0
13
0

Year Published

2015
2015
2024
2024

Publication Types

Select...
3
1
1

Relationship

3
2

Authors

Journals

citations
Cited by 6 publications
(13 citation statements)
references
References 21 publications
0
13
0
Order By: Relevance
“…Our work constitutes a significant improvement over our earlier proposal [5], which, to the best of our knowledge, was the first system able to generate automatically both the search pattern and the replacement expression based only on examples. Our earlier proposal was based on GP and consisted of three steps: (i) a first evolutionary search aimed at constructing a preliminary search pattern; (ii) construction of a replacement expression of predefined structure, tailored to the provided examples; and, (iii) a further evolutionary search aimed at constructing the search pattern that, coupled with the replacement expression obtained at the previous step, would solve the user-specified task.…”
Section: Introductionmentioning
confidence: 93%
See 2 more Smart Citations
“…Our work constitutes a significant improvement over our earlier proposal [5], which, to the best of our knowledge, was the first system able to generate automatically both the search pattern and the replacement expression based only on examples. Our earlier proposal was based on GP and consisted of three steps: (i) a first evolutionary search aimed at constructing a preliminary search pattern; (ii) construction of a replacement expression of predefined structure, tailored to the provided examples; and, (iii) a further evolutionary search aimed at constructing the search pattern that, coupled with the replacement expression obtained at the previous step, would solve the user-specified task.…”
Section: Introductionmentioning
confidence: 93%
“…In particular, we introduced the enforcement of a phenotypic diversity promotion scheme [7], we extended the number and variety of individuals in the initial population that are generated based on the available examples (rather than at random) and, most importantly, we introduced a significantly different fitness function. In our earlier work [5], we used a multi-objective fitness function based on two indexes: the amount of characterlevel errors and a quantification of the structural mismatch between the two components of a candidate solution, i.e., search pattern and replacement expression (please refer to the cited paper for full details). In this work we introduce a new fitness function composed of three objectives: the amount of character-level errors, a quantification of the ability to identify all the substrings in the examples that have to be modified (a form of character-level recall), a complexity measure of the candidate solution.…”
Section: Introductionmentioning
confidence: 99%
See 1 more Smart Citation
“…Our pattern evolutionary search is built upon the approaches proposed in [2,12,18], which we extend in three key aspects: (i) different fitness definitions (we use three objectives rather than two objectives); (ii) different fitness comparison criteria (we use a hierarchy between the fitness indexes rather than a Paretoranking); and, (iii) a mechanism for enforcing diversity among individuals.…”
Section: Pattern Evolutionary Searchmentioning
confidence: 99%
“…, 9; (iv) partial ranges obtained from the slices in (s,X d ,Xu)∈T X d according to the procedure described in [12]-a partial range being the largest interval of characters occurring in a set of strings (e.g., a-c and l-n are two partial ranges obtained from {cabin, male}), see the cited paper for full details); (v) other special characters such as \., :, @, and so on. The initialization of the population of n pop individuals is based on the slices in (s,X d ,Xu)∈T X d , as follows (similarly to [18]). For each slice x s ∈ (s,X d ,Xu)∈T X d , two individuals are built: one whose string representation is equal to the content of x s where each digit is replaced by \d and each other alphabetic character is replaced by \w; another individual whose string representation is the same as the former and where consecutive occurrences of \d (or \w) are replaced by \d++ (or \w++).…”
Section: Pattern Evolutionary Searchmentioning
confidence: 99%