public class SimilarityModel extends Object implements TestSimilarityModel, TrainSimilarityModel
Modifier and Type | Method and Description |
---|---|
double |
compatible(Context mention1,
Context mention2)
Returns a number between 0 and 1 which represents the models belief that the specified mentions are compatible.
|
static void |
main(String[] args) |
void |
setExtents(Context[] extentContexts)
Creates simialrity training pairs based on the specified extents.
|
static TestSimilarityModel |
testModel(String name) |
void |
trainModel()
Train a model based on the previously supplied evidence.
|
static TrainSimilarityModel |
trainModel(String name) |
public static TestSimilarityModel testModel(String name) throws IOException
IOException
public static TrainSimilarityModel trainModel(String name) throws IOException
IOException
public void setExtents(Context[] extentContexts)
TrainSimilarityModel
setExtents
in interface TrainSimilarityModel
public double compatible(Context mention1, Context mention2)
compatible
in interface TestSimilarityModel
mention1
- The first mention to be considered.mention2
- The second mention to be considered.public void trainModel() throws IOException
trainModel
in interface TrainSimilarityModel
IOException
setExtents(Context[])
public static void main(String[] args) throws IOException
IOException
Copyright © 2018 The Apache Software Foundation. All rights reserved.