resources.sentenceSplitter.grammar.no-splits.jape Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of annie Show documentation
Show all versions of annie Show documentation
ANNIE is a general purpose information extraction system that
provides the building blocks of many other GATE applications.
The newest version!
/*
* no-splits.jape
*
* Copyright (c) 1998-2004, The University of Sheffield.
*
* This file is part of GATE (see http://gate.ac.uk/), and is free
* software, licenced under the GNU Library General Public License,
* Version 2, June 1991 (in the distribution as file licence.html,
* and also available at http://gate.ac.uk/gate/licence.html).
*
* Valentin Tablan, 23 Jan 2007
*
* $Id$
*/
//This grammar deals with documents that have no splits
Phase:noSplits
Input: Token Split
Options: control = once
Rule: blah
{Token}
-->
{
AnnotationSet splits = inputAS.get("Split");
if(splits == null || splits.isEmpty()){
outputAS.add(outputAS.firstNode(), outputAS.lastNode(),
"TempNoSplitText", Factory.newFeatureMap());
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy