Info-str-specific Filler-Head rule subject-specific constraints

I am trying to license the following sentence with the means of complement extraction:

Ivan to-Masha book gave (Ivan gave a book to Masha).

The base grammar was obtained with the info structure library, specifying SVO basic word order and clause-final focus position. To that I then added 2nd-complement head-comp and comp-head rules, to accommodate ditransitive verbs (those are of special interest in the context of multiple question fronting in Slavic).

So what I think I want is:

(1) first extract a complement from gave’s V (this requires relaxing 2nd-comp-head rule’s COMPS to list from 0-1-list at the moment);
(2) then attach book’s NP to the resulting V by the special non-MC comp-head rule provided by the info-str library;
(3) then attach to-Masha to the resulting V by an appropriate filler-head rule.

I am currently stuck at step (3) because the filler-head rule somehow wants Ivan there and not Masha (poor Masha!):

– it also wants [CASE nom] there instead of dative.

What is identifying the non-head daughter of the filler head to the specific subject of the clause? I cannot immediately tell.

Here’s the filler-head rule:

infostr-dislocated-phrase := narrow-focus &
  [ SYNSEM.LOCAL.CAT [ MC +,
                       VAL.SUBJ < > ],
    C-CONT [ RELS <!  !>,
             HCONS <!  !>,
             ICONS <! #icons & info-str &
                      [ IARG1 #clause,
                        IARG2 #index ] !> ],
    HEAD-DTR.SYNSEM.LOCAL [ CAT [ MC -,
                                  HEAD verb ],
                            CONT.HOOK [ INDEX #clause,
                                        CLAUSE-KEY #clause ] ],
    NON-HEAD-DTR.SYNSEM [ LIGHT -,
                          LOCAL [ CAT.HEAD +np,
                                  CONT.HOOK [ INDEX #index,
                                              ICONS-KEY #icons ] ] ] ].

infostr-head-filler-phrase := nc-head-filler-phrase & infostr-dislocated-phrase & head-initial &
  [ SYNSEM.R-PERIPH +,
    HEAD-DTR.SYNSEM [ R-PERIPH -,
                      LOCAL.CAT.VAL.SUBJ olist ],
    NON-HEAD-DTR.SYNSEM.LOCAL.CONT.HOOK.ICONS-KEY semantic-focus ].

; SSH 2013-04-08 non-canonical filler-phrase (Rigth Dislocation, etc.)
nc-filler-phrase := binary-phrase & phrasal &
  [ SYNSEM [ LOCAL.CAT.VAL [ COMPS < >,
                             SPR < > ],
	     NON-LOCAL.SLASH 0-dlist ],
    ARGS <  [ SYNSEM [ LOCAL.CAT [ VAL.COMPS olist ],
		       NON-LOCAL [ SLASH 1-dlist &
					 [ LIST [ FIRST #slash,
						  REST < > & #last ],
					   LAST #last ],
				   QUE 0-dlist,
				   REL 0-dlist ] ] ],
	    [ SYNSEM [ LOCAL #slash & local &
			     [ CAT.VAL [ SUBJ olist,
					 COMPS olist,
					 SPR olist ],
			       CTXT.ACTIVATED + ],
		       NON-LOCAL.SLASH 0-dlist ] ] > ].

nc-head-filler-phrase := nc-filler-phrase & head-compositional.

sform := basic-binary-headed-phrase.

focality := sform & [ SYNSEM.LOCAL.CAT.MKG fc-only ].

narrow-focus := focality &
 [ SYNSEM.LIGHT - ].

Hmm well for one thing, I am clearly extracting the accusative complement and not the dative one. That already is incorrect. Still not sure why I am seeing masc in the unification failure though…

Perhaps this is why (I am seeing subject’s properties on what I want to be the second complement):

; SSH 2013-04-08 non-canonical and non-matrix clausal head-comp-phrase
; This type cannot be a root node by itself ([MC -]).
; This typed phrase is supposed to be combined with a filler-phrase.
basic-head-comp-nmc-phrase := head-valence-phrase & head-compositional &
                              binary-headed-phrase &
  [ SYNSEM phr-synsem &
       [ LOCAL.CAT [ MC -,
                     VAL [ SUBJ < >,
                           SPR #spr ],
                     POSTHEAD #ph,
                     HC-LIGHT #light ],
         LIGHT #light ],
    HEAD-DTR.SYNSEM
       [ LOCAL.CAT [ VAL [ SUBJ < [ LOCAL #slash ] >,
                           SPR #spr ],
                     HC-LIGHT #light,
                     POSTHEAD #ph ],
         NON-LOCAL.SLASH 1-dlist & [ LIST < #slash > ] ],
    NON-HEAD-DTR.SYNSEM canonical-synsem,
    C-CONT [ RELS <! !>, HCONS <! !>, ICONS <! !> ] ].

I think this ultimately boils down to this: Subject extraction vs Non-Main-Clause rules in info-str library