Examples of realise()


Examples of org.mindswap.pellet.owlapi.Reasoner.realise()

    OWLIndividual Remus = Individual( ns + "Remus" );
    OWLIndividual Romulus = Individual( ns + "Romulus" );

    for( int test = 0; test < 2; test++ ) {
      if( test != 0 )
        reasoner.realise();

      assertTrue( reasoner.hasObjectPropertyRelationship( Abel, sibling, Cain ) );

      assertIteratorValues( reasoner.getRelatedIndividuals( Abel, sibling ).iterator(),
          new Object[] { Cain } );
View Full Code Here

Examples of org.mindswap.pellet.owlapi.Reasoner.realise()

    OWLIndividual Bob = Individual( ns + "Bob" );
    OWLIndividual Charlie = Individual( ns + "Charlie" );

    for( int test = 0; test < 1; test++ ) {
      if( test != 0 )
        reasoner.realise();

      assertIteratorValues( reasoner.getIndividuals( DreamTeamMember, false ).iterator(),
          new Object[] { Alice, Bob, Charlie } );

      assertIteratorValues( reasoner.getIndividuals( DreamTeamMember1, false ).iterator(),
View Full Code Here

Examples of simplenlg.realiser.english.Realiser.realise()

    // create a realiser.  Note that a lexicon is specified, this should be
    // the same one used by the NLGFactory
    Realiser realiser = new Realiser(lexicon);
    //realiser.setDebugMode(true);     // uncomment this to print out debug info during realisation
    NLGElement realised = realiser.realise(paragraph);

    System.out.println(realised.getRealisation());

    // end of main example
   
View Full Code Here

Examples of simplenlg.realiser.english.Realiser.realise()

    // create InflectedWordElement from word element
    InflectedWordElement inflectedWord = new InflectedWordElement(word);
    // set the inflected word to plural
    inflectedWord.setPlural(true);
    // realise the inflected word
    String result = realiser.realise(inflectedWord).getRealisation();
   
    System.out.println(result);
  }
}
View Full Code Here

Examples of simplenlg.realiser.english.Realiser.realise()

    DocumentElement s2 = nlgFactory.createSentence( p2 ) ;
    DocumentElement s3 = nlgFactory.createSentence( p3 ) ;
   
    DocumentElement par1 = nlgFactory.createParagraph( Arrays.asList( s1, s2, s3 ) ) ;
   
    String output14a = realiser.realise( par1 ).getRealisation() ;
    Assert.assertEquals( "Mary chases the monkey. The monkey fights back. Mary is nervous.\n\n", output14a ) ;
    //   actual output ~  Mary chases the monkey. The monkey fights back. Mary is nervous.
    // So what exactly is JUnit not happy about?
    DocumentElement section = nlgFactory.createSection( "The Trials and Tribulation of Mary and the Monkey" ) ;
View Full Code Here

Examples of simplenlg.realiser.english.Realiser.realise()

    //   actual output ~  Mary chases the monkey. The monkey fights back. Mary is nervous.
    // So what exactly is JUnit not happy about?
    DocumentElement section = nlgFactory.createSection( "The Trials and Tribulation of Mary and the Monkey" ) ;
        section.addComponent( par1 ) ;
        String output14b = realiser.realise( section ).getRealisation() ;
        Assert.assertEquals( "The Trials and Tribulation of Mary and the Monkey\nMary chases the monkey. The monkey fights back. Mary is nervous.\n\n", output14b ) ;
  } // testSection14

} // class
View Full Code Here

Examples of simplenlg.realiser.english.Realiser.realise()

        DocumentElement t = w.UnwrapDocumentElement(wt);
        if (t != null) {
          Realiser r = new Realiser(lexicon);
          r.initialise();

          NLGElement tr = r.realise(t);

          output = tr.getRealisation();
        }

      } catch (Exception e) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.