Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Problem with adjectives (or with N/N?)

Help
2010-06-04
2013-04-08
  • Hi all,

    I'm wiriting a small grammar for Italian Sign Language and I have a problem with Adjectives. I don't  understand if my problems in realization depend on the syntactic category or depend on the logical form.

    For instance, if you use the French grammar (http://comp.ling.utexas.edu/wiki/lib/exe/fetch.php/openccg/grammars/french.ccg.txt ), you can parse "un bon livre", but you cannot realize the same fragment (in tccg as well as by using ccg-realize). Starting from the LF you can generate only "un livre". Is this correct? It depends on the N/N category or from the semantics of the adjective  "bon"? I'm loosing something?

    Thanks again for your great work in OpenCCG

    Alessandro

    P.S.
    I'm using the last version of OpenCCG (0.9.3) on MacOSX

     
  • Michael White
    Michael White
    2010-06-04

    Hi Alessandro

    An adjective, like other modifiers, should introduce its own nominal.  If you look at the category for determiners, you'll see that this grammar models them as "grammatemes", ie as adding a semantic feature on the nominal X:

    family Det(indexRel="det") {
      entry: np<2>  /^ n<2> : X:sem-obj(<det>*);
    }

    That's not an appropriate treatment for adjectives, which should introduce their own nominal, eg P for property:

    family Adj {
      entry: n<2> /^ n<2> : X:sem-obj(<adj>(P *));
    }

    This category will produce a node in the LF for the adjectival predicate; during realization, the words realizing the predicate will be looked up and added to the chart.  The existing cat could be made to work using indexRel, but that's not an appropriate solution for open class words; in particular, it would preclude adverbial modification of the adjective.

    -Mike

     
  • Hi Mike,

    ok, now I understand :)

    Thx a lot for your help!

    Alessandro

     
  • Hi Mike,

    after a while I back on this topic :)

    Consider again the adj definition

    family Adj { entry: n<2> /^ n<2> : X:sem-obj(<adj>(P *)); }

    I cannot understand how to modify the adjective with an adverb (e.g, "very large"). I think that in the adverb category (n/n)/(n/n)  needs to access to the P nominal, but the syntactic category of the adjective shows only the X variable.  Where I'm wrong?

    Thanks a lot,

    Alessandro

     
  • Michael White
    Michael White
    2010-09-13

    Ah, an excellent question!  With a not so excellent answer, unfortunately.

    Background: the problem of how to handle modifier modifiers, such as the intensifying adverb 'very', was not addressed in the original work by Baldridge and Kruijff on Hybrid Logic Dependency Semantics.  I managed to avoid the issue in my work on grammars for dialogue systems, but was unable to continue ignoring it in my group's more recent work on broad coverage realization.  Jason and I discussed several options, which I'll touch on below.  Unfortunately though, the approach we've taken is not supported in ccg2xml, ie in the dotccg sytax, at present.  I'd love for a volunteer to look into this, and may post it as an open feature request.  In the meanwhile, I've updated openccg/grammars/tiny/lexicon.xml (in the cvs) with an example of the solution we've used in the broad coverage work, to illustrate concretely how phrases like "a very blue book" can parse and realize using the xml format.

    Ok, on the solutions we considered.  One option would be to have the category for an adjective be something like

    blue :- (n/n) : @X(<Mod>(P ^ blue)

    where the nominal P appears in a feature structure for the higher-order category (n/n).  However, in openccg only atomic categories have feature structures, so we decided against this solution.

    The solution we've been pursuing is to make both nominals available in the result category, where the first (X) is the value of the usual 'index' feature, while the second (M) is the value of a new 'mod-index' feature (M for mod-index):

    blue :- n<~2>/n<2> : @X(<Mod>(M ^ blue))

    Note that default unification (inheritsFrom) is used, so that with multiple adjectives, M will be the nominal of the most recent modifier's predicate.

    Once the 'mod-index' is there, an intensifier like 'very' can pick it up to specify the Magnitude:

    very :- n<~1>/n<1>/(n<~2>/n<2>) : @M(<Magnitude>(R ^ very))

    Of course, to handle modifier modifier modifiers, we'd need to do something further, but this case doesn't seem to have arisen.

    So, again, this solution works in the native xml format, but ccg2xml does not have support for the mod-index feature.  I tried it and it doesn't work; looking at the code, it seems that modifications would be necessary to accommodate another nominal variable other than the 'index'.  Note that 'mod-index' does receive special treatment (just like 'index') in the realizer, so it would make sense to incorporate some special treatment for it in ccg2xml.  One option might be to reserve the variable 'M' for the mod-index, but that could break backwards compatibility.  Another option might be to assume that the second variable that looks like an index is the mod-index.

    The final solution we considered was to treat adjectives in a non-standard way, as follows:

    blue : adj : @M(blue)
    very: adj/adj: @M(<Magn>(R ^ very))
    adj_prenom_rule: adj => n/n : @X(<Mod>M)

    Here an adjective just starts out with a basic category that can be modified by 'very'.  It is later promoted by a unary rule to a prenominal modifier, n/n, adding in the modification relation (Mod).  This solution may already work in ccg2xml (I haven't tried it).  The reason we didn't go with this solution is that it uses non-standard categories, which is maybe not a problem in a particular grammar, but perhaps not something that the tool should force on the grammar writer.

    Interestingly, since we had this discussion, Matthew Honnibal did his thesis work on 'hat' categories, which in this case can be seen as essentially combining the adj cat and the adj => n/n unary rule into one unit.  As such, the hat category approach (or something like it) could be a way to resolve the impasse we ran into: either invoke the extra 'mod-index', or require non-standard categories.  Instead, with hat categories, it might be possible to have both nominals available, while still retaining a more traditional CCG approach (namely n/n for prenom adjectives).

    -Mike

     
  • Hi Mike,

    thanks for your detailed answer.  I tried in ccg2xml the solution that uses "adj" category and it works! Indeed,
    I gave a look to the lexicon.xml file on CVS but I think to l use the "adj"  in my work on Italian Sign Language for the moment, since I'm writing the grammar by using the "ccg2xml"  and for the moment I don't want to modify "by hand" the files produced.

    Thanks again for the great work on openccg.

    -Alessandro

     
  • Michael White
    Michael White
    2010-09-17

    Glad to hear the 'adj' solution works in ccgxml!  Thanks for your reply.  -Mike