From b30acda4216c28419f53ffe372ac9d25eba42b97 Mon Sep 17 00:00:00 2001 From: Adam Radziszewski <adam.radziszewski@pwr.wroc.pl> Date: Mon, 9 May 2011 17:36:06 +0200 Subject: [PATCH] simple syntactic example --- examples/np-match.ccl | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 examples/np-match.ccl diff --git a/examples/np-match.ccl b/examples/np-match.ccl new file mode 100644 index 0000000..127fb7a --- /dev/null +++ b/examples/np-match.ccl @@ -0,0 +1,33 @@ +match_rules( + apply( + match( + optional(equal(base[0], "nie")), + repeat( + inter(class[0], {adj, ppas, pact}) + ) + ), + cond( + agr(first(:2), last(M), {nmb,gnd,cas}) + ), + actions( + mark(M, "AdjP") + ) + ); + + apply( + match( + optional(is("AdjP")), + inter(class[0], {subst, ger, depr}) + ), + cond( + or( + empty(:1), + agrpp(last(:1), first(:2), {nmb,gnd,cas}) + ) + ), + actions( + mark(M, M, :2, "NP") + ) + ) +) + -- GitLab