completed QuestionBul module

This commit is contained in:
krasimir
2008-02-22 14:10:50 +00:00
parent 038bb07c33
commit dd8331ce2b
3 changed files with 22 additions and 14 deletions

View File

@@ -8,14 +8,17 @@ concrete QuestionBul of Question = CatBul ** open ResBul, Prelude in {
s = \\t,a,p =>
let cls = cl.s ! t ! a ! p
in table {
QDir => cls ! OQuest ;
QIndir => "àêî" ++ cls ! ODir
QDir => cls ! Quest ;
QIndir => "àêî" ++ cls ! Main
} ---- "whether" in ExtEng
} ;
QuestVP ip vp =
let cl = mkClause ip.s {gn = ip.gn ; p = P3} vp
in {s = \\t,a,b,_ => cl.s ! t ! a ! b ! ODir} ;
let cl = mkClause (ip.s ! Nom) {gn = ip.gn ; p = P3} vp
in {s = \\t,a,b,_ => cl.s ! t ! a ! b ! Main} ;
QuestSlash ip slash =
mkQuestion (ss (slash.c2 ++ ip.s ! Acc)) slash ;
QuestIAdv iadv cl = mkQuestion iadv cl ;
@@ -30,10 +33,14 @@ concrete QuestionBul of Question = CatBul ** open ResBul, Prelude in {
} ;
IDetCN idet num ord cn = {
s = idet.s ! gennum cn.g idet.n ++
num.s ! dgenderSpecies cn.g Indef Nom ++
ord.s ! aform (gennum cn.g num.n) Indef Nom ++
cn.s ! NF idet.n Indef ;
s = \\c => let nf = case <idet.n, num.nonEmpty> of {
<Pl,True> => NFPlCount ;
_ => NF idet.n Indef
}
in idet.s ! gennum cn.g idet.n ++
num.s ! dgenderSpecies cn.g Indef Nom ++
ord.s ! aform (gennum cn.g num.n) Indef Nom ++
cn.s ! nf ;
gn = gennum cn.g idet.n
} ;

View File

@@ -57,7 +57,7 @@ resource ResBul = ParamX ** open Prelude in {
-- The order of sentence is needed already in $VP$.
Order = ODir | OQuest ;
Order = Main | Inv | Quest ;
--2 For $Adjective$
@@ -360,8 +360,9 @@ resource ResBul = ParamX ** open Prelude in {
verb = vp.s ! t ! a ! b ! agr ;
compl = vp.s2 ! agr
in case o of {
ODir => subj ++ verb ++ compl ;
OQuest => subj ++ verb ++ "ëè" ++ compl
Main => subj ++ verb ++ compl ;
Inv => verb ++ subj ++ compl ;
Quest => subj ++ verb ++ "ëè" ++ compl
}
} ;
@@ -450,8 +451,8 @@ resource ResBul = ParamX ** open Prelude in {
let cls = cl.s ! t ! a ! p ;
why = wh.s
in table {
QDir => why ++ cls ! OQuest ;
QIndir => why ++ cls ! ODir
QDir => why ++ cls ! Inv ;
QIndir => why ++ cls ! Main
}
} ;
}

View File

@@ -21,7 +21,7 @@ concrete SentenceBul of Sentence = CatBul ** open Prelude, ResBul in {
EmbedQS qs = {s = qs.s ! QIndir} ;
UseCl t a p cl = {
s = t.s ++ a.s ++ p.s ++ cl.s ! t.t ! a.a ! p.p ! ODir
s = t.s ++ a.s ++ p.s ++ cl.s ! t.t ! a.a ! p.p ! Main
} ;
UseQCl t a p cl = {
s = \\q => t.s ++ a.s ++ p.s ++ cl.s ! t.t ! a.a ! p.p ! q