Revision: 18302
          http://sourceforge.net/p/gate/code/18302
Author:   dgmaynard
Date:     2014-09-09 15:28:58 +0000 (Tue, 09 Sep 2014)
Log Message:
-----------
little grammar to remove dates inside percentages

Modified Paths:
--------------
    gate/trunk/plugins/ANNIE/resources/NE/main-twitter.jape
    gate/trunk/plugins/ANNIE/resources/NE/main.jape

Added Paths:
-----------
    gate/trunk/plugins/ANNIE/resources/NE/number_clean.jape

Modified: gate/trunk/plugins/ANNIE/resources/NE/main-twitter.jape
===================================================================
--- gate/trunk/plugins/ANNIE/resources/NE/main-twitter.jape     2014-09-09 
14:49:12 UTC (rev 18301)
+++ gate/trunk/plugins/ANNIE/resources/NE/main-twitter.jape     2014-09-09 
15:28:58 UTC (rev 18302)
@@ -23,6 +23,7 @@
 date
 reldate
 number
+number_clean
 address
 url_pre
 url

Modified: gate/trunk/plugins/ANNIE/resources/NE/main.jape
===================================================================
--- gate/trunk/plugins/ANNIE/resources/NE/main.jape     2014-09-09 14:49:12 UTC 
(rev 18301)
+++ gate/trunk/plugins/ANNIE/resources/NE/main.jape     2014-09-09 15:28:58 UTC 
(rev 18302)
@@ -24,6 +24,7 @@
 date
 reldate
 number
+number_clean
 address
 url_pre
 url

Added: gate/trunk/plugins/ANNIE/resources/NE/number_clean.jape
===================================================================
--- gate/trunk/plugins/ANNIE/resources/NE/number_clean.jape                     
        (rev 0)
+++ gate/trunk/plugins/ANNIE/resources/NE/number_clean.jape     2014-09-09 
15:28:58 UTC (rev 18302)
@@ -0,0 +1,28 @@
+
+
+
+Phase: Number_Clean
+Input: Percent Money
+Options: control = appelt
+
+
+
+
+
+Rule: PercentDate
+Priority: 50
+
+// If there's a Date annotation within a Percent annotation, remove the Date
+
+(
+ {Percent contains Date}
+): tag
+
+-->
+{
+  AnnotationSet tagAS = (AnnotationSet) bindings.get("tag");
+ AnnotationSet DateAS = inputAS.get("Date", tagAS.firstNode().getOffset(), 
tagAS.lastNode().getOffset());
+
+  outputAS.removeAll(DateAS);
+}
+ 

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
_______________________________________________
GATE-cvs mailing list
GATE-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to