Examples of analyseSentence()


Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()


    @Test
    public void testSingleSentenceDefaultConfig(){
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertTrue(analyzer.getConfig().isPosTaggerEnable());
        assertTrue(analyzer.getConfig().isPosTypeChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()

    @Test
    public void testSingleSentenceChunkerConfig(){
        TextAnalyzerConfig config = new TextAnalyzerConfig();
        config.forcePosTypeChunker(false);
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE,config);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertTrue(analyzer.getConfig().isPosTaggerEnable());
        assertTrue(analyzer.getConfig().isChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()

    @Test
    public void testSingleSentenceNoChunkerConfig(){
        TextAnalyzerConfig config = new TextAnalyzerConfig();
        config.enableChunker(false);
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE,config);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertTrue(analyzer.getConfig().isPosTaggerEnable());
        assertFalse(analyzer.getConfig().isChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()

    public void testSingleSentenceNoChunkerNoPosConfig(){
        TextAnalyzerConfig config = new TextAnalyzerConfig();
        config.enablePosTagger(false);
        config.enableChunker(true);//must be ignored for Chunks if no Pos
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE,config);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertFalse(analyzer.getConfig().isPosTaggerEnable());
        assertTrue(analyzer.getConfig().isChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()


    @Test
    public void testSingleSentenceDefaultConfig(){
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertTrue(analyzer.getConfig().isPosTaggerEnable());
        assertTrue(analyzer.getConfig().isPosTypeChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()

    @Test
    public void testSingleSentenceChunkerConfig(){
        TextAnalyzerConfig config = new TextAnalyzerConfig();
        config.forcePosTypeChunker(false);
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE,config);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertTrue(analyzer.getConfig().isPosTaggerEnable());
        assertTrue(analyzer.getConfig().isChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()

    @Test
    public void testSingleSentenceNoChunkerConfig(){
        TextAnalyzerConfig config = new TextAnalyzerConfig();
        config.enableChunker(false);
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE,config);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertTrue(analyzer.getConfig().isPosTaggerEnable());
        assertFalse(analyzer.getConfig().isChunkerEnabled());
View Full Code Here

Examples of org.apache.stanbol.commons.opennlp.TextAnalyzer.analyseSentence()

    public void testSingleSentenceNoChunkerNoPosConfig(){
        TextAnalyzerConfig config = new TextAnalyzerConfig();
        config.enablePosTagger(false);
        config.enableChunker(true);//must be ignored for Chunks if no Pos
        TextAnalyzer analyzer = new TextAnalyzer(openNLP,LANGUAGE,config);
        AnalysedText analysed = analyzer.analyseSentence(SINGLE_SENTENCE);
        assertNotNull(analysed);
        //check the default config
        assertFalse(analyzer.getConfig().isSimpleTokenizerForced());
        assertFalse(analyzer.getConfig().isPosTaggerEnable());
        assertTrue(analyzer.getConfig().isChunkerEnabled());
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.