Search code examples
gf

Generating a sentence with passive tense in GF without "to be"


I used Phrase to generate the sentence "Play a comedy movie hosted by BBC".

mkPhr (mkVP(
        (mkV2 (mkV ("Play")))
        (mkNP
            aSg_Det
            (mkCN 
                (mkCN (mkN ("comedy")))
                (mkSC (passiveVP
                         (mkV2 ("host"))
                         (mkNP (mkN ("BBC"))))))))

But I get the result "Play a movie to be hosted by BBC". I checked GF librires but it seems like there is no way to change a VP to a NP in order to avoid "to be".

May you guys to teach me how to get rid of this to be, or is there any way in GF to add up two sentences or more to a Phrase.

Thank you~


Solution

  • Like @aschepler said, "hosted by BBC" is a participle phrase, not passive voice. In the Extend module, there are a couple of functions to create participles from VPs:

    PastPartAP      : VPSlash -> AP ;         -- lost (opportunity) ; (opportunity) lost in space
    PastPartAgentAP : VPSlash -> NP -> AP ;   -- (opportunity) lost by the company
    

    So we can use PastPartAgentAP to create the participle "hosted by BBC". If you open ExtendEng in your GF file, you can use all of its functions, just like you're already doing with SyntaxEng and ParadigmsEng. (See also this answer.)

    Here's an example that you can copy and paste into a file called Comedy.gf and play with it in the GF shell.

    resource Comedy = open SyntaxEng, ParadigmsEng, ExtendEng in {
    
    oper
      -- Some lexicon
      comedy_N : N = mkN "comedy" ;
      host_V2 : V2 = mkV2 "host" ;
      play_V2 : V2 = mkV2 "play" ;
      BBC_PN : PN = mkPN "BBC" ;
    
      -- Intermediate phrases
      hosted_by_BBC : AP =
        PastPartAgentAP (mkVPSlash host_V2) (mkNP BBC_PN) ;
    
      comedy_hosted_by_BBC : NP =
        mkNP a_Det (mkCN comedy_N hosted_by_BBC) ;
    
      -- The final phrase
      play_comedy_hosted_by_BBC : Utt =
        mkUtt (mkImp (mkVP play_V2 comedy_hosted_by_BBC)) ;
    }
    

    When you open Comedy.gf in a GF shell with the flag -retain, you can check the lexicon and the intermediate results with the command cc. For example:

    > cc -table comedy_hosted_by_BBC
    s . NCase Nom => a comedy hosted by BBC
    s . NCase Gen => a comedy's hosted by BBC
    s . NPAcc => a comedy hosted by BBC
    s . NPNomPoss => a comedy hosted by BBC
    a . AgP3Sg Neutr
    
    > cc -one play_comedy_hosted_by_BBC
    play a comedy hosted by BBC