mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-09 04:59:31 -06:00
working on ExTramI and german verbs phrase
This commit is contained in:
41
examples/tram/ExTramI.gfe
Normal file
41
examples/tram/ExTramI.gfe
Normal file
@@ -0,0 +1,41 @@
|
||||
--# -resource=../../lib/multimodal/MultimodalEng.gfc
|
||||
--# -path=multimodal:present:mathematical:prelude
|
||||
|
||||
incomplete concrete TramI of Tram = open Multimodal, DemRes, Symbol in {
|
||||
|
||||
flags startcat=Query ; lexer=literals ;
|
||||
|
||||
lincat
|
||||
Query = Phr ; -- top level, plain string
|
||||
Input = MS ; -- two parallel sequences (text and clicks)
|
||||
Dep, Dest = MAdv ;
|
||||
Click = Point ;
|
||||
|
||||
lin
|
||||
QInput = PhrMS PPos ;
|
||||
|
||||
GoFromTo x_MAdv y_MAdv = in MultimodalEng.MS "I want to go X Y" ;
|
||||
|
||||
ComeToFrom x_MAdv y_MAdv = in MultimodalEng.MS "I want to come X Y" ;
|
||||
|
||||
ComeFrom x_MAdv = in MultimodalEng.MS "I want to come X" ;
|
||||
|
||||
GoTo x_MAdv = in MultimodalEng.MS "I want to go X" ;
|
||||
|
||||
DepClick c = mkDem Adv (in MAdv "from here") c ;
|
||||
DestClick c = mkDem Adv (in MAdv "to here") c ;
|
||||
DepHere = DemAdv (in Adv "from here") ;
|
||||
DestHere = DemAdv (in Adv "to here") ;
|
||||
DepNamed s = MPrepNP from_Prep (DemNP (UsePN (SymbPN (MkSymb s)))) ;
|
||||
DestNamed s = MPrepNP to_Prep (DemNP (UsePN (SymbPN (MkSymb s)))) ;
|
||||
|
||||
CCoord x y = {point = "(" ++ x.s ++ "," ++ y.s ++ ")" ; lock_Point = <>} ;
|
||||
|
||||
-- Place = DNP ; -- name + click - not possible for "here"
|
||||
-- PClick c = this_DNP c ;
|
||||
-- PHere = DemNP this_NP ;
|
||||
-- PNamed s = DemNP (UsePN (SymbPN s)) ;
|
||||
|
||||
---- FromThisPlace =
|
||||
|
||||
}
|
||||
@@ -21,7 +21,10 @@ resources, located in
|
||||
To produce them, use 'make' and 'make install' in GF/lib/resource-1.0.
|
||||
You moreover have to set your GF_LIB_PATH to point to your GF/lib/.
|
||||
|
||||
|
||||
AR 7/11/2005 -- 25/2/2006
|
||||
The grammar in ExTramI.gfe compiles, but does not give the same grammar
|
||||
as TramI.gf.
|
||||
|
||||
|
||||
AR 7/11/2005 -- 6/3/2006
|
||||
|
||||
|
||||
|
||||
@@ -12,9 +12,9 @@ fun
|
||||
|
||||
fun
|
||||
GoFromTo : Dep -> Dest -> Input ; -- user input "want to go from a to b"
|
||||
GoToFrom : Dest -> Dep -> Input ; -- user input "want to go to a from b"
|
||||
ComeFrom : Dep -> Input ; -- user input "want to come from x (to where I am now)
|
||||
GoTo : Dest -> Input ; -- user input "want to go to x (from where I am now)
|
||||
ComeToFrom: Dest -> Dep -> Input ; -- user input "want to come to a from b"
|
||||
ComeFrom : Dep -> Input ; -- user input "want to come from x (to where I'm now)
|
||||
GoTo : Dest -> Input ; -- user input "want to go to x (from where I'm now)
|
||||
|
||||
DepClick : Click -> Dep ; -- "from here" with click
|
||||
DestClick : Click -> Dest ; -- "to here" with click
|
||||
|
||||
@@ -15,13 +15,13 @@ lin
|
||||
MPredVP (DemNP (UsePron i_Pron))
|
||||
(MAdvVP (MAdvVP (MComplVV want_VV (MUseV go_V)) x) y) ;
|
||||
|
||||
GoToFrom x y =
|
||||
ComeToFrom x y =
|
||||
MPredVP (DemNP (UsePron i_Pron))
|
||||
(MAdvVP (MAdvVP (MComplVV want_VV (MUseV go_V)) x) y) ;
|
||||
(MAdvVP (MAdvVP (MComplVV want_VV (MUseV come_V)) x) y) ;
|
||||
|
||||
ComeFrom x =
|
||||
MPredVP (DemNP (UsePron i_Pron))
|
||||
(MAdvVP (MComplVV want_VV (MUseV go_V)) x) ;
|
||||
(MAdvVP (MComplVV want_VV (MUseV come_V)) x) ;
|
||||
|
||||
GoTo x =
|
||||
MPredVP (DemNP (UsePron i_Pron))
|
||||
|
||||
Reference in New Issue
Block a user