Eckhard Bick <[email protected]> čálii:
> Hello everybody,
>
> I would like to suggest a temporary fix to the tag order sensitivity
> problem, while we wait for a permanent solution. Please forgive me, if
> anybody has suggested this method before, but I think the idea is new:
>
> 1. We introduce a magic tag LINE, maintained by the compiler,
> constituted by the *whole* reading line (plus the word form at the
> start) as *one* tag, i.e. *without breaking on space*.
>
> 2. If LIST or on-the-fly definitions use a tag parenthesis with space,
> e.g. (Tag1 Tag2), in a rule with the flag TAGORDER, this will be
> converted internally to /^(.* )?Tag1 Tag2( .*)?$/r.
>
> REMOVE TAGORDER (Tag3) IF (*1 (Tag1 Tag2)) ;
If this was in response to my question about COPY order, I think it may
be solving a different problem. At least for the use-case in the Divvun
grammar checker (and in Apertium MT), we typically only care about order
when the string of tags changes (tags are inserted or removed, as in
SUBSTITUTE/COPY), not when context conditions are matched. The reason is
that this string of tags is sent to an order-sensitive FST, e.g. for
word-form generation.
That said, before we had subreadings, a TAGORDER option might have
solved the issue with overlapping tags in compounds, previously
represented as
"<kaffikake>"
"kaffi" n m sg ind + "kake" n m pl def
(though we'd still have to match on LINE using a regex, to differentiate
def-at-end-of-LINE vs def-in-the-middle). Now we represent compounds as
"<kaffikake>"
"kake" n m pl def
"kaffi" n m sg ind
and the SUB:-option lets us pick the right subreading.
But perhaps there are other use cases I haven't thought of?
--
Kevin Brubeck Unhammer
--
You received this message because you are subscribed to the Google Groups
"Constraint Grammar" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/constraint-grammar.
For more options, visit https://groups.google.com/d/optout.