From 8839448d38bfe4daf29a049b20d597158bf1b7f4 Mon Sep 17 00:00:00 2001 From: Santhosh Thottingal Date: Sun, 3 Jun 2018 17:10:16 +0530 Subject: [PATCH] Update concessive to use past.a and avoid duplication of patterns --- vinfl/Makefile | 1 + vinfl/concessive.fst | 32 +++++++++++++++++++++----------- 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/vinfl/Makefile b/vinfl/Makefile index b88e08c..9df8a80 100644 --- a/vinfl/Makefile +++ b/vinfl/Makefile @@ -6,6 +6,7 @@ SUBDIRS = aspects moods all: tense.a subdirs tense.a: past.a future.a present.a converb-past.a converb.a concessive.a +concessive.a: past.a converb.a: converb-past.a subdirs: $(SUBDIRS) diff --git a/vinfl/concessive.fst b/vinfl/concessive.fst index 1a18ffc..8a0daff 100644 --- a/vinfl/concessive.fst +++ b/vinfl/concessive.fst @@ -1,19 +1,29 @@ #include "../symbols.fst" +% ഉദാഹരണം: പോവുക - പോയാലും, പാടുക - പാടിയാലും , ചാടുക - ചാടിയാലും , തരിക-തന്നാലും +% കരയും - കരഞ്ഞാലും കുളിക്കുക - കുളിച്ചാലും + ALPHABET = [#AAsym#] %%%% Concessives അനുവാദകങ്ങൾ %%%%%%%%% -% ഉദാഹരണം: പോവുക - പോയാലും, പാടുക - പാടിയാലും , ചാടുക - ചാടിയാലും , തരിക-തന്നാലും -% കരയും - കരഞ്ഞാലും കുളിക്കുക - കുളിച്ചാലും +$past-tense$ = "" + +$concessive-exceptions$ = {പോകുക}:{പോയാലും} + +% We need to wrap the verb into past form first. For that, fake a past tag and pass +% it through the past.a. Only when the input has at end. +$fake-past$ = : ^-> ([] __ []) +$remove-past$ = : ^-> ([] __ []) + +$verb-suffix-map$ = {ു}:{ാലും} | \ + {ി} :{യാലും} +% The in above line has no functional effecet. But without that 3 duplicate results +% are generated. 3 is the length of ിയേ. I have not figured out the reason. + +$concessive-form$ = $verb-suffix-map$ ^-> ([#Consonants#]+ __ [#BM##TMP#]+ ) +$concessive$ = $fake-past$ || $past-tense$ || $concessive-form$ || $remove-past$ -$concessive-forms$ = {വരുക} : {വന്നാലും} | {വരിക} : {വന്നാലും} |\ - {തരുക} : {തന്നാലും} | {തരിക} : {തന്നാലും} |\ - {രുക}: {ർന്നാലും} | {രുക}: {ർന്നാലും} | \ - {യുക}: {ഞ്ഞാലും} | {യുക}: {ഞ്ഞാലും} |\ - {യ്ക്കുക} : {ച്ചാലും} | {യ്ക്കുക} : {ച്ചാലും} |\ - {ക്കുക} : {ന്നാലും} | {ക്കുക} : {ന്നാലും} |\ - {ിക്കുക} : {ിച്ചാലും} | {ിക്കുക} : {ിച്ചാലും} +$concessive-ex$ = $concessive-exceptions$ <>: ^-> ( __ [#POS##BM##Numbers##TMP#]+ ) -$concessives$ = $concessive-forms$ <>: ^-> ([#Letters#]+ __ [#POS##BM##Numbers##TMP#]+ ) -$concessives$ \ No newline at end of file +$concessive-ex$ || $concessive$ \ No newline at end of file