From 2f5a039c9ede65741bacbc8948c81a385dce94fe Mon Sep 17 00:00:00 2001 From: Hao Wu Date: Sun, 4 Feb 2018 12:32:52 -0500 Subject: [PATCH 1/2] init project --- finetyper/pom.xml | 24 +++++++++++++++++++ .../cs/cogcomp/finetyper/FineTyper.java | 7 ++++++ .../finetyper/typers/FINER113Typer.java | 13 ++++++++++ .../finetyper/typers/OpendomainTyper.java | 12 ++++++++++ .../cs/cogcomp/finetyper/typers/Typer.java | 21 ++++++++++++++++ pom.xml | 1 + 6 files changed, 78 insertions(+) create mode 100644 finetyper/pom.xml create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java diff --git a/finetyper/pom.xml b/finetyper/pom.xml new file mode 100644 index 000000000..a3cbfdaa4 --- /dev/null +++ b/finetyper/pom.xml @@ -0,0 +1,24 @@ + + + 4.0.0 + + + illinois-cogcomp-nlp + edu.illinois.cs.cogcomp + 4.0.1 + + + fine-typer + + + + edu.illinois.cs.cogcomp + illinois-core-utilities + 4.0.1 + + + + + \ No newline at end of file diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java new file mode 100644 index 000000000..cebf55e1a --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java @@ -0,0 +1,7 @@ +package edu.illinois.cs.cogcomp.finetyper; + +/** + * Created by haowu4 on 2/3/18. + */ +public class FineTyper { +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java new file mode 100644 index 000000000..42c399fca --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java @@ -0,0 +1,13 @@ +package edu.illinois.cs.cogcomp.finetyper.typers; + +/** + * Created by haowu4 on 2/3/18. + *

+ * A Fine-Grained Entity Recognizer that recognize 113 type defined in the following paper. + *

+ * Xiao Ling and Daniel S. Weld (2012). + * "Fine-Grained Entity Recognition", + * in Proceedings OF THE TWENTY-SIXTH AAAI CONFERENCE ON ARTIFICIAL INTELLIGENCE (AAAI), 2012. + */ +public class FINER113Typer { +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java new file mode 100644 index 000000000..559eeff10 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java @@ -0,0 +1,12 @@ +package edu.illinois.cs.cogcomp.finetyper.typers; + +/** + * Created by haowu4 on 2/3/18. + * + * Open Domain fine-grain typing based on WebisA and word embedding similarity. + * + * + */ +public class OpendomainTyper { + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java new file mode 100644 index 000000000..5d542f335 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java @@ -0,0 +1,21 @@ +package edu.illinois.cs.cogcomp.finetyper.typers; + +import edu.illinois.cs.cogcomp.core.datastructures.Pair; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; + +import java.util.List; +import java.util.Map; + +/** + * Created by haowu4 on 2/4/18. + */ +public interface Typer { + /** + * Determine types for the given + * + * @param query + * @return list of constituents with type and their confidence added as labels. + */ + List getTypes(List query); +} diff --git a/pom.xml b/pom.xml index 27fe4e73e..6e33211d0 100644 --- a/pom.xml +++ b/pom.xml @@ -33,6 +33,7 @@ verbsense pipeline dataless-classifier + finetyper external/external-commons external/clausie From 6ae609414be4256afda0d252acdbb39de2951e38 Mon Sep 17 00:00:00 2001 From: Hao Wu Date: Wed, 7 Feb 2018 05:39:58 -0500 Subject: [PATCH 2/2] ported everything, still have some issue with datastore, will fix it later. --- .../core/datastructures/ViewNames.java | 4 + finetyper/pom.xml | 33 + .../cs/cogcomp/finetyper/FineTyper.java | 7 - .../cs/cogcomp/finetyper/FinerResource.java | 43 + .../illinois/cs/cogcomp/finetyper/Utils.java | 29 + .../finetyper/finer/FinerAnnotator.java | 69 + .../finetyper/finer/FinerTyperFactory.java | 184 + .../mention/BasicMentionDetection.java | 46 + .../components/mention/MentionDetecter.java | 14 + .../finer/components/mention/TypeMapper.java | 31 + .../components/typers/HypernymTyper.java | 80 + .../finer/components/typers/IFinerTyper.java | 13 + .../finer/components/typers/KBBiasTyper.java | 64 + .../finer/components/typers/NGramPattern.java | 66 + .../typers/NGramPatternBasedTyper.java | 75 + .../datastructure/FineTypeConstituent.java | 79 + .../finer/datastructure/types/FinerType.java | 126 + .../finer/datastructure/types/TypeSystem.java | 106 + .../finetyper/finer/wordnet/WordNetUtils.java | 214 + .../finetyper/typers/FINER113Typer.java | 13 - .../finetyper/typers/OpendomainTyper.java | 12 - .../cs/cogcomp/finetyper/typers/Typer.java | 21 - .../finetyper/wsd/WordSenseAnnotator.java | 194 + .../wsd/datastructure/WordAndPOS.java | 42 + .../wsd/embedding/EmbeddingSpace.java | 109 + .../finetyper/wsd/math/FloatDenseVector.java | 73 + .../finetyper/wsd/math/Similarity.java | 56 + .../finer_resource/figer.xiang.label | 10442 ++++++++++++++++ .../resources/finer_resource/figer_hier.json | 428 + .../finer_resource/ontonote_type_mapping.json | 24 + .../resources/finer_resource/patterndb.txt | 931 ++ .../finetyper/FinerResourceUpload.java | 37 + .../cs/cogcomp/finetyper/TestFiger.java | 113 + 33 files changed, 13725 insertions(+), 53 deletions(-) delete mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FinerResource.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/Utils.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerAnnotator.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerTyperFactory.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/BasicMentionDetection.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/MentionDetecter.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/TypeMapper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/HypernymTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/IFinerTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/KBBiasTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPattern.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPatternBasedTyper.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/FineTypeConstituent.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/FinerType.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/TypeSystem.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/wordnet/WordNetUtils.java delete mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java delete mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java delete mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/WordSenseAnnotator.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/datastructure/WordAndPOS.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/embedding/EmbeddingSpace.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/FloatDenseVector.java create mode 100644 finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/Similarity.java create mode 100644 finetyper/src/main/resources/finer_resource/figer.xiang.label create mode 100644 finetyper/src/main/resources/finer_resource/figer_hier.json create mode 100644 finetyper/src/main/resources/finer_resource/ontonote_type_mapping.json create mode 100644 finetyper/src/main/resources/finer_resource/patterndb.txt create mode 100644 finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/FinerResourceUpload.java create mode 100644 finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/TestFiger.java diff --git a/core-utilities/src/main/java/edu/illinois/cs/cogcomp/core/datastructures/ViewNames.java b/core-utilities/src/main/java/edu/illinois/cs/cogcomp/core/datastructures/ViewNames.java index fd788635a..963903d63 100644 --- a/core-utilities/src/main/java/edu/illinois/cs/cogcomp/core/datastructures/ViewNames.java +++ b/core-utilities/src/main/java/edu/illinois/cs/cogcomp/core/datastructures/ViewNames.java @@ -132,6 +132,10 @@ public class ViewNames { public static final String POST_ERE = "POST_ERE"; public static final String EVENT_ERE = "EVENT_ERE"; + public static final String FINE_NER_TYPE = "FINE_NER_TYPE"; + public static final String FINE_NER_TYPE_WSD = "FINE_NER_TYPE_WSD"; + public static final String WEB_IS_A = "WEB_IS_A"; + public static final String TRANSLITERATION = "TRANSLITERATION"; public static ViewTypes getViewType(String viewName) { diff --git a/finetyper/pom.xml b/finetyper/pom.xml index a3cbfdaa4..eadc8ce4e 100644 --- a/finetyper/pom.xml +++ b/finetyper/pom.xml @@ -18,6 +18,39 @@ illinois-core-utilities 4.0.1 + + org.cogcomp + cogcomp-datastore + RELEASE + + + net.sf.extjwnl + extjwnl + 1.9.2 + + + net.sf.extjwnl + extjwnl-data-wn30 + 1.2 + + + org.apache.commons + commons-compress + 1.8.1 + + + edu.illinois.cs.cogcomp + illinois-nlp-pipeline + 4.0.0 + test + + + org.slf4j + slf4j-api + 1.7.25 + test + + diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java deleted file mode 100644 index cebf55e1a..000000000 --- a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FineTyper.java +++ /dev/null @@ -1,7 +0,0 @@ -package edu.illinois.cs.cogcomp.finetyper; - -/** - * Created by haowu4 on 2/3/18. - */ -public class FineTyper { -} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FinerResource.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FinerResource.java new file mode 100644 index 000000000..1234adf11 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/FinerResource.java @@ -0,0 +1,43 @@ +package edu.illinois.cs.cogcomp.finetyper; + +import io.minio.errors.InvalidEndpointException; +import io.minio.errors.InvalidPortException; +import org.apache.commons.compress.archivers.tar.TarArchiveInputStream; +import org.apache.commons.compress.compressors.gzip.GzipCompressorInputStream; +import org.cogcomp.Datastore; +import org.cogcomp.DatastoreException; + +import java.io.*; + +/** + * Created by haowu4 on 2/3/18. + */ +public class FinerResource { + + public static final String FINER_RESOURCE_GROUP_ID = "edu.cogcomp.cs.illinois.finetyper"; + + public static final String WORD_EMBEDDING_TAR_GZ = "word_embedding.txt.tar.gz"; + public static final String SENSE_EMBEDDING_TAR_GZ = "synset_embeddings_300.txt.tar.gz"; + public static final String KB_BIAS_RESOURCE_TAR_GZ = "kbias.txt.tar.gz"; + public static final String WORD_POS_TO_SENSE_TAR_GZ = "word_pos_to_synsets.txt.tar.gz"; + public static final String SYNSET2TYPE_TAR_GZ = "synset2TypeMap.txt.tar.gz"; + + public static InputStream getTarGZInputStrem(File file) throws IOException { + return new TarArchiveInputStream(new GzipCompressorInputStream(new FileInputStream(file))); + } + + public static Datastore getDefaultDatastore() throws DatastoreException { + return new Datastore(); + } + + public static InputStream getResourceInputStream(Datastore dataStore, String name) throws IOException, DatastoreException { + File file = dataStore.getFile( + FinerResource.FINER_RESOURCE_GROUP_ID, name, 1.0); + if (name.endsWith("tar.gz")) { + return getTarGZInputStrem(file); + } + return new FileInputStream(file); + } + + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/Utils.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/Utils.java new file mode 100644 index 000000000..4a5c769d5 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/Utils.java @@ -0,0 +1,29 @@ +package edu.illinois.cs.cogcomp.finetyper; + +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.View; + +import java.util.ArrayList; +import java.util.List; + +/** + * Created by haowu4 on 2/7/18. + */ +public class Utils { + public static List getSentenceConstituents(Sentence sentence, TextAnnotation ta, String viewName) { + List ret = new ArrayList<>(); + int start = sentence.getStartSpan(); + int end = sentence.getEndSpan(); + View view = ta.getView(viewName); + + for (Constituent ct : view.getConstituents()) { + if (ct.getStartSpan() >= start && ct.getEndSpan() < end) { + ret.add(ct); + } + } + return ret; + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerAnnotator.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerAnnotator.java new file mode 100644 index 000000000..4f371b9e6 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerAnnotator.java @@ -0,0 +1,69 @@ +package edu.illinois.cs.cogcomp.finetyper.finer; + +import edu.illinois.cs.cogcomp.annotation.Annotator; +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.*; +import edu.illinois.cs.cogcomp.core.utilities.configuration.ResourceManager; +import edu.illinois.cs.cogcomp.finetyper.finer.components.typers.IFinerTyper; +import edu.illinois.cs.cogcomp.finetyper.finer.components.mention.MentionDetecter; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; + +import java.util.ArrayList; +import java.util.List; +import java.util.Optional; + +/** + * Created by haowu4 on 1/15/17. + */ +public class FinerAnnotator extends Annotator { + private MentionDetecter mentionDetecter; + private List typers; + + + public FinerAnnotator(MentionDetecter mentionDetecter, List typers) { + super(ViewNames.FINE_NER_TYPE, new String[]{ViewNames.POS, ViewNames.NER_ONTONOTES}); + this.mentionDetecter = mentionDetecter; + this.typers = typers; + } + + public void setMentionDetecter(MentionDetecter mentionDetecter) { + this.mentionDetecter = mentionDetecter; + } + + public void addTyper(IFinerTyper typer) { + this.typers.add(typer); + } + + @Override + public void initialize(ResourceManager rm) { + + } + + public void addView(TextAnnotation ta) { + List fineTypes = this.getAllFineTypeConstituents(ta); + View finalAnnotation = new SpanLabelView(ViewNames.FINE_NER_TYPE, ta); + for (FineTypeConstituent c : fineTypes) { + Optional ret = c.toConstituent(ViewNames.FINE_NER_TYPE); + ret.ifPresent(finalAnnotation::addConstituent); + } + ta.addView(ViewNames.FINE_NER_TYPE, finalAnnotation); + } + + public List getAllFineTypeConstituents(TextAnnotation ta) { + List allCandidates = new ArrayList<>(); + for (int i = 0; i < ta.getNumberOfSentences(); i++) { + Sentence sent = ta.getSentence(i); + List sentence_candidates = mentionDetecter.getMentionCandidates(ta, sent); + for (IFinerTyper typer : this.typers) { + typer.annotate(sentence_candidates, sent); + } + + for (FineTypeConstituent c : sentence_candidates) { + c.finish(); + allCandidates.add(c); + } + } + return allCandidates; + } + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerTyperFactory.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerTyperFactory.java new file mode 100644 index 000000000..5779a8ece --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/FinerTyperFactory.java @@ -0,0 +1,184 @@ +package edu.illinois.cs.cogcomp.finetyper.finer; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; +import edu.illinois.cs.cogcomp.finetyper.FinerResource; +import edu.illinois.cs.cogcomp.finetyper.finer.components.typers.IFinerTyper; +import edu.illinois.cs.cogcomp.finetyper.finer.components.mention.MentionDetecter; +import edu.illinois.cs.cogcomp.finetyper.finer.components.typers.HypernymTyper; +import edu.illinois.cs.cogcomp.finetyper.finer.components.typers.KBBiasTyper; +import edu.illinois.cs.cogcomp.finetyper.finer.components.mention.BasicMentionDetection; +import edu.illinois.cs.cogcomp.finetyper.finer.components.mention.TypeMapper; +import edu.illinois.cs.cogcomp.finetyper.finer.components.typers.NGramPattern; +import edu.illinois.cs.cogcomp.finetyper.finer.components.typers.NGramPatternBasedTyper; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.TypeSystem; +import org.cogcomp.Datastore; +import org.cogcomp.DatastoreException; + +import java.io.*; +import java.util.*; +import java.util.stream.Collectors; + +/** + * Created by haowu4 on 5/16/17. + */ +public class FinerTyperFactory { + public FinerTyperFactory() throws DatastoreException { + this(true); + } + + public FinerTyperFactory(boolean lazyInit) throws DatastoreException { + + this.typers = new ArrayList<>(); + if (!lazyInit) { + this.init(); + } + } + + private void init() throws DatastoreException { + + try (InputStream is = ClassLoader.getSystemResourceAsStream("finer_resource/figer_hier.json")) { + this.typeSystem = TypeSystem.getFromJson(is); + } catch (IOException e) { + e.printStackTrace(); + } + + try (InputStream is = ClassLoader.getSystemResourceAsStream("finer_resource/ontonote_type_mapping.json")) { + this.mentionDetecter = this.getMentionDetecter(is); + } catch (IOException e) { + e.printStackTrace(); + } + + try (InputStream is = ClassLoader.getSystemResourceAsStream("finer_resource/patterndb.txt")) { + this.typers.add(this.getPatternTyper(is)); + } catch (IOException e) { + e.printStackTrace(); + } + + // Now load larger components from Datastore. + Datastore ds = FinerResource.getDefaultDatastore(); + try (InputStream is = FinerResource.getResourceInputStream(ds, FinerResource.SYNSET2TYPE_TAR_GZ)) { + this.typers.add(this.getHypTyper(is)); + } catch (IOException e) { + e.printStackTrace(); + } + + try (InputStream is = FinerResource.getResourceInputStream(ds, FinerResource.KB_BIAS_RESOURCE_TAR_GZ)) { + this.typers.add(this.getKBBiasTyper(is)); + } catch (IOException e) { + e.printStackTrace(); + } + } + + + public FinerAnnotator getAnnotator() throws DatastoreException { + if (this.mentionDetecter == null || this.typers.isEmpty()) { + this.init(); + } + return new FinerAnnotator(this.mentionDetecter, this.typers); + } + + private MentionDetecter getMentionDetecter(InputStream is) { + Gson gson = new GsonBuilder().create(); + Map ret = new HashMap<>(); + + try (BufferedReader reader = + new BufferedReader(new InputStreamReader(is))) { + ret = gson.fromJson(reader, ret.getClass()); + } catch (IOException e) { + e.printStackTrace(); + } + + return new BasicMentionDetection(new TypeMapper(this.typeSystem, ret)); + } + + private IFinerTyper getKBBiasTyper(InputStream is) throws IOException { + Map> map = new HashMap<>(); + BufferedReader reader = new BufferedReader(new InputStreamReader(is)); + String line; + while ((line = reader.readLine()) != null) { + String[] parts = line.split("\\t"); + String pattern = parts[0]; + Map scoreMap = new HashMap<>(); + try { + for (String typeAndScore : parts[1].split(" ")) { + FinerType type = getTypeOrFail(typeAndScore.split(":")[0]); + double score = Double.parseDouble(typeAndScore.split(":")[1]); + scoreMap.put(type, score); + } + map.put(pattern, scoreMap); + } catch (RuntimeException exp) { + System.err.println("[" + line + "] failed to process.."); + } + + } + return new KBBiasTyper(map); + } + + private IFinerTyper getHypTyper(InputStream is) throws IOException { + Map> map = new HashMap<>(); + BufferedReader reader = new BufferedReader(new InputStreamReader(is)); + String line; + while ((line = reader.readLine()) != null) { + String[] parts = line.split("\t"); + String synsetId = parts[0]; + List types = Arrays.stream(parts[1].split(" ")) + .map(this::getType) + .filter(Optional::isPresent) + .map(Optional::get) + .collect(Collectors.toList()); + map.put(synsetId, types); + } + return new HypernymTyper(map); + } + + private IFinerTyper getPatternTyper(InputStream is) throws IOException { + Map> map = new HashMap<>(); + BufferedReader reader = new BufferedReader(new InputStreamReader(is)); + String line; + while ((line = reader.readLine()) != null) { + String[] parts = line.split("\t"); + + int before = Integer.parseInt(parts[0]); + String[] tokens = parts[1].split(" "); + int after = Integer.parseInt(parts[2]); + + NGramPattern pattern = new NGramPattern(before, after, tokens); + + List types = Arrays.stream(parts[3].split(" ")) + .map(this::getType) + .filter(Optional::isPresent) + .map(Optional::get) + .collect(Collectors.toList()); + map.put(pattern, types); + } + return new NGramPatternBasedTyper(map); + + } + + private FinerType getTypeOrFail(String name) { + return this.typeSystem.getTypeOrFail(name); + } + + private Optional getType(String name) { + return this.typeSystem.getType(name); + } + + + private TypeSystem typeSystem = null; + private MentionDetecter mentionDetecter = null; + private List typers = null; + + public void setMentionDetecter(MentionDetecter mentionDetecter) { + this.mentionDetecter = mentionDetecter; + } + + public void setTypers(List typers) { + this.typers = typers; + } + + public List getTypers() { + return typers; + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/BasicMentionDetection.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/BasicMentionDetection.java new file mode 100644 index 000000000..19c7bb8e3 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/BasicMentionDetection.java @@ -0,0 +1,46 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.mention; + +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation; +import edu.illinois.cs.cogcomp.finetyper.Utils; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * Created by haowu4 on 1/15/17. + *

+ * A FINER mention detection using Ontonotes NER output. + */ +public class BasicMentionDetection implements MentionDetecter { + TypeMapper mapper; + + public BasicMentionDetection(TypeMapper mapper) { + this.mapper = mapper; + } + + @Override + public List getMentionCandidates(TextAnnotation ta, Sentence sentence) { + List ret = new ArrayList<>(); + List ner = Utils.getSentenceConstituents(sentence, ta, ViewNames.NER_ONTONOTES); + for (Constituent c : ner) { + FinerType coarseType = mapper.getType(c.getLabel()); + if (coarseType == null) { + continue; + } + String typeName = coarseType.toString(); + Map l2s = new HashMap<>(); + l2s.put(typeName, 1.0); + FineTypeConstituent mention = new FineTypeConstituent(c); + mention.addCoarseType(coarseType); + ret.add(mention); + } + return ret; + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/MentionDetecter.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/MentionDetecter.java new file mode 100644 index 000000000..67efedc3a --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/MentionDetecter.java @@ -0,0 +1,14 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.mention; + +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; + +import java.util.List; + +/** + * Created by haowu4 on 1/15/17. + */ +public interface MentionDetecter { + List getMentionCandidates(TextAnnotation ta, Sentence sentence); +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/TypeMapper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/TypeMapper.java new file mode 100644 index 000000000..a476b4166 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/mention/TypeMapper.java @@ -0,0 +1,31 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.mention; + +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.TypeSystem; + +import java.util.Map; + +/** + * Created by haowu4 on 5/17/17. + *

+ * Map a given string to one of the type in a fine type taxonomy. + */ +public class TypeMapper { + TypeSystem types; + Map mapping; + + public TypeMapper(TypeSystem types, Map mapping) { + this.types = types; + this.mapping = mapping; + } + + public FinerType getType(String label) { + String tname = mapping.getOrDefault(label, null); + if (tname != null) + return types.getTypeOrFail(tname); + else { + return null; + } + } + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/HypernymTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/HypernymTyper.java new file mode 100644 index 000000000..d146bf3a6 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/HypernymTyper.java @@ -0,0 +1,80 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.typers; + +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.View; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; +import edu.illinois.cs.cogcomp.finetyper.finer.wordnet.WordNetUtils; +import net.sf.extjwnl.JWNLException; +import net.sf.extjwnl.data.Synset; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +/** + * Created by haowu4 on 5/21/17. + */ +public class HypernymTyper implements IFinerTyper { + Map> typeToSynsets; + WordNetUtils wordNetUtils; + + public HypernymTyper(Map> typeToSynsets) { + this.typeToSynsets = typeToSynsets; + try { + wordNetUtils = WordNetUtils.getInstance(); + } catch (JWNLException e) { + e.printStackTrace(); + } + } + + public void annotateOneMention(FineTypeConstituent mention) throws JWNLException { + FinerType coarseType = mention.getCoarseType(); + int start = mention.getConstituent().getStartSpan(); + int end = mention.getConstituent().getEndSpan(); + if (start > 0) { + Constituent word_before = mention.getConstituent().getTextAnnotation().getView(ViewNames.TOKENS).getConstituents().get(start - 1); + if (word_before.getSentenceId() == mention.getConstituent().getSentenceId()) { + start = start - 1; + } + } + + View wsdView = mention.getConstituent().getTextAnnotation().getView(ViewNames.FINE_NER_TYPE_WSD); + View posView = mention.getConstituent().getTextAnnotation().getView(ViewNames.POS); + + for (Constituent c : wsdView.getConstituentsCoveringSpan(start, end)) { + if (posView.getConstituentsCovering(c).get(0).getLabel().startsWith("N")) { + if (c.getLabel().isEmpty()) { + continue; + } + Synset synset; + try { + synset = wordNetUtils.getSynsetByOffset(c.getLabel()); + } catch (ArrayIndexOutOfBoundsException e) { + System.err.println(c.getLabel() + " Not Found..."); + continue; + } + String synset_offset_pos = synset.getOffset() + "" + synset.getPOS(); + List infered = typeToSynsets.getOrDefault(synset_offset_pos, new ArrayList<>()); + for (FinerType t : infered) { + if (t.isChildOf(coarseType)) { + mention.addFineType(t); + } + } + } + } + } + + @Override + public void annotate(List mentions, Sentence sentence) { + for (FineTypeConstituent m : mentions) { + try { + annotateOneMention(m); + } catch (Exception e) { + e.printStackTrace(); + } + } + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/IFinerTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/IFinerTyper.java new file mode 100644 index 000000000..bfaacc8dd --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/IFinerTyper.java @@ -0,0 +1,13 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.typers; + +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; + +import java.util.List; + +/** + * Created by haowu4 on 5/15/17. + */ +public interface IFinerTyper { + void annotate(List mentions, Sentence sentence); +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/KBBiasTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/KBBiasTyper.java new file mode 100644 index 000000000..93c6251dd --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/KBBiasTyper.java @@ -0,0 +1,64 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.typers; + +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; + +import java.util.*; +import java.util.stream.Collectors; + +/** + * Created by haowu4 on 5/15/17. + */ +public class KBBiasTyper implements IFinerTyper { + Map> surfaceToTypeDB; + + public KBBiasTyper(Map> surfaceToTypeDB) { + this.surfaceToTypeDB = surfaceToTypeDB; + } + + public List annotateSingleMention(Constituent mention, FinerType coarseType) { + Set ret = new HashSet<>(); + String surface = mention.getSurfaceForm(); + Map candidates = surfaceToTypeDB.getOrDefault(surface, new HashMap<>()); + + double bestScore = Double.NEGATIVE_INFINITY; + FinerType bestType = null; + double norm = 0.0; + + for (Map.Entry entry : candidates.entrySet()) { + FinerType t = entry.getKey(); + double v = entry.getValue(); + if (coarseType.isParentOf(t)) { + if (v == 1.0) { + ret.add(t); + } else { + norm += v; + if (bestScore < v) { + bestScore = v; + bestType = t; + } + } + } + } + + if (bestType != null && bestScore / norm > 0.4) { + ret.add(bestType); + } + + return ret.stream().collect(Collectors.toList()); + + } + + @Override + public void annotate(List mentions, Sentence sentence) { + for (FineTypeConstituent mention : mentions) { + List annotated = annotateSingleMention(mention.getConstituent(), mention.getCoarseType()); + for (FinerType t : annotated) { + mention.addFineType(t); + } + } + + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPattern.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPattern.java new file mode 100644 index 000000000..8d651b7de --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPattern.java @@ -0,0 +1,66 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.typers; + +import java.util.Arrays; + +/** + * Created by haowu4 on 5/15/17. + */ +public class NGramPattern { + private int before; + private int after; + private String[] tokens; + + public NGramPattern(int before, int after, String[] tokens) { + this.before = before; + this.after = after; + this.tokens = tokens; + } + + public int getBefore() { + return before; + } + + public int getAfter() { + return after; + } + + public String[] getTokens() { + return tokens; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + + NGramPattern that = (NGramPattern) o; + + if (before != that.before) return false; + if (after != that.after) return false; + // Probably incorrect - comparing Object[] arrays with Arrays.equals + return Arrays.equals(tokens, that.tokens); + } + + @Override + public int hashCode() { + int result = before; + result = 31 * result + after; + result = 31 * result + Arrays.hashCode(tokens); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + for (int i = 0; i < before; i++) { + sb.append("* "); + } + + sb.append(String.join(" ", tokens)); + + for (int i = 0; i < after; i++) { + sb.append(" *"); + } + return sb.toString(); + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPatternBasedTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPatternBasedTyper.java new file mode 100644 index 000000000..b75cd3d83 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/components/typers/NGramPatternBasedTyper.java @@ -0,0 +1,75 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.components.typers; + +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.FineTypeConstituent; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Map; + +/** + * Created by haowu4 on 5/15/17. + */ +public class NGramPatternBasedTyper implements IFinerTyper { + + private Map> allPatterns; + private int windowSize = 5; + + public NGramPatternBasedTyper(Map> allPatterns) { + this(allPatterns, 5); + } + + public NGramPatternBasedTyper(Map> allPatterns, int windowSize) { + this.allPatterns = allPatterns; + this.windowSize = windowSize; + } + + public List extractAllPattern(String[] surface) { + List ret = new ArrayList<>(); + for (int i = 0; i < surface.length; i++) { + String w = surface[i]; + int word_before = i; + for (int j = 0; j < this.windowSize; j++) { + int word_after = surface.length - i - j; + if (word_after < 0) { + break; + } + + NGramPattern sp = new NGramPattern(word_before, word_after, Arrays.copyOfRange(surface, i, i + j)); + ret.add(sp); + } + } + return ret; + } + + public void annotateOneMention(FineTypeConstituent c) { + FinerType coarseType = c.getCoarseType(); + int start = c.getConstituent().getStartSpan(); + int end = c.getConstituent().getEndSpan(); + String[] surface = new String[end - start]; + TextAnnotation ta = c.getConstituent().getTextAnnotation(); + for (int i = 0; i < surface.length; i++) { + surface[i] = ta.getToken(start + i); + } + + List existing_patterns = extractAllPattern(surface); + + for (NGramPattern sp : existing_patterns) { + for (FinerType t : allPatterns.getOrDefault(sp, new ArrayList<>())) { + if (t.isChildOf(coarseType)) { + c.addFineType(t); + } + } + } + } + + @Override + public void annotate(List mentions, Sentence sentence) { + for (FineTypeConstituent mention : mentions) { + annotateOneMention(mention); + } + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/FineTypeConstituent.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/FineTypeConstituent.java new file mode 100644 index 000000000..036e69c1a --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/FineTypeConstituent.java @@ -0,0 +1,79 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.datastructure; + +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.FinerType; + +import java.util.*; +import java.util.stream.Collectors; + +/** + * Created by haowu4 on 5/17/17. + */ +public class FineTypeConstituent { + + private Constituent constituent; + private FinerType coarseType; + private Set fineTypes; + private Map labelsToScores; + + private static Map getLablToScore() { + Map ret = new HashMap(); + ret.put("FinerType", 1.0); + return ret; + } + + public FineTypeConstituent(Constituent constituent) { + this.constituent = constituent; + this.fineTypes = new HashSet<>(); + this.labelsToScores = new HashMap<>(); + } + + + public void addFineType(FinerType t) { + this.fineTypes.add(t); + } + + public void addCoarseType(FinerType t) { + this.coarseType = t; + } + + + public FinerType getCoarseType() { + return coarseType; + } + + public void finish() { + this.labelsToScores.clear(); + for (FinerType t : this.fineTypes) { + if (t.isVisible()) { + this.labelsToScores.put(t, 1.0); + } + } + + if (this.coarseType.isVisible()) { + this.labelsToScores.put(this.coarseType, 1.0); + } + } + + + public Optional toConstituent(String viewName) { + this.finish(); + if (labelsToScores.isEmpty()) { + return Optional.empty(); + } else { + Map labelStrToScores = labelsToScores + .entrySet() + .stream() + .collect(Collectors.toMap(x -> x.getKey().getType(), Map.Entry::getValue)); + return Optional.of(new Constituent(labelStrToScores, + viewName, + this.constituent.getTextAnnotation(), + constituent.getStartSpan(), constituent.getEndSpan())); + } + + } + + public Constituent getConstituent() { + return constituent; + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/FinerType.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/FinerType.java new file mode 100644 index 000000000..f55a414ef --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/FinerType.java @@ -0,0 +1,126 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types; + +import net.sf.extjwnl.data.Synset; + +import java.util.ArrayList; +import java.util.List; + +/** + * Created by haowu4 on 5/15/17. + */ +public class FinerType { + private TypeSystem typeSystem; + private String type; + private boolean isVisible; + private FinerType parent; + private List children; + private List wordnetIds; + + FinerType(String name, boolean isVisible) { + this.typeSystem = null; + this.type = name; + this.isVisible = isVisible; + this.parent = null; + this.children = new ArrayList<>(); + this.wordnetIds = new ArrayList<>(); + } + + public boolean isVisible() { + return isVisible; + } + + public void setVisible(boolean visible) { + isVisible = visible; + } + + public TypeSystem getTypeSystem() { + return typeSystem; + } + + public void setTypeSystem(TypeSystem typeSystem) { + this.typeSystem = typeSystem; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public FinerType getParent() { + return parent; + } + + public void setParent(FinerType parent) { + this.parent = parent; + } + + public List getChildren() { + return children; + } + + public void addChildren(FinerType child) { + this.children.add(child); + } + + public boolean isParentOf(FinerType t) { + FinerType it = t.parent; + while (it != null) { + if (it.equals(this)) { + return true; + } + it = it.parent; + } + return false; + } + + public boolean isParentOfOrEqual(FinerType t) { + FinerType it = t; + while (it != null) { + if (it.equals(this)) { + return true; + } + it = it.parent; + } + return false; + } + + public boolean isChildOf(FinerType t) { + return t.isParentOf(this); + } + + public boolean isChildOfOrEqual(FinerType t) { + return t.isParentOfOrEqual(this); + } + + public boolean isCoarseType(FinerType t) { + return this.parent == null; + } + + public List wordNetSenseIds() { + return this.wordnetIds; + } + + public void addWordNetSenseId(Synset senseId) { + this.wordnetIds.add(senseId); + } + + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + + FinerType finerType = (FinerType) o; + + return type.equals(finerType.type); + } + + + @Override + public int hashCode() { + return type.hashCode(); + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/TypeSystem.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/TypeSystem.java new file mode 100644 index 000000000..c203c859c --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/datastructure/types/TypeSystem.java @@ -0,0 +1,106 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types; + +import com.google.gson.Gson; +import com.google.gson.GsonBuilder; + +import java.io.BufferedReader; +import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.util.*; + +/** + * Created by haowu4 on 5/15/17. + */ +public class TypeSystem { + + // IO related helper class. + private static class TypeInfo { + String parent; + boolean is_figer_type; + } + + private static class TypeInfos { + Map typeInfos; + } + + public static TypeSystem getFromJson(InputStream is) throws IOException { + + + Gson gson = new GsonBuilder().create(); + TypeInfos load = null; + try (BufferedReader reader = + new BufferedReader(new InputStreamReader(is))) { + load = gson.fromJson(reader, TypeInfos.class); + } + Map typeCollection = new HashMap<>(); + Set invisiableTypes = new HashSet<>(); + for (Map.Entry entry : load.typeInfos.entrySet()) { + String typeName = entry.getKey(); + TypeInfo info = entry.getValue(); + FinerType type = new FinerType(typeName, info.is_figer_type); + typeCollection.put(typeName, type); + } + + for (Map.Entry entry : load.typeInfos.entrySet()) { + String typeName = entry.getKey(); + TypeInfo info = entry.getValue(); + + FinerType currentType = typeCollection.get(typeName); + if (!currentType.isVisible()) { + invisiableTypes.add(currentType); + } + String parentName = info.parent; + if (parentName != null) { + FinerType parentType = typeCollection.get(parentName); + parentType.addChildren(currentType); + currentType.setParent(parentType); + } + } + + TypeSystem typeSystem = new TypeSystem(typeCollection, invisiableTypes); + + for (FinerType type : typeCollection.values()) { + type.setTypeSystem(typeSystem); + } + + return typeSystem; + } + + public TypeSystem(Map typeCollection, Set invisiableTypes) { + this.typeCollection = typeCollection; + this.invisiableTypes = invisiableTypes; + } + + private Map typeCollection; + private Set invisiableTypes; + + public FinerType getTypeOrFail(String name) { + if (typeCollection.containsKey(name)) { + FinerType t = typeCollection.get(name); + if (t != null) { + return t; + } else { + throw new RuntimeException("Type [" + name + "] is NULL."); + } + } else { + throw new RuntimeException("Type [" + name + "] Not Found"); + } + } + + public Set failedQueries = new HashSet<>(); + + public Optional getType(String name) { + FinerType t = typeCollection.get(name); + if (t == null) { + if (!failedQueries.contains(name)) { + failedQueries.add(name); + System.err.println("Type [" + name + "] Not Found"); + } + return Optional.empty(); + } else { + return Optional.of(t); + } + } + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/wordnet/WordNetUtils.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/wordnet/WordNetUtils.java new file mode 100644 index 000000000..ea6f32e81 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/finer/wordnet/WordNetUtils.java @@ -0,0 +1,214 @@ +package edu.illinois.cs.cogcomp.finetyper.finer.wordnet; + +import net.sf.extjwnl.JWNLException; +import net.sf.extjwnl.data.*; +import net.sf.extjwnl.data.list.PointerTargetTree; +import net.sf.extjwnl.data.list.PointerTargetTreeNode; +import net.sf.extjwnl.dictionary.Dictionary; + +import java.io.IOException; +import java.util.*; + +/** + * Created by muddire2 on 1/10/17. + */ +public class WordNetUtils { + + private static WordNetUtils WORD_NET_UTILS; + private static final Object lock = new Object(); + public Dictionary dictionary; + private Synset entitySynset; + + private WordNetUtils() throws JWNLException { + dictionary = Dictionary.getDefaultResourceInstance(); + entitySynset = getSynsets("entity").get(0); + } + + public static WordNetUtils getInstance() throws JWNLException { + synchronized (WordNetUtils.class) { + if (WORD_NET_UTILS == null) + WORD_NET_UTILS = new WordNetUtils(); + } + return WORD_NET_UTILS; + } + + public static WordNetUtils getInstanceFastOrNull() { + return WORD_NET_UTILS; + } + + + public List getSynsets(String lemma, POS pos) throws JWNLException { + IndexWord w = dictionary.lookupIndexWord(pos, lemma); + return (w == null) ? new ArrayList<>() : w.getSenses(); + } + + public List getSynsets(String lemma) throws JWNLException { + return getSynsets(lemma, POS.NOUN); + } + + public PointerTargetTree getHyponymTree(Synset synset) throws JWNLException { + PointerTargetTree hyponymTree = PointerUtils.getHyponymTree(synset); + return hyponymTree; + } + + public POS getPOS(String posString) { + POS pos = null; + switch (posString) { + case "n": + pos = POS.NOUN; + break; + case "v": + pos = POS.VERB; + break; + case "a": + pos = POS.ADJECTIVE; + break; + case "s": + pos = POS.ADVERB; + break; + default: + throw new IllegalArgumentException("Invalid POS string - " + posString); + } + return pos; + } + + public Synset getSynsetFromNLTKString(String nltkSynsetString) throws JWNLException { + String[] tokens = nltkSynsetString.split("\\."); + assert tokens.length == 3; + String lemma = tokens[0]; + POS pos = getPOS(tokens[1]); + int id = Integer.parseInt(tokens[2]) - 1; + IndexWord w = dictionary.lookupIndexWord(pos, lemma); + if (w == null) + throw new IllegalArgumentException("Word/Lemma not found in wordnet - " + nltkSynsetString); + if (id >= w.getSenses().size()) + throw new IllegalArgumentException("Invalid word sense index - " + nltkSynsetString); + return w.getSenses().get(id); + } + + public List getPointers(Synset synset, PointerType type) { + List pointers = new ArrayList<>(); + // strict matching i.e. instance hyponyms not in hyponyms + for (Pointer p : synset.getPointers(type)) + if (p.getType().getKey().equals(type.getKey())) + pointers.add(p); + return pointers; + } + + public Synset getFirstInTree(Synset targetSynset, PointerTargetTree tree) { + Queue bfsQueue = new LinkedList<>(); + bfsQueue.add(tree.getRootNode()); + PointerTargetTreeNode curNode; + PointerTargetTreeNode result = null; + while (result == null && bfsQueue.size() > 0) { + curNode = bfsQueue.remove(); + if (curNode.hasValidChildTreeList()) + bfsQueue.addAll(curNode.getChildTreeList()); + if (curNode.getSynset().equals(targetSynset)) + result = curNode; + } + return (result == null) ? null : result.getSynset(); + } + + private String synsetToString(Synset synset) { + StringBuilder words = new StringBuilder(); + + words.append("( "); + for (int i = 0; i < synset.getWords().size(); ++i) { + if (i > 0) { + words.append(", "); + } + + words.append(((Word) synset.getWords().get(i)).getLemma()); + } + words.append(" )"); + + return words.toString(); + } + + private void recurseForward(Synset n, Synset t, Map sn) throws JWNLException { + sn.put(n, sn.getOrDefault(n, 0) + 1); + for (Pointer hypPointer : getPointers(n, PointerType.HYPERNYM)) { + Synset c = hypPointer.getTargetSynset(); + recurseForward(c, t, sn); + } + } + + private int recurseBackward(Synset n, Synset t, Map nt) throws JWNLException { + int tmp = 0; + for (Pointer hypPointer : getPointers(n, PointerType.HYPERNYM)) { + Synset c = hypPointer.getTargetSynset(); + if (!nt.containsKey(c)) + nt.put(c, recurseBackward(c, t, nt)); + tmp += nt.get(c); + } + nt.put(n, Math.max(1, tmp)); + return nt.get(n); + } + + private Map getSynsetScores(Synset synset) throws JWNLException { +// assert synset.getPOS() == POS.NOUN; + if (synset.getPOS() != POS.NOUN) + return new HashMap<>(); + Map synsetScores = new HashMap<>(); + + Map sn = new HashMap<>(); + Map nt = new HashMap<>(); + + recurseForward(synset, entitySynset, sn); + recurseBackward(synset, entitySynset, nt); + + int numPaths = nt.get(synset); +// System.out.println("Number of paths = " + numPaths); + + for (Synset countSynset : nt.keySet()) + synsetScores.put(countSynset, (double) nt.get(countSynset) * sn.get(countSynset) / numPaths); + + return synsetScores; + } + + private Map getTypeScores(Synset synset, Map> typeToSynsets) throws JWNLException { + Map synsetScores = getSynsetScores(synset); + Map typeScores = new HashMap<>(); + for (String type : typeToSynsets.keySet()) { + double typeScore = 0; + for (Synset typeSynset : typeToSynsets.get(type)) + if (synsetScores.containsKey(typeSynset)) + typeScore += synsetScores.get(typeSynset); + if (typeScore == 0.0) { + continue; + } + typeScores.put(type, typeScore); + } + return typeScores; + } + + public Map getTypeScores(String synsetOffsetPOS, + Map> typeToSynsets) throws JWNLException { + Synset synset = getSynsetByOffset(synsetOffsetPOS); + return getTypeScores(synset, typeToSynsets); + } + + public Synset getSynsetOfNoun(String readableName) throws JWNLException { + String[] parts = readableName.split("\\."); + int idx = Integer.valueOf(parts[2]); + Synset synset = dictionary.lookupIndexWord(POS.NOUN, parts[0]).getSenses().get(idx - 1); + + return synset; + } + + public Synset getSynsetByOffset(String synsetOffsetPOS) throws JWNLException { + String[] tokens = synsetOffsetPOS.split("_"); + POS synsetPOS = getPOS(tokens[1]); + long synsetOffset = Long.parseLong(tokens[0]); + Synset synset = dictionary.getSynsetAt(synsetPOS, synsetOffset); + return synset; + } + + public static void main(String[] args) throws JWNLException, CloneNotSupportedException, IOException { + WordNetUtils wordNetUtils = WordNetUtils.getInstance(); + + Synset quellSynset = wordNetUtils.getSynsets("quell", POS.VERB).get(0); + System.out.println(quellSynset.getPOS()); + } +} \ No newline at end of file diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java deleted file mode 100644 index 42c399fca..000000000 --- a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/FINER113Typer.java +++ /dev/null @@ -1,13 +0,0 @@ -package edu.illinois.cs.cogcomp.finetyper.typers; - -/** - * Created by haowu4 on 2/3/18. - *

- * A Fine-Grained Entity Recognizer that recognize 113 type defined in the following paper. - *

- * Xiao Ling and Daniel S. Weld (2012). - * "Fine-Grained Entity Recognition", - * in Proceedings OF THE TWENTY-SIXTH AAAI CONFERENCE ON ARTIFICIAL INTELLIGENCE (AAAI), 2012. - */ -public class FINER113Typer { -} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java deleted file mode 100644 index 559eeff10..000000000 --- a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/OpendomainTyper.java +++ /dev/null @@ -1,12 +0,0 @@ -package edu.illinois.cs.cogcomp.finetyper.typers; - -/** - * Created by haowu4 on 2/3/18. - * - * Open Domain fine-grain typing based on WebisA and word embedding similarity. - * - * - */ -public class OpendomainTyper { - -} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java deleted file mode 100644 index 5d542f335..000000000 --- a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/typers/Typer.java +++ /dev/null @@ -1,21 +0,0 @@ -package edu.illinois.cs.cogcomp.finetyper.typers; - -import edu.illinois.cs.cogcomp.core.datastructures.Pair; -import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; -import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; - -import java.util.List; -import java.util.Map; - -/** - * Created by haowu4 on 2/4/18. - */ -public interface Typer { - /** - * Determine types for the given - * - * @param query - * @return list of constituents with type and their confidence added as labels. - */ - List getTypes(List query); -} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/WordSenseAnnotator.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/WordSenseAnnotator.java new file mode 100644 index 000000000..c54d87e0c --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/WordSenseAnnotator.java @@ -0,0 +1,194 @@ +package edu.illinois.cs.cogcomp.finetyper.wsd; + +import edu.illinois.cs.cogcomp.annotation.Annotator; +import edu.illinois.cs.cogcomp.annotation.AnnotatorException; +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.View; +import edu.illinois.cs.cogcomp.core.utilities.configuration.ResourceManager; +import edu.illinois.cs.cogcomp.finetyper.FinerResource; +import edu.illinois.cs.cogcomp.finetyper.wsd.datastructure.WordAndPOS; +import edu.illinois.cs.cogcomp.finetyper.wsd.embedding.EmbeddingSpace; +import edu.illinois.cs.cogcomp.finetyper.wsd.math.FloatDenseVector; +import edu.illinois.cs.cogcomp.finetyper.wsd.math.Similarity; +import org.cogcomp.Datastore; +import org.cogcomp.DatastoreException; + +import java.io.*; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + + +/** + * Created by haowu4 on 1/13/17. + */ + +public class WordSenseAnnotator extends Annotator { + + public static final String ANNOTATOR_NAME = "EmbeddingWSDAnnotator"; + public final String VIEWNAME; + + private EmbeddingSpace wordEmbeddings; + private EmbeddingSpace senseEmbeddings; + private Map> candidatesMaps; + + private List wordToSense(String w, String pos) { + return candidatesMaps.getOrDefault(new WordAndPOS(w, pos), new + ArrayList()); + } + + public WordSenseAnnotator(String viewName, ResourceManager rm) { + super(viewName, new String[]{ViewNames.POS}, rm); + VIEWNAME = rm.getString("fine_type_wsd_viewname", ViewNames.FINE_NER_TYPE_WSD); + } + + + @Override + public void initialize(ResourceManager rm) { + + try { + Datastore ds = FinerResource.getDefaultDatastore(); + + // Read word embedding. + + try (InputStream input = FinerResource.getResourceInputStream(ds, FinerResource.WORD_EMBEDDING_TAR_GZ)) { + wordEmbeddings = EmbeddingSpace.readEmbeddingStream(input); + } catch (IOException e) { + e.printStackTrace(); + System.err.println("Having trouble reading important resources WORD_EMBEDDING_TAR_GZ."); + } + + + // Read sense embedding. + try (InputStream input = FinerResource.getResourceInputStream(ds, FinerResource.SENSE_EMBEDDING_TAR_GZ)) { + senseEmbeddings = EmbeddingSpace.readEmbeddingStream(input); + } catch (IOException e) { + e.printStackTrace(); + System.err.println("Having trouble reading important resources SENSE_EMBEDDING_TAR_GZ."); + } + + + candidatesMaps = new HashMap<>(); + + try (InputStream inputStream = FinerResource.getResourceInputStream(ds, FinerResource.WORD_POS_TO_SENSE_TAR_GZ)) { + try (BufferedReader br = new BufferedReader(new InputStreamReader(inputStream))) { + + String line; + + while ((line = br.readLine()) != null) { + String trimedLine = line.trim(); + if (trimedLine.isEmpty()) { + continue; + } + + String[] parts = trimedLine.split("\t"); + String word = parts[0]; + String pos = parts[1]; + String[] senses = parts[2].split(" "); + WordAndPOS key = new WordAndPOS(word, pos); + List candidates = candidatesMaps.getOrDefault(key, new + ArrayList()); + for (String s : senses) { + candidates.add(s); + } + candidatesMaps.put(key, candidates); + } + } catch (IOException e) { + e.printStackTrace(); + System.err.println("Having trouble reading important resources WORD_POS_TO_SENSE_TAR_GZ."); + } + } catch (IOException e) { + e.printStackTrace(); + System.err.println("Having trouble reading important resources WORD_POS_TO_SENSE_TAR_GZ."); + } + + + } catch (DatastoreException e) { + e.printStackTrace(); + System.err.println("Having trouble connecting to Datastore."); + } + + + } + + @Override + public void addView(TextAnnotation ta) throws AnnotatorException { + View v = new View(VIEWNAME, ANNOTATOR_NAME, ta, 1.0); + View tokens = ta.getView(ViewNames.TOKENS); + for (Sentence sentence : ta.sentences()) { + int startTokenId = sentence.getStartSpan(); + int endTokenId = sentence.getStartSpan(); + for (int i = startTokenId; i < endTokenId; i++) { + Constituent ct = tokens.getConstituents().get(i); + Map result = predict(sentence, ct); + if (result.isEmpty()) continue; + v.addConstituent(new Constituent(result, VIEWNAME, ta, ct + .getStartSpan(), ct.getEndSpan())); + } + } + ta.addView(VIEWNAME, v); + } + + /** + * Map Part of speech to the convention used in the sense embedding. + * + * @param pos String of POS tag, such as VB. + * @return + */ + public static String mapPOS(String pos) { + switch (pos.toLowerCase().charAt(0)) { + case 'v': + return "v"; + case 'n': + return "n"; + default: + return ""; + } + } + + /** + * Predict the sense of a token based on the cosine similarity of sense embedding and average word embedding in + * the sentence. + * + * @param sentence Sentence that contains the given constituent. + * @param ct The given constituent + * @return + */ + public Map predict(Sentence sentence, Constituent ct) { + Map result = new HashMap<>(); + + String query = ct.getSurfaceForm(); + String pos = ct.getTextAnnotation().getView(ViewNames.POS) + .getConstituentsCovering(ct).get(0).getLabel(); + List senses = wordToSense(query, mapPOS(pos)); + + if (senses.isEmpty()) { + return result; + } + + FloatDenseVector sentenceEmbedding = wordEmbeddings.getEmbeddingOrNull(sentence); + + + if (sentenceEmbedding == null) { + return result; + } + + double normOfSentence = Similarity.l2norm(sentenceEmbedding); + for (String s : senses) { + FloatDenseVector senseEmbedding = senseEmbeddings.getEmbeddingOrNull(s); + if (senseEmbedding == null) continue; + double sim = Similarity.cosine(sentenceEmbedding, senseEmbedding, + normOfSentence, + Similarity.l2norm(senseEmbedding)); + result.put(s, sim); + } + + return result; + } + + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/datastructure/WordAndPOS.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/datastructure/WordAndPOS.java new file mode 100644 index 000000000..3aa40d0df --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/datastructure/WordAndPOS.java @@ -0,0 +1,42 @@ +package edu.illinois.cs.cogcomp.finetyper.wsd.datastructure; + + +/** + * Created by haowu4 on 2/6/18. + * Pair of word and its part of speech tag. + */ +public class WordAndPOS { + private String word; + private String pos; + + public WordAndPOS(String word, String pos) { + this.word = word; + this.pos = pos; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + + WordAndPOS that = (WordAndPOS) o; + + if (!word.equals(that.word)) return false; + return pos.equals(that.pos); + } + + @Override + public int hashCode() { + int result = word.hashCode(); + result = 31 * result + pos.hashCode(); + return result; + } + + public String getWord() { + return word; + } + + public String getPos() { + return pos; + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/embedding/EmbeddingSpace.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/embedding/EmbeddingSpace.java new file mode 100644 index 000000000..327437866 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/embedding/EmbeddingSpace.java @@ -0,0 +1,109 @@ +package edu.illinois.cs.cogcomp.finetyper.wsd.embedding; + + +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Sentence; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.View; +import edu.illinois.cs.cogcomp.finetyper.wsd.math.FloatDenseVector; + +import java.io.*; +import java.util.*; + +/** + * Created by haowu4 on 1/14/17. + * A Embedding manager. + */ +public class EmbeddingSpace { + + Map entryToId; + FloatDenseVector[] embeddings; + + /** + * Initialize a EmbeddingSpace from a file. + * + * @param inputStream Stream that contains the Embedding Table. + * @return + */ + public static EmbeddingSpace readEmbeddingStream(InputStream inputStream) { + List vectors = new ArrayList<>(); + Map toId = new HashMap<>(); + try (BufferedReader br = new BufferedReader(new InputStreamReader(inputStream))) { + String line; + int counter = 0; + while ((line = br.readLine()) != null) { + String trimedLine = line.trim(); + if (trimedLine.isEmpty()) { + continue; + } + + String[] parts = trimedLine.split("\t"); + if (parts.length != 2) { + continue; + } + String entry = parts[0]; + String[] vecParts = parts[1].split(" "); + float[] vec = new float[vecParts.length]; + for (int i = 0; i < vecParts.length; i++) { + vec[i] = Float.valueOf(vecParts[i]); + } + vectors.add(new FloatDenseVector(vec)); + toId.put(entry, counter); + counter++; + } + } catch (IOException e) { + e.printStackTrace(); + } + return new EmbeddingSpace(toId, vectors); + } + + /** + * Default constructor. + * + * @param entryToId Lookup table for entry to index of the embeddings array. + * @param embeddings Array of Embeddings. + */ + public EmbeddingSpace(Map entryToId, FloatDenseVector[] + embeddings) { + this.entryToId = entryToId; + this.embeddings = embeddings; + } + + public EmbeddingSpace(Map toId, List + vectors) { + this(toId, vectors.toArray(new FloatDenseVector[vectors.size()])); + } + + /** + * Get the embedding of a word or return null. + * + * @param word Query. + * @return Embedding of word query. + */ + public FloatDenseVector getEmbeddingOrNull(String word) { + if (entryToId.containsKey(word)) { + return embeddings[entryToId.get(word)]; + } + return null; + } + + public FloatDenseVector getEmbeddingOrNull(Sentence sentence) { + View tokens = sentence.getView(ViewNames.TOKENS); + List constituents = tokens.getConstituents(); + FloatDenseVector sum = null; + for (Constituent c : constituents) { + String token = c.getSurfaceForm(); + + FloatDenseVector dv = getEmbeddingOrNull(token); + if (dv == null) continue; + if (sum == null) { + sum = new FloatDenseVector(dv); + } else { + sum.iadd(dv); + } + } + + return sum; + } + +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/FloatDenseVector.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/FloatDenseVector.java new file mode 100644 index 000000000..7f6235240 --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/FloatDenseVector.java @@ -0,0 +1,73 @@ +package edu.illinois.cs.cogcomp.finetyper.wsd.math; + +/** + * Created by haowu4 on 1/13/17. + */ +public class FloatDenseVector { + float[] data; + + public FloatDenseVector(int dim) { + this(new float[dim]); + } + + public FloatDenseVector(float[] data) { + this.data = data; + } + + /** + * Copy constructor. + * + * @param other + */ + public FloatDenseVector(FloatDenseVector other) { + float[] k = other.getDataReference(); + this.data = new float[k.length]; + for (int i = 0; i < k.length; i++) { + this.data[i] = k[i]; + } + } + + /** + * Return the reference of the internal float array. + * + * @return reference of its data. + */ + public float[] getDataReference() { + return data; + } + + /** + * Inplace add another dense vector. + * + * @param v vector to add. + */ + public void iadd(FloatDenseVector v) { + float[] dv = v.getDataReference(); + for (int i = 0; i < dv.length; i++) { + this.data[i] += dv[i]; + } + } + + /** + * Inplace divide by a constant scalar. + * + * @param v constant to divided by. + */ + public void idivide(float v) { + for (int i = 0; i < data.length; i++) { + this.data[i] /= v; + } + } + + /** + * Inplace subtract another vector. + * + * @param v constant to subtract. + */ + public void isub(FloatDenseVector v) { + float[] dv = v.getDataReference(); + for (int i = 0; i < dv.length; i++) { + this.data[i] -= dv[i]; + } + } +} diff --git a/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/Similarity.java b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/Similarity.java new file mode 100644 index 000000000..bb3872c5c --- /dev/null +++ b/finetyper/src/main/java/edu/illinois/cs/cogcomp/finetyper/wsd/math/Similarity.java @@ -0,0 +1,56 @@ +package edu.illinois.cs.cogcomp.finetyper.wsd.math; + +/** + * Created by haowu4 on 1/13/17. + */ +public class Similarity { + /** + * Compute cosine similarity of two vectors. + * You need to provide a precomputed l2norm for both vector. + * This function is useful when you want to avoid re-computation of the l2norm of one vector. + * + * @param v1 First vector. + * @param v2 Second vector. + * @param v1n L2 Norm of first vector. + * @param v2n L2 Norm of second vector. + * @return Cosine similarity of v1 and v2. + */ + public static double cosine(FloatDenseVector v1, FloatDenseVector v2, double v1n, + double v2n) { + float[] v1_ = v1.getDataReference(); + float[] v2_ = v2.getDataReference(); + double r = 0; + for (int i = 0; i < v1_.length; i++) { + r += (v1_[i] * v2_[i]); + } + return r / (v1n * v2n); + + } + + /** + * Compute cosine similarity of two vectors. + * + * @param v1 First vector. + * @param v2 Second vector. + * @return Cosine similarity of v1 and v2. + */ + public static double cosine(FloatDenseVector v1, FloatDenseVector v2) { + return cosine(v1, v2, l2norm(v1), l2norm(v2)); + } + + /** + * Compute L2 l2norm of the vector. + * + * @param v1 Vector to compute l2norm. + * @return L2 l2norm of the vector. + */ + public static double l2norm(FloatDenseVector v1) { + float[] v1_ = v1.getDataReference(); + double r = 0; + for (int i = 0; i < v1_.length; i++) { + r += (v1_[i] * v1_[i]); + } + return Math.sqrt(r); + + } +} diff --git a/finetyper/src/main/resources/finer_resource/figer.xiang.label b/finetyper/src/main/resources/finer_resource/figer.xiang.label new file mode 100644 index 000000000..3da329893 --- /dev/null +++ b/finetyper/src/main/resources/finer_resource/figer.xiang.label @@ -0,0 +1,10442 @@ +A O +handful O +of O +professors O +in O +the O +UW B-/organization,/organization/educational_institution +Department B-/education/department,/organization,/education +of I-/education/department,/organization,/education +Chemistry I-/education/department,/organization,/education +are O +being O +recognized O +by O +the O +American B-/organization +Association I-/organization +for I-/organization +the I-/organization +Advancement I-/organization +of I-/organization +Science I-/organization +( O +AAAS B-/organization +) O +for O +their O +efforts O +and O +contributions O +to O +the O +scientific O +community O +. O + +The O +AAAS B-/organization +is O +the O +largest O +scientific O +society O +in O +the O +world O +and O +publishes O +journals O +such O +as O +Science B-/written_work +, O +and O +Science B-/written_work +Translational I-/written_work +Medicine I-/written_work +. O + +Last O +month O +, O +the O +organization O +elected O +539 O +of O +its O +members O +as O +Fellows B-/title +of O +AAAS B-/organization +, O +an O +honor O +that O +recognizes O +members O +“ O +whose O +efforts O +on O +behalf O +of O +the O +advancement O +of O +science O +or O +its O +applications O +are O +scientifically O +or O +socially O +distinguished O +, O +” O +according O +to O +the O +association O +’s O +website O +. O + +Nine O +of O +the O +individuals O +elected O +are O +UW B-/organization,/organization/educational_institution +faculty O +members O +. O + +“ O +Election O +to O +the O +AAAS B-/organization +is O +a O +very O +high O +honor O +, O +” O +said O +chemistry O +department O +chair O +Paul B-/person +Hopkins I-/person +. O + +“ O +[ O +Fellows O +] O +are O +very O +deserving O +of O +these O +awards O +. O +” O + +Hopkins B-/person +said O +four O +fellow O +elections O +is O +curious O +, O +considering O +the O +size O +of O +his O +faculty O +. O + +“ O +We O +’re O +a O +faculty O +of O +33 O +members O +, O +” O +Hopkins O +said O +. O + +“ O +To O +have O +four O +of O +them O +elected O +in O +a O +single O +year O +is O +more O +than O +10 O +percent O +of O +my O +department O +, O +which O +is O +very O +unusual O +. O +” O + +He O +said O +it O +speaks O +to O +the O +stature O +and O +the O +performance O +of O +the O +faculty O +in O +this O +department O +, O +and O +at O +this O +university O +in O +general O +, O +that O +faculty O +is O +being O +recognized O +by O +the O +association O +. O + +Of O +these O +nine O +fellows O +, O +four O +of O +them O +are O +part O +of O +the O +UW B-/organization,/organization/educational_institution +Department B-/education/department,/education +of I-/education/department,/education +Chemistry I-/education/department,/education +: O +Daniel B-/person +T. I-/person +Chiu I-/person +, O +Daniel B-/person +R. I-/person +Gamelin I-/person +, O +Karen B-/person +I. I-/person +Goldberg I-/person +, O +and O +Bruce B-/person +H. I-/person +Robinson I-/person +. O + +“ O +It O +’s O +an O +honor O +that O +the O +department O +was O +recognized O +in O +this O +way O +, O +” O +Gamelin B-/person +said O +. O + +Hopkins B-/person +explained O +this O +year O +’s O +elected O +fellows O +were O +an O +especially O +varied O +group O +. O + +Each O +of O +the O +professors O +was O +elected O +for O +very O +different O +reasons O +, O +he O +said O +. O + +Bruce B-/person +Robinson I-/person +is O +a O +theorist O +and O +spectroscopist O +, O +who O +has O +been O +contributing O +to O +the O +field O +for O +the O +past O +40 O +years O +. O + +Currently O +, O +Gamelin B-/person/author,/person +is O +researching O +the O +synthesis O +of O +nanomaterials O +; O +Chiu B-/person +is O +working O +on O +manipulation O +of O +matter O +with O +lasers O +; O +and O +Goldberg B-/person +is O +exploring O +inorganic O +catalysis O +, O +where O +she O +seeks O +to O +find O +more O +efficient O +ways O +of O +catalyzing O +chemical O +reactions O +. O + +To O +be O +eligible O +for O +election O +, O +members O +must O +be O +nominated O +by O +three O +fellows O +. O + +These O +nominations O +are O +then O +reviewed O +by O +steering O +groups O +within O +the O +association O +who O +elect O +fellows O +from O +a O +pool O +of O +their O +approved O +nominees O +. O + +Newly O +elected O +fellows O +are O +invited O +to O +attend O +the O +annual O +Fellows B-/event +Forum I-/event +, O +held O +this O +year O +in O +Vancouver B-/location/city,/location +, O +B.C B-/location,/location/province +. O + +The B-/event +Fellows I-/event +Forum I-/event +, O +concerned O +in O +part O +with O +the O +induction O +of O +newly O +elected O +fellows O +, O +is O +just O +one O +event O +of O +the O +association O +’s O +annual O +meeting O +. O + +Open O +to O +all O +members O +, O +the O +meeting O +consists O +of O +exhibits O +, O +seminars O +, O +and O +presentations O +by O +members O +in O +various O +scientific O +fields O +. O + +It O +will O +take O +place O +Feb. B-/time +16 I-/time +– I-/time +20 I-/time +. O + +Some O +of O +the O +UW B-/organization,/organization/educational_institution +’s O +Fellows O +believe O +these O +nominations O +are O +a O +testament O +to O +the O +faculty O +’s O +success O +despite O +financial O +troubles O +. O + +“ O +This O +speaks O +very O +highly O +of O +the O +quality O +of O +hiring O +we O +do O +in O +spite O +of O +the O +budget O +problems O +, O +” O +said O +professor O +Charles B-/person/author,/person +Campbell I-/person/author,/person +, O +who O +was O +elected O +as O +an O +Fellow O +in O +2010 O +. O + +“ O +We O +’ve O +really O +hired O +some O +good O +people O +here O +. O +” O + +Other O +newly O +elected O +, O +UW-based O +fellows O +include O +E. B-/person +Virginia I-/person +Armbrust I-/person +of O +the O +School B-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Oceanography I-/organization,/organization/educational_institution +, O +Neil B-/person +M. I-/person +Nathanson I-/person +of O +the O +Department B-/education/department,/organization,/education +of I-/education/department,/organization,/education +Pharmacology I-/education/department,/organization,/education +, O +Danny B-/person +Shen I-/person +and O +Jashvant B-/person +Unadkat I-/person +of O +the O +School B-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Pharmacy I-/organization,/organization/educational_institution +, O +and O +Michael B-/person +Schick I-/person +of O +the O +Department B-/education/department,/organization,/education +of I-/education/department,/organization,/education +Physics I-/education/department,/organization,/education +. O + +A O +federal O +grand O +jury O +has O +indicted O +eight O +people O +suspected O +of O +operating O +a O +human-trafficking O +ring O +for O +interstate O +prostitution O +from O +a O +Korean O +nightclub O +in O +Federal B-/location/city,/location +Way I-/location/city,/location +. O + +Prosecutors O +say O +the O +owner O +, O +manager O +and O +others O +at O +the O +Blue B-/location +Moon I-/location +, O +31140 O +Pacific B-/transportation/road,/location,/transportation +Highway I-/transportation/road,/location,/transportation +South I-/transportation/road,/location,/transportation +, O +were O +recruiting O +Korean O +women O +, O +many O +from O +overseas O +, O +to O +work O +as O +“ O +hostesses O +. O +” O + +The O +women O +were O +expected O +to O +entertain O +men O +and O +set O +up O +subsequent O +meetings O +for O +paid O +sex O +to O +repay O +their O +travel O +and O +living O +expenses O +, O +the O +U.S. B-/organization,/government_agency +Attorney I-/organization,/government_agency +’s I-/organization,/government_agency +Office I-/organization,/government_agency +announced O +Friday B-/time +. O + +The O +grand O +jury O +issued O +a O +12-count O +indictment O +Wednesday B-/time +against O +eight O +men O +and O +women O +associated O +with O +the O +Blue B-/location +Moon I-/location +. O + +The O +owner O +and O +seven O +others O +were O +charged O +with O +several O +crimes O +, O +including O +conspiracy O +to O +commit O +money O +laundering O +, O +visa O +fraud O +, O +harboring O +illegal O +aliens O +, O +bribery O +and O +transportation O +in O +furtherance O +of O +prostitution O +. O + +Federal O +agents O +served O +search O +warrants O +on O +the O +Blue B-/location +Moon I-/location +and O +several O +homes O +Thursday B-/time +. O + +The O +club O +was O +closed O +Friday B-/time +and O +might O +not O +reopen O +, O +federal O +officials O +said O +. O + +The O +indictment O +is O +the O +result O +of O +a O +two-year O +, O +multi-agency O +investigation O +headed O +by O +the O +U.S. B-/organization,/government_agency +Immigration I-/organization,/government_agency +and I-/organization,/government_agency +Customs I-/organization,/government_agency +Enforcement I-/organization,/government_agency +’s O +homeland O +security O +investigations O +unit O +. O + +“ O +The O +organizers O +of O +this O +criminal O +scheme O +exploited O +vulnerable O +young O +women O +to O +satisfy O +their O +greed O +, O +” O +U.S. B-/title +Attorney I-/title +Jenny B-/person +A. I-/person +Durkan I-/person +said O +. O + +“ O +They O +also O +sought O +to O +protect O +their O +business O +by O +offering O +bribes O +to O +law O +enforcement O +. O +” O + +Agents O +arrested O +six O +of O +the O +accused O +Thursday B-/time +morning O +, O +including O +the O +club O +’s O +owner O +, O +Chang B-/person +Young I-/person +Kim I-/person +, O +a O +58-year-old O +Milton B-/location/city,/location +resident O +; O +and O +his O +wife O +, O +35-year-old O +Yeun B-/person +Jeong I-/person +Mun I-/person +. O + +Investigators O +suspect O +Mun B-/person +worked O +as O +a O +former O +madam O +at O +the O +club O +, O +prosecutors O +said O +. O + +Also O +arrested O +Thursday B-/time +were O +: O +Miyoung B-/person +Roberts I-/person +, O +40 O +, O +of O +Federal B-/location/city,/location +Way I-/location/city,/location +; O +accused O +of O +being O +the O +current O +madam O +at O +the O +club O +. O + +Jung B-/person +San I-/person +So I-/person +, O +55 O +, O +of O +Seattle B-/location/city,/location +; O +suspected O +of O +being O +the O +current O +club O +manager O +. O + +Raymond B-/person +Jung I-/person +, O +51 O +, O +of O +Federal B-/location/city,/location +Way I-/location/city,/location +; O +accused O +of O +leasing O +apartments O +where O +the O +women O +were O +housed O +. O + +Kwang B-/person +Frank I-/person +Lee I-/person +, O +57 O +, O +of O +Federal B-/location/city,/location +Way I-/location/city,/location +; O +accused O +of O +providing O +money O +to O +finance O +a O +bogus O +marriage O +tied O +to O +the O +scheme O +. O + +During O +court O +appearances O +Thursday B-/time +, O +the O +six O +defendants O +were O +ordered O +held O +without O +bond O +pending O +detention O +hearings O +. O + +Two O +other O +defendants O +– O +Sung B-/person +Hee I-/person +Han I-/person +and O +Hee B-/person +Jae I-/person +Cho I-/person +, O +both O +40 O +and O +of O +Federal B-/location/city,/location +Way I-/location/city,/location +– O +still O +are O +sought O +. O + +Han B-/person +is O +suspected O +of O +being O +an O +assistant O +madam O +at O +the O +Blue B-/location +Moon I-/location +, O +and O +Cho B-/person +is O +a O +former O +manager O +, O +according O +to O +prosecutors O +. O + +Investigators O +suspect O +Cho B-/person +is O +in O +the O +Los B-/location/city,/location +Angeles I-/location/city,/location +area O +. O + +Agents O +began O +investigating O +the O +club O +in O +November B-/time +2009 I-/time +. O + +Seattle B-/organization,/government_agency +police I-/organization,/government_agency +detectives O +had O +been O +investigating O +an O +unrelated O +embezzlement O +scheme O +when O +they O +received O +information O +on O +the O +sex-trafficking O +ring O +and O +passed O +it O +along O +to O +the O +federal O +agents O +. O + +In O +addition O +to O +other O +charges O +, O +prosecutors O +suspect O +Kim B-/person +, O +the O +club O +’s O +owner O +, O +tried O +to O +bribe O +an O +undercover O +officer O +in O +the O +case O +. O + +Kim B-/person +offered O +$ O +15,000 O +in O +exchange O +for O +a O +heads-up O +on O +law O +enforcement O +inspections O +and O +cooperation O +from O +immigration O +authorities O +to O +allow O +undocumented O +Korean O +women O +to O +come O +to O +the O +United B-/location/country,/location +States I-/location/country,/location +, O +prosecutors O +said O +. O + +Kim B-/person +has O +been O +charged O +with O +five O +crimes O +related O +to O +the O +bribery O +accusations O +. O + +Seattle B-/government,/government/government +City I-/government,/government/government +Council I-/government,/government/government +members O +said O +Friday O +they O +are O +troubled O +that O +Mayor B-/person/politician,/person +Mike I-/person/politician,/person +McGinn I-/person/politician,/person +would O +hire O +a O +consultant O +to O +advise O +the O +city O +on O +the O +development O +of O +a O +new O +, O +state-of-the-art O +sports O +facility O +that O +could O +draw O +an O +NBA B-/organization,/organization/sports_league +team O +back O +to O +Seattle B-/location/city,/location +— O +without O +conferring O +with O +them O +. O + +" O +I O +understand O +vague O +rumors O +are O +one O +thing O +. O + +But O +if O +they O +[ O +the B-/government_agency +Mayor I-/government_agency +'s I-/government_agency +Office I-/government_agency +] O +felt O +this O +was O +important O +enough O +to O +enter O +into O +a O +contract O +, O +I O +think O +it O +would O +have O +been O +appropriate O +to O +notify O +the O +council O +at O +that O +point O +, O +" O +said O +Councilmember B-/person/politician,/person +Richard I-/person/politician,/person +Conlin I-/person/politician,/person +. O + +McGinn B-/person +agreed O +to O +a O +$ O +19,500-per-month O +contract O +in O +July B-/time +with O +a O +nationally O +prominent O +sports-facilities O +consultant O +, O +Carl B-/person +Hirsh I-/person +. O + +McGinn B-/person +is O +allowed O +to O +spend O +up O +to O +$ O +250,000 O +on O +contracts O +before O +he O +'s O +required O +to O +notify O +the O +council O +. O + +The O +council O +knew O +nothing O +of O +Hirsh B-/person +'s O +hiring O +, O +nor O +of O +the O +mayor O +'s O +discussions O +with O +a O +potential O +investment O +group O +that O +has O +acquired O +property O +in O +the O +Sodo B-/location +District I-/location +, O +until O +The B-/news_agency,/organization,/organization/company +Seattle I-/news_agency,/organization,/organization/company +Times I-/news_agency,/organization,/organization/company +in O +December B-/time +was O +about O +to O +report O +that O +the O +city O +was O +examining O +an O +" O +opportunity O +" O +to O +bring O +an O +NBA B-/organization,/organization/sports_league +team O +to O +Seattle B-/location/city,/location +. O + +" O +It O +would O +have O +been O +nice O +to O +know O +about O +it O +sooner O +, O +even O +though O +I O +understand O +they O +do O +n't O +have O +a O +firm O +proposal O +, O +" O +said O +Councilmember B-/person/politician,/person +Sally I-/person/politician,/person +Clark I-/person/politician,/person +. O + +McGinn B-/person +said O +Friday B-/time +that O +his O +office O +was O +approached O +last O +year O +by O +" O +a O +private O +party O +interested O +in O +making O +a O +significant O +investment O +to O +construct O +a O +new O +arena O +in O +Seattle B-/location/city,/location +. O +" O + +The B-/news_agency,/organization,/organization/company +Times I-/news_agency,/organization,/organization/company +also O +reported O +in O +December B-/time +that O +the O +investment O +group O +is O +headed O +by O +San B-/location/county,/location/city,/location +Francisco I-/location/county,/location/city,/location +hedge-fund O +manager O +Christopher B-/person +Hansen I-/person +, O +who O +has O +family O +ties O +to O +Seattle B-/location/city,/location +. O + +McGinn B-/person +said O +he O +assembled O +an O +internal O +city O +team O +to O +evaluate O +the O +proposal O +. O + +He O +said O +he O +and O +the O +team O +reached O +the O +conclusion O +that O +additional O +expertise O +was O +warranted O +, O +including O +hiring O +Hirsh B-/person +. O + +The O +city O +also O +hired O +a O +local O +bond O +attorney O +, O +Hugh B-/person +Spitzer I-/person +, O +in O +September B-/time +to O +advise O +it O +on O +financial O +and O +legal O +issues O +, O +including O +Initiative B-/written_work +91 I-/written_work +, O +the O +2006 O +voter-approved O +initiative O +that O +requires O +the O +city O +to O +earn O +a O +return O +on O +investment O +for O +any O +sports O +venue O +. O + +The B-/news_agency,/organization,/organization/company +Seattle I-/news_agency,/organization,/organization/company +Times I-/news_agency,/organization,/organization/company +requested O +copies O +of O +the O +consultants O +' O +contracts O +under O +the O +state O +Public B-/law +Records I-/law +Act I-/law +in O +December B-/time +. O + +McGinn B-/person +'s O +office O +initially O +said O +the O +documents O +would O +not O +be O +released O +until O +February B-/time +, O +but O +changed O +course O +and O +made O +them O +available O +Friday B-/time +. O + +" O +My O +direction O +to O +city O +staff O +and O +our O +experts O +is O +to O +focus O +on O +two O +goals O +: O +1 O +) O +Seriously O +explore O +and O +consider O +the O +opportunity O +, O +and O +2 O +) O +Ensure O +that O +taxpayers O +and O +the O +city O +of O +Seattle B-/location/city,/location +are O +protected O +, O +particularly O +in O +light O +of O +the O +public O +'s O +direction O +through O +I-91 B-/written_work +, O +" O +McGinn B-/person +said O +in O +an O +emailed O +statement O +. O + +McGinn B-/person +reiterated O +that O +the O +city O +has O +not O +received O +a O +concrete O +proposal O +. O + +If O +it O +does O +, O +he O +said O +, O +" O +consulting O +with O +the O +City B-/government_agency +Council I-/government_agency +will O +be O +my O +first O +step O +in O +moving O +forward O +. O +" O + +Clark B-/person +said O +she O +appreciated O +that O +the O +contract O +with O +Hirsh B-/person +included O +protecting O +the O +city O +'s O +financial O +interest O +and O +evaluating O +any O +proposal O +. O + +" O +We O +know O +that O +the O +Sonics B-/organization/sports_team,/organization +left O +an O +empty O +arena O +. O + +How O +do O +you O +convince O +the O +city O +to O +support O +a O +new O +arena O +given O +what O +they O +know O +about O +taxpayers O +being O +left O +holding O +the O +mortgage O +? O +" O + +Clark B-/person +asked O +. O + +Hirsh B-/person +worked O +for O +former O +Sonics B-/organization/sports_team,/organization +owner O +Howard B-/person +Schultz I-/person +, O +when O +the O +team O +was O +evaluating O +how O +to O +make O +KeyArena B-/location,/building/sports_facility,/building +financially O +profitable O +. O + +Schultz B-/person +sold O +the O +team O +in O +2006 O +to O +Clay B-/person +Bennett I-/person +. O + +Bennett B-/person +said O +the O +city-owned O +arena O +lacked O +the O +amenities O +to O +support O +an O +NBA B-/organization,/organization/company,/organization/sports_league +franchise O +and O +moved O +the O +team O +to O +Oklahoma B-/location/city,/location +City I-/location/city,/location +after O +failing O +to O +secure O +a O +new O +arena O +here O +. O + +" O +I O +understand O +the O +challenges O +of O +KeyArena B-/location,/building/sports_facility,/building +and O +the O +economics O +of O +the O +NBA B-/organization,/organization/company,/organization/sports_league +and O +NHL B-/organization,/organization/company,/organization/sports_league +, O +" O +Hirsh B-/person +said O +Friday B-/time +. O + +Hirsh B-/person +, O +managing O +partner O +of O +Stafford B-/organization +Sports I-/organization +in O +New B-/location,/location/province +Jersey I-/location,/location/province +, O +has O +advised O +the O +San B-/organization/sports_team,/organization +Antonio I-/organization/sports_team,/organization +Spurs I-/organization/sports_team,/organization +through O +construction O +of O +their O +new O +arena O +, O +the O +AT&T B-/location,/building/sports_facility,/building +Center I-/location,/building/sports_facility,/building +. O + +He O +worked O +with O +the O +city O +of O +Orlando B-/location/city,/location +to O +negotiate O +an O +agreement O +with O +the O +Orlando B-/organization/sports_team,/organization +Magic I-/organization/sports_team,/organization +for O +a O +new O +downtown O +arena O +and O +with O +senior O +management O +planning O +a O +new O +Madison B-/organization,/location,/building/sports_facility,/building,/organization/company +Square I-/organization,/location,/building/sports_facility,/building,/organization/company +Garden I-/organization,/location,/building/sports_facility,/building,/organization/company +in O +New B-/location/city,/location +York I-/location/city,/location +City I-/location/city,/location +. O + +Hirsh B-/person +estimated O +it O +would O +cost O +$ O +400 O +million O +to O +build O +a O +new O +arena O +, O +although O +the O +NBA B-/organization,/organization/sports_league +'s O +New B-/organization/sports_team,/organization +Jersey I-/organization/sports_team,/organization +Nets I-/organization/sports_team,/organization +will O +spend O +$ O +800 O +million O +on O +one O +in O +Brooklyn B-/location/city,/location +. O + +A O +large O +portion O +of O +that O +was O +the O +cost O +of O +land O +, O +Hirsh B-/person +said O +. O + +He O +said O +an O +arena O +could O +be O +built O +on O +as O +little O +as O +7 O +to O +8 O +acres O +, O +which O +is O +about O +the O +size O +of O +the O +parcel O +the O +Hansen B-/organization,/organization/company +investment O +group O +has O +shown O +an O +interest O +in O +acquiring O +. O + +A O +limited O +liability O +corporation O +headed O +by O +Hansen B-/organization,/organization/company +recently O +purchased O +3 O +acres O +on O +the O +east O +side O +of O +Occidental B-/transportation/road,/location,/transportation +Avenue I-/transportation/road,/location,/transportation +South I-/transportation/road,/location,/transportation +between O +South B-/transportation/road,/location,/transportation +Massachusetts I-/transportation/road,/location,/transportation +and O +South B-/transportation/road,/location,/transportation +Holgate I-/transportation/road,/location,/transportation +streets O +. O + +Hirsh O +pointed O +to O +San B-/organization/sports_team,/organization +Antonio I-/organization/sports_team,/organization +as O +an O +example O +of O +a O +small-market O +city O +making O +a O +new O +arena O +pencil O +out O +financially O +. O + +The B-/location,/building/sports_facility,/building +AT&T I-/location,/building/sports_facility,/building +Center I-/location,/building/sports_facility,/building +is O +home O +to O +three O +teams O +— O +the O +Spurs B-/organization/sports_team,/organization +, O +the O +WNBA B-/organization,/organization/sports_league +'s O +Silver B-/organization/sports_team,/organization +Stars I-/organization/sports_team,/organization +and O +the O +American B-/organization,/organization/sports_league +Hockey I-/organization,/organization/sports_league +League I-/organization,/organization/sports_league +'s O +Rampage B-/organization/sports_team,/organization +. O + +It O +also O +hosts O +a O +three-week O +rodeo O +as O +well O +as O +concerts O +and O +events O +. O + +The O +building O +was O +a O +partnership O +between O +the O +city O +and O +the O +Spurs B-/organization/sports_team,/organization +, O +with O +San B-/location/city,/location +Antonio I-/location/city,/location +voters O +approving O +a O +visitor O +'s O +tax O +on O +hotels O +, O +motels O +and O +rental O +cars O +to O +finance O +three-fourths O +of O +the O +costs O +and O +the O +team O +contributing O +the O +rest O +, O +said O +Rick B-/person +Pych I-/person +, O +president O +of O +business O +operations O +for O +San B-/organization/sports_team,/organization +Antonio I-/organization/sports_team,/organization +Spurs I-/organization/sports_team,/organization +Sports O +. O + +Hirsh B-/person +said O +many O +pieces O +remain O +to O +be O +put O +together O +to O +make O +a O +new O +arena O +work O +in O +Seattle B-/location/city,/location +. O + +And O +he O +reiterated O +what O +the O +mayor O +and O +council O +members O +have O +said O +, O +that O +there O +is O +no O +firm O +proposal O +. O + +But O +he O +said O +the O +developer O +is O +very O +motivated O +. O + +" O +Do O +I O +think O +it O +will O +be O +easy O +? O + +No O +. O + +Do O +I O +think O +we O +can O +put O +together O +a O +deal O +? O + +Yes O +. O +" O + +A O +deal O +also O +might O +help O +resurrect O +the O +political O +fortunes O +of O +McGinn B-/person/politician,/person +, O +who O +in O +August B-/time +lost O +the O +fight O +over O +the O +waterfront O +tunnel O +, O +which O +he O +stridently O +opposed O +, O +and O +suffered O +defeat O +of O +a O +proposed O +$ O +60 O +vehicle-license O +fee O +, O +which O +he O +favored O +. O + +Christian B-/person +Sinderman I-/person +, O +a O +political O +consultant O +, O +said O +that O +while O +the O +number O +of O +people O +who O +want O +professional O +basketball O +returned O +to O +Seattle B-/location/city,/location +is O +high O +, O +the O +number O +who O +think O +it O +'s O +essential O +is O +low O +. O + +Building O +a O +new O +arena O +and O +bringing O +a O +team O +back O +" O +is O +not O +a O +political O +game-changer O +, O +" O +Sinderman B-/person +said O +. O + +But O +he O +did O +acknowledge O +that O +if O +an O +arena O +got O +built O +under O +terms O +favorable O +to O +the O +city O +, O +" O +It O +could O +show O +that O +this O +mayor O +is O +capable O +of O +cutting O +a O +deal O +and O +delivering O +. O +" O + +Homeless O +children O +in O +the O +U-District B-/location +will O +get O +the O +opportunity O +to O +show O +their O +art O +pieces O +in O +an O +exhibit O +held O +at O +the O +UW B-/organization,/location,/organization/educational_institution +School I-/organization,/location,/organization/educational_institution +of I-/organization,/location,/organization/educational_institution +Social I-/organization,/location,/organization/educational_institution +Work I-/organization,/location,/organization/educational_institution +this O +winter O +quarter O +. O + +The O +pieces O +were O +compiled O +at O +the O +Sanctuary B-/organization,/location,/building +Art I-/organization,/location,/building +Center I-/organization,/location,/building +, O +a O +non-profit O +, O +University B-/organization,/location +Lutheran I-/organization,/location +Church-based I-/organization,/location +organization O +designed O +to O +teach O +creativity O +to O +youth O +. O + +Homeless O +youth O +and O +young O +adults O +ages O +13 O +to O +25 O +attend O +sessions O +at O +the O +art O +center O +. O + +About O +14 O +young O +adults O +at O +a O +time O +go O +to O +drop-in O +sessions O +where O +they O +create O +drawings O +, O +paintings O +, O +sculptures O +, O +T-shirt O +designs O +, O +stained O +glass O +, O +play O +guitar O +and O +drums O +, O +and O +work O +on O +other O +art O +they O +find O +soothing O +. O + +“ O +Some O +art O +pieces O +are O +very O +telling O +, O +” O +said O +Jamie B-/person +Lee I-/person +, O +director O +of O +development O +for O +the O +Sanctuary O +Art O +Center O +. O + +“ O +There O +is O +one O +piece O +in O +our O +permanent O +collection O +that O +shows O +a O +person O +walking O +with O +a O +single O +rain O +cloud O +over O +his O +head O +… O +[ O +representing O +] O +that O +bad O +luck O +follows O +you O +everywhere O +. O +” O + +The O +Sanctuary B-/organization,/location,/building +Art I-/organization,/location,/building +Center I-/organization,/location,/building +also O +has O +an O +education O +program O +, O +which O +is O +partnered O +with O +the O +Interagency B-/organization,/organization/educational_institution +Academy I-/organization,/organization/educational_institution +, O +an O +alternative O +school O +in O +Seattle B-/location/city,/location +that O +allows O +young O +adults O +to O +get O +credit O +toward O +their O +GEDs O +by O +participating O +in O +the O +program O +. O + +Art O +pieces O +from O +students O +of O +the O +education O +program O +are O +shown O +in O +the O +exhibit O +as O +well O +. O + +At O +the O +art O +center O +, O +children O +learn O +different O +lessons O +every O +day O +instead O +of O +focusing O +on O +just O +one O +piece O +of O +art O +over O +a O +certain O +amount O +of O +time O +, O +and O +some O +of O +their O +art O +is O +shown O +to O +the O +public O +when O +completed O +. O + +The O +opening O +reception O +for O +the O +art O +exhibit O +was O +held O +at O +the O +UW B-/organization,/location,/organization/educational_institution +School I-/organization,/location,/organization/educational_institution +of I-/organization,/location,/organization/educational_institution +Social I-/organization,/location,/organization/educational_institution +Work I-/organization,/location,/organization/educational_institution +on O +Jan. B-/time +11 I-/time +, O +and O +the O +showing O +continues O +until O +March B-/time +15 I-/time +. O + +Madeline B-/person +Galbraith I-/person +, O +co-chair O +of O +the O +art O +committee O +at O +the O +School B-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Social I-/organization,/organization/educational_institution +Work I-/organization,/organization/educational_institution +, O +said O +homeless O +youth O +do O +n’t O +usually O +get O +to O +show O +their O +artwork O +to O +the O +public O +, O +and O +most O +of O +the O +art O +pieces O +are O +very O +powerful O +and O +passionate O +. O + +“ O +We O +want O +to O +get O +the O +work O +that O +is O +done O +by O +the O +youth O +out O +in O +the O +community O +so O +they O +can O +feel O +appreciated O +and O +accomplished O +, O +” O +Lee O +said O +. O + +Some O +youth O +face O +issues O +with O +dysfunctional O +homes O +, O +the O +trauma O +of O +everyday O +life O +, O +and O +living O +on O +the O +streets O +, O +Galbraith B-/person +said O +. O + +Michael B-/person +Winans I-/person +, O +co-chair O +of O +the O +art O +committee O +at O +the O +UW B-/organization,/organization/educational_institution +, O +believes O +art O +has O +the O +ability O +to O +soak O +up O +bad O +memories O +and O +thoughts O +for O +these O +youth O +and O +work O +as O +an O +outlet O +for O +their O +life O +struggles O +, O +“ O +Art O +can O +absorb O +time O +and O +mind O +and O +help O +[ O +kids O +] O +get O +away O +from O +their O +everyday O +lives O +, O +” O +said O +Winans B-/person +. O + +For O +the O +art O +pieces O +on O +sale O +, O +90 O +percent O +of O +the O +profits O +go O +to O +the O +young O +artists O +and O +the O +rest O +goes O +to O +the O +Sanctuary B-/organization +organization O +, O +whose O +mission O +is O +“ O +to O +provide O +a O +safe O +, O +warm O +, O +and O +calm O +environment O +for O +homeless O +and O +street O +involved O +youth O +to O +experience O +creativity O +and O +success O +through O +the O +use O +of O +various O +artistic O +media O +. O +” O + +“ O +[ O +The O +Art O +Center O +] O +is O +a O +place O +to O +go O +for O +children O +to O +create O +something O +, O +get O +off O +the O +streets O +, O +and O +clean O +up O +, O +” O +Galbraith B-/person +said O +. O + +Lee B-/person +said O +the O +Sanctuary B-/organization,/building +Art I-/organization,/building +Center I-/organization,/building +gives O +children O +the O +opportunity O +to O +connect O +with O +their O +community O +through O +their O +art O +. O + +Art O +shows O +by O +this O +organization O +are O +held O +all O +over O +the O +Seattle B-/location/city,/location +area O +sporadically O +throughout O +the O +year O +. O + +Some O +young O +adults O +choose O +to O +play O +music O +rather O +than O +drawing O +on O +a O +canvas O +. O + +Sets O +of O +drums O +and O +other O +instruments O +are O +available O +at O +the O +art O +center O +, O +which O +will O +also O +hold O +a O +benefit O +concert O +Feb. B-/time +14 I-/time +. O + +“ O +[ O +Sanctuary B-/organization +] O +teaches O +creativity O +as O +an O +outlet O +for O +the O +stresses O +and O +the O +things O +youth O +are O +going O +through O +, O +” O +Lee B-/person +said O +. O + +“ O +Creativity O +[ O +is O +] O +almost O +a O +form O +of O +therapy O +. O +” O + +Washington O +women O +’s O +head O +basketball O +coach O +Kevin B-/person/coach,/person +McGuff I-/person/coach,/person +anticipated O +his O +team O +’s O +depth O +would O +be O +one O +of O +its O +major O +strengths O +entering O +this O +season O +. O + +A O +recent O +spate O +of O +injuries O +, O +though O +, O +has O +suddenly O +left O +the O +Huskies B-/organization/sports_team,/organization +surprisingly O +thin O +in O +the O +frontcourt O +going O +into O +Saturday O +’s O +game O +against O +Washington B-/organization/sports_team,/organization +State I-/organization/sports_team,/organization +in O +Pullman B-/location +, O +Wash. B-/location,/location/province +, O +where O +the O +UW B-/organization,/organization/educational_institution +will O +attempt O +to O +extend O +its O +32-game O +winning O +streak O +against O +the O +Cougars B-/organization/sports_team,/organization +. O + +The O +biggest O +cause O +for O +concern O +for O +McGuff B-/person +is O +the O +bruised O +hamstring O +Regina B-/person/athlete,/person +Rogers I-/person/athlete,/person +suffered O +against O +Utah B-/organization/sports_team,/organization +last O +Saturday B-/time +. O + +Rogers B-/person/athlete,/person +, O +the O +UW B-/organization,/organization/educational_institution +’s O +leading O +scorer O +( O +16.2 O +points O +per O +game O +) O +and O +rebounder O +( O +7.8 O +) O +, O +will O +be O +a O +game-time O +decision O +against O +Washington B-/organization/sports_team,/organization +State I-/organization/sports_team,/organization +. O + +“ O +I O +do O +n’t O +want O +to O +think O +about O +that O +right O +now O +, O +” O +Rogers B-/person +said O +of O +potentially O +missing O +the O +game O +. O + +“ O +I O +’m O +hoping O +for O +the O +best O +, O +so O +hopefully O +I O +can O +play O +. O +” O + +Alone O +, O +Rogers B-/person +’ I-/person +potential O +absence O +would O +be O +a O +major O +, O +but O +bearable O +blow O +. O + +But O +, O +when O +coupled O +with O +the O +ACL O +tear O +suffered O +by O +forward O +Marjie B-/person/athlete,/person +Heard I-/person/athlete,/person +earlier O +this O +week O +and O +the O +increasing O +likelihood O +that O +freshman O +forward O +Talia B-/person/athlete,/person +Walton I-/person/athlete,/person +will O +miss O +the O +rest O +of O +the O +season O +and O +pursue O +a O +medical O +redshirt O +, O +the O +Huskies B-/organization/sports_team,/organization +might O +be O +left O +with O +just O +two O +players O +taller O +than O +6-foot O +that O +are O +ready O +to O +go O +against O +Washington B-/organization/sports_team,/organization +State I-/organization/sports_team,/organization +. O + +If O +Rogers B-/person +is O +unable O +to O +play O +, O +much O +of O +the O +onus O +of O +attempting O +to O +replace O +her O +minutes O +would O +fall O +on O +two O +seniors O +, O +Mackenzie B-/person/athlete,/person +Argens I-/person/athlete,/person +and O +Mollie B-/person/athlete,/person +Williams I-/person/athlete,/person +. O + +Argens B-/person +has O +been O +a O +consistent O +second O +banana O +in O +the O +past O +two O +weeks O +, O +but O +would O +probably O +be O +counted O +on O +to O +up O +her O +scoring O +against O +the O +Cougars B-/organization/sports_team,/organization +with O +Rogers B-/person/athlete,/person +out O +. O + +Williams B-/person +, O +meanwhile O +, O +has O +been O +part O +of O +the O +UW B-/organization,/organization/educational_institution +’s O +revolving O +door O +at O +power O +forward O +, O +seeing O +major O +minutes O +some O +games O +and O +spending O +the O +majority O +of O +the O +game O +on O +the O +bench O +in O +others O +. O + +With O +Heard B-/person/athlete,/person +done O +for O +the O +season O +, O +though O +, O +she O +figures O +to O +become O +a O +mainstay O +in O +the O +UW O +rotation O +. O + +The O +Huskies B-/organization/sports_team,/organization +could O +n’t O +have O +picked O +a O +worse O +time O +to O +get O +bitten O +by O +the O +injury O +bug O +. O + +After O +playing O +a O +deep O +, O +experienced O +Cougar B-/organization/sports_team,/organization +team O +Saturday B-/time +, O +the O +UW B-/organization/sports_team,/organization +will O +begin O +preparing O +for O +its O +toughest O +road O +trip O +of O +the O +season O +, O +into O +the O +Bay B-/location +Area I-/location +to O +play O +No. O +4 O +Stanford B-/organization/sports_team,/organization +and O +Cal B-/organization/sports_team,/organization +. O + +But O +for O +now O +, O +the O +focus O +is O +on O +the O +Cougars B-/organization/sports_team,/organization +and O +extending O +that O +famous O +winning O +streak O +. O + +McGuff B-/person +, O +though O +, O +cautioned O +putting O +too O +much O +emphasis O +on O +the O +streak O +in O +his O +first O +foray O +into O +the O +cross-state O +rivalry O +. O + +“ O +It O +’s O +a O +fact O +of O +life O +, O +” O +he O +said O +. O + +“ O +But O +I O +do O +n’t O +think O +you O +can O +put O +too O +much O +into O +it O +, O +because O +then O +it O +gets O +your O +kids O +thinking O +about O +that O +, O +and O +that O +’s O +thinking O +about O +the O +wrong O +thing O +. O + +Washington B-/organization/sports_team,/organization +State I-/organization/sports_team,/organization +’s O +an O +excellent O +team O +, O +and O +we O +’ll O +have O +our O +hands O +full O +with O +them O +based O +on O +what O +they O +do O +on O +the O +court O +. O +” O + +The B-/organization/sports_team,/organization +Cougars I-/organization/sports_team,/organization +, O +led O +by O +former O +UW O +head O +coach O +June B-/person/coach,/person +Daugherty I-/person/coach,/person +, O +have O +six O +different O +players O +averaging O +between O +6.4 O +and O +9.4 O +points O +per O +game O +. O + +Unlike O +the B-/organization/sports_team,/organization +Huskies I-/organization/sports_team,/organization +, O +who O +of O +late O +have O +mainly O +relied O +on O +Rogers B-/person/athlete,/person +and O +point O +guard O +Jazmine B-/person/athlete,/person +Davis I-/person/athlete,/person +to O +carry O +the O +scoring O +load O +, O +they O +have O +no O +real O +offensive O +pecking O +order O +. O + +That O +fact O +, O +as O +McGuff B-/person +discussed O +, O +can O +make O +them O +a O +challenge O +to O +prepare O +for O +. O + +“ O +They O +’re O +very O +balanced O +, O +and O +it O +makes O +it O +a O +little O +bit O +difficult O +, O +” O +he O +said O +. O + +“ O +They O +do O +n’t O +win O +because O +one O +person O +dominates O +the O +game O +; O +they O +win O +because O +they O +share O +the O +ball O +well O +, O +they O +execute O +well O +on O +offense O +, O +and O +they O +can O +make O +shots O +. O +” O + +If O +Rogers B-/person/athlete,/person +is O +in O +the O +game O +, O +the O +Huskies B-/organization/sports_team,/organization +will O +be O +much O +better O +equipped O +to O +match O +the O +Cougars B-/organization/sports_team,/organization +in O +that O +aspect O +. O + +If O +she O +is O +unable O +to O +play O +, O +the O +UW O +will O +likely O +have O +to O +try O +to O +beat O +Washington B-/organization/sports_team,/location,/organization +State I-/organization/sports_team,/location,/organization +at O +its O +own O +, O +well-balanced O +game O +. O + +Outside O +Safeway B-/organization,/building,/organization/company +in O +the O +U-District B-/location +, O +students O +pass O +by O +the O +man O +sitting O +by O +the O +doors O +. O + +They O +'ve O +seen O +the O +69-year-old O +several O +times O +and O +, O +even O +more O +likely O +, O +heard O +him O +. O + +" O +Real B-/written_work +Change I-/written_work +? O +" O + +he O +asks O +, O +followed O +automatically O +with O +, O +" O +Have O +a O +great O +day O +, O +sir O +; O +have O +a O +great O +day O +, O +madam O +. O +" O + +Known O +simply O +as O +“ O +the O +Real O +Change O +guy O +” O +to O +most O +, O +Edward B-/person +McClain I-/person +has O +been O +sitting O +at O +his O +spot O +outside O +the O +grocery O +store O +for O +18 O +years O +. O + +“ O +Everybody O +knows O +me O +in O +this O +area O +, O +” O +he O +said O +. O + +Before O +he O +was O +“ O +the O +Real O +Change O +guy O +, O +” O +McClain B-/person +was O +a O +student O +, O +a O +caseworker O +, O +and O +a O +cook O +. O + +He O +was O +born O +in O +Jackson B-/location +, I-/location +Miss. I-/location +, O +but O +was O +raised O +in O +Chicago B-/location/city,/location +. O + +He O +has O +a O +bachelor B-/education/educational_degree,/education +’s I-/education/educational_degree,/education +degree I-/education/educational_degree,/education +in O +political O +science O +and O +sociology O +from O +Northern B-/organization,/location,/organization/educational_institution +Illinois I-/organization,/location,/organization/educational_institution +University I-/organization,/location,/organization/educational_institution +and O +other O +credit O +hours O +in O +microeconomics O +from O +Concordia B-/organization,/organization/educational_institution,/location +University I-/organization,/organization/educational_institution,/location +in O +Canada B-/location/country,/location +. O + +He O +was O +a O +caseworker O +in O +Minnesota B-/location,/location/province +but O +left O +the O +job O +because O +he O +found O +himself O +perpetually O +sick O +from O +the O +environments O +in O +which O +he O +worked O +. O + +He O +also O +has O +30 O +years O +of O +baking O +and O +cooking O +experience O +. O + +After O +18 O +years O +, O +McClain B-/person +is O +still O +consistently O +one O +of O +the O +top O +sellers O +for O +Real B-/written_work +Change I-/written_work +. O + +“ O +Ed B-/person +is O +one O +of O +our O +greatest O +success O +stories O +, O +” O +Harris B-/person +said O +. O + +“ O +But O +there O +are O +hundreds O +of O +success O +stories O +. O +” O + +Employees O +of O +Real B-/organization,/organization/company +Change I-/organization,/organization/company +work O +as O +their O +own O +bosses O +. O + +For O +McClain B-/person +, O +this O +means O +he O +does O +not O +have O +a O +set O +work O +schedule O +. O + +However O +, O +he O +said O +he O +spends O +seven O +days O +a O +week O +sitting O +in O +his O +metal O +folding O +chair O +, O +usually O +for O +10 O +to O +12 O +hours O +per O +day O +. O + +“ O +Makes O +no O +sense O +to O +come O +sit O +here O +and O +walk O +away O +with O +$ O +10 O +when O +I O +could O +walk O +away O +with O +$ O +100 O +, O +” O +McClain B-/person +said O +. O + +“ O +I O +mean O +I O +have O +nothing O +else O +to O +do O +. O + +Nobody O +is O +at O +home O +; O +I O +do O +n’t O +got O +any O +pets O +I O +’ve O +got O +to O +worry O +about O +. O + +Nobody O +is O +there O +, O +so O +what O +am O +I O +rushing O +home O +to O +? O + +The O +TV O +? O + +No O +, O +I O +’d O +rather O +have O +the O +money O +. O +” O + +The O +best O +part O +of O +his O +job O +is O +that O +there O +is O +never O +a O +dull O +moment O +, O +McClain B-/person +said O +. O + +He O +said O +he O +has O +seen O +everything O +sitting O +outside O +the O +store O +. O + +“ O +I O +’ve O +seen O +acts O +that O +Hollywood O +ca O +n’t O +reproduce O +, O +” O +he O +said O +. O + +“ O +Things O +you O +would O +n’t O +believe O +you O +’ve O +seen O +— O +I O +’ve O +seen O +everything O +here O +. O +” O + +Sara B-/person +Osborne I-/person +, O +Safeway B-/organization,/organization/company +’s O +public O +and O +government O +affairs O +director O +, O +said O +the O +store O +has O +had O +one O +or O +two O +complaints O +over O +the O +years O +regarding O +customers O +disliking O +McClain O +’s O +solicitation O +outside O +the O +store O +, O +but O +she O +said O +it O +has O +been O +years O +since O +they O +’ve O +received O +a O +complaint O +. O + +Osborne B-/person +said O +the O +customers O +know O +McClain B-/person +and O +the O +employees O +get O +along O +with O +him O +. O + +She O +said O +there O +have O +been O +cases O +in O +which O +McClain B-/person +will O +chase O +down O +shoplifters O +from O +Safeway B-/organization,/location,/organization/company +. O + +“ O +[ O +McClain B-/person +] O +has O +been O +a O +fixture O +in O +the O +community O +for O +a O +long O +time O +, O +” O +Osborne B-/person +said O +. O + +“ O +I O +think O +people O +just O +know O +him O +and O +expect O +him O +to O +be O +there O +and O +he O +has O +rapport O +with O +many O +of O +the O +customers O +. O +” O + +McClain B-/person +began O +his O +work O +outside O +Safeway B-/organization,/organization/company +in O +the O +beginning O +of O +his O +50s O +. O + +Despite O +being O +past O +retirement O +age O +now O +, O +McClain B-/person +plans O +to O +continue O +working O +as O +long O +as O +he O +is O +healthy O +. O + +“ O +I O +do O +n’t O +want O +to O +sit O +at O +home O +and O +grow O +old O +, O +because O +you O +’re O +just O +going O +to O +die O +quicker O +, O +” O +he O +said O +. O + +“ O +I O +want O +to O +stay O +as O +active O +, O +as O +long O +as O +I O +can O +, O +take O +care O +of O +myself O +. O + +I O +’m O +cool O +in O +the O +game O +with O +that O +. O +” O + +The B-/organization +Seattle I-/organization +Coalition I-/organization +on I-/organization +Homelessness I-/organization +counted O +2,442 O +people O +sleeping O +on O +the O +streets O +of O +Seattle B-/location/city,/location +last O +year O +in O +its O +annual O +One O +Night O +Count O +. O + +Having O +been O +one O +of O +them O +, O +McClain B-/person +tries O +to O +give O +homeless O +people O +in O +the O +area O +advice O +. O + +He O +said O +they O +’re O +often O +young O +kids O +who O +have O +“ O +dropped O +out O +of O +society O +, O +” O +and O +he O +tries O +to O +stress O +the O +importance O +of O +education O +to O +them O +. O + +“ O +Those O +who O +do O +n’t O +have O +a O +GED O +or O +high-school O +education O +, O +I O +preach O +to O +them O +constantly O +. O + +‘ O +You O +are O +going O +to O +need O +an O +education O +in O +this O +society O +; O +this O +is O +your O +society O +, O +not O +mine O +, O +’” O +he O +said O +, O +“ O +because O +I O +’m O +on O +my O +last O +leg O +. O + +I O +’m O +not O +going O +to O +be O +here O +another O +30 O +years O +. O +” O + +On O +the O +sidewalk O +next O +to O +McClain B-/person +was O +a O +container O +of O +macaroni O +salad O +. O + +A O +teenage O +girl O +stopped O +by O +with O +a O +drink O +, O +leaving O +it O +by O +his O +chair O +. O + +McClain B-/person +often O +does O +this O +as O +well O +— O +he O +likes O +to O +bake O +in O +his O +spare O +time O +and O +bring O +food O +for O +the O +employees O +at O +Safeway B-/organization,/location/city,/location,/organization/company +as O +well O +as O +Real B-/organization,/organization/company +Change I-/organization,/organization/company +to O +show O +his O +appreciation O +. O + +“ O +I O +do O +n’t O +have O +the O +money O +to O +give O +these O +people O +, O +so O +I O +go O +home O +and O +I O +’ll O +bake O +and O +say O +thank O +you O +very O +much O +for O +what O +you O +did O +for O +me O +; O +this O +is O +a O +token O +of O +my O +appreciation O +, O +” O +he O +said O +. O + +“ O +I O +could O +never O +pay O +the O +people O +back O +who O +’ve O +really O +been O +nice O +to O +me O +. O + +There O +’s O +not O +that O +much O +money O +in O +the O +world O +, O +there O +’s O +not O +that O +much O +gratitude O +in O +the O +world O +, O +the O +only O +thing O +I O +can O +say O +is O +thank O +you O +. O + +I O +try O +to O +give O +a O +little O +back O +. O +” O + +McClain B-/person +sat O +outside O +Safeway B-/organization,/building,/organization/company +in O +heavy O +gear O +for O +the O +winter O +weather O +, O +selling O +the O +small O +bundle O +of O +papers O +in O +his O +hand O +. O + +He O +broke O +his O +selling O +regimen O +from O +time O +to O +time O +to O +say O +“ O +hello O +” O +to O +a O +friend O +. O + +“ O +Bye O +, O +bye O +, O +little O +dude O +, O +” O +he O +said O +, O +waving O +to O +a O +toddler O +with O +blond O +curls O +. O + +“ O +Have O +a O +great O +day O +, O +madam O +, O +” O +he O +said O +to O +the O +boy O +’s O +mother O +. O + +He O +waits O +for O +the O +next O +person O +to O +cross O +his O +path O +when O +he O +will O +again O +ask O +, O +“ O +Real O +Change O +? O +” O + +Students O +from O +the O +UW B-/organization,/location,/organization/educational_institution +School I-/organization,/location,/organization/educational_institution +of I-/organization,/location,/organization/educational_institution +Law I-/organization,/location,/organization/educational_institution +Innocence I-/organization,/location,/organization/educational_institution +Project I-/organization,/location,/organization/educational_institution +Northwest I-/organization,/location,/organization/educational_institution +( I-/organization,/location,/organization/educational_institution +IPNW I-/organization,/location,/organization/educational_institution +) I-/organization,/location,/organization/educational_institution +Clinic I-/organization,/location,/organization/educational_institution +will O +testify O +in O +support O +of O +a O +bill O +that O +establishes O +a O +compensation O +statute O +for O +individuals O +wrongfully O +convicted O +in O +Washington B-/location,/location/province +State I-/location,/location/province +. O + +House B-/law +Bill I-/law +2221 I-/law +aims O +to O +assist O +those O +who O +are O +wrongly O +convicted O +by O +providing O +legal O +redress O +to O +recover O +$ O +50,000 O +in O +damages O +per O +year O +of O +wrongful O +imprisonment O +. O + +Exonerees O +would O +also O +receive O +$ O +50,000 O +for O +each O +year O +they O +spent O +on O +death O +row O +, O +and O +$ O +25,000 O +for O +each O +year O +they O +spent O +out O +of O +prison O +, O +but O +with O +a O +criminal O +charge O +on O +their O +record O +. O + +UW O +law O +students O +Amy B-/person +Shebeck I-/person +, O +Thomas B-/person +Hudson I-/person +, O +Caroline B-/person +Bercier I-/person +, O +and O +Michael B-/person +Windle I-/person +will O +testify O +during O +the O +House B-/event +Committee I-/event +on I-/event +Judiciary I-/event +’s I-/event +public I-/event +hearing I-/event +today O +. O + +The O +lobbying O +students O +are O +part O +of O +a O +partnership O +between O +IPNW B-/organization +and O +UW B-/organization,/location +Law I-/organization,/location +’s I-/organization,/location +Legislative I-/organization,/location +Advocacy I-/organization,/location +Clinic I-/organization,/location +. O + +The O +IPNW B-/organization +grew O +from O +a O +volunteer O +effort O +in O +1997 O +and O +aims O +at O +freeing O +inmates O +who O +have O +been O +wrongfully O +convicted O +of O +crimes O +, O +and O +the O +legislative O +advocacy O +division O +is O +new O +this O +year O +. O + +Shebeck B-/person +, O +a O +second-year O +law O +student O +, O +said O +other O +ideas O +the O +clinic O +is O +working O +on O +are O +allowing O +defense O +the O +right O +to O +propose O +DNA O +testing O +and O +creating O +legislation O +opposing O +testimony O +from O +jailhouse O +informants O +who O +receive O +compensation O +for O +tips O +. O + +“ O +We O +’re O +hoping O +to O +convince O +the O +Legislature B-/organization +… O +the O +moral O +reason O +why O +, O +as O +a O +matter O +of O +justice O +, O +this O +should O +be O +done O +, O +” O +said O +Hudson B-/person +, O +also O +a O +second-year O +law O +student O +. O + +He O +added O +that O +today O +’s O +testimony O +also O +concerns O +the O +funding O +issues O +. O + +The O +bill O +is O +written O +to O +be O +a O +cause O +of O +action O +against O +the O +county O +that O +has O +wrongly O +convicted O +someone O +, O +meaning O +the O +exonerated O +persons O +will O +file O +lawsuits O +and O +prove O +their O +innocence O +in O +courts O +in O +order O +to O +receive O +compensation O +. O + +“ O +There O +’s O +a O +common O +widespread O +misconception O +that O +people O +who O +are O +exonerated O +can O +just O +go O +in O +and O +get O +a O +bunch O +of O +money O +, O +” O +said O +Lara B-/person +Zarowsky I-/person +, O +the O +IPNW B-/organization +policy O +staff-attorney O +who O +drafted O +the O +bill O +. O + +“ O +The O +truth O +is O +, O +it O +’s O +very O +difficult O +. O + +… O +There O +has O +to O +be O +some O +kind O +of O +provable O +misconduct O +in O +the O +case O +. O +” O + +The O +law O +students O +helped O +Zarowsky B-/person +draft O +the O +bill O +. O + +Testifying O +today O +alongside O +the O +students O +are O +Ted B-/person +Bradford I-/person +, O +Alan B-/person +Northrop I-/person +, O +and O +Larry B-/person +Davis I-/person +, O +exonerees O +that O +were O +freed O +with O +the O +help O +of O +IPNW B-/organization +. O + +All O +men O +were O +acquitted O +because O +of O +post-conviction O +DNA O +testing O +that O +proved O +their O +innocence O +. O + +“ O +Their O +stories O +are O +very O +compelling O +, O +” O +Shebeck B-/person +said O +. O + +“ O +It O +’s O +really O +hard O +to O +squabble O +about O +funding O +— O +though O +people O +may O +try O +— O +when O +you O +have O +these O +guys O +telling O +such O +crazy O +stories O +about O +what O +’s O +happened O +to O +them O +. O +” O + +Bradford B-/person +was O +convicted O +of O +rape O +and O +, O +in O +2010 O +, O +became O +the O +first O +person O +in O +Washington B-/location,/location/province +to O +be O +acquitted O +by O +the O +Court B-/government_agency +of I-/government_agency +Appeals I-/government_agency +based O +on O +DNA O +testing O +. O + +Northrop B-/person +— O +who O +is O +the O +focus O +of O +a O +CNN O +documentary O +— O +and O +Davis B-/person +each O +served O +17 O +years O +in O +prison O +after O +being O +wrongly O +convicted O +in O +a O +rape O +and O +burglary O +trial O +because O +of O +bad O +eyewitness O +identifications O +. O + +In O +2010 O +, O +they O +were O +acquitted O +. O + +Shebeck B-/person +said O +eyewitness O +identification O +is O +the O +most O +common O +way O +people O +are O +wrongly O +convicted O +. O + +“ O +There O +’s O +been O +a O +ton O +of O +social-science O +research O +on O +how O +common O +it O +is O +, O +” O +she O +said O +. O + +“ O +That O +memory O +is O +really O +inaccurate O +. O +” O + +The O +students O +have O +been O +working O +for O +the O +IPNW B-/organization +clinic O +since O +this O +summer O +and O +have O +had O +multiple O +work O +sessions O +with O +Rep. B-/person/politician,/person +Tina I-/person/politician,/person +Orwall I-/person/politician,/person +, O +who O +sponsors O +the O +compensation O +statute O +. O + +Hudson B-/person +said O +the O +students O +are O +confident O +about O +the O +bill O +passing O +. O + +“ O +We O +feel O +this O +is O +a O +very O +good O +cause O +, O +and O +the O +[ O +compensation O +] O +package O +is O +reasonable O +, O +” O +he O +said O +. O + +The O +compensation O +is O +being O +requested O +not O +only O +because O +of O +the O +negative O +effects O +on O +the O +wrongly O +convicted O +individuals O +, O +but O +also O +the O +effects O +on O +their O +families O +. O + +“ O +The O +effects O +go O +beyond O +the O +person O +who O +is O +wrongly O +convicted O +, O +” O +Hudson B-/person +said O +. O + +“ O +There O +’s O +a O +lot O +of O +suffering O +around O +taking O +away O +someone O +’s O +life O +and O +throwing O +them O +in O +prison O +for O +something O +they O +did O +n’t O +do O +. O +” O + +Shebeck B-/person +said O +Northrop B-/person +had O +three O +children O +when O +he O +went O +to O +prison O +. O + +After O +17 O +years O +, O +he O +owed O +$ O +110,000 O +in O +child O +support O +. O + +“ O +That O +’s O +just O +one O +example O +of O +those O +kinds O +of O +effects O +, O +” O +she O +said O +. O + +“ O +Yes O +, O +they O +were O +exonerated O +— O +not O +even O +getting O +into O +missing O +out O +on O +his O +children O +’s O +lives O +— O +but O +, O +as O +soon O +as O +he O +can O +work O +again O +, O +his O +paycheck O +is O +being O +garnished O +. O +” O + +Shebeck B-/person +and O +Hudson B-/person +took O +an O +interest O +in O +the O +IPNW B-/organization +because O +of O +their O +respective O +interests O +in O +criminal O +law O +and O +government O +. O + +For O +Zarowsky B-/person +, O +no O +longer O +a O +student O +, O +a O +wrongful O +conviction O +case O +is O +what O +brought O +her O +to O +law O +school O +. O + +“ O +I O +could O +think O +of O +no O +greater O +injustice O +for O +our O +society O +to O +impose O +on O +someone O +than O +to O +incarcerate O +someone O +for O +something O +they O +did O +n’t O +do O +, O +” O +she O +said O +. O + +“ O +There O +’s O +so O +much O +of O +our O +system O +that O +makes O +it O +difficult O +for O +the O +criminal O +defense O +. O + +… O +When O +you O +have O +someone O +who O +’s O +completely O +innocent O +, O +how O +do O +you O +not O +try O +to O +do O +something O +about O +that O +? O +” O + +Zarowsky B-/person +said O +some O +states O +have O +more O +procedures O +for O +compensating O +the O +wrongly O +accused O +because O +they O +’ve O +taken O +the O +issue O +seriously O +after O +having O +exonerations O +. O + +“ O +Work O +needs O +to O +be O +done O +and O +, O +in O +Washington B-/location,/location/province +state I-/location,/location/province +, O +almost O +none O +of O +that O +work O +has O +been O +done O +, O +” O +Zarowsky B-/person +said O +. O + +“ O +We O +’re O +still O +trying O +to O +build O +interest O +in O +changing O +the O +practices O +that O +are O +really O +entrenched O +. O +” O + +Hudson B-/person +said O +the O +use O +of O +science O +and O +the O +latest O +studies O +is O +a O +way O +to O +prevent O +wrongful O +accusations O +. O + +“ O +Tradition O +has O +a O +large O +weight O +on O +legal O +decisions O +, O +oftentimes O +trumping O +science O +, O +” O +Hudson B-/person +said O +. O + +Police O +procedures O +and O +how O +courts O +deal O +with O +certain O +evidence O +must O +change O +, O +Zarowsky B-/person +said O +, O +and O +it O +’s O +not O +a O +quick O +process O +. O + +“ O +When O +they O +say O +, O +‘ O +The O +wheels O +of O +justice O +grind O +slow O +, O +’ O +they O +mean O +it O +, O +” O +she O +said O +. O + +“ O +It O +takes O +a O +long O +time O +to O +change O +things O +. O +” O + +Marek B-/person/artist,/person +Wieczorek I-/person/artist,/person +, O +UW O +associate O +professor O +of O +art O +history O +, O +remembers O +his O +first O +exhibition O +well O +: O +In O +1989 O +, O +he O +curated O +“ B-/art +The B-/art +Desire I-/art +of I-/art +the I-/art +Museum I-/art +” O +at O +the O +Whitney B-/organization,/location,/building +Museum I-/organization,/location,/building +in O +New B-/location/city,/location +York I-/location/city,/location +. O + +It O +was O +the O +beginning O +of O +a O +passion O +to O +which O +Wieczorek B-/person +would O +devote O +most O +of O +his O +life O +. O + +“ O +This O +was O +really O +exciting O +— O +­ O +my O +first O +year O +in O +New B-/location/city,/location +York I-/location/city,/location +, O +fresh O +out O +of O +the O +Netherlands B-/location/country,/location +, O +” O +Wieczorek B-/person +said O +. O + +The O +exhibition O +“ O +put O +the O +museum O +on O +the O +couch O +, O +” O +as O +he O +described O +it O +, O +“ O +examining O +the O +museum O +as O +an O +institution O +under O +the O +Freudian B-/person +lens I-/person +. O +” O + +He O +was O +a O +student O +in O +the O +Whitney B-/organization,/organization/educational_institution +Museum I-/organization,/organization/educational_institution +’s I-/organization,/organization/educational_institution +Independent I-/organization,/organization/educational_institution +Study I-/organization,/organization/educational_institution +Program I-/organization,/organization/educational_institution +at O +the O +time O +, O +studying O +under O +both O +critical O +studies O +and O +the O +curatorial O +program O +. O + +Even O +then O +, O +there O +was O +one O +artist O +for O +whom O +he O +held O +an O +affinity O +: O +Carel B-/person/artist,/person +Balth I-/person/artist,/person +. O + +Wieczorek B-/person +first O +met O +Balth B-/person +when O +he O +was O +still O +a O +graduate O +student O +in O +New B-/location/city,/location +York I-/location/city,/location +. O + +His O +first O +publication O +was O +on O +Balth B-/person +’s O +“ O +Laser B-/art +Paintings I-/art +. O +” O + +Since O +then O +, O +Wieczorek B-/person +has O +visited O +Balth B-/person +’s O +studio O +near O +Amsterdam B-/location/city,/location +many O +times O +. O + +“ O +That O +was O +a O +marvelous O +experience O +, O +being O +a O +graduate O +student O +and O +publishing O +something O +, O +” O +Wieczorek B-/person +said O +. O + +“ O +I O +have O +known O +the O +artist O +for O +over O +two O +decades O +. O + +His O +work O +spanned O +over O +four O +decades O +. O + +… O +I O +always O +wanted O +to O +curate O +his O +work O +. O +” O + +After O +years O +of O +wanting O +to O +curate O +such O +an O +exhibition O +, O +Wieczorek B-/person +has O +collaborated O +with O +the O +Henry B-/location,/building +Art I-/location,/building +Gallery I-/location,/building +to O +feature O +26 O +pieces O +of O +Balth B-/person +’s O +“ O +Videowatercolors B-/art +. O +” O + +Other O +pieces O +came O +from O +the O +Henry B-/location,/building +Art I-/location,/building +Gallery I-/location,/building +collections O +that O +he O +felt O +would O +coordinate O +with O +Balth B-/person +’s O +works O +. O + +A O +colloquium O +tomorrow O +, O +Jan. O +13 O +, O +at O +6 O +p.m. O +, O +will O +include O +presentations O +from O +four O +or O +five O +of O +Wieczorek B-/person +’s I-/person +former O +students O +before O +the O +exhibition O +tours O +. O + +“ O +The O +colloquium O +is O +the O +culmination O +of O +Marek B-/person +’s O +classwork O +for O +this O +past O +quarter O +, O +” O +said O +Betsey B-/person/artist,/person +Brock I-/person/artist,/person +, O +the O +Henry B-/location,/building +Art I-/location,/building +Gallery I-/location,/building +’s O +associate O +director O +for O +communications O +and O +outreach O +. O + +She O +said O +the O +gallery O +is O +excited O +to O +have O +an O +exhibition O +used O +as O +a O +“ O +springboard O +” O +for O +a O +class O +curriculum O +. O + +For O +Wieczorek B-/person +, O +Balth B-/person +’s O +work O +is O +powerful O +because O +of O +the O +interplay O +of O +different O +mediums O +, O +known O +as O +intermedia O +. O + +Wieczorek B-/person +said O +Balth B-/person +addresses O +the O +question O +, O +“ O +What O +does O +it O +mean O +to O +work O +with O +photography O +, O +paint O +, O +and O +new O +media O +? O +” O + +“ O +Balth B-/person +’s O +work O +, O +in O +a O +sense O +, O +does O +a O +bit O +of O +all O +, O +” O +Wieczorek B-/person +said O +. O + +“ O +That O +’s O +what O +I O +love O +about O +Balth B-/person +’s O +art O +. O + +It O +’s O +always O +in O +between O +. O +” O + +Balth B-/person +sometimes O +uses O +digital O +video O +to O +capture O +motifs O +and O +a O +videograb O +to O +capture O +moving O +light O +. O + +He O +then O +prints O +the O +work O +on O +watercolor O +paper O +, O +creating O +a O +mixture O +of O +both O +contemporary O +art O +, O +photos O +, O +and O +an O +older O +form O +of O +art O +, O +watercolor O +. O + +He O +often O +plays O +with O +light O +and O +perception O +. O + +In O +one O +of O +his O +“ O +Videowatercolor B-/art +” O +pieces O +, O +“ O +Moving B-/art +II I-/art +, O +” O +Balth B-/person +simply O +rotates O +an O +image O +of O +water O +, O +juxtaposing O +it O +with O +the O +original O +photo O +and O +making O +it O +unrecognizable O +. O + +“ O +Our O +eyes O +are O +so O +conditioned O +to O +see O +a O +certain O +way O +, O +” O +Wieczorek B-/person +said O +. O + +“ O +You O +do O +not O +have O +to O +have O +any O +foreknowledge O +of O +art O +to O +appreciate O +[ O +the O +piece O +] O +. O +” O + +Wieczorek B-/person +said O +Balth B-/person +also O +plays O +with O +the O +“ O +liminal O +conditions O +of O +perception O +. O +” O + +In O +Balth B-/person +’s O +work O +“ O +Artwork B-/art +without I-/art +the I-/art +Tulipman I-/art +, O +” O +Balth B-/person +took O +a O +Polaroid O +of O +a O +building O +and O +scratched O +the O +photo O +with O +his O +nails O +before O +removing O +the O +film O +. O + +This O +made O +orange O +colors O +look O +like O +they O +radiated O +off O +the O +building O +, O +as O +if O +it O +were O +on O +fire O +. O + +Wieczorek B-/person +calls O +it O +“ O +chemical O +light O +, O +” O +saying O +that O +Balth B-/person +is O +“ O +casting O +light O +into O +the O +dark O +. O +” O + +“ O +There O +was O +never O +any O +light O +in O +the O +photograph O +, O +but O +we O +think O +we O +see O +light O +, O +” O +Wieczorek B-/person +said O +. O + +In O +an O +interview O +with O +The B-/news_agency,/organization,/written_work,/organization/company +Seattle I-/news_agency,/organization,/written_work,/organization/company +Times I-/news_agency,/organization,/written_work,/organization/company +, O +Balth B-/person +said O +his O +intention O +in O +his O +art O +is O +“ O +to O +come O +to O +the O +heart O +of O +seeing O +, O +the O +core O +of O +perception O +. O +” O + +Speaking O +to O +the O +artist O +about O +his O +pieces O +, O +Wieczorek B-/person +said O +, O +helped O +him O +understand O +Balth B-/person +’s O +intentions O +behind O +the O +work O +. O + +However O +, O +Wieczorek B-/person +said O +the O +curator O +does O +n’t O +need O +to O +know O +the O +artist O +personally O +to O +help O +create O +an O +exhibition O +of O +his O +or O +her O +work O +. O + +“ O +I O +do O +not O +think O +it O +’s O +necessary O +to O +know O +the O +artist O +intimately O +, O +but O +I O +think O +it O +helps O +, O +” O +he O +said O +. O + +“ O +You O +kind O +of O +understand O +more O +what O +the O +artist O +is O +doing O +. O + +I O +think O +it O +makes O +a O +difference O +. O +” O + +In O +the O +end O +, O +Wieczorek B-/person +said O +knowing O +the O +artist O +is O +not O +what O +makes O +the O +work O +powerful O +. O + +Rather O +, O +it O +’s O +how O +the O +pieces O +themselves O +speak O +to O +the O +audience O +. O + +“ O +The O +work O +stands O +on O +its O +own O +, O +” O +he O +said O +. O + +“ O +It O +should O +, O +ideally O +, O +speak O +for O +itself O +. O +” O + +Although O +the O +bill O +concerning O +it O +has O +been O +tabled O +by O +the O +ASUW B-/organization +Board I-/organization +of I-/organization +Directors I-/organization +, O +many O +students O +still O +feel O +a O +new O +commission O +representing O +South B-/location,/people/ethnicity,/people +Asian I-/location,/people/ethnicity,/people +student O +groups O +would O +be O +beneficial O +to O +the O +community O +. O + +The O +proposed O +commission O +would O +reduce O +the O +number O +of O +constituent O +organizations O +under O +the O +Asian B-/organization +Student I-/organization +Commission I-/organization +( O +ASC B-/organization +) O +. O + +Currently O +encompassing O +28 O +RSOs O +, O +the O +ASC B-/organization +represents O +the O +widest O +community O +under O +the O +ASUW B-/organization +Joint I-/organization +Commission I-/organization +Committee I-/organization +. O + +Divya B-/person +Ramachandra I-/person +, O +secretary O +of O +the O +Indian B-/organization +Student I-/organization +Association I-/organization +( O +ISA B-/organization +) O +, O +said O +that O +the O +broad O +community O +covered O +in O +ASC B-/organization +makes O +it O +difficult O +for O +some O +constituents O +to O +feel O +connected O +to O +others O +. O + +“ O +The O +South B-/location +Asian I-/location +student O +groups O +and O +cultures O +are O +very O +different O +than O +the O +East B-/location +Asian I-/location +student O +groups O +and O +cultures O +, O +and O +I O +know O +people O +want O +a O +separate O +commission O +to O +better O +fit O +the O +needs O +of O +these O +groups O +, O +” O +Ramachandra B-/person +said O +. O + +“ O +It O +’s O +hard O +to O +get O +our O +constituents O +to O +go O +to O +other O +ASC B-/organization +events O +because O +they O +’re O +not O +interested O +or O +they O +do O +n’t O +have O +time O +. O + +They O +want O +to O +get O +to O +know O +their O +own O +cultures O +more O +than O +they O +have O +time O +to O +get O +to O +know O +other O +cultures O +. O +” O + +Despite O +these O +views O +, O +Ramachandra B-/person +said O +she O +personally O +has O +reservations O +about O +the O +proposed O +commission O +. O + +“ O +I O +guess O +I O +just O +see O +diversity O +not O +as O +segregating O +but O +more O +as O +bringing O +together O +other O +cultures O +, O +” O +Ramashandra B-/person +said O +. O + +“ O +If O +you O +narrow O +the O +culture O +even O +more O +to O +one O +student O +commission O +, O +then O +how O +are O +you O +supposed O +to O +get O +to O +know O +other O +RSOs O +around O +campus O +? O +” O + +The O +ASUW B-/organization +bill O +regarding O +a O +proposed O +South B-/location +Asian I-/location +commission O +created O +a O +task O +force O +to O +determine O +if O +a O +new O +commission O +was O +truly O +desired O +in O +the O +community O +. O + +Jonathan B-/person +Winn I-/person +, O +ASUW B-/organization +director O +of O +diversity O +efforts O +, O +said O +he O +wrote O +the O +bill O +after O +hearing O +discussion O +about O +such O +a O +commission O +during O +recent O +years O +. O + +“ O +I O +wanted O +to O +explore O +the O +option O +because O +there O +has O +always O +been O +talk O +about O +it O +, O +but O +there O +has O +never O +been O +a O +task O +force O +to O +officially O +see O +if O +that O +was O +something O +that O +the O +ASUW B-/organization +would O +take O +on O +, O +” O +Winn B-/person +said O +. O + +Winn B-/person +said O +he O +was O +not O +upset O +the O +bill O +was O +being O +tabled O +because O +it O +gives O +the O +community O +time O +to O +review O +the O +idea O +of O +forming O +a O +new O +commission O +before O +making O +a O +decision O +. O + +ASC B-/organization +Director B-/person +Melvin I-/person +Taing I-/person +said O +that O +because O +the O +commission O +is O +still O +in O +the O +exploratory O +stages O +, O +he O +has O +been O +trying O +to O +approach O +the O +subject O +objectively O +and O +has O +continued O +to O +ask O +his O +constituents O +’ O +opinions O +. O + +A O +forum O +will O +be O +held O +Jan. B-/time +18 I-/time +for O +students O +to O +discuss O +the O +matter O +. O + +Discussion O +between O +the O +ASC B-/organization +constituents O +has O +been O +a O +struggle O +with O +such O +a O +large O +community O +, O +Taing B-/person +said O +. O + +According O +to O +statistics O +released O +by O +the O +UW B-/organization +Office I-/organization +of I-/organization +the I-/organization +Registrar I-/organization +last O +quarter O +, O +Asian B-/people/ethnicity,/people +and O +Asian-American B-/people/ethnicity,/people +students O +currently O +make O +up O +22.2 O +percent O +of O +the O +UW O +population O +. O + +Representing O +nearly O +a O +quarter O +of O +the O +current O +student O +body O +, O +ASC B-/organization +has O +been O +overflowing O +with O +constituents O +. O + +This O +would O +not O +be O +the O +first O +time O +the O +ASC B-/organization +community O +has O +been O +divided O +. O + +In O +2000 O +, O +student O +groups O +split O +from O +ASC B-/organization +in O +order O +to O +form O +the O +Pacific B-/organization +Islander I-/organization +Student I-/organization +Commission I-/organization +. O + +Taing B-/person +said O +that O +some O +students O +feel O +as O +though O +smaller O +commissions O +could O +allow O +for O +better O +communication O +between O +RSOs O +. O + +“ O +All O +the O +South O +Asian O +groups O +are O +pretty O +close O +with O +each O +other O +and O +communicate O +with O +each O +other O +fairly O +often O +, O +but O +that O +is O +not O +being O +done O +at O +all O +with O +ASC B-/organization +, O +” O +Taing B-/person +said O +. O + +“ O +Some O +people O +have O +felt O +that O +South B-/location,/people/ethnicity,/people +Asian I-/location,/people/ethnicity,/people +people O +have O +been O +left O +out O +of O +the O +Asian B-/organization +Student I-/organization +Commission I-/organization +and O +that O +they O +do O +n’t O +feel O +like O +they O +are O +being O +represented O +well O +in O +the O +ASC B-/organization +. O +” O + +Taing B-/person +said O +the O +new O +commission O +would O +also O +shrink O +his O +workload O +and O +increase O +the O +funding O +that O +reaches O +his O +constituents O +. O + +“ O +A O +lot O +of O +the O +work O +that O +I O +have O +to O +do O +every O +day O +is O +busy-work O +trying O +to O +get O +all O +of O +the O +28 O +groups O +on O +the O +same O +page O +, O +” O +Taing B-/person +said O +. O + +“ O +The O +commission O +would O +actually O +alleviate O +a O +lot O +of O +the O +workload O +and O +resources O +. O +” O + +Ramachandra B-/person +said O +she O +believes O +these O +resources O +would O +help O +fund O +more O +constituents O +’ O +events O +, O +such O +as O +Bhangra B-/event +Bash I-/event +. O + +“ O +Bhangra B-/event +Bash I-/event +used O +to O +be O +our O +biggest O +event O +because O +we O +would O +fly O +in O +people O +from O +all O +of O +the O +country O +, O +but O +as O +one O +RSO O +, O +it O +was O +way O +too O +hard O +for O +us O +to O +put O +it O +on O +as O +a O +group O +, O +” O +Ramachandra B-/person +said O +. O + +“ O +Having O +the O +South B-/location,/people/ethnicity,/people +Asian I-/location,/people/ethnicity,/people +student O +commission O +would O +give O +more O +opportunities O +for O +some O +of O +the O +events O +that O +we O +have O +had O +in O +the O +past O +but O +are O +not O +able O +to O +do O +now O +because O +we O +do O +n’t O +have O +enough O +people O +or O +enough O +time O +or O +money O +. O +” O + +A O +statewide O +contest O +titled O +“ O +Be O +the O +Change O +” O +wants O +UW O +students O +to O +try O +their O +hand O +at O +solving O +any O +one O +of O +the O +world O +’s O +most O +pressing O +health O +issues O +. O + +“ O +Seattle B-/location/city,/location +is O +one O +of O +the O +capitals O +of O +global O +health O +, O +and O +yet O +there O +are O +n’t O +enough O +young O +people O +aware O +of O +the O +opportunities O +to O +do O +something O +positive O +with O +their O +lives O +and O +to O +actually O +have O +a O +career O +working O +in O +global O +health O +, O +” O +said O +William B-/person +Heisel I-/person +, O +a O +representative O +at O +the O +Institute B-/organization +for I-/organization +Health I-/organization +Metrics I-/organization +and I-/organization +Evaluation I-/organization +( O +IHME B-/organization +) O +. O + +UW O +staff O +from O +the O +Foster B-/organization,/organization/educational_institution +School I-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Business I-/organization,/organization/educational_institution +and O +IHME B-/organization +helped O +create O +the O +contest O +, O +which O +is O +sponsored O +by O +the O +Global B-/organization +Health I-/organization +Nexus I-/organization +— O +an O +initiative O +of O +the O +Washington B-/organization +Global I-/organization +Health I-/organization +Alliance I-/organization +that O +works O +to O +raise O +statewide O +awareness O +of O +global O +health O +. O + +“ O +Be O +the O +Change O +” O +committee O +members O +used O +the O +Foster B-/organization,/organization/educational_institution +School I-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Business I-/organization,/organization/educational_institution +’ O +annual O +Global B-/event +Social I-/event +Entrepreneurship I-/event +Competition I-/event +( O +GSEC O +) O +as O +a O +model O +to O +design O +their O +competition O +. O + +Similar O +to O +“ O +Be O +the O +Change O +, O +” O +students O +work O +to O +reduce O +poverty O +in O +a O +developing O +economy O +, O +but O +do O +so O +by O +designing O +and O +creating O +a O +global O +business O +. O + +“ O +The O +goal O +with O +Foster O +’s O +[ O +contest O +] O +is O +to O +generate O +innovative O +ideas O +and O +kind O +of O +push O +the O +envelope O +from O +a O +business O +perspective O +, O +and O +we O +’re O +hoping O +to O +do O +the O +same O +thing O +from O +a O +global O +health O +perspective O +, O +” O +Heisel B-/person +said O +. O + +“ O +Be O +the O +Change O +” O +will O +accept O +applications O +from O +any O +high O +school O +, O +community O +college O +, O +or O +university O +students O +through O +Jan. O +13 O +. O + +Finalists O +are O +chosen O +by O +a O +panel O +of O +judges O +made O +up O +of O +local O +business O +leaders O +and O +educators O +and O +will O +receive O +revisions O +to O +their O +solution O +in O +March B-/time +. O + +Part O +of O +the O +judging O +criteria O +will O +include O +whether O +or O +not O +a O +solution O +can O +be O +easily O +applied O +. O + +The O +winner O +will O +be O +announced O +next O +summer O +, O +but O +even O +students O +who O +do O +n’t O +win O +may O +still O +have O +the O +opportunity O +to O +discuss O +their O +solution O +with O +someone O +from O +a O +relevant O +organization O +— O +such O +as O +the O +Bill B-/organization +& I-/organization +Melinda I-/organization +Gates I-/organization +Foundation I-/organization +; O +the O +international O +, O +nonprofit O +organization O +PATH O +; O +the O +Seattle B-/location,/building/hospital,/building +Children I-/location,/building/hospital,/building +’s I-/location,/building/hospital,/building +Hospital I-/location,/building/hospital,/building +, O +and O +IHME B-/organization +, O +a O +UW O +affiliate O +. O + +“ O +There O +’s O +the O +chance O +not O +just O +to O +win O +, O +but O +the O +idea O +that O +students O +are O +able O +to O +engage O +with O +people O +in O +global O +health O +who O +might O +be O +beneficial O +to O +their O +career O +, O +” O +Heisel B-/person +said O +. O + +“ O +This O +is O +a O +way O +for O +young O +people O +to O +get O +their O +foot O +in O +the O +door O +. O +” O + +To O +enter O +, O +students O +must O +choose O +an O +issue O +and O +submit O +a O +two-page O +proposal O +or O +video O +that O +thoroughly O +explains O +their O +solution O +. O + +Common O +issues O +include O +things O +like O +developing O +a O +malaria O +education O +curriculum O +or O +improving O +access O +to O +clean O +water O +. O + +The O +latter O +topic O +is O +what O +freshman O +Jamie B-/person +Choe I-/person +chose O +. O + +She O +entered O +the O +competition O +with O +a O +team O +of O +four O +bioengineering O +classmates O +after O +hearing O +of O +it O +through O +an O +email O +. O + +Her O +team O +’s O +proposal O +describes O +a O +water-filtration O +device O +, O +consisting O +of O +a O +microfiber O +bag O +that O +separates O +clean O +water O +from O +dirty O +water O +. O + +Choe B-/person +’s O +team O +, O +dubbed O +“ O +Ali B-/organization +Baba I-/organization +, O +” O +hopes O +that O +this O +basic O +contraption O +could O +be O +used O +in O +countries O +such O +as O +India B-/location/country,/location +, O +which O +is O +currently O +plagued O +with O +a O +water O +crisis O +. O + +“ O +It O +sounds O +like O +a O +simple O +solution O +, O +but O +it O +can O +save O +lives O +in O +other O +places O +, O +” O +Choe B-/person +said O +. O + +UW O +faculty O +member O +Alyssa B-/person +Taylor I-/person +instructed O +the O +students O +from O +“ O +Ali O +Baba O +” O +in O +a O +bioengineering O +class O +last O +quarter O +. O + +Taylor B-/person +said O +the O +contest O +is O +a O +way O +for O +students O +to O +easily O +engage O +with O +important O +global O +issues O +, O +even O +when O +lacking O +technical O +knowledge O +and O +experience O +that O +comes O +with O +age O +. O + +“ O +With O +global-health O +problems O +, O +a O +lot O +of O +the O +solutions O +are O +pretty O +simple O +, O +” O +she O +said O +. O + +“ O +In O +fact O +, O +sometimes O +it O +’s O +the O +simple O +solutions O +that O +work O +best O +. O + +Students O +can O +really O +get O +immersed O +in O +this O +— O +they O +feel O +like O +they O +can O +actually O +make O +a O +difference O +in O +this O +area O +, O +and O +they O +can O +actually O +improve O +people O +’s O +lives O +. O +” O + +The O +emotion O +in O +the O +room O +was O +palpable O +when O +state O +Adirondack B-/organization,/government_agency +Park I-/organization,/government_agency +Agency I-/organization,/government_agency +commissioners O +approved O +a O +permit O +for O +the O +Adirondack B-/building,/building/hotel +Club I-/building,/building/hotel +and I-/building,/building/hotel +Resort I-/building,/building/hotel +Friday O +morning O +. O + +After O +Executive O +Director O +Terry B-/person +Martino I-/person +announced O +the O +final O +vote O +count O +- O +10 O +to O +1 O +- O +a O +round O +of O +applause O +erupted O +from O +the O +many O +Tupper B-/person +Lakers I-/person +and O +local O +government O +representatives O +packed O +into O +the O +APA B-/organization +'s O +board O +room O +. O + +As O +people O +started O +to O +make O +statements O +after O +the O +decision O +, O +there O +were O +also O +more O +than O +a O +few O +happy O +tears O +. O + +More O +than O +one O +person O +called O +the O +decision O +historic O +. O + +" O +I O +look O +at O +this O +as O +a O +historic O +moment O +, O +" O +Gerald B-/person +Delaney I-/person +, O +chairman O +of O +the O +Local B-/organization +Government I-/organization +Review I-/organization +Board I-/organization +, O +said O +during O +a O +public O +comment O +session O +after O +the O +vote O +. O + +" O +This O +is O +the O +largest O +project O +this O +agency O +has O +ever O +, O +ever O +had O +a O +party O +to O +give O +permits O +to O +. O +" O + +A O +day O +of O +twists O +and O +turns O +in O +the O +Michael B-/person +Scaringe I-/person +rape O +case O +ended O +with O +Franklin B-/government_agency +County I-/government_agency +Court I-/government_agency +Judge B-/person +Robert I-/person +Main I-/person +declaring O +a O +mistrial O +. O + +The O +move O +came O +late O +Friday O +afternoon O +after O +Scaringe B-/person +dismissed O +Brian B-/person +Barrett I-/person +of O +Lake B-/location/city,/location +Placid I-/location/city,/location +as O +one O +of O +his O +defense O +attorneys O +. O + +" O +This O +afternoon O +Judge B-/person +Main I-/person +granted O +a O +defense O +motion O +for O +a O +mistrial O +, O +" O +county O +Court O +Clerk O +Bruce B-/person +Cox I-/person +said O +in O +a O +message O +left O +with O +the O +Enterprise O +. O + +" O +It O +was O +granted O +as O +a O +consequence O +of O +a O +change O +in O +the O +defense O +counsel O +. O +" O + +Barrett B-/person +had O +represented O +the O +former O +Saranac B-/organization +Lake I-/organization +Youth I-/organization +Center I-/organization +director O +since O +he O +was O +arrested O +in O +January O +2009 O +on O +charges O +of O +raping O +a O +then-13-year-old-girl O +who O +frequented O +the O +center O +. O + +Barrett B-/person +brought O +on O +Mary B-/person +Rain I-/person +of O +Ogdensburg B-/location/city,/location +as O +his O +co-counsel O +in O +the O +case O +at O +some O +point O +last O +year O +. O + +Barrett B-/person +confirmed O +to O +the O +Enterprise O +earlier O +this O +afternoon O +that O +Scaringe B-/person +had O +dismissed O +him O +, O +though O +the O +lawyer O +initially O +declined O +to O +go O +into O +detail O +as O +to O +why O +. O + +" O +There O +was O +a O +difference O +of O +opinion O +between O +my O +co-counsel O +and O +myself O +, O +" O +he O +said O +in O +a O +phone O +conversation O +Friday O +afternoon O +. O + +" O +Mr. B-/person +Scaringe I-/person +opted O +to O +continue O +with O +Ms. B-/person +Rain I-/person +, O +and O +I O +wish O +him O +the O +best O +of O +luck O +. O +" O + +Rain B-/person +declined O +to O +speak O +to O +the O +press O +about O +the O +circumstances O +surrounding O +Barrett B-/person +'s O +departure O +or O +the O +status O +of O +the O +case O +when O +she O +left O +the O +courthouse O +with O +Scaringe B-/person +and O +his O +family O +. O + +That O +was O +before O +the O +Enterprise O +was O +notified O +that O +Judge B-/person +Main I-/person +had O +declared O +a O +mistrial O +. O + +The O +newspaper O +later O +left O +a O +message O +with O +Rain B-/person +that O +had O +n't O +been O +returned O +as O +of O +press O +time O +. O + +Scaringe B-/person +'s O +decision O +to O +dismiss O +Barrett B-/person +came O +one O +day O +after O +a O +jury O +was O +finally O +seated O +for O +the O +trial O +and O +the O +prosecution O +and O +the O +defense O +delivered O +opening O +statements O +in O +the O +case O +. O + +Less O +than O +an O +hour O +after O +the O +trial O +was O +scheduled O +to O +resume O +Friday O +morning O +, O +Judge B-/person +Main I-/person +sent O +the O +jury O +home O +. O + +He O +said O +he O +had O +been O +meeting O +with O +the O +prosecution O +and O +the O +defense O +to O +try O +and O +pare O +down O +the O +lengthy O +witness O +list O +in O +the O +case O +. O + +More O +than O +40 O +names O +were O +submitted O +to O +the O +court O +as O +potential O +witnesses O +at O +the O +start O +of O +the O +trial O +. O + +Spencer B-/person/doctor,/person +Anderson I-/person/doctor,/person +was O +in O +veterinary O +school O +when O +he O +joined O +the O +U.S. B-/organization,/military +Army I-/organization,/military +in O +2000 O +. O + +Before O +9/11 O +, O +he O +noted O +. O + +The O +33-year-old O +Billings B-/location/city,/location +native O +enlisted O +as O +a O +military O +veterinarian O +. O + +“ O +I O +thought O +it O +was O +an O +opportunity O +for O +me O +to O +still O +be O +in O +the O +military O +and O +be O +a O +veterinarian O +, O +” O +said O +Spencer B-/person/soldier,/person +, O +as O +he O +prefers O +to O +be O +called O +. O + +After O +his O +military O +graduation O +, O +Spencer B-/person/soldier,/person +spent O +three O +years O +tending O +the O +Army B-/organization,/military +’s O +dogs O +and O +horses O +— O +nearly O +a O +year O +of O +that O +in O +Iraq B-/location/country,/location +. O + +The O +“ O +working O +” O +German B-/living_thing,/livingthing/animal,/livingthing +shepherds I-/living_thing,/livingthing/animal,/livingthing +and O +Belgian B-/living_thing,/livingthing/animal,/livingthing +malinois I-/living_thing,/livingthing/animal,/livingthing +he O +cared O +for O +were O +either O +attack O +dogs O +or O +bomb O +or O +narcotics O +sniffers O +, O +he O +said O +, O +standing O +in O +his O +year-old O +Baxter B-/building/hospital,/building +Creek I-/building/hospital,/building +Veterinary I-/building/hospital,/building +Clinic I-/building/hospital,/building +. O + +He O +’d O +treat O +them O +for O +lameness O +after O +a O +hard O +day O +of O +trekking O +. O + +Or O +he O +performed O +dental O +root O +canals O +— O +something O +not O +typically O +done O +domestically O +— O +because O +, O +like O +their O +human O +counterparts O +, O +military O +dogs O +ca O +n’t O +take O +a O +day O +off O +. O + +“ O +It O +was O +neat O +to O +see O +that O +work O +because O +you O +do O +n’t O +get O +a O +lot O +of O +that O +in O +civilian O +work O +, O +” O +Spencer B-/person +said O +. O + +While O +serving O +he O +taught O +himself O +acupuncture B-/medicine/medical_treatment,/medicine +. O + +When O +he O +left O +the O +Army B-/organization,/military +, O +Spencer B-/person/soldier,/person +got O +a O +job O +in O +Bozeman B-/location/city,/location +, O +where O +he O +used O +acupuncture O +to O +save O +a O +dog O +that O +could O +n’t O +walk O +anymore O +. O + +The O +patient O +was O +scheduled O +to O +be O +euthanized O +but O +walked O +out O +after O +the O +treatment O +. O + +“ O +It O +does O +n’t O +always O +work O +that O +way O +, O +” O +Spencer B-/person +said O +. O + +“ O +It O +was O +dumb O +luck O +. O +” O + +Now O +certified O +in O +veterinary O +acupuncture O +, O +the O +doggie O +doc O +has O +true O +devotees O +. O + +Jennifer B-/person +Leight I-/person +has O +been O +bringing O +her O +17-year-old O +Newfoundland B-/living_thing,/livingthing/animal,/livingthing +, O +Barley O +, O +to O +Spencer B-/person +since O +June O +. O + +Barley O +was O +having O +difficulty O +walking O +due O +to O +muscle O +tightness O +and O +spinal O +arthritis O +. O + +Leight B-/person +was O +skeptical O +about O +acupuncture O +but O +was O +sold O +when O +Barley O +“ O +bounced O +out O +of O +the O +room O +” O +after O +his O +first O +treatment O +. O + +Now O +Barley O +gets O +about O +30 O +needles O +monthly O +and O +it O +seems O +to O +be O +working O +. O + +“ O +When O +we O +go O +in O +he O +’s O +barely O +walking O +, O +” O +Leight B-/person +said O +. O + +“ O +When O +he O +comes O +out O +, O +he O +’s O +like O +a O +new-found O +puppy O +. O +” O + +A O +tree O +fell O +on O +a O +power O +line O +in O +Bridger B-/location +Canyon I-/location +on O +Sunday O +morning O +, O +knocking O +out O +power O +to O +850 O +customers O +, O +including O +the O +Bridger B-/location +Bowl I-/location +ski I-/location +area I-/location +. O + +Northwestern B-/organization,/organization/company +Energy I-/organization,/organization/company +spokeswoman O +Claudia B-/person +Rapkoch I-/person +said O +the O +outage O +started O +at O +10:50 O +a.m O +. O + +It O +took O +about O +three O +hours O +to O +restore O +power O +to O +all O +those O +affected O +, O +she O +said O +. O + +However O +, O +the O +outage O +shut O +down O +Bridger B-/location +Bowl I-/location +for O +the O +rest O +of O +the O +day O +, O +according O +to O +a O +posting O +on O +the O +ski O +area O +'s O +Facebook B-/organization,/internet/website,/internet,/organization/company +page O +. O + +Officials O +at O +Bridger B-/organization,/organization/company +could O +not O +be O +reached O +for O +comment O +Sunday O +afternoon O +. O + +Earlier O +this O +month O +, O +Sony B-/organization,/organization/company +released O +the O +first O +XQD O +format O +memory O +card O +, O +but O +the O +company O +is O +n't O +stopping O +there O +with O +pushing O +into O +new O +storage O +options O +. O + +Sony B-/organization,/organization/company +has O +now O +announced O +that O +they O +'re O +creating O +a O +new O +line O +of O +high-speed O +SD O +cards O +. O + +The O +flagship O +UHS-I B-/product +series O +will O +be O +available O +in O +8GB O +, O +16GB O +, O +and O +32GB O +versions O +, O +and O +promises O +94MB/s O +read O +and O +45MB/s O +write O +speeds O +. O + +Starting O +at O +$ O +44.99 O +a O +pop O +, O +Sony B-/organization,/organization/company +has O +also O +treated O +them O +to O +be O +water O +resistant O +, O +and O +will O +have O +them O +on O +shelves O +in O +March O +. O + +Also O +at O +CES B-/event +, O +the O +SD B-/organization +Association I-/organization +announced O +a O +new O +standard O +for O +WiFi O +communications O +across O +all O +the O +SD B-/product +cards O +. O + +With O +the O +huge O +popularity O +of O +EyeFi B-/product +cards O +, O +this O +should O +make O +wireless O +communication O +directly O +from O +an O +SD O +card O +even O +easier O +. O + +The O +new O +format O +will O +differentiate O +between O +cards O +that O +use O +a O +home O +network O +interface O +, O +and O +those O +that O +work O +through O +a O +web O +interface O +using O +a O +" O +D O +" O +and O +" O +W O +" O +symbol O +respectively O +. O + +While O +these O +developments O +are O +going O +on O +, O +some O +card O +manufacturers O +have O +been O +less O +than O +enthusiastic O +to O +embrace O +the O +change O +. O + +According O +to O +PhotographyBlog B-/internet/website,/internet +, O +SanDisk B-/organization,/organization/company +and O +Lexar B-/organization,/organization/company +have O +no O +immediate O +plans O +to O +produce O +XQD O +or O +WiFi O +SD O +cards O +. O + +Speaking O +at O +CES B-/event +, O +both O +companies O +have O +no O +plans O +to O +jump O +to O +the O +new O +formats O +in O +the O +near O +future O +, O +and O +Lexar B-/organization,/organization/company +pointed O +out O +that O +its O +new O +1000x O +card O +is O +faster O +than O +Sony B-/organization,/organization/company +'s O +XQD O +. O + +Two O +years O +after O +a O +catastrophic O +earthquake O +occured O +near O +the O +capital O +of O +Port-au-Prince B-/location/city,/location +, O +most O +of O +the O +images O +we O +see O +coming O +out O +of O +Haiti B-/location/country,/location +show O +damage O +and O +despair O +, O +and O +most O +come O +from O +foreign O +photographers O +. O + +This O +is O +something O +American O +photographer O +Maggie B-/person/artist,/person +Steber I-/person/artist,/person +( O +who O +has O +been O +shooting O +in O +Haiti B-/location/country,/location +for O +30 O +years O +) O +is O +trying O +to O +change O +through O +organizations O +like O +the O +nonprofit O +FotoKonbit B-/organization +, O +where O +she O +is O +an O +adviser O +. O + +While O +the O +7.0 O +earthquake O +was O +characterized O +by O +the O +United B-/organization +Nations I-/organization +as O +“ O +the O +largest O +urban O +disaster O +in O +modern O +history O +, O +” O +and O +rebuilding O +efforts O +have O +been O +slow O +, O +Steber B-/person +wants O +the O +world O +to O +know O +that O +tragedy O +is O +n’t O +the O +only O +narrative O +the O +country O +has O +to O +offer O +. O + +Students O +in O +FotoKonbit B-/organization +workshops O +used O +Holga B-/product/camera,/product +cameras O +to O +document O +their O +communities O +, O +and O +the O +resulting O +images O +are O +beautiful O +in O +their O +complexity O +— O +struggle O +, O +pride O +, O +love O +, O +simplicity O +, O +hope O +, O +despair O +— O +in O +a O +word O +: O +life O +. O + +“ O +When O +you O +see O +what O +Haitians B-/location/country,/location +think O +is O +beautiful O +to O +photograph O +, O +important O +, O +profound O +, O +” O +says O +Steber B-/person +, O +“ O +you O +learn O +more O +about O +them O +than O +anything O +an O +outsider O +can O +show O +you O +. O + +To O +put O +cameras O +in O +the O +hands O +of O +Haitians B-/location/country,/location +give O +them O +the O +power O +to O +show O +us O +what O +they O +think O +is O +important O +. O +” O + +The O +scale O +of O +the O +ethical O +challenges O +faced O +by O +veterinary O +surgeons O +and O +their O +perceived O +stressful O +consequences O +were O +investigated O +via O +a O +short O +questionnaire O +, O +completed O +by O +58 O +practising O +veterinary O +surgeons O +. O + +Respondents O +were O +asked O +to O +report O +how O +frequently O +they O +faced O +ethical O +dilemmas O +, O +and O +to O +rate O +on O +a O +simple O +numerical O +scale O +( O +zero O +to O +10 O +) O +how O +stressful O +they O +found O +three O +common O +scenarios O +. O + +Fifty O +seven O +per O +cent O +of O +respondents O +reported O +that O +they O +faced O +one O +to O +two O +dilemmas O +per O +week O +, O +while O +34 O +per O +cent O +stated O +they O +typically O +faced O +three O +to O +five O +dilemmas O +per O +week O +. O + +The O +three O +scenarios O +provided O +were O +all O +rated O +as O +highly O +stressful O +with O +‘ O +client O +wishing O +to O +continue O +treatment O +despite O +poor O +animal O +welfare O +’ O +rated O +as O +the O +most O +stressful O +( O +median O +9 O +) O +. O + +The O +female O +veterinary O +surgeons O +gave O +two O +of O +the O +scenarios O +significantly O +higher O +stress O +ratings O +than O +the O +male O +veterinary O +surgeons O +. O + +Stress O +ratings O +were O +not O +influenced O +by O +number O +of O +years O +in O +practice O +( O +which O +ranged O +from O +one O +to O +more O +than O +25 O +years O +) O +. O + +The O +results O +show O +that O +veterinary O +surgeons O +regularly O +face O +ethical O +dilemmas O +and O +that O +they O +find O +these O +stressful O +. O + +This O +has O +implications O +for O +the O +wellbeing O +of O +veterinary O +surgeons O +and O +supports O +the O +case O +for O +increased O +provision O +of O +training O +and O +support O +, O +especially O +for O +those O +who O +entered O +the O +profession O +before O +undergraduate O +ethics O +teaching O +was O +widely O +available O +. O + +The O +study O +is O +from O +the O +College B-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Medical I-/organization,/organization/educational_institution +, I-/organization,/organization/educational_institution +Veterinary I-/organization,/organization/educational_institution +& I-/organization,/organization/educational_institution +Life I-/organization,/organization/educational_institution +Sciences I-/organization,/organization/educational_institution +, O +University B-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Glasgow I-/organization,/organization/educational_institution +, O +Glasgow B-/location/city,/location +, O +UK B-/location/country,/location +. O + +Questionnaires O +were O +distributed O +to O +all O +members O +of O +the O +Companion B-/organization +Animal I-/organization +Society I-/organization +, O +part O +of O +the O +New B-/organization +Zealand I-/organization +Veterinary I-/organization +Association I-/organization +. O + +The O +questionnaire O +gathered O +information O +on O +the O +demographics O +of O +respondents O +, O +obtained O +an O +assessment O +by O +veterinarians O +of O +the O +level O +of O +pain O +associated O +with O +clinical O +procedures O +for O +rabbits O +and O +guinea O +pigs O +, O +established O +the O +willingness O +of O +respondents O +to O +perform O +these O +, O +obtained O +information O +on O +the O +anaesthetics O +and O +analgesics O +used O +during O +these O +procedures O +, O +and O +the O +factors O +associated O +with O +selecting O +different O +types O +of O +drug O +. O + +The O +level O +of O +knowledge O +of O +respondents O +and O +interest O +in O +continuing O +education O +regarding O +pain O +recognition O +and O +management O +in O +these O +species O +was O +also O +assessed O +. O + +RESULTS O +: O +A O +total O +of O +155/610 O +( O +25.4 O +% O +) O +responses O +were O +obtained O +. O + +Rodents O +and O +lagomorphs O +accounted O +for O +0-5 O +% O +of O +the O +total O +caseload O +in O +the O +practices O +of O +most O +( O +133/155 O +; O +86 O +% O +) O +respondents O +. O + +Anticipated O +pain O +scores O +differed O +for O +different O +procedures O +( O +p O +< O +0.001 O +) O +but O +did O +not O +differ O +between O +male O +and O +female O +respondents O +or O +between O +species O +of O +animal O +. O + +There O +were O +also O +differences O +between O +procedures O +in O +the O +respondents O +willingness O +to O +perform O +them O +( O +p O +< O +0.001 O +) O +. O + +Selection O +of O +anaesthetics O +and O +analgesics O +was O +mainly O +determined O +by O +the O +amount O +of O +information O +available O +for O +the O +species O +, O +and O +ketamine O +was O +the O +drug O +most O +commonly O +used O +. O + +Many O +veterinarians O +felt O +their O +level O +of O +knowledge O +regarding O +the O +recognition O +and O +treatment O +of O +pain O +in O +rabbits O +and O +guinea O +pigs O +was O +inadequate O +. O + +CONCLUSIONS O +: O +Rabbits O +and O +guinea O +pigs O +represented O +a O +small O +percentage O +of O +the O +caseload O +of O +veterinarians O +in O +this O +study O +. O + +From O +an O +animal O +welfare O +perspective O +this O +may O +be O +of O +concern O +as O +, O +anecdotally O +, O +these O +species O +are O +common O +pets O +. O + +However O +, O +further O +study O +regarding O +the O +actual O +number O +of O +these O +animals O +kept O +as O +pets O +in O +New B-/location/country,/location +Zealand I-/location/country,/location +is O +required O +for O +validation O +. O + +Veterinary O +perception O +of O +anticipated O +pain O +, O +and O +willingness O +to O +perform O +procedures O +, O +varied O +between O +procedures O +, O +but O +was O +not O +influenced O +by O +gender O +of O +veterinarian O +. O + +Many O +respondents O +felt O +their O +knowledge O +of O +issues O +relating O +to O +pain O +recognition O +, O +anaesthesia B-/medicine,/medicine/symptom +and O +analgesia B-/medicine,/medicine/symptom +in O +rabbits O +and O +guinea O +pigs O +was O +inadequate O +. O + +CLINICAL O +RELEVANCE O +: O +Understanding O +how O +veterinarians O +choose O +to O +provide O +analgesia O +or O +when O +they O +decline O +to O +perform O +surgeries O +for O +rabbits O +and O +guinea O +pigs O +may O +provide O +significant O +information O +for O +targeting O +professional O +development O +, O +and O +improving O +animal O +welfare O +. O + +The O +study O +is O +from O +the O +Unitec B-/organization,/organization/educational_institution +Institute I-/organization,/organization/educational_institution +of I-/organization,/organization/educational_institution +Technology I-/organization,/organization/educational_institution +, O +Auckland B-/location/city,/location +, O +New B-/location/country,/location +Zealand I-/location/country,/location +. O + diff --git a/finetyper/src/main/resources/finer_resource/figer_hier.json b/finetyper/src/main/resources/finer_resource/figer_hier.json new file mode 100644 index 000000000..336d2a27f --- /dev/null +++ b/finetyper/src/main/resources/finer_resource/figer_hier.json @@ -0,0 +1,428 @@ +{ + "typeInfos": { + "art": { + "is_figer_type": true, + "parent": "work" + }, + "art.film": { + "is_figer_type": true, + "parent": "work" + }, + "astral_body": { + "is_figer_type": true, + "parent": "geography" + }, + "award": { + "is_figer_type": true, + "parent": null + }, + "broadcast_program": { + "is_figer_type": true, + "parent": "work" + }, + "building": { + "is_figer_type": true, + "parent": null + }, + "building.airport": { + "is_figer_type": true, + "parent": "building" + }, + "building.dam": { + "is_figer_type": true, + "parent": "building" + }, + "building.hospital": { + "is_figer_type": true, + "parent": "building" + }, + "building.hotel": { + "is_figer_type": true, + "parent": "building" + }, + "building.library": { + "is_figer_type": true, + "parent": "building" + }, + "building.power_station": { + "is_figer_type": true, + "parent": "building" + }, + "building.restaurant": { + "is_figer_type": true, + "parent": "building" + }, + "building.sports_facility": { + "is_figer_type": true, + "parent": "building" + }, + "building.theater": { + "is_figer_type": true, + "parent": "building" + }, + "computer.programming_language": { + "is_figer_type": true, + "parent": "norpl" + }, + "education.department": { + "is_figer_type": true, + "parent": "organization" + }, + "education.educational_degree": { + "is_figer_type": true, + "parent": "award" + }, + "event": { + "is_figer_type": true, + "parent": null + }, + "event.attack": { + "is_figer_type": true, + "parent": "event" + }, + "event.election": { + "is_figer_type": true, + "parent": "event" + }, + "event.military_conflict": { + "is_figer_type": true, + "parent": "event" + }, + "event.natural_disaster": { + "is_figer_type": true, + "parent": "event" + }, + "event.protest": { + "is_figer_type": true, + "parent": "event" + }, + "event.sports_event": { + "is_figer_type": true, + "parent": "event" + }, + "event.terrorist_attack": { + "is_figer_type": true, + "parent": "event.attack" + }, + "finance.currency": { + "is_figer_type": true, + "parent": null + }, + "finance.stock_exchange": { + "is_figer_type": true, + "parent": "organization" + }, + "food": { + "is_figer_type": true, + "parent": "product" + }, + "geography": { + "is_figer_type": true, + "parent": "location" + }, + "geography.glacier": { + "is_figer_type": true, + "parent": "geography" + }, + "geography.island": { + "is_figer_type": true, + "parent": "geography" + }, + "geography.mountain": { + "is_figer_type": true, + "parent": "geography" + }, + "government.government": { + "is_figer_type": true, + "parent": "organization" + }, + "government.political_party": { + "is_figer_type": true, + "parent": "organization" + }, + "government_agency": { + "is_figer_type": true, + "parent": "government.government" + }, + "language": { + "is_figer_type": true, + "parent": "norpl" + }, + "law": { + "is_figer_type": true, + "parent": null + }, + "living_thing": { + "is_figer_type": true, + "parent": null + }, + "livingthing.animal": { + "is_figer_type": true, + "parent": "living_thing" + }, + "location": { + "is_figer_type": true, + "parent": null + }, + "location.body_of_water": { + "is_figer_type": true, + "parent": "geography" + }, + "location.bridge": { + "is_figer_type": true, + "parent": "building" + }, + "location.cemetery": { + "is_figer_type": true, + "parent": "location" + }, + "location.city": { + "is_figer_type": true, + "parent": "location" + }, + "location.country": { + "is_figer_type": true, + "parent": "location" + }, + "location.county": { + "is_figer_type": true, + "parent": "location" + }, + "location.province": { + "is_figer_type": true, + "parent": "location" + }, + "medicine": { + "is_figer_type": false, + "parent": null + }, + "medicine.drug": { + "is_figer_type": true, + "parent": "medicine" + }, + "medicine.medical_treatment": { + "is_figer_type": true, + "parent": "medicine" + }, + "medicine.symptom": { + "is_figer_type": true, + "parent": "medicine" + }, + "metropolitan_transit.transit_line": { + "is_figer_type": true, + "parent": "organization.company" + }, + "military": { + "is_figer_type": true, + "parent": "organization" + }, + "music": { + "is_figer_type": true, + "parent": "work" + }, + "news_agency": { + "is_figer_type": true, + "parent": "organization.company" + }, + "newspaper": { + "is_figer_type": true, + "parent": "written_work" + }, + "norpl": { + "is_figer_type": false, + "parent": null + }, + "organization": { + "is_figer_type": true, + "parent": null + }, + "organization.airline": { + "is_figer_type": true, + "parent": "organization.company" + }, + "organization.company": { + "is_figer_type": true, + "parent": "organization" + }, + "organization.educational_institution": { + "is_figer_type": true, + "parent": "organization" + }, + "organization.fraternity_sorority": { + "is_figer_type": true, + "parent": "organization" + }, + "organization.sports_league": { + "is_figer_type": true, + "parent": "organization" + }, + "organization.sports_team": { + "is_figer_type": true, + "parent": "organization" + }, + "organization.terrorist_organization": { + "is_figer_type": true, + "parent": "organization" + }, + "park": { + "is_figer_type": true, + "parent": "location" + }, + "people.ethnicity": { + "is_figer_type": true, + "parent": "norpl" + }, + "person": { + "is_figer_type": true, + "parent": null + }, + "person.actor": { + "is_figer_type": true, + "parent": "person.artist" + }, + "person.architect": { + "is_figer_type": true, + "parent": "person" + }, + "person.artist": { + "is_figer_type": true, + "parent": "person" + }, + "person.athlete": { + "is_figer_type": true, + "parent": "person" + }, + "person.author": { + "is_figer_type": true, + "parent": "person" + }, + "person.coach": { + "is_figer_type": true, + "parent": "person" + }, + "person.director": { + "is_figer_type": true, + "parent": "person.artist" + }, + "person.doctor": { + "is_figer_type": true, + "parent": "person" + }, + "person.engineer": { + "is_figer_type": true, + "parent": "person" + }, + "person.monarch": { + "is_figer_type": true, + "parent": "person" + }, + "person.musician": { + "is_figer_type": true, + "parent": "person.artist" + }, + "person.politician": { + "is_figer_type": true, + "parent": "person" + }, + "person.religious_leader": { + "is_figer_type": true, + "parent": "person" + }, + "person.soldier": { + "is_figer_type": true, + "parent": "person" + }, + "person.terrorist": { + "is_figer_type": true, + "parent": "person" + }, + "play": { + "is_figer_type": true, + "parent": "work" + }, + "product": { + "is_figer_type": true, + "parent": null + }, + "product.airplane": { + "is_figer_type": true, + "parent": "product" + }, + "product.camera": { + "is_figer_type": true, + "parent": "product" + }, + "product.car": { + "is_figer_type": true, + "parent": "product" + }, + "product.computer": { + "is_figer_type": true, + "parent": "product" + }, + "product.engine_device": { + "is_figer_type": true, + "parent": "product" + }, + "product.instrument": { + "is_figer_type": true, + "parent": "product" + }, + "product.mobile_phone": { + "is_figer_type": true, + "parent": "product" + }, + "product.ship": { + "is_figer_type": true, + "parent": "product" + }, + "product.spacecraft": { + "is_figer_type": true, + "parent": "product" + }, + "product.weapon": { + "is_figer_type": true, + "parent": "product.instrument" + }, + "rail.railway": { + "is_figer_type": true, + "parent": "organization.company" + }, + "software": { + "is_figer_type": true, + "parent": null + }, + "time": { + "is_figer_type": true, + "parent": null + }, + "title": { + "is_figer_type": true, + "parent": null + }, + "train": { + "is_figer_type": true, + "parent": "product" + }, + "transit": { + "is_figer_type": true, + "parent": "organization.company" + }, + "transportation.road": { + "is_figer_type": true, + "parent": null + }, + "visual_art.color": { + "is_figer_type": true, + "parent": null + }, + "work": { + "is_figer_type": false, + "parent": null + }, + "written_work": { + "is_figer_type": true, + "parent": "work" + } + } +} \ No newline at end of file diff --git a/finetyper/src/main/resources/finer_resource/ontonote_type_mapping.json b/finetyper/src/main/resources/finer_resource/ontonote_type_mapping.json new file mode 100644 index 000000000..0a28506a9 --- /dev/null +++ b/finetyper/src/main/resources/finer_resource/ontonote_type_mapping.json @@ -0,0 +1,24 @@ +{ + "ANIMAL": "living_thing", + "CARDINAL": null, + "DATE": "time", + "EVENT": "event", + "FAC": "building", + "GPE": "location", + "LANGUAGE": "norpl", + "LAW": "law", + "LOC": "location", + "MEDICINE": "medicine", + "MONEY": "finance.currency", + "NORP": "norpl", + "ORDINAL": null, + "ORG": "organization", + "PERCENT": null, + "PERSON": "person", + "PRODUCT": "product", + "QUANTITY": null, + "ROAD": "transportation.road", + "TIME": "time", + "TITLE": "title", + "WORK_OF_ART": "work" +} \ No newline at end of file diff --git a/finetyper/src/main/resources/finer_resource/patterndb.txt b/finetyper/src/main/resources/finer_resource/patterndb.txt new file mode 100644 index 000000000..43988d27b --- /dev/null +++ b/finetyper/src/main/resources/finer_resource/patterndb.txt @@ -0,0 +1,931 @@ +2 Championships in 5 event.sports_event event +1 Scotia Route 1 transportation.road +0 Supreme Court 2 government_agency +2 Open – Doubles 0 event.sports_event +2 Senate election in 3 event.election +2 National Cemetery 0 location.cemetery +1 States House of 3 event.election +2 futsal team 0 organization.sports_team +2 rugby union team 0 organization.sports_team +3 the line 0 product.ship +2 Open - Singles 0 event.sports_event +2 Pomeranian Voivodeship 0 location.city +0 United States 5 event event.election +1 men's national 3 organization.sports_team +0 Governor of 1 title +1 Ohio Infantry 0 military +1 Wimbledon Championships 3 event.sports_event event +2 AG 1 organization.company +1 Premier League 1 event +1 at the 3 event +1 national rugby union team 0 organization.sports_team +2 Volunteer Infantry Regiment 0 military +1 University, main campus 0 organization.educational_institution organization organization.company +1 West Pomeranian 1 location.city +2 University of 1 organization.educational_institution +0 Mexican Federal 2 transportation.road +1 Virginia Infantry 0 military +4 College, main campus 0 organization.educational_institution +3 Ice Hockey 0 organization.sports_team +2 and the 1 written_work art.film +1 International Airport 0 building.airport +0 Athletics at the 8 event event.sports_event +0 Wisconsin Highway 1 transportation.road +1 Wisconsin Volunteer Infantry Regiment 0 military +2 Air Squadron 0 military +2 National Football 1 organization.sports_team +1 Independent School 1 organization +0 Oklahoma State Highway 1 transportation.road +0 Maine State 2 transportation.road +3 - Doubles 0 event.sports_event +0 California State Route 1 transportation.road +0 Athletics at 8 event event.sports_event +1 School of 3 organization.educational_institution +1 Indiana Infantry 1 military +2 Film Festival 0 event +0 Count of 1 title +0 Missouri Route 1 transportation.road +0 Georgia State 2 transportation.road +3 Water Aerodrome 0 building.airport +4 GmbH 1 organization.company +1 national cricket 1 organization.sports_team +2 Silesian Voivodeship 0 location.city +1 Football Association 0 organization.sports_league +4 for the 4 government.government government_agency +2 Championships in Athletics 5 event.sports_event +1 County Sheriff's 1 military government_agency +0 Province of 1 location.province +2 Halifax Regional Municipality 0 location.body_of_water +1 Institute of 3 organization.educational_institution +1 of State 2 title +0 GmbH 1 organization.company +0 University of 4 organization.educational_institution organization.sports_team organization +2 Corp. 1 organization.company +0 Oregon Route 1 transportation.road +3 Corp. 2 organization.company +3 - Men's Singles 0 event event.sports_event +3 election in 2 event.election event +3 Open – 1 event.sports_event event +0 Battle of 2 event event.military_conflict +3 - Women's 1 event event.sports_event +0 United States House 7 event.election +0 Battle of the 1 event.military_conflict +1 in the 1 music written_work broadcast_program art.film +0 Order of 2 title +5 Technology, main campus 0 organization.educational_institution +1 Senior High School 0 organization.educational_institution +2 District Court for 5 government.government government_agency +0 United States Ambassador to 1 title +2 High School, 2 organization.educational_institution +1 legislative election, 1 event.election event +2 Cup team 0 organization.sports_team +2 High School 0 organization.educational_institution organization +4 Summer Olympics - 4 event.sports_event +2 Department of 1 government_agency +2 Premier League 0 event +2 House of Representatives elections, 1 event.election +0 Texas State Highway 1 transportation.road +2 House of Representatives 2 event.election +0 United States House of 3 event.election +1 State University 2 organization.sports_team +2 national football 1 organization.sports_team +3 Mens Football 0 organization.sports_team +5 – Singles 0 event event.sports_event +0 North Carolina Highway 1 transportation.road +1 State Route 1 transportation.road location +2 College, main campus 0 organization.educational_institution organization +2 Inc. 2 organization.company +3 Hockey League 0 organization.sports_league +1 nucleolar RNA 1 biology chemistry +1 Institute of Technology 0 organization.educational_institution +1 States House of Representatives 4 event.election +5 Olympics – Men's 1 event.sports_event +1 Wimbledon Championships – 2 event.sports_event +3 of Representatives 2 event.election +1 Township, Minnesota 0 location.city +1 Wisconsin Volunteer Infantry 1 military +1 State Road 1 transportation.road +1 Secondary School 0 organization.educational_institution +1 GmbH 2 organization.company +0 United States Senate election 3 event event.election +2 Police Department 0 government_agency military +1 at the 8 event.sports_event event +1 Futebol Clube 0 organization.sports_team +5 Olympics - 3 event.sports_event event +1 Corp. 1 organization.company +0 Embassy of 2 government_agency +2 Co. 2 organization.company +3 main campus 0 organization.educational_institution organization organization.company location +2 Infantry Brigade 0 military +4 of the 1 game +1 World Championships in 5 event.sports_event event +1 Naval Air Squadron 0 military +0 Swimming at 10 event.sports_event event +2 Volunteer Infantry 1 military +1 women's national 2 organization.sports_team +2 Council election, 1 event.election event +0 Edmonton municipal 2 event.election +1 New York 0 location.city +0 Communist Party of 2 government.political_party +1 Stock Exchange 0 finance.stock_exchange +1 Socialist Party 0 government.political_party +1 Air Force 0 military +0 South African 3 train +1 Premier League 0 organization.sports_league +1 County High 1 organization.educational_institution +1 Department of 1 government_agency +1 Greater Poland Voivodeship 0 location.city +1 Communist Party 0 government.political_party +0 Small nucleolar 2 biology chemistry +2 national rugby 2 organization.sports_team +1 Illinois Volunteer Infantry Regiment 0 military +0 Corp. 2 organization.company +1 presidential election, 1 event.election event +1 Lake Water 1 building.airport +3 Act of 1 law +3 of Representatives elections 3 event.election +5 – Doubles 0 event event.sports_event +0 Nova Scotia 2 transportation.road +3 Co. 2 organization.company +0 Lac de 1 location.body_of_water +2 Prince of 1 person.monarch +1 Water Aerodrome 0 building.airport +2 High School, main campus 0 organization.educational_institution +3 of the 1 game written_work +4 Men's Singles 0 event event.sports_event +2 Borough Council 2 event.election +2 House of 6 event.election +0 Utah State Route 1 transportation.road +4 Inc. 0 organization.company +4 GmbH 2 organization.company +0 United States House 4 event.election +0 Treaty of 2 law +2 Party of 1 government.political_party +1 women's national football team 0 organization.sports_team +3 GmbH 1 organization.company +4 Co. 0 organization.company +1 Indian Infantry 1 military +0 Kentucky Route 1 transportation.road +1 Lower Silesian Voivodeship 0 location.city +4 Summer Olympics - 3 event event.sports_event +5 Olympics - 4 event event.sports_event +4 Representatives elections 4 event.election +0 Co. 2 organization.company +1 City Airport 0 building.airport +1 Air Force Base 0 building.airport +4 Summer Olympics – Men's 1 event.sports_event +0 Swimming at the 8 event.sports_event event +1 Air Refueling Squadron 0 military +2 election, 2006 0 event.election +2 Open – 2 event.sports_event event +1 Independent School District 0 organization +1 Illinois Volunteer 2 military +1 National Route 1 transportation.road +2 College of 1 organization.educational_institution +0 Battle of 1 event.military_conflict event +0 Louisiana Highway 1 transportation.road +0 Sony Ericsson 1 product.mobile_phone product +1 West Pomeranian Voivodeship 0 location.city +4 Corp. 2 organization.company +1 in the 2 people.ethnicity +0 Order of 3 title +3 University, main campus 0 organization.educational_institution +5 hockey team 0 organization.sports_team +1 Jersey Route 1 transportation.road +6 – Men's 1 event.sports_event event +2 LLC 1 organization.company +0 New South Wales 3 train +2 Corp. 0 organization.company +2 Open – 1 event event.sports_event +2 Inc. 1 organization.company +1 Bombardment Squadron 0 military +4 Athletics - 3 event.sports_event +0 Second Battle 2 event.military_conflict +0 British Rail 2 train +1 women's national football 1 organization.sports_team +1 GmbH 0 organization.company +0 Utah State 2 transportation.road +2 Community College, main 1 organization.educational_institution +0 Japanese cruiser 1 product.ship +2 election, 2005 0 event.election +1 Co. 1 organization.company +0 Government of 1 government.government +1 States District 7 government.government government_agency +0 Communist Party of 1 government.political_party +2 First Nation 0 people.ethnicity +4 - Singles 0 event.sports_event event +2 Water Aerodrome 0 building.airport +0 Florida State 2 transportation.road +3 Championships – 3 event.sports_event +0 Illinois Route 1 transportation.road +1 national basketball team 0 organization.sports_team +2 Artillery Regiment 0 military +2 national football team 0 organization.sports_team +0 China National Highway 1 transportation.road +4 Corp. 1 organization.company +2 International Airport 0 building.airport +1 Mens National Soccer 1 organization.sports_team +1 States House 4 event.election +4 Summer Olympics - Men's 2 event event.sports_event +0 LLC 2 organization.company +3 - Singles 0 event event.sports_event +0 Alabama State 2 transportation.road +2 Operations Squadron 0 military +0 Saskatchewan Highway 1 transportation.road +0 Ministry of 6 government_agency +1 at the 9 event.sports_event event +1 Air Division 0 military +1 College of 4 organization.educational_institution +5 elections in 2 event.election +1 York State Route 1 transportation.road +3 union team 0 organization.sports_team +0 Embassy of 3 government_agency +4 AG 0 organization.company +1 of the 4 title +2 Senate election 4 event.election +0 AG 0 organization.company +0 AG 1 organization.company +1 national cricket team 0 organization.sports_team +2 national volleyball team 0 organization.sports_team +1 women's national 3 organization.sports_team +1 Men's National Football Team 0 organization.sports_team +0 President of 1 title +0 Farm to 3 transportation.road +1 Mens National Soccer Team 0 organization.sports_team +1 Institute of 4 organization.educational_institution +0 Supreme Court of 1 government_agency +2 of Technology 0 organization.educational_institution +1 railway station 0 building location +2 Community College, 2 organization.educational_institution +1 General Hospital 0 building.hospital +3 Grand Prix 0 event +1 National Cemetery 0 location.cemetery +1 West Virginia 0 location.city +7 main campus 0 organization.educational_institution +2 football team 0 organization.sports_team +2 Co. 0 organization.company +0 Virginia State 2 transportation.road +3 Regional Municipality 0 location.body_of_water +1 Department of 4 government_agency +1 of the 1 title event.military_conflict game written_work art broadcast_program art.film music +3 Inc. 2 organization.company +1 Mens Football Team 0 organization.sports_team +1 Soccer Team 0 organization.sports_team +1 University, main 1 organization.educational_institution organization organization.company +2 Infantry Division 0 military +0 Corp. 1 organization.company +1 Naval Air 1 military +2 gubernatorial election, 1 event.election +3 County, Indiana 0 location.city +2 Market Road 1 transportation.road +0 Vermont Route 1 transportation.road +2 presidential election, 1 event.election +2 University, main campus 0 organization.educational_institution organization +3 Inc. 1 organization.company +4 Infantry Regiment 0 military +2 Autonomous County 0 location.county +6 main campus 0 organization.educational_institution organization +1 Greater Poland 1 location.city +1 Municipal Airport 0 building.airport +1 Hampshire Route 1 transportation.road +1 AG 0 organization.company +2 of Technology, 2 organization.educational_institution +4 College, main 1 organization.educational_institution +3 in Athletics 4 event.sports_event event +3 of Alexandria 0 person.religious_leader +2 Championships in Athletics - 3 event.sports_event event +4 Summer Olympics 5 event.sports_event event +2 AG 0 organization.company +1 de la 1 geography.mountain +0 Co. 1 organization.company +2 of the line 0 product.ship +1 I of 1 person.monarch +4 Summer Olympics – Men's 2 event event.sports_event +0 Swimming at the 9 event.sports_event event +0 United States Ambassador 2 title +0 University of 6 organization.educational_institution organization.sports_team +1 Men's National 2 organization.sports_team +1 Street Bridge 0 location.bridge +1 Buses route 1 metropolitan_transit.transit_line +1 District, China 0 location.county +1 national futsal team 0 organization.sports_team +1 Inc. 2 organization.company +0 Nevada State 2 transportation.road +1 Men's National Soccer 1 organization.sports_team +0 London Buses 2 metropolitan_transit.transit_line +2 Power Station 0 building.power_station +2 School of 3 organization.educational_institution +2 of the 2 written_work +4 AG 1 organization.company +0 Prime Minister 2 title +2 at the 3 event +2 Act of 1 law +3 Soccer Team 0 organization.sports_team +0 Iowa Highway 1 transportation.road +2 men's basketball 0 organization.sports_team +1 Labour Party 0 government.political_party +1 High School, 1 organization.educational_institution +1 States Senate 5 event.election +1 Battle of 2 event.military_conflict +2 the 2010 7 event.sports_event +0 New Hampshire Route 1 transportation.road +2 National Football Team 0 organization.sports_team +1 Infantry Division 0 military +0 United States House of 5 event.election +1 State University 0 organization.educational_institution +1 US Open 3 event.sports_event +1 at the 2010 7 event.sports_event +1 County High School 0 organization.educational_institution +2 District Court for the 4 government.government government_agency +1 Senior High 1 organization.educational_institution +2 School, main 1 organization.educational_institution +1 Town F.C. 0 organization.sports_team +1 Czech Republic 0 location.city +0 University of 3 organization organization.sports_team organization.educational_institution +0 First Battle of 1 event.military_conflict +1 Nations Security Council 2 law +3 Volunteer Infantry 1 military +1 Łódź Voivodeship 0 location.city +4 Corp. 0 organization.company +0 Ohio State 2 transportation.road +1 railway line 0 metropolitan_transit.transit_line +1 Masovian Voivodeship 0 location.city +0 GmbH 0 organization.company +3 County, Illinois 0 location.city +1 Corp. 2 organization.company +4 union team 0 organization.sports_team +1 at the 6 event event.sports_event +0 Oklahoma State 2 transportation.road +1 Air Refueling 1 military +3 Medical Center 0 building.hospital +2 Championships – 2 event event.sports_event +1 Ministry of 4 government_agency +1 Infantry Division 1 military +0 Republic of 1 location.country +2 Count of 1 person.monarch +1 Football Team 0 organization.sports_team +1 municipal election, 1 event.election +0 AG 2 organization.company +1 Field Artillery Regiment 0 military +3 of Representatives elections in 3 event.election +2 railway station 0 location building +2 Inc. 0 organization.company +0 United States 2 government_agency +0 Ministry of 3 government_agency +6 – Women's 3 event.sports_event event +2 election, 2008 0 event.election +4 LLC 1 organization.company +3 railway station 0 building +1 Warmian-Masurian Voivodeship 0 location.city +1 Mens Football 1 organization.sports_team +4 Summer Olympics – Women's 3 event.sports_event +3 College, main campus 0 organization.educational_institution organization +2 Medical Center 0 building.hospital +2 Covered Bridge 0 location.bridge +0 Kingdom of 1 location.country +3 GmbH 2 organization.company +1 States House 6 event.election +4 Co. 1 organization.company +1 College of 1 organization.educational_institution +8 main campus 0 organization.educational_institution +1 States House of 5 event.election +2 House of Representatives elections 3 event.election +1 Mens National Football Team 0 organization.sports_team +2 election, 2007 0 event.election +2 basketball team 0 organization.sports_team +0 Corp. 0 organization.company +0 South African Class 2 train +3 LLC 1 organization.company +1 Police Department 0 government_agency military +1 Journal of 2 written_work +3 Inc. 0 organization.company +2 Infantry Regiment 0 military +1 Island Airport 0 building.airport +1 local elections, 1 event.election +0 Communist Party 2 government.political_party +4 LLC 0 organization.company +0 Arkansas Highway 1 transportation.road +1 AG 1 organization.company +4 Co. 2 organization.company +3 volleyball team 0 organization.sports_team +1 Hydroelectric Power 1 building.power_station +5 Olympics – Women's 2 event.sports_event +1 Lake Water Aerodrome 0 building.airport +1 National Soccer 1 organization.sports_team +4 Summer Olympics 4 event event.sports_event +1 United F.C. 0 organization.sports_team +0 Co. 0 organization.company +2 Poland Voivodeship 0 location.city +0 Alabama State Route 1 transportation.road +0 New York state 2 event.election +4 Summer Olympics – Men's 3 event event.sports_event +0 University of 1 organization.educational_institution organization +2 Corp. 2 organization.company +2 Wind Farm 0 building.power_station +0 Minnesota State 2 transportation.road +3 general election, 1 event.election +1 Memorial Hospital 0 building.hospital +2 College of 3 organization.educational_institution +3 Men's Basketball 0 organization.sports_team +1 District Council election, 1 event.election +0 Inc. 0 organization.company +1 War of 1 event.military_conflict +2 School of 2 organization.educational_institution +1 federal election, 1 event.election +6 – Men's 3 event.sports_event event +1 general election, 1 event.election event +0 United States Senate 5 event.election +0 National Highway 1 transportation.road +0 United Nations Security Council 2 law +1 eclipse of 3 event +0 United Nations 4 law +3 Technology, main 1 organization.educational_institution +1 Nations Security Council Resolution 1 law +1 High School, 2 organization.educational_institution +0 High Sheriff of 1 title +1 States House 7 event.election +4 Summer Olympics – 4 event.sports_event event +5 Ice Hockey 0 organization.sports_team +1 Mare River 0 location.body_of_water +1 College, main campus 0 organization organization.educational_institution organization.company +0 Japan National 2 transportation.road +0 New York 3 transportation.road event.election +4 class locomotive 0 train +5 - Singles 0 event.sports_event +2 election, 2002 0 event.election +0 Siege of 2 event.military_conflict +0 Lago di 1 location.body_of_water +0 China National 2 transportation.road +1 of the 2 art.film written_work event.military_conflict title +0 Parliament of 1 government.government +1 national basketball 1 organization.sports_team +0 Pennsylvania Route 1 transportation.road +1 Mens Soccer 1 organization.sports_team +3 AG 2 organization.company +3 Football Club 0 organization.sports_team +3 Volunteer Infantry 0 military +1 ship of 2 product.ship +1 Borough Council election, 1 event.election +3 – Women's 1 event event.sports_event +2 Secondary School 0 organization.educational_institution +1 Museum of 1 building +2 School District 0 organization +3 School District 0 organization +2 Community College 0 organization.educational_institution +1 Fighter Squadron 0 military +0 Ministry of 4 government_agency +1 at the 7 event event.sports_event +1 Nations Security 3 law +1 City Council 0 government.government +1 College of 2 organization.educational_institution +2 of Technology, main campus 0 organization.educational_institution +3 rugby union team 0 organization.sports_team +0 Tennessee State 2 transportation.road +1 Football Club 0 organization.sports_team +1 River Bridge 0 location.bridge +1 Lake Airport 0 building.airport +3 University, main 1 organization.educational_institution +2 Squadron RAF 0 military +1 parliamentary election, 1 event event.election +0 Swimming at 9 event.sports_event event +0 Maine State Route 1 transportation.road +0 Connecticut Route 1 transportation.road +1 States Senate election in 3 event.election +1 Inc. 1 organization.company +6 – Women's 2 event.sports_event +3 Council Resolution 1 law +3 Co. 0 organization.company +0 West Virginia Route 1 transportation.road +2 Airlines Flight 1 event.natural_disaster +0 Arizona State Route 1 transportation.road +1 York state election, 1 event.election +0 Nebraska Highway 1 transportation.road +1 Battalion, CEF 0 military +4 – Singles 0 event event.sports_event +4 Women's Singles 0 event event.sports_event +0 Party of 2 government.political_party +1 Public Library 0 building.library +1 Men's National Soccer Team 0 organization.sports_team +1 Federal Highway 1 transportation.road +3 Men's Football 0 organization.sports_team +1 Fighter Wing 0 military +1 State University, 2 organization.educational_institution +1 to Market Road 1 transportation.road +2 GmbH 2 organization.company +0 U.S. Route 3 transportation.road +0 High Sheriff 2 title +0 London Buses route 1 metropolitan_transit.transit_line +3 – Singles 0 event.sports_event event +1 Community College, main 1 organization.educational_institution +1 Carolina Highway 1 transportation.road +2 College of 2 organization.educational_institution +0 New York state election, 1 event.election +3 LLC 0 organization.company +1 Court of 1 government_agency +0 German submarine 1 product.ship +1 Australian Open 3 event.sports_event +1 Minister of 1 title +3 AG 0 organization.company +1 Men's Football Team 0 organization.sports_team +1 International School 0 organization.educational_institution +5 Olympics - Men's 2 event.sports_event event +0 Tropical Storm 1 event.natural_disaster +2 National Soccer Team 0 organization.sports_team +2 House of 5 event.election +1 LLC 2 organization.company +0 Massachusetts Route 1 transportation.road +0 Treaty of 1 law +5 Olympics – Women's 3 event.sports_event +0 Inc. 1 organization.company +5 Olympics – 3 event event.sports_event +2 Power Plant 0 building.power_station +1 Airlines Flight 1 event.attack event.natural_disaster +1 Democratic Party 2 government.political_party +3 rugby union 1 organization.sports_team +3 Infantry Regiment 0 military +1 Dakota Highway 1 transportation.road +5 main campus 0 organization.educational_institution organization +2 State Route 1 transportation.road +1 World Championships 6 event.sports_event event +0 Small nucleolar RNA 1 biology chemistry +0 Roman Catholic 3 location +3 in Athletics – 3 event.sports_event +0 Action of 3 event.military_conflict +2 Duke of 1 person.monarch +1 Community College, main campus 0 organization.educational_institution +3 College of 1 organization.educational_institution +0 Minister of 4 title +2 Championships - 2 event event.sports_event +2 School of 1 organization.educational_institution +4 LLC 2 organization.company +3 election, 2006 0 event.election +6 – Men's 2 event.sports_event event +0 United States Senate 4 event event.election +1 World Championships in Athletics 4 event.sports_event event +1 County Sheriff's Office 0 government_agency military +1 Metropolitan Borough 3 event.election +1 gubernatorial election, 1 event event.election +1 Valley Railway 0 rail.railway +1 Inc. 0 organization.company +0 Malaysia Federal Route 1 transportation.road +0 French frigate 1 product.ship +0 New York State Route 1 transportation.road +2 Municipal Airport 0 building.airport +0 New South 4 train +1 Regiment of 1 military +2 Championships in 6 event.sports_event +2 Public Library 0 building.library +1 Men's Football 1 organization.sports_team +1 regional election, 1 event.election +1 Football League 1 event +1 Men's National Football 1 organization.sports_team +0 Solar eclipse 4 event +2 Open - 1 event event.sports_event +1 of the 3 title +1 Virginia Route 1 transportation.road +2 rugby union 1 organization.sports_team +1 Power Station 0 building.power_station +3 Secondary School 0 organization.educational_institution +4 High School 0 organization.educational_institution +3 College, main 1 organization.educational_institution organization +1 President of 1 title +0 Malaysia Federal 2 transportation.road +3 AG 1 organization.company +1 Co. 0 organization.company +0 United States 8 government_agency government.government event.election +0 SS Empire 1 product.ship +1 National Football Team 0 organization.sports_team +1 Community College 0 organization.educational_institution +6 - Men's 3 event.sports_event +3 of Representatives elections, 1 event.election +1 Borough Council 2 event.election +3 Volunteer Cavalry 0 military +0 LLC 0 organization.company +1 States District Court 6 government.government government_agency +1 Corp. 0 organization.company +1 Men's Soccer 1 organization.sports_team +0 Ministry of 5 government_agency +1 at the 4 event +1 national rugby union 1 organization.sports_team +3 and Cemetery 0 location.cemetery +1 Regiment Kentucky Volunteer 1 military +3 County, Ohio 0 location.city +3 Court for the 4 government.government government_agency +0 County Route 1 transportation.road +3 - Men's 1 event.sports_event event +1 University of 4 organization.educational_institution +0 Mississippi Highway 1 transportation.road +1 States Ambassador to 1 title +0 Athletics at the 7 event event.sports_event +4 Act of 1 law +2 Security Council Resolution 1 law +3 Council election, 1 event.election +3 Mens Basketball 0 organization.sports_team +0 United States 3 event.election title +4 Ice Hockey 0 organization.sports_team +0 Nevada State Route 1 transportation.road +1 States Senate election in 2 event event.election +1 Football Federation 0 organization.sports_league +2 Squadron RAAF 0 military +2 main campus 0 organization.educational_institution location organization.company organization +1 AG 2 organization.company +5 Technology, main 1 organization.educational_institution +1 University of 1 organization.educational_institution +1 Community College, 2 organization.educational_institution +0 Virginia State Route 1 transportation.road +1 Esporte Clube 0 organization.sports_team +2 Soccer Team 0 organization.sports_team +0 Japanese destroyer 1 product.ship +1 National Football 1 organization.sports_team +4 Light Artillery 0 military +0 University of 5 organization.educational_institution organization.sports_team +1 Regional Airport 0 building.airport +2 Democratic Party 0 government.political_party +1 County, China 0 location.county +2 School, main campus 0 organization.educational_institution +0 PKP class 1 train +0 Maryland Route 1 transportation.road +1 State University, main campus 0 organization.educational_institution +2 1st Baron 1 person.politician +3 Earl of 1 person.politician +3 Technology, main campus 0 organization.educational_institution +0 Minnesota State Highway 1 transportation.road +3 in Athletics 5 event.sports_event +2 Hockey League 0 organization.sports_league +1 Covered Bridge 0 location.bridge +0 Battle of Fort 1 event.military_conflict +4 Summer Olympics – 3 event.sports_event event +1 Metropolitan Borough Council 2 event.election +2 election, 2004 0 event.election +5 Olympics - Men's 3 event.sports_event +0 Washington State 2 transportation.road +1 Davis Cup team 0 organization.sports_team +1 Ministry of 2 government_agency +1 College, main 1 organization.educational_institution organization organization.company +1 Lower Silesian 1 location.city +1 Infantry Brigade 0 military +3 – Men's Singles 0 event.sports_event event +2 in the 1 written_work +1 Air Force 1 building.airport +1 Party of 1 government.political_party +3 – Men's 1 event.sports_event event +2 House of Representatives elections 4 event.election +1 Infantry Regiment 0 military +2 House of Representatives 5 event.election +2 Championships in Athletics – 3 event.sports_event +1 Indian Infantry Brigade 0 military +0 Ontario Highway 1 transportation.road +4 Athletics – 3 event.sports_event +1 Nuclear Power 1 building.power_station +1 Airlift Squadron 0 military +0 SNCF Class 2 train +0 New York State 2 transportation.road +0 Inc. 2 organization.company +2 national volleyball 1 organization.sports_team +1 States Senate election 3 event event.election +2 Open – Singles 0 event.sports_event event +1 Grammar School 0 organization.educational_institution +2 Training Squadron 0 military +2 Open - 2 event.sports_event event +0 French ship 1 product.ship +0 New Jersey Route 1 transportation.road +5 Olympics – Men's 2 event event.sports_event +1 LLC 1 organization.company +1 Wind Farm 0 building.power_station +1 High School 0 organization organization.educational_institution +3 of Representatives 5 event.election +0 Siege of 1 event.military_conflict event +4 Representatives elections 3 event.election +2 LLC 0 organization.company +1 Battle of 1 event.military_conflict +4 AG 2 organization.company +0 United Nations Security 3 law +1 GmbH 1 organization.company +0 Nova Scotia Route 1 transportation.road +0 United States House of 6 event.election +3 – Doubles 0 event.sports_event event +0 Mexican Federal Highway 1 transportation.road +1 Ministry of 1 government_agency +1 Football League 0 organization.sports_league +1 First Nation 0 people.ethnicity +2 Co. 1 organization.company +1 South Wales 3 train +2 National Soccer 1 organization.sports_team +3 Co. 1 organization.company +1 York State 2 transportation.road +2 Ambassador to 1 title +1 of Fort 1 event.military_conflict +0 United States 7 event.election +1 Mens Soccer Team 0 organization.sports_team +0 Arizona State 2 transportation.road +6 - Men's 2 event event.sports_event +2 Football League 0 organization.sports_league +0 LLC 1 organization.company +1 Metropolitan Borough Council election, 1 event.election +3 International Airport 0 building.airport +1 Rail Class 1 train +0 United States Senate election 4 event.election +0 United States District Court 6 government.government government_agency +3 Volunteer Infantry Regiment 0 military +3 in Athletics - 3 event.sports_event +0 West Virginia 2 transportation.road +4 Men's Football 0 organization.sports_team +5 Olympics – 2 event.sports_event event +2 University of 3 organization.educational_institution +1 Department of 2 government_agency +7 District of 1 government_agency government.government +2 general election, 1 event.election event +3 1st Baronet 0 person.politician +1 to Market 2 transportation.road +4 Representatives elections in 2 event.election +2 Security Council 2 law +0 Colorado State Highway 1 transportation.road +1 National Soccer Team 0 organization.sports_team +2 AG 2 organization.company +1 national football team 0 organization.sports_team +0 Colorado State 2 transportation.road +1 District Council 2 event.election +1 York state 2 event.election +1 Mens National Football 1 organization.sports_team +0 Quebec Route 1 transportation.road +1 University of 2 organization.educational_institution +1 School of 1 organization.educational_institution +3 Football Team 0 organization.sports_team +2 Football Club 0 organization.sports_team +2 House of 3 event.election +1 Fed Cup team 0 organization.sports_team +5 elections in 3 event.election +0 Texas State 2 transportation.road +2 Force Base 0 building.airport +1 District, Hokkaido 0 location.county +4 – Doubles 0 event event.sports_event +2 Grand Prix 0 event event.sports_event +3 football team 0 organization.sports_team +2 GmbH 0 organization.company +0 North Carolina 2 transportation.road +1 States Ambassador 2 title +1 Mens National 2 organization.sports_team +0 Duke of 1 title +3 Corp. 0 organization.company +3 LLC 2 organization.company +4 International Airport 0 building.airport +4 Summer Olympics – 2 event event.sports_event +1 Illinois Volunteer Infantry 1 military +1 Medical Center 0 building.hospital +1 Federal Route 1 transportation.road +1 County / 3 location.city location +3 of Representatives elections in 2 event.election +1 Party of 2 government.political_party +0 Farm to Market 2 transportation.road +2 Open – Men's 1 event.sports_event +4 Representatives elections in 3 event.election +2 Football Team 0 organization.sports_team +2 of the 1 music game broadcast_program art.film written_work product.ship +3 School, main campus 0 organization.educational_institution +1 Air Base 0 building.airport +1 Democratic Party 0 government.political_party +3 Court for 5 government.government government_agency +0 United States District 7 government.government government_agency +2 House of Representatives 4 event.election +0 GmbH 2 organization.company +0 University of 2 organization.sports_team organization.educational_institution +1 State Highway 1 transportation.road +0 Indiana State Road 1 transportation.road +1 Co. 2 organization.company +0 U.S. Route 1 transportation.road +5 Olympics – 4 event.sports_event event +9 metre freestyle 0 event.sports_event +4 Inc. 1 organization.company +3 College of 3 organization.educational_institution +0 Solar eclipse of 3 event +2 Open – Women's 1 event.sports_event +3 – Women's Singles 0 event event.sports_event +2 Kentucky Volunteer 1 military +1 States House of 6 event.election +0 Ohio State Route 1 transportation.road +0 Second Battle of 1 event.military_conflict +4 main campus 0 location organization.educational_institution organization.company organization +0 Communist Party 3 government.political_party +1 LLC 0 organization.company +2 Mens Basketball 0 organization.sports_team +3 of Representatives 4 event.election +1 Act of 1 law +1 County Airport 0 building.airport +2 College, main 1 organization.educational_institution organization +2 Community College, main campus 0 organization.educational_institution +1 Sign Language 0 language +2 election, 2010 0 event.election +0 California State 2 transportation.road +0 Alberta Highway 1 transportation.road +0 Farm to Market Road 1 transportation.road +2 Senate election in 2 event event.election +0 Prime Minister of 1 title +1 College of 3 organization.educational_institution +2 Senate election 3 event event.election +2 state election, 1 event.election +1 III of 1 person.monarch +1 Field Artillery 1 military +1 State University, main 1 organization.educational_institution +3 - Women's Singles 0 event.sports_event +1 States House of Representatives 2 event.election +1 Operations Group 0 military +0 United States 6 event.election +2 Refueling Squadron 0 military +2 Regional Airport 0 building.airport +3 Football League 0 organization.sports_league +1 national rugby 2 organization.sports_team +1 ship of the line 0 product.ship +4 Mens Football 0 organization.sports_team +1 II of 1 person.monarch +1 state election, 1 event.election +0 Washington State Route 1 transportation.road +1 States Senate 4 event event.election +2 Halifax Regional 1 location.body_of_water +3 High School 0 organization.educational_institution organization +1 Department of 3 government_agency +1 High School, main campus 0 organization.educational_institution +1 States House of Representatives 5 event.election +0 Earl of 1 title +2 cricket team 0 organization.sports_team +3 of Representatives elections 4 event.election +0 Indiana State 2 transportation.road +1 Democratic Party of 1 government.political_party +2 Mens Football 0 organization.sports_team +1 University of 5 organization.educational_institution +1 County Courthouse 0 building +3 School of 1 organization.educational_institution +2 of Technology, main 1 organization.educational_institution +0 Athletics at 9 event event.sports_event +1 University of 3 organization.educational_institution organization +1 School of 2 organization.educational_institution +0 New Hampshire 2 transportation.road +1 Cricket Club 0 organization.sports_team +0 Florida State Road 1 transportation.road +0 Capture of 1 event.military_conflict +0 First Battle 2 event.military_conflict +1 Indiana Infantry Regiment 0 military +4 GmbH 0 organization.company +3 School, main 1 organization.educational_institution +2 District Court 6 government.government government_agency +0 United States House 6 event.election +1 Davis Cup 1 organization.sports_team +4 Summer Olympics 0 event +2 Championships in Athletics 4 event.sports_event event +2 GmbH 1 organization.company +1 rail crash 0 event.natural_disaster +1 States Senate election 4 event.election +0 New Jersey 2 transportation.road +0 Bishop of 1 title +1 Institute of 2 organization.educational_institution +0 Battle of 4 event.military_conflict +4 Representatives elections, 1 event.election +1 National Highway 1 transportation.road +1 Men's Soccer Team 0 organization.sports_team +5 Olympics – Men's 3 event.sports_event event +3 Corp. 1 organization.company +0 British Rail Class 1 train +3 election in 3 event.election +2 Borough Council election, 1 event.election +0 Battle of 3 event.military_conflict +1 Pomeranian Voivodeship 0 location.city +0 Battle of the 2 event.military_conflict +2 Sheriff's Office 0 military government_agency +1 People's Party 0 government.political_party +0 Order of 1 title +1 County / 2 location location.city +0 Georgia State Route 1 transportation.road +3 GmbH 0 organization.company +2 Men's Basketball 0 organization.sports_team +4 Summer Olympics 3 event event.sports_event +1 Mic River 0 location.body_of_water +1 Institute of 1 organization.educational_institution +1 Party of 3 government.political_party +1 Wisconsin Volunteer 2 military +0 Tennessee State Route 1 transportation.road +1 States District Court for 5 government.government government_agency +1 national futsal 1 organization.sports_team +2 Men's Football 0 organization.sports_team +1 Air Expeditionary 1 military +0 European route 1 transportation.road +2 High School, main 1 organization.educational_institution +1 State University 3 organization.sports_team +4 hockey team 0 organization.sports_team +2 election, 2009 0 event.election +1 national football 1 organization.sports_team +4 Inc. 2 organization.company +1 Puerto Rico 0 location.county +1 ship of the 1 product.ship +1 Sheriff of 1 title +0 Journal of 2 written_work +4 and Technology 0 organization.educational_institution +2 LLC 2 organization.company +2 at the 6 event.sports_event +1 Regiment Kentucky 2 military +1 African Class 2 train +1 Fed Cup 1 organization.sports_team +1 Air Defense 1 military +2 University, main 1 organization.educational_institution organization +1 High School, main 1 organization.educational_institution +3 Film Festival 0 event +0 Japan National Route 1 transportation.road +3 School of 3 organization.educational_institution diff --git a/finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/FinerResourceUpload.java b/finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/FinerResourceUpload.java new file mode 100644 index 000000000..bb970f18e --- /dev/null +++ b/finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/FinerResourceUpload.java @@ -0,0 +1,37 @@ +package edu.illinois.cs.cogcomp.finetyper; + +import io.minio.errors.InvalidEndpointException; +import io.minio.errors.InvalidPortException; +import org.cogcomp.Datastore; +import org.cogcomp.DatastoreException; + +import java.io.File; + +import static org.junit.Assert.*; + +/** + * Created by haowu4 on 2/7/18. + */ +public class FinerResourceUpload { + public static void main(String[] args) throws InvalidPortException, InvalidEndpointException, DatastoreException { + String accessKey = "7BDP8NOBCLRHDENUDZ1H"; + String secretKey = "zkTS6t8OsmXuVHqClpDMlwaG6wKvLy/uKz3aDUbL"; + String serverAddress = "http://127.0.0.1:9000"; + + String baseFolder = "/data/fine-tpying-package"; + + Datastore datastore = new Datastore(serverAddress, accessKey, secretKey); + String[] toupload = new String[]{ + FinerResource.WORD_EMBEDDING_TAR_GZ, + FinerResource.SENSE_EMBEDDING_TAR_GZ, + FinerResource.KB_BIAS_RESOURCE_TAR_GZ, + FinerResource.WORD_POS_TO_SENSE_TAR_GZ, + FinerResource.SYNSET2TYPE_TAR_GZ + }; + + for (String file : toupload) { + datastore.publishFile(FinerResource.FINER_RESOURCE_GROUP_ID, file, 1.0, new File(baseFolder, file).getAbsolutePath()); + } + + } +} \ No newline at end of file diff --git a/finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/TestFiger.java b/finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/TestFiger.java new file mode 100644 index 000000000..d3c91e05c --- /dev/null +++ b/finetyper/src/test/java/edu/illinois/cs/cogcomp/finetyper/TestFiger.java @@ -0,0 +1,113 @@ +package edu.illinois.cs.cogcomp.finetyper; + +import edu.illinois.cs.cogcomp.annotation.AnnotatorException; +import edu.illinois.cs.cogcomp.annotation.BasicAnnotatorService; +import edu.illinois.cs.cogcomp.annotation.BasicTextAnnotationBuilder; +import edu.illinois.cs.cogcomp.core.datastructures.ViewNames; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.Constituent; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.TextAnnotation; +import edu.illinois.cs.cogcomp.core.datastructures.textannotation.View; +import edu.illinois.cs.cogcomp.core.utilities.configuration.ResourceManager; +import edu.illinois.cs.cogcomp.finetyper.finer.FinerAnnotator; +import edu.illinois.cs.cogcomp.finetyper.finer.FinerTyperFactory; +import edu.illinois.cs.cogcomp.finetyper.finer.datastructure.types.TypeSystem; +import edu.illinois.cs.cogcomp.finetyper.wsd.WordSenseAnnotator; +import edu.illinois.cs.cogcomp.finetyper.wsd.math.FloatDenseVector; +import edu.illinois.cs.cogcomp.pipeline.main.PipelineFactory; +import org.apache.commons.io.FileUtils; +import org.apache.commons.io.LineIterator; +import org.cogcomp.DatastoreException; + +import java.io.*; +import java.util.ArrayList; +import java.util.List; +import java.util.Properties; + + +/** + * Created by haowu4 on 1/31/17. + */ +public class TestFiger { + + public static void printColumn(TextAnnotation ta) { + View view = ta.getView(ViewNames.FINE_NER_TYPE); + String[] tokens = ta.getTokens(); + String[] bios = new String[tokens.length]; + String[] types = new String[tokens.length]; + + for (int i = 0; i < tokens.length; i++) { + bios[i] = "O"; + types[i] = null; + } + for (Constituent c : view.getConstituents()) { + for (int j = c.getStartSpan(); j < c.getEndSpan(); j++) { + bios[j] = "I"; + types[j] = String.join(",", c.getLabelsToScores().keySet()); + } + + bios[c.getStartSpan()] = "B"; + } + + for (int i = 0; i < tokens.length; i++) { + String label = "O"; + if (null != types[i]) { + label = String.format("%s-%s", bios[i], types[i]); + } + System.out.println(String.format("%s\t%s", tokens[i], label)); + } + } + + public static List loadFigers() throws + IOException, AnnotatorException { + List sentences = new ArrayList<>(); + List tas = new ArrayList<>(); + + try (BufferedReader br = new BufferedReader( + new InputStreamReader( + ClassLoader.getSystemResourceAsStream("finer_resource/figer.xiang.label")))) { + String line; + BasicAnnotatorService bas = PipelineFactory.buildPipeline(ViewNames.POS, ViewNames.NER_ONTONOTES); + while ((line = br.readLine()) != null) { + line = line.trim(); + if (line.isEmpty()) { + List doc = new ArrayList<>(); + String[] x = new String[sentences.size()]; + for (int i = 0; i < sentences.size(); i++) { + x[i] = sentences.get(i); + } + doc.add(x); + TextAnnotation ta = BasicTextAnnotationBuilder + .createTextAnnotationFromTokens(doc); + ta = bas.annotateTextAnnotation(ta, false); + ta.getView(ViewNames.POS); + ta.getView(ViewNames.NER_ONTONOTES); + tas.add(ta); + sentences = new ArrayList<>(); + } else { + String w = line.split("\t")[0]; + sentences.add(w); + } + } + } catch (IOException e) { + e.printStackTrace(); + } + + + return tas; + } + + public static void main(String[] args) throws IOException, + AnnotatorException, DatastoreException { + List inputs = loadFigers(); + WordSenseAnnotator wsd = new WordSenseAnnotator(ViewNames.FINE_NER_TYPE_WSD, new ResourceManager(new Properties())); + FinerTyperFactory factory = new FinerTyperFactory(); + FinerAnnotator finer = factory.getAnnotator(); + for (TextAnnotation ta : inputs) { + wsd.addView(ta); + finer.addView(ta); + printColumn(ta); + System.out.println(); + } + + } +}