Modeling Regex Operators for Solving Regex Crossword Puzzles

Published: 01 Jan 2023, Last Modified: 13 May 2025SETTA 2023EveryoneRevisionsBibTeXCC BY-SA 4.0
Abstract: Modeling regular expressions (regexes) has been applied in abundant scenes, but at present, there is a lack of comprehensive modeling for extended operators, which limits their usage in related scenes. To address the problem, we comprehensively model the operators of regexes and apply the modeling method to solve regex crossword puzzles. Firstly, to solve the challenges of comprehensive modeling of regexes, we propose an over-approximate modeling method for regex operators according to their languages or semantics, and use a counterexample-guided abstraction refinement scheme to strengthen constraints, thereby eliminating spurious solutions and ensuring the correctness of our modeling. Then, based on our modeling method, we present a novel algorithm for solving regex crossword puzzles. We collect 803 rectangular puzzles and 95 hexagonal puzzles from the most popular regex crossword puzzles website, and compare our algorithm with five state-of-the-art tools. Experiment results show that our algorithm can solve 97.76% rectangular puzzles and 98.95% hexagonal puzzles in an acceptable running time, which are 19.06% and 65.27% higher than the highest success rates of other methods respectively.
Loading