Index: trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/SlidingCoherenceDisambiguatorTest.java |
— | — | @@ -19,7 +19,7 @@ |
20 | 20 | } |
21 | 21 | |
22 | 22 | public void testDisambiguateTerms() throws PersistenceException { |
23 | | - SlidingCoherenceDisambiguator disambiguator = new SlidingCoherenceDisambiguator(meaningFetcher, featureFetcher); |
| 23 | + SlidingCoherenceDisambiguator disambiguator = new SlidingCoherenceDisambiguator(meaningFetcher, featureFetcher, 10); |
24 | 24 | disambiguator.setInitialWindow(1); |
25 | 25 | disambiguator.setWindow(3); |
26 | 26 | |
— | — | @@ -43,7 +43,7 @@ |
44 | 44 | public void testDisambiguatePhraseNode() throws PersistenceException { |
45 | 45 | PhraseOccuranceSet set = getBankAndMonumentPhrases(); |
46 | 46 | |
47 | | - SlidingCoherenceDisambiguator disambiguator = new SlidingCoherenceDisambiguator(meaningFetcher, featureFetcher); |
| 47 | + SlidingCoherenceDisambiguator disambiguator = new SlidingCoherenceDisambiguator(meaningFetcher, featureFetcher, 10); |
48 | 48 | disambiguator.setTrace(traceOutput); |
49 | 49 | disambiguator.setInitialWindow(1); |
50 | 50 | disambiguator.setWindow(3); |
Index: trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/PopularityDisambiguatorTest.java |
— | — | @@ -21,7 +21,7 @@ |
22 | 22 | } |
23 | 23 | |
24 | 24 | public void testGetTermsForList() throws PersistenceException { |
25 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 25 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
26 | 26 | |
27 | 27 | Term uk = new Term("UK"); |
28 | 28 | Term london = new Term("London"); |
— | — | @@ -47,7 +47,7 @@ |
48 | 48 | |
49 | 49 | //FIXME: Test case for getHorizon |
50 | 50 | |
51 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 51 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
52 | 52 | |
53 | 53 | Collection<PhraseOccurance> terms = disambiguator.getTerms(set.getRootNode(), 0); |
54 | 54 | assertTrue("empty term set", sameElements( getBankAndMonumentTerms(0), terms) ); |
— | — | @@ -60,7 +60,7 @@ |
61 | 61 | } |
62 | 62 | |
63 | 63 | public void testGetMeaningsForList() throws PersistenceException { |
64 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 64 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
65 | 65 | |
66 | 66 | Term uk = new Term("UK"); |
67 | 67 | Term london = new Term("London"); |
— | — | @@ -79,7 +79,7 @@ |
80 | 80 | } |
81 | 81 | |
82 | 82 | public void testGetMeaningsForNode() throws PersistenceException { |
83 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 83 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
84 | 84 | |
85 | 85 | PhraseOccuranceSet set = getBankAndMonumentPhrases(); |
86 | 86 | Map<PhraseOccurance, List<? extends LocalConcept>> res = disambiguator.getMeanings(set.getRootNode()); |
— | — | @@ -94,7 +94,7 @@ |
95 | 95 | } |
96 | 96 | |
97 | 97 | public void testGetSequences() throws PersistenceException { |
98 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 98 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
99 | 99 | PhraseOccuranceSet set = getBankAndMonumentPhrases(); |
100 | 100 | |
101 | 101 | Collection<List<PhraseOccurance>> res = disambiguator.getSequences(set.getRootNode(), 1); |
— | — | @@ -108,7 +108,7 @@ |
109 | 109 | } |
110 | 110 | |
111 | 111 | public void testDisambiguateTerms() throws PersistenceException { |
112 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 112 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
113 | 113 | |
114 | 114 | Term uk = new Term("UK"); |
115 | 115 | Term london = new Term("London"); |
— | — | @@ -127,7 +127,7 @@ |
128 | 128 | public void testDisambiguateNode() throws PersistenceException { |
129 | 129 | PhraseOccuranceSet set = getBankAndMonumentPhrases(); |
130 | 130 | |
131 | | - PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher); |
| 131 | + PopularityDisambiguator disambiguator = new PopularityDisambiguator(meaningFetcher, 10); |
132 | 132 | disambiguator.setTrace(traceOutput); |
133 | 133 | |
134 | 134 | Result<PhraseOccurance, LocalConcept> result = disambiguator.disambiguate(set.getRootNode(), null); |
Index: trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguatorTest.java |
— | — | @@ -25,7 +25,7 @@ |
26 | 26 | } |
27 | 27 | |
28 | 28 | public void testGetSequenceInterpretations() throws PersistenceException { |
29 | | - CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher); |
| 29 | + CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher, 10); |
30 | 30 | |
31 | 31 | Term uk = new Term("UK"); |
32 | 32 | Pair<Term, LocalConcept> uk_as_United_Kingdom = new Pair<Term, LocalConcept>(uk, getConcept("United_Kingdom")); |
— | — | @@ -89,7 +89,7 @@ |
90 | 90 | } |
91 | 91 | |
92 | 92 | public void testGetInterpretations() throws PersistenceException { |
93 | | - CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher); |
| 93 | + CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher, 10); |
94 | 94 | |
95 | 95 | Term uk = new Term("UK"); |
96 | 96 | Pair<Term, LocalConcept> uk_as_United_Kingdom = new Pair<Term, LocalConcept>(uk, getConcept("United_Kingdom")); |
— | — | @@ -120,7 +120,7 @@ |
121 | 121 | } |
122 | 122 | |
123 | 123 | public void testDisambiguateTerms() throws PersistenceException { |
124 | | - CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher); |
| 124 | + CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher, 10); |
125 | 125 | disambiguator.setTrace(traceOutput); |
126 | 126 | |
127 | 127 | List<Term> sequence = terms("UK", "London", "Underground", "Bank"); |
— | — | @@ -143,7 +143,7 @@ |
144 | 144 | public void testDisambiguatePhraseNode() throws PersistenceException { |
145 | 145 | PhraseOccuranceSet set = getBankAndMonumentPhrases(); |
146 | 146 | |
147 | | - CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher); |
| 147 | + CoherenceDisambiguator disambiguator = new CoherenceDisambiguator(meaningFetcher, featureFetcher, 10); |
148 | 148 | disambiguator.setTrace(traceOutput); |
149 | 149 | |
150 | 150 | Result<PhraseOccurance, LocalConcept> result = disambiguator.disambiguate(set.getRootNode(), null); |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/MeaningCache.java |
— | — | @@ -2,6 +2,7 @@ |
3 | 3 | |
4 | 4 | import java.util.ArrayList; |
5 | 5 | import java.util.Collection; |
| 6 | +import java.util.Collections; |
6 | 7 | import java.util.HashMap; |
7 | 8 | import java.util.List; |
8 | 9 | import java.util.Map; |
— | — | @@ -19,6 +20,7 @@ |
20 | 21 | protected List<MeaningCache<C>> stack; |
21 | 22 | |
22 | 23 | public Manager(MeaningFetcher<? extends C> root, int maxDepth) { |
| 24 | + if (root==null) throw new NullPointerException(); |
23 | 25 | this.stack = new ArrayList<MeaningCache<C>>(maxDepth+1); |
24 | 26 | this.maxDepth = maxDepth; |
25 | 27 | this.root = root; |
— | — | @@ -94,12 +96,15 @@ |
95 | 97 | } |
96 | 98 | } |
97 | 99 | |
98 | | - Map<X, List<? extends C>> parentMeanings = parent.getMeanings(todo); //XXX: ugly cast, generics are a pain |
99 | | - |
100 | | - meanings.putAll(parentMeanings); |
101 | | - |
102 | | - for (Map.Entry<X, List<? extends C>> e: parentMeanings.entrySet()) { |
103 | | - cache.put(e.getKey().getTerm(), e.getValue()); |
| 100 | + if (!todo.isEmpty()) { |
| 101 | + Map<X, List<? extends C>> parentMeanings = parent.getMeanings(todo); //XXX: ugly cast, generics are a pain |
| 102 | + meanings.putAll(parentMeanings); |
| 103 | + |
| 104 | + for (X t: todo) { |
| 105 | + List<? extends C> m = parentMeanings.get(t); |
| 106 | + if (m==null) m = Collections.emptyList(); |
| 107 | + cache.put(t.getTerm(), m); |
| 108 | + } |
104 | 109 | } |
105 | 110 | |
106 | 111 | return meanings; |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguator.java |
— | — | @@ -60,25 +60,35 @@ |
61 | 61 | protected Functor2.Double weightCombiner = ProductCombiner.instance; |
62 | 62 | protected Functor.Double weightBooster = SquareBooster.instance; |
63 | 63 | |
64 | | - public CoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher) { |
65 | | - this(meaningFetcher, featureFetcher, WikiWordConcept.theCardinality, |
66 | | - featureFetcher.getFeaturesAreNormalized() ? ScalarVectorSimilarity.<Integer>getInstance() : CosineVectorSimilarity.<Integer>getInstance()); //if pre-normalized, use scalar to calc cosin |
| 64 | + public CoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher, int cacheDepth) { |
| 65 | + this(meaningFetcher, featureFetcher, cacheDepth, null, null); |
67 | 66 | } |
68 | 67 | |
69 | | - public CoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher, Measure<WikiWordConcept> popularityMeasure, Similarity<LabeledVector<Integer>> sim) { |
70 | | - super(meaningFetcher); |
| 68 | + public CoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher, int cacheDepth, Measure<WikiWordConcept> popularityMeasure, Similarity<LabeledVector<Integer>> sim) { |
| 69 | + this( new MeaningCache.Manager<LocalConcept>(meaningFetcher, cacheDepth), |
| 70 | + new FeatureCache.Manager<LocalConcept, Integer>(featureFetcher, cacheDepth), |
| 71 | + popularityMeasure, sim ); |
| 72 | + } |
| 73 | + |
| 74 | + public CoherenceDisambiguator(MeaningCache.Manager<LocalConcept> meaningCacheManager, FeatureCache.Manager<LocalConcept, Integer> featureCacheManager, Measure<WikiWordConcept> popularityMeasure, Similarity<LabeledVector<Integer>> sim) { |
| 75 | + super(meaningCacheManager); |
71 | 76 | |
72 | | - if (popularityMeasure==null) throw new NullPointerException(); |
73 | | - if (sim==null) throw new NullPointerException(); |
74 | | - if (featureFetcher==null) throw new NullPointerException(); |
| 77 | + if (popularityMeasure==null) popularityMeasure = WikiWordConcept.theCardinality; |
| 78 | + if (sim==null) sim = featureCacheManager.getFeaturesAreNormalized() ? ScalarVectorSimilarity.<Integer>getInstance() : CosineVectorSimilarity.<Integer>getInstance(); //if pre-normalized, use scalar to calc cosin |
| 79 | + if (featureCacheManager==null) throw new NullPointerException(); |
75 | 80 | |
76 | | - this.featureCacheManager = new FeatureCache.Manager<LocalConcept, Integer>(featureFetcher, 10); //TODO: depth |
77 | | - this.popularityDisambiguator = new PopularityDisambiguator(meaningFetcher, popularityMeasure); |
| 81 | + this.featureCacheManager = featureCacheManager; |
| 82 | + this.popularityDisambiguator = new PopularityDisambiguator(meaningCacheManager, popularityMeasure); |
78 | 83 | |
79 | 84 | this.setPopularityMeasure(popularityMeasure); |
80 | 85 | this.setSimilarityMeasure(sim); |
81 | 86 | } |
82 | 87 | |
| 88 | + public FeatureCache.Manager<LocalConcept, Integer> getFeatureCacheManager() { |
| 89 | + return featureCacheManager; |
| 90 | + } |
| 91 | + |
| 92 | + |
83 | 93 | public Functor.Double getPopularityNormalizer() { |
84 | 94 | return popularityNormalizer; |
85 | 95 | } |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/AbstractDisambiguator.java |
— | — | @@ -10,6 +10,7 @@ |
11 | 11 | |
12 | 12 | import de.brightbyte.io.Output; |
13 | 13 | import de.brightbyte.util.PersistenceException; |
| 14 | +import de.brightbyte.wikiword.disambig.MeaningCache.Manager; |
14 | 15 | import de.brightbyte.wikiword.model.PhraseNode; |
15 | 16 | import de.brightbyte.wikiword.model.TermListNode; |
16 | 17 | import de.brightbyte.wikiword.model.TermReference; |
— | — | @@ -63,10 +64,18 @@ |
64 | 65 | |
65 | 66 | private Map<? extends T, C> meaningOverrides; |
66 | 67 | |
67 | | - public AbstractDisambiguator(MeaningFetcher<? extends C> meaningFetcher) { |
68 | | - if (meaningFetcher==null) throw new NullPointerException(); |
69 | | - this.meaningCacheManager = new MeaningCache.Manager<C>(meaningFetcher, 10); |
| 68 | + public AbstractDisambiguator(MeaningFetcher<? extends C> meaningFetcher, int cacheDepth) { |
| 69 | + this(new MeaningCache.Manager<C>(meaningFetcher, cacheDepth)); |
70 | 70 | } |
| 71 | + |
| 72 | + public AbstractDisambiguator(MeaningCache.Manager<C> meaningCacheManager) { |
| 73 | + if (meaningCacheManager==null) throw new NullPointerException(); |
| 74 | + this.meaningCacheManager = meaningCacheManager; |
| 75 | + } |
| 76 | + |
| 77 | + public MeaningCache.Manager<C> getMeaningCacheManager() { |
| 78 | + return meaningCacheManager; |
| 79 | + } |
71 | 80 | |
72 | 81 | public void setMeaningOverrides(Map<? extends T, C> overrideMap) { |
73 | 82 | this.meaningOverrides = overrideMap; |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/FeatureCache.java |
— | — | @@ -19,6 +19,7 @@ |
20 | 20 | protected List<FeatureCache<C, K>> stack; |
21 | 21 | |
22 | 22 | public Manager(FeatureFetcher<C, K> root, int maxDepth) { |
| 23 | + if (root==null) throw new NullPointerException(); |
23 | 24 | this.stack = new ArrayList<FeatureCache<C, K>>(maxDepth+1); |
24 | 25 | this.maxDepth = maxDepth; |
25 | 26 | this.root = root; |
— | — | @@ -38,6 +39,10 @@ |
39 | 40 | |
40 | 41 | return cache; |
41 | 42 | } |
| 43 | + |
| 44 | + public boolean getFeaturesAreNormalized() { |
| 45 | + return root.getFeaturesAreNormalized(); |
| 46 | + } |
42 | 47 | } |
43 | 48 | |
44 | 49 | protected FeatureFetcher<C, K> parent; |
— | — | @@ -77,9 +82,11 @@ |
78 | 83 | } |
79 | 84 | } |
80 | 85 | |
81 | | - Map<Integer, ConceptFeatures<C, K>> parentFeatures = parent.getFeatures(todo); |
82 | | - features.putAll(parentFeatures); |
83 | | - cache.putAll(parentFeatures); |
| 86 | + if (!todo.isEmpty()) { |
| 87 | + Map<Integer, ConceptFeatures<C, K>> parentFeatures = parent.getFeatures(todo); |
| 88 | + features.putAll(parentFeatures); |
| 89 | + cache.putAll(parentFeatures); |
| 90 | + } |
84 | 91 | |
85 | 92 | return features; |
86 | 93 | } |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/SlidingCoherenceDisambiguator.java |
— | — | @@ -25,14 +25,18 @@ |
26 | 26 | protected int window; |
27 | 27 | protected int initialWindow; |
28 | 28 | |
29 | | - public SlidingCoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher) { |
30 | | - this(meaningFetcher, featureFetcher, WikiWordConcept.theCardinality, |
31 | | - featureFetcher.getFeaturesAreNormalized() ? ScalarVectorSimilarity.<Integer>getInstance() : CosineVectorSimilarity.<Integer>getInstance(), //if pre-normalized, use scalar to calc cosin |
32 | | - 5, 5); |
| 29 | + public SlidingCoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher, int cacheDepth) { |
| 30 | + this(meaningFetcher, featureFetcher, cacheDepth, null, null, 5, 5); |
33 | 31 | } |
34 | 32 | |
35 | | - public SlidingCoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher, Measure<WikiWordConcept> popularityMeasure, Similarity<LabeledVector<Integer>> sim, int window, int initialWindow) { |
36 | | - super(meaningFetcher, featureFetcher, popularityMeasure, sim); |
| 33 | + public SlidingCoherenceDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, FeatureFetcher<LocalConcept, Integer> featureFetcher, int cacheDepth, Measure<WikiWordConcept> popularityMeasure, Similarity<LabeledVector<Integer>> sim, int window, int initialWindow) { |
| 34 | + this(new MeaningCache.Manager<LocalConcept>(meaningFetcher, cacheDepth), |
| 35 | + new FeatureCache.Manager<LocalConcept, Integer>(featureFetcher, cacheDepth), |
| 36 | + popularityMeasure, sim, window, initialWindow); |
| 37 | + } |
| 38 | + |
| 39 | + public SlidingCoherenceDisambiguator(MeaningCache.Manager<LocalConcept> meaningCacheManager, FeatureCache.Manager<LocalConcept, Integer> featureCacheManager, Measure<WikiWordConcept> popularityMeasure, Similarity<LabeledVector<Integer>> sim, int window, int initialWindow) { |
| 40 | + super(meaningCacheManager, featureCacheManager, popularityMeasure, sim); |
37 | 41 | |
38 | 42 | this.window = window; |
39 | 43 | this.initialWindow = initialWindow; |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/PopularityDisambiguator.java |
— | — | @@ -23,12 +23,16 @@ |
24 | 24 | protected Functor.Double weightBooster = SquareBooster.instance; |
25 | 25 | protected Functor2.Double weigthCombiner = new ProductCombiner(); //NOTE: pop and weight are not in the same scale. |
26 | 26 | |
27 | | - public PopularityDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher) { |
28 | | - this(meaningFetcher, WikiWordConcept.theCardinality); |
| 27 | + public PopularityDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, int cacheDepth) { |
| 28 | + this(meaningFetcher, cacheDepth, WikiWordConcept.theCardinality); |
29 | 29 | } |
30 | 30 | |
31 | | - public PopularityDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, Measure<WikiWordConcept> popularityMeasure) { |
32 | | - super(meaningFetcher); |
| 31 | + public PopularityDisambiguator(MeaningFetcher<LocalConcept> meaningFetcher, int cacheDepth, Measure<WikiWordConcept> popularityMeasure) { |
| 32 | + this(new MeaningCache.Manager<LocalConcept>(meaningFetcher, cacheDepth), popularityMeasure); |
| 33 | + } |
| 34 | + |
| 35 | + public PopularityDisambiguator(MeaningCache.Manager<LocalConcept> meaningCacheManager, Measure<WikiWordConcept> popularityMeasure) { |
| 36 | + super(meaningCacheManager); |
33 | 37 | |
34 | 38 | this.setPopularityMeasure(popularityMeasure); |
35 | 39 | } |
Index: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/query/QueryConsole.java |
— | — | @@ -451,7 +451,7 @@ |
452 | 452 | if (disambiguator==null) { |
453 | 453 | StoredMeaningFetcher meaningFetcher = new StoredMeaningFetcher(getLocalConceptStore()); |
454 | 454 | StoredFeatureFetcher<LocalConcept, Integer> featureFetcher = new StoredFeatureFetcher<LocalConcept, Integer>(getFeatureStore()); |
455 | | - disambiguator = new SlidingCoherenceDisambiguator( meaningFetcher, featureFetcher ); |
| 455 | + disambiguator = new SlidingCoherenceDisambiguator( meaningFetcher, featureFetcher, 10 ); //FIXME: cache depth from config |
456 | 456 | |
457 | 457 | LeveledOutput.Trace trace = new LeveledOutput.Trace(out); |
458 | 458 | meaningFetcher.setTrace(trace); |
Index: trunk/WikiWord/WikiWordBuilder/src/main/java/de/brightbyte/wikiword/extract/WordSenseIndexer.java |
— | — | @@ -83,7 +83,7 @@ |
84 | 84 | |
85 | 85 | StoredMeaningFetcher meaningFetcher = new StoredMeaningFetcher(getLocalConceptStore(), spec); |
86 | 86 | StoredFeatureFetcher<LocalConcept, Integer> featureFetcher = new StoredFeatureFetcher<LocalConcept, Integer>(getFeatureStore()); |
87 | | - disambiguator = new SlidingCoherenceDisambiguator( meaningFetcher, featureFetcher ); |
| 87 | + disambiguator = new SlidingCoherenceDisambiguator( meaningFetcher, featureFetcher, 10 ); //FIXME: cache depth from config |
88 | 88 | |
89 | 89 | Measure<WikiWordConcept> popularityMeasure = new Measure<WikiWordConcept>(){ //boost locations //FIXME: configure! |
90 | 90 | public double measure(WikiWordConcept concept) { |