User:Mlforcada/Robust LR for Transfer
We need a way to implement Apertium4 Bison grammars that are robust.
Here, Bison GRAMMAR is a LALR(1) grammar with actions between braces.
There should be a way (or a procedure) to complete handwritten rules, if possible automatically, to generate a robust parser (and translator). The idea is to take the handwritten Bison grammar Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle G} and complement it with automatically-generated glue rules in such a way that conflicts are not produced (or are harmless) to produce a new grammar Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle G'} .
One possible way to do so is to model left-to-right restarts as follows:
- by accepting the longest possible constituent that cannot be merged with the remaining output and generating some kind of translation for it
- and treating the remaining output as a complete sentence again