# &compoundword takes care of compound verbs and compound nouns. # &parword resolves the ambiguity in the use of par as loc_pp and as disj # marker sub compoundword{ #we assume that if there is a combination like #bandh kiyaa, #it has to be a compound word. Also: aur koii, aur kuch local($word) = @_; local($nextword) = $inpsent[$i]; @comptag = (); $word .= " "; $word .= $nextword; if( ( $d = &vp($word) ) eq "true"){ @comptag = @tensetag; @tensetag = (); $i++; $retval = "true"; } elsif ( ( $d = &np($word) ) ne "false") { @comptag = @nptag; @nptag = (); $i++; $retval = "true"; } else { $retval = "false";} } sub parword{ #if previous word of par is a noun, it is loc_pp #else it is a disjunctive form (but). local($word) = @_; @parwrd = (); if ( $word eq "par" ){ $previouswd = $inpsent[$i-2]; if ( ( $res = &np($previouswd) ) ne "false" ){ push(@parwrd, "(par loc_pp)"); $retval = "true"; } else{ push(@parwrd,"(par disj)"); $retval = "true";} }else { $retval = "false";} } 1;