Consider this text:
Would you like to have responses to your questions sent to you via email ?
I'm going to propose multiple choices for several words by marking up them like that:
Would you like [to get]|[having]|g[to have] responses to your questions sent [up to]|g[to]|[on] you via email ?
The choices are bracketted and separated by pipes
The good choice is preceded by a g
I would like to parse this sentence to get the text formatted like that:
Would you like __ responses to your questions sent __ you via email ?
With a list like:
[
[
{"to get":0},
{"having":0},
{"to have":1},
],
[
{"up to":0},
{"to":1},
{"on":0},
],
]
Is my markup design ok ?
How to regex the sentence to get the needed result and generate the list ?
edit: User oriented markup language needed