lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lance Norskog <goks...@gmail.com>
Subject Re: need help on OpenNLP with Solr
Date Thu, 09 Jan 2014 23:33:25 GMT
There is no way to do these things with LUCENE-2899.


On Mon, Jan 6, 2014 at 8:07 AM, rashi gandhi <gandhirashi19@gmail.com>wrote:

> Hi,
>
>
>
> I have applied OpenNLP (LUCENE 2899.patch) patch to SOLR-4.5.1 for nlp
> searching and it is working fine.
>
> Also I have designed an analyzer for this:
>
> <fieldType name="nlp_type" class="solr.TextField"
> positionIncrementGap="100">
>
>   <analyzer type="index">
>
>         <tokenizer class="solr.OpenNLPTokenizerFactory"
> sentenceModel="opennlp/en-test-sent.bin"
>    tokenizerModel="opennlp/en-test-tokenizer.bin"/>
>
>                                 <filter class="solr.StopFilterFactory"
> ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true"/>
>
>                                 <filter class="solr.OpenNLPFilterFactory"
> posTaggerModel="opennlp/en-pos-maxent.bin"/>
>
>                                 <filter class="solr.OpenNLPFilterFactory"
> nerTaggerModels="opennlp/en-ner-person.bin"/>
>
>                                 <filter class="solr.OpenNLPFilterFactory"
> nerTaggerModels="opennlp/en-ner-location.bin"/>
>
>                                 <filter
> class="solr.LowerCaseFilterFactory"/>
>
>                                 <filter
> class="solr.SnowballPorterFilterFactory"/>
>
>    </analyzer>
>
>    <analyzer type="query">
>
>         <tokenizer class="solr.OpenNLPTokenizerFactory"
> sentenceModel="opennlp/en-test-sent.bin" tokenizerModel
> ="opennlp/en-test-tokenizer.bin"/>
>
>                                 <filter class="solr.StopFilterFactory"
> ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true"/>
>
>                                 <filter class="solr.OpenNLPFilterFactory"
> posTaggerModel="opennlp/en-pos-maxent.bin"/>
>
>                                 <filter class="solr.OpenNLPFilterFactory"
> nerTaggerModels="opennlp/en-ner-person.bin"/>
>
>                                 <filter class="solr.OpenNLPFilterFactory"
> nerTaggerModels="opennlp/en-ner-location.bin"/>
>
>                                 <filter
> class="solr.LowerCaseFilterFactory"/>
>
>                                 <filter
> class="solr.SnowballPorterFilterFactory"/>
>
>    </analyzer>
>
> </fieldType>
>
>
> I am able to find that posTaggerModel is performing tagging in the phrases
> and add the payloads. ( but iam not able to analyze it)
>
> My Question is:
> Can i search a phrase giving high boost to NOUN then VERB ?
> For example: if iam searching "sitting on blanket" , so i want to give high
> boost to NOUN term first then VERB, that are tagged by OpenNLP.
> How can i use payloads for boosting?
> What are the changes required in schema.xml?
>
> Please provide me some pointers to move ahead
>
> Thanks in advance
>



-- 
Lance Norskog
goksron@gmail.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message