Skip to content

Commit a4d3774

Browse files
author
Daniel Khashabi
authored
Merge pull request #244 from shyamupa/master
Deprecated old gazetter View Generator. Also incremented minor version number.
2 parents f5aeb9f + 917fa66 commit a4d3774

File tree

18 files changed

+56
-56
lines changed

18 files changed

+56
-56
lines changed

big-data-utils/pom.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<parent>
44
<artifactId>illinois-cogcomp-nlp</artifactId>
55
<groupId>edu.illinois.cs.cogcomp</groupId>
6-
<version>3.0.77</version>
6+
<version>3.0.78</version>
77
</parent>
88

99
<modelVersion>4.0.0</modelVersion>
@@ -23,7 +23,7 @@
2323
<dependency>
2424
<groupId>edu.illinois.cs.cogcomp</groupId>
2525
<artifactId>illinois-core-utilities</artifactId>
26-
<version>3.0.77</version>
26+
<version>3.0.78</version>
2727
</dependency>
2828
<dependency>
2929
<groupId>org.xeustechnologies.google-api</groupId>

chunker/pom.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<parent>
33
<artifactId>illinois-cogcomp-nlp</artifactId>
44
<groupId>edu.illinois.cs.cogcomp</groupId>
5-
<version>3.0.77</version>
5+
<version>3.0.78</version>
66
</parent>
77

88
<modelVersion>4.0.0</modelVersion>
@@ -13,7 +13,7 @@
1313
<dependency>
1414
<groupId>edu.illinois.cs.cogcomp</groupId>
1515
<artifactId>illinois-core-utilities</artifactId>
16-
<version>3.0.77</version>
16+
<version>3.0.78</version>
1717
</dependency>
1818

1919
<dependency>
@@ -24,12 +24,12 @@
2424
<dependency>
2525
<groupId>edu.illinois.cs.cogcomp</groupId>
2626
<artifactId>LBJava-NLP-tools</artifactId>
27-
<version>3.0.77</version>
27+
<version>3.0.78</version>
2828
</dependency>
2929
<dependency>
3030
<groupId>edu.illinois.cs.cogcomp</groupId>
3131
<artifactId>illinois-pos</artifactId>
32-
<version>3.0.77</version>
32+
<version>3.0.78</version>
3333
</dependency>
3434
<dependency>
3535
<groupId>edu.illinois.cs.cogcomp</groupId>

core-utilities/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>illinois-cogcomp-nlp</artifactId>
77
<groupId>edu.illinois.cs.cogcomp</groupId>
8-
<version>3.0.77</version>
8+
<version>3.0.78</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

corpusreaders/pom.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<parent>
55
<artifactId>illinois-cogcomp-nlp</artifactId>
66
<groupId>edu.illinois.cs.cogcomp</groupId>
7-
<version>3.0.77</version>
7+
<version>3.0.78</version>
88
</parent>
99

1010
<modelVersion>4.0.0</modelVersion>
@@ -15,12 +15,12 @@
1515
<dependency>
1616
<groupId>edu.illinois.cs.cogcomp</groupId>
1717
<artifactId>illinois-core-utilities</artifactId>
18-
<version>3.0.77</version>
18+
<version>3.0.78</version>
1919
</dependency>
2020
<dependency>
2121
<groupId>edu.illinois.cs.cogcomp</groupId>
2222
<artifactId>illinois-tokenizer</artifactId>
23-
<version>3.0.77</version>
23+
<version>3.0.78</version>
2424
</dependency>
2525
<dependency>
2626
<groupId>org.slf4j</groupId>

curator/pom.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>illinois-cogcomp-nlp</artifactId>
77
<groupId>edu.illinois.cs.cogcomp</groupId>
8-
<version>3.0.77</version>
8+
<version>3.0.78</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

@@ -15,7 +15,7 @@
1515
<dependency>
1616
<groupId>edu.illinois.cs.cogcomp</groupId>
1717
<artifactId>illinois-core-utilities</artifactId>
18-
<version>3.0.77</version>
18+
<version>3.0.78</version>
1919
</dependency>
2020

2121
<!-- Curator-related dependencies -->

edison/pom.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>illinois-cogcomp-nlp</artifactId>
77
<groupId>edu.illinois.cs.cogcomp</groupId>
8-
<version>3.0.77</version>
8+
<version>3.0.78</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

@@ -15,7 +15,7 @@
1515
<dependency>
1616
<groupId>edu.illinois.cs.cogcomp</groupId>
1717
<artifactId>illinois-core-utilities</artifactId>
18-
<version>3.0.77</version>
18+
<version>3.0.78</version>
1919
</dependency>
2020
<dependency>
2121
<groupId>edu.illinois.cs.cogcomp</groupId>
@@ -26,13 +26,13 @@
2626
<dependency>
2727
<groupId>edu.illinois.cs.cogcomp</groupId>
2828
<artifactId>illinois-corpusreaders</artifactId>
29-
<version>3.0.77</version>
29+
<version>3.0.78</version>
3030
</dependency>
3131
<!-- Used only in utilities.CreateTestTAResource -->
3232
<dependency>
3333
<groupId>edu.illinois.cs.cogcomp</groupId>
3434
<artifactId>illinois-curator</artifactId>
35-
<version>3.0.77</version>
35+
<version>3.0.78</version>
3636
<scope>test</scope>
3737
</dependency>
3838
<!-- Used only in features.FeatureUtilities to convert to LBJava-based feature vectors -->

edison/src/main/java/edu/illinois/cs/cogcomp/edison/annotators/GazetteerViewGenerator.java

+2
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
import java.util.zip.GZIPInputStream;
3939

4040
/**
41+
* Use SimpleGazetteerAnnotator instead
4142
* Use this class to create a gazetteer view for your text.
4243
*
4344
* Use this in combination with cogcomp-common-resources, and pass in
@@ -47,6 +48,7 @@
4748
*
4849
* @author Vivek Srikumar
4950
*/
51+
@Deprecated
5052
public class GazetteerViewGenerator extends Annotator {
5153
public static final GazetteerViewGenerator gazetteersInstance, cbcInstance;
5254
private static final Logger log = LoggerFactory.getLogger(GazetteerViewGenerator.class);

edison/src/main/java/edu/illinois/cs/cogcomp/edison/annotators/SimpleGazetteerAnnotator.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
* @author redman
3737
*/
3838
public class SimpleGazetteerAnnotator extends Annotator {
39-
39+
// ? should this not have a viewName?
4040
/** this hash tree contains the terms as exactly as they are. */
4141
ArrayList<GazetteerTree> dictionaries;
4242
/** this hash tree contains the terms in lowercase. */

edison/src/main/java/edu/illinois/cs/cogcomp/edison/features/factory/WordFeatureExtractorFactory.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation;
1313
import edu.illinois.cs.cogcomp.core.io.IOUtils;
1414
import edu.illinois.cs.cogcomp.core.io.LineIO;
15-
import edu.illinois.cs.cogcomp.edison.annotators.GazetteerViewGenerator;
15+
import edu.illinois.cs.cogcomp.edison.annotators.SimpleGazetteerAnnotator;
1616
import edu.illinois.cs.cogcomp.edison.features.*;
1717
import edu.illinois.cs.cogcomp.edison.features.factory.WordNetFeatureExtractor.WordNetFeatureClass;
1818
import edu.illinois.cs.cogcomp.edison.features.helpers.WordHelpers;
@@ -406,7 +406,7 @@ private static Set<Feature> getConditionalFeature(boolean condition, Feature...
406406
}
407407

408408
public static WordFeatureExtractor getGazetteerFeatureExtractor(final String name,
409-
final GazetteerViewGenerator gazetteerViewGenerator) {
409+
final SimpleGazetteerAnnotator gazetteerViewGenerator) {
410410

411411
if (!gazetteerFeatureExtractors.containsKey(name)) {
412412

edison/src/main/java/edu/illinois/cs/cogcomp/edison/features/manifest/KnownFexes.java

+5-6
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
package edu.illinois.cs.cogcomp.edison.features.manifest;
99

1010
import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent;
11-
import edu.illinois.cs.cogcomp.edison.annotators.GazetteerViewGenerator;
1211
import edu.illinois.cs.cogcomp.edison.features.CurrencyIndicator;
1312
import edu.illinois.cs.cogcomp.edison.features.DiscreteFeature;
1413
import edu.illinois.cs.cogcomp.edison.features.Feature;
@@ -102,11 +101,11 @@ public Set<Feature> getFeatures(Constituent c) throws EdisonException {
102101
fexes.put("brown-clusters-1000", BrownClusterFeatureExtractor.instance1000);
103102
fexes.put("brown-clusters-3200", BrownClusterFeatureExtractor.instance3200);
104103

105-
fexes.put("gazetteers", WordFeatureExtractorFactory.getGazetteerFeatureExtractor(
106-
"gazetteers", GazetteerViewGenerator.gazetteersInstance));
107-
108-
fexes.put("cbc", WordFeatureExtractorFactory.getGazetteerFeatureExtractor("cbc",
109-
GazetteerViewGenerator.gazetteersInstance));
104+
// fexes.put("gazetteers", WordFeatureExtractorFactory.getGazetteerFeatureExtractor(
105+
// "gazetteers", GazetteerViewGenerator.gazetteersInstance));
106+
//
107+
// fexes.put("cbc", WordFeatureExtractorFactory.getGazetteerFeatureExtractor("cbc",
108+
// GazetteerViewGenerator.gazetteersInstance));
110109

111110
fexes.put("CORLEX", CorlexFeatureExtractor.instance);
112111
fexes.put("roget-thesaurus", RogetThesaurusFeatures.INSTANCE);

edison/src/test/java/edu/illinois/cs/cogcomp/edison/features/factory/TestWordFeatureFactory.java

+11-11
Original file line numberDiff line numberDiff line change
@@ -191,17 +191,17 @@ public final void testFeatureCollection() throws Exception {
191191
}
192192
}
193193
}
194-
195-
public final void testGazetteerFeatures() throws Exception {
196-
System.out.println("\tTesting gazetteer features");
197-
WordFeatureExtractor fex =
198-
WordFeatureExtractorFactory.getGazetteerFeatureExtractor("gazetteer",
199-
new GazetteerViewGenerator("gazetteers", ViewNames.GAZETTEER));
200-
201-
for (TextAnnotation ta : tas) {
202-
runTest(ta, fex);
203-
}
204-
}
194+
// Not needed anymore, as test of SimpleGazetteerAnnotator in SimpleGazetteerAnnotatorTest.java suffice.
195+
// public final void testGazetteerFeatures() throws Exception {
196+
// System.out.println("\tTesting gazetteer features");
197+
// WordFeatureExtractor fex =
198+
// WordFeatureExtractorFactory.getGazetteerFeatureExtractor("gazetteer",
199+
// new GazetteerViewGenerator("gazetteers", ViewNames.GAZETTEER));
200+
//
201+
// for (TextAnnotation ta : tas) {
202+
// runTest(ta, fex);
203+
// }
204+
// }
205205

206206
private void runTest(TextAnnotation ta, WordFeatureExtractor fex) throws EdisonException {
207207

edison/src/test/java/edu/illinois/cs/cogcomp/edison/utilities/CreateTestFeaturesResource.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,10 @@
77
*/
88
package edu.illinois.cs.cogcomp.edison.utilities;
99

10-
import edu.illinois.cs.cogcomp.core.datastructures.ViewNames;
1110
import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent;
1211
import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation;
1312
import edu.illinois.cs.cogcomp.core.io.IOUtils;
14-
import edu.illinois.cs.cogcomp.edison.annotators.GazetteerViewGenerator;
13+
import edu.illinois.cs.cogcomp.edison.annotators.SimpleGazetteerAnnotator;
1514
import edu.illinois.cs.cogcomp.edison.features.Feature;
1615
import edu.illinois.cs.cogcomp.edison.features.FeatureCollection;
1716
import edu.illinois.cs.cogcomp.edison.features.WordFeatureExtractor;
@@ -181,7 +180,7 @@ private void addGazetteerFeatures() throws Exception {
181180
System.out.println("\tadding gazetteer features");
182181
WordFeatureExtractor fex =
183182
WordFeatureExtractorFactory.getGazetteerFeatureExtractor("gazetteer",
184-
new GazetteerViewGenerator("gazetteers", ViewNames.GAZETTEER));
183+
new SimpleGazetteerAnnotator());
185184

186185
for (TextAnnotation ta : tas) {
187186
addFeatures(ta, fex);

lbjava-nlp-tools/pom.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<parent>
44
<artifactId>illinois-cogcomp-nlp</artifactId>
55
<groupId>edu.illinois.cs.cogcomp</groupId>
6-
<version>3.0.77</version>
6+
<version>3.0.78</version>
77
</parent>
88

99
<modelVersion>4.0.0</modelVersion>
@@ -31,7 +31,7 @@
3131
<dependency>
3232
<groupId>edu.illinois.cs.cogcomp</groupId>
3333
<artifactId>illinois-core-utilities</artifactId>
34-
<version>3.0.77</version>
34+
<version>3.0.78</version>
3535
</dependency>
3636
</dependencies>
3737

lemmatizer/pom.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>illinois-cogcomp-nlp</artifactId>
77
<groupId>edu.illinois.cs.cogcomp</groupId>
8-
<version>3.0.77</version>
8+
<version>3.0.78</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

@@ -15,12 +15,12 @@
1515
<dependency>
1616
<groupId>edu.illinois.cs.cogcomp</groupId>
1717
<artifactId>illinois-core-utilities</artifactId>
18-
<version>3.0.77</version>
18+
<version>3.0.78</version>
1919
</dependency>
2020
<dependency>
2121
<groupId>edu.illinois.cs.cogcomp</groupId>
2222
<artifactId>illinois-edison</artifactId>
23-
<version>3.0.77</version>
23+
<version>3.0.78</version>
2424
</dependency>
2525
<dependency>
2626
<groupId>edu.stanford.nlp</groupId>

ner/pom.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>illinois-cogcomp-nlp</artifactId>
77
<groupId>edu.illinois.cs.cogcomp</groupId>
8-
<version>3.0.77</version>
8+
<version>3.0.78</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

@@ -23,12 +23,12 @@
2323
<dependency>
2424
<groupId>edu.illinois.cs.cogcomp</groupId>
2525
<artifactId>illinois-tokenizer</artifactId>
26-
<version>3.0.77</version>
26+
<version>3.0.78</version>
2727
</dependency>
2828
<dependency>
2929
<groupId>edu.illinois.cs.cogcomp</groupId>
3030
<artifactId>illinois-core-utilities</artifactId>
31-
<version>3.0.77</version>
31+
<version>3.0.78</version>
3232
</dependency>
3333
<!-- Contains the gazetteers and Brown clusters -->
3434
<dependency>
@@ -44,7 +44,7 @@
4444
<dependency>
4545
<groupId>edu.illinois.cs.cogcomp</groupId>
4646
<artifactId>LBJava-NLP-tools</artifactId>
47-
<version>3.0.77</version>
47+
<version>3.0.78</version>
4848
</dependency>
4949

5050
<!-- models: you need to use/specify a new path to avoid using these -->

pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<groupId>edu.illinois.cs.cogcomp</groupId>
88
<artifactId>illinois-cogcomp-nlp</artifactId>
99
<packaging>pom</packaging>
10-
<version>3.0.77</version>
10+
<version>3.0.78</version>
1111

1212
<modules>
1313
<module>core-utilities</module>

pos/pom.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<parent>
33
<artifactId>illinois-cogcomp-nlp</artifactId>
44
<groupId>edu.illinois.cs.cogcomp</groupId>
5-
<version>3.0.77</version>
5+
<version>3.0.78</version>
66
</parent>
77

88
<modelVersion>4.0.0</modelVersion>
@@ -13,7 +13,7 @@
1313
<dependency>
1414
<groupId>edu.illinois.cs.cogcomp</groupId>
1515
<artifactId>illinois-core-utilities</artifactId>
16-
<version>3.0.77</version>
16+
<version>3.0.78</version>
1717
</dependency>
1818

1919
<dependency>
@@ -24,7 +24,7 @@
2424
<dependency>
2525
<groupId>edu.illinois.cs.cogcomp</groupId>
2626
<artifactId>LBJava-NLP-tools</artifactId>
27-
<version>3.0.77</version>
27+
<version>3.0.78</version>
2828
</dependency>
2929
<dependency>
3030
<groupId>edu.illinois.cs.cogcomp</groupId>

tokenizer/pom.xml

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<parent>
66
<artifactId>illinois-cogcomp-nlp</artifactId>
77
<groupId>edu.illinois.cs.cogcomp</groupId>
8-
<version>3.0.77</version>
8+
<version>3.0.78</version>
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111

@@ -15,17 +15,17 @@
1515
<dependency>
1616
<groupId>edu.illinois.cs.cogcomp</groupId>
1717
<artifactId>illinois-core-utilities</artifactId>
18-
<version>3.0.77</version>
18+
<version>3.0.78</version>
1919
</dependency>
2020
<dependency>
2121
<groupId>edu.illinois.cs.cogcomp</groupId>
2222
<artifactId>LBJava-NLP-tools</artifactId>
23-
<version>3.0.77</version>
23+
<version>3.0.78</version>
2424
</dependency>
2525
<dependency>
2626
<groupId>edu.illinois.cs.cogcomp</groupId>
2727
<artifactId>illinois-curator</artifactId>
28-
<version>3.0.77</version>
28+
<version>3.0.78</version>
2929
<scope>test</scope>
3030
</dependency>
3131
</dependencies>

0 commit comments

Comments
 (0)