use of infoeval.main.WikiData.WikiParsing in project Info-Evaluation by TechnionYP5777.
the class AnalyzeParagraph method LoadIEClassifiers.
public void LoadIEClassifiers() throws IOException {
// Load openIE classifiers
WikiParsing wiki = (new WikiParsing("https://en.wikipedia.org/wiki/Adele"));
wiki.Parse("won");
setParagraphsAwards(wiki.getParagraphs());
clearAwardsInformation();
AwardsQuery();
clearAwardsInformation();
}
use of infoeval.main.WikiData.WikiParsing in project Info-Evaluation by TechnionYP5777.
the class AnalyzeParagraphTest method Test1.
@Test
public void Test1() throws IOException {
WikiParsing wiki = (new WikiParsing("https://en.wikipedia.org/wiki/The_Weeknd"));
wiki.Parse("arrested");
AnalyzeParagraph analyze = new AnalyzeParagraph();
analyze.setParagraphsArrests(wiki.getParagraphs());
analyze.AnalyzeArrestsQuery();
assert (!analyze.getArrestsInformation().isEmpty());
}
use of infoeval.main.WikiData.WikiParsing in project Info-Evaluation by TechnionYP5777.
the class AnalyzeParagraphTest method Test2.
// This test is for the new method of awards query.(see issue #224)
@Test
public void Test2() throws IOException {
WikiParsing wiki = (new WikiParsing("https://en.wikipedia.org/wiki/Adele"));
wiki.Parse("won");
AnalyzeParagraph analyze = new AnalyzeParagraph();
analyze.setParagraphsAwards(wiki.getParagraphs());
analyze.AwardsQuery();
LinkedList<String> info = analyze.getAwardsInformation();
for (final String ¢ : info) // System.out.println(¢);
assert (info.contains(" At the 51st Grammy Awards in 2009, Adele received the awards for Best New Artist and Best Female Pop Vocal Performance"));
}
use of infoeval.main.WikiData.WikiParsing in project Info-Evaluation by TechnionYP5777.
the class WikiParsingTest method test4.
@Test
public void test4() throws IOException {
WikiParsing wp = new WikiParsing("https://en.wikipedia.org/wiki/Michael_Jackson");
wp.Parse("refer");
assert !wp.isConflictedName();
}
use of infoeval.main.WikiData.WikiParsing in project Info-Evaluation by TechnionYP5777.
the class WikiParsingTest method test8.
@Test
public void test8() throws IOException {
WikiParsing wp = new WikiParsing("https://en.wikipedia.org/wiki/Slash");
wp.Parse("married");
wp.CheckAmbiguities();
assert wp.getNames().size() == 28;
}
Aggregations