Hi Linas

I understand that the templates for the first rule are the subset of the
second one, and look redundant. But my point is that Action for the two
rules are different. The action that you saw from the rules are the same,
but the first rule starts with Pv link, and the <F_R ref> of Pv link is
different from <F_R ref> of RS link...

In the first case, the RS link connect "is" instead of "injured", but we
don't want "who(player, is)" here, in order to be consistent with
_predadj(player, injured), we want to have "who(player, injured)", so we
have to use the <F_R ref> of Pv link instead of RS link for the second
argument.

I suggested Rodas change the format of the two rules something like:

#TemplateActionAlg
Adjective-clause-who-1
<LAB> = \RS\.*
<F_R linkR0 LAB> = \P\.*
<F_L str> = who
=
<F_R COPULA-TAG> = T
<F_L linkL0 F_L ref links who> += <F_R linkR0 F_R ref>


#TemplateActionAlg
Adjective-clause-who-2
<LAB> = \RS\.*|\CV
<F_L str> = who
<F_R COPULA-TAG> !=T
=
<F_L linkL0 F_L ref links who> += <F_R ref>


Then the two rules won't look that confusing. Suggestions? Thanks.

--
Ruiting Lian


On Fri, Feb 21, 2014 at 12:47 AM, Linas Vepstas <notifications@github.com>wrote:

> In data/relex-semantic-algs.txt:
>
> >  ;
> > +; Example: "The woman who lives next door is a nurse."
> > +#TemplateActionAlg
> > +Adjective-clause-who-1
> > +<LAB> = \P\.*
> > +<F_L linkL1 LAB> = \RS\.*
> > +<F_L linkL1 F_L str> = who
> > +=
> > +<F_L adm_set> = <F_L ref>
> > +<F_L linkL1 F_L linkL0 F_L ref links who> += <F_R ref>
> > +#TemplateActionAlg
> > +Adjective-clause-who-2
> > +<LAB> = \RS\.*
> > +<F_L str> = who
> > +<F_R adm_set> = %
>
> What I'm trying to say is that you don't need two rules to handle this:
> one is enough. The only difference between the two parses is that one has a
> Pv link, the other has an Os link, otherwise, they are identical. For the
> second rule, you do not even try to verify that Os is the link type, you
> just ignore the link type completely.
>
> In other words, if RS is the link, then contains "injury", in both cases.
>
> In other words, you can completely remove the first rule, and remove = %
> from the second rule, and it will work as before.
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/opencog/relex/pull/4/files#r9913442>
> .
>