Trying to do several attachments inside a WITH block

8 views
Skip to first unread message

Paul Meurer

unread,
Dec 20, 2024, 5:09:21 PM12/20/24
to Constraint Grammar, Paul Meurer
Hi,

I am trying to do several attachments in a WITH block.

In the sentence

A B C

I want to get

C -> A
B -> C

I try this rule set:

WITH ("C")
IF (-2 ("A"))
(-1 ("B"))
(NOT p (*)) {
SETPARENT (*) TO (jC1 (*)) ;
SETPARENT _C2_ TO (0 (*)) ;
} ;

but it does only do the first attachment C -> A.

Is there something wrong with my syntax; can this be done at all?

I tried a variant:

WITH ("C")
IF (-2 ("A"))
(-1 ("B"))
(NOT p (*)) {
SETPARENT (*) TO (jC1 (*)) ;
SETPARENT _C2_ TO (jC1 (*)) ;
} ;

This does work and gives me C -> A, C -> B. (This is however not what I need.)

- Paul Meurer

Paul Meurer

unread,
Dec 20, 2024, 5:25:22 PM12/20/24
to Constraint Grammar, Paul Meurer
Sorry, the last line should have read:

This does work and gives me C -> A, B -> A. (This is however not what I need.)


> Am 20. 12. 24 um 23:09 schrieb Paul Meurer <Paul....@uib.no>:

Daniel Swanson

unread,
Dec 20, 2024, 11:00:52 PM12/20/24
to constrain...@googlegroups.com, Paul Meurer
You could try replacing (0 (*)) with (jT (*)) or restructure it into a
SETCHILD rule.

(0 (*)) is a contextual target, which is evaluated as a contextual
test and thus does not automatically evaluate to the target like the
other (*) does and instead tries to create a self-loop.

Daniel
> --
> 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 constraint-gram...@googlegroups.com.
> To view this discussion visit https://groups.google.com/d/msgid/constraint-grammar/47DB168A-AB87-489E-865B-2B1F66121D48%40uib.no.



--
Daniel Swanson, Certified Geek

Paul Meurer

unread,
Dec 21, 2024, 4:28:06 AM12/21/24
to Daniel Swanson, Paul Meurer, constrain...@googlegroups.com
Thanks for your suggestions. Unfortunately, none of this does work.

When I use

SETPARENT _C2_ TO (jT (*)) ;

the resulting attachment is B -> A (instead of B -> C).

When I use

SETCHILD (*) TO (jC2 (*)) ;

the rule isn’t triggered at all.

I seem still to be missing something.

- Paul

> Am 21. 12. 24 um 05:00 schrieb Daniel Swanson <popcorn.t...@gmail.com>:
> [External email] Make sure you recognize the sender's email address before you click links, open attachments, or get involved in financial transactions. Contact IT-support BRITA if you have any questions.

Tino Didriksen

unread,
Dec 21, 2024, 3:55:38 PM12/21/24
to constrain...@googlegroups.com
Fixed in latest version (1.4.19) - all packages and binaries are updated. Your testcase hit 2 separate bugs.

-- Tino Didriksen


--
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 constraint-gram...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages