mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-05-22 01:22:51 -06:00
extended api with some IQuant rules
This commit is contained in:
@@ -50,7 +50,7 @@ lin
|
|||||||
(mkCN common_A (mkCN divisor_N2 (mkNP and_Conj nps))) ;
|
(mkCN common_A (mkCN divisor_N2 (mkNP and_Conj nps))) ;
|
||||||
|
|
||||||
WhatIs np = mkPhr (mkQS (mkQCl whatSg_IP (mkVP np))) ;
|
WhatIs np = mkPhr (mkQS (mkQCl whatSg_IP (mkVP np))) ;
|
||||||
-- WhichAre cn ap = mkPhr (mkQS (mkQCl (mkIP (mkIDet which_IQuant plNum) cn) (mkVP ap))) ;
|
WhichAre cn ap = mkPhr (mkQS (mkQCl (mkIP which_IQuant cn) (mkVP ap))) ;
|
||||||
QuestS s = mkPhr (mkQS (mkQCl s)) ;
|
QuestS s = mkPhr (mkQS (mkQCl s)) ;
|
||||||
|
|
||||||
Yes = mkPhr yes_Utt ;
|
Yes = mkPhr yes_Utt ;
|
||||||
|
|||||||
@@ -30,10 +30,10 @@ langs = [
|
|||||||
langsLang = langs `except` ["Ara"]
|
langsLang = langs `except` ["Ara"]
|
||||||
|
|
||||||
-- languages for which to compile Try
|
-- languages for which to compile Try
|
||||||
langsAPI = langsLang `except` ["Cat","Hin","Ina","Rus","Tha"]
|
langsAPI = langsLang `except` ["Bul","Cat","Hin","Ina","Rus","Tha"]
|
||||||
|
|
||||||
-- languages for which to compile Mathematical
|
-- languages for which to compile Mathematical
|
||||||
langsMath = langsLang `except` ["Bul","Cat","Hin","Ina","Rus","Tha"]
|
langsMath = langsAPI
|
||||||
|
|
||||||
-- languages for which to run treebank test
|
-- languages for which to run treebank test
|
||||||
langsTest = langsLang `except` ["Cat","Hin","Spa","Tha"]
|
langsTest = langsLang `except` ["Cat","Hin","Spa","Tha"]
|
||||||
|
|||||||
@@ -704,16 +704,16 @@ incomplete resource Constructors = open Grammar in {
|
|||||||
mkQCl : IP -> QCl -- 8. what is there
|
mkQCl : IP -> QCl -- 8. what is there
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
{-
|
|
||||||
--3 IP, interrogative pronouns
|
--3 IP, interrogative pronouns
|
||||||
|
|
||||||
mkIP : overload {
|
mkIP : overload {
|
||||||
|
|
||||||
-- Interrogative pronouns
|
-- Interrogative pronouns
|
||||||
-- can be formed much like noun phrases, by using interrogative determiners.
|
-- can be formed much like noun phrases, by using interrogative quantifiers.
|
||||||
|
|
||||||
mkIP : IDet -> N -> IP ; -- 1. which city
|
mkIP : IQuant -> N -> IP ; -- 1. which city
|
||||||
mkIP : IDet -> (Num) -> (Ord) -> CN -> IP ; -- 2. which five best cities
|
mkIP : IQuant -> (Num) -> CN -> IP ; -- 2. which five big cities
|
||||||
|
|
||||||
-- An interrogative pronoun can be modified by an adverb.
|
-- An interrogative pronoun can be modified by an adverb.
|
||||||
|
|
||||||
@@ -722,7 +722,7 @@ incomplete resource Constructors = open Grammar in {
|
|||||||
|
|
||||||
-- More interrogative pronouns and determiners can be found in $Structural$.
|
-- More interrogative pronouns and determiners can be found in $Structural$.
|
||||||
|
|
||||||
-}
|
|
||||||
|
|
||||||
--3 IAdv, interrogative adverbs.
|
--3 IAdv, interrogative adverbs.
|
||||||
|
|
||||||
@@ -1315,11 +1315,18 @@ incomplete resource Constructors = open Grammar in {
|
|||||||
= IdetCN ;
|
= IdetCN ;
|
||||||
mkIP : IDet -> N -> IP -- which song
|
mkIP : IDet -> N -> IP -- which song
|
||||||
= \i,n -> IdetCN i (UseN n) ;
|
= \i,n -> IdetCN i (UseN n) ;
|
||||||
|
mkIP : IQuant -> CN -> IP -- which songs
|
||||||
|
= \i,n -> IdetCN (IdetQuant i NumSg) n ;
|
||||||
|
mkIP : IQuant -> Num -> CN -> IP -- which songs
|
||||||
|
= \i,nu,n -> IdetCN (IdetQuant i nu) n ;
|
||||||
|
mkIP : IQuant -> N -> IP -- which song
|
||||||
|
= \i,n -> IdetCN (IdetQuant i NumSg) (UseN n) ;
|
||||||
mkIP : IP -> Adv -> IP -- who in Europe
|
mkIP : IP -> Adv -> IP -- who in Europe
|
||||||
= AdvIP
|
= AdvIP
|
||||||
} ;
|
} ;
|
||||||
|
|
||||||
whichSg_IDet : IDet = IdetQuant which_IQuant NumSg ;
|
whichSg_IDet : IDet = IdetQuant which_IQuant NumSg ;
|
||||||
|
whichPl_IDet : IDet = IdetQuant which_IQuant NumPl ;
|
||||||
|
|
||||||
mkIAdv : Prep -> IP -> IAdv = PrepIP ;
|
mkIAdv : Prep -> IP -> IAdv = PrepIP ;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user