What about the readability of the generated code?
Expressions that are generated are always in the same form - if you are looking for the second integer from the left, this system will output a regex that finds 1. non integer text I call 'filler' 2. the first integer 3. non integer text 4. the second integer. Only the second integer will be bracketed for extraction. In the generated code, you can see it building this expression. See this example to see what I mean.