lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robin Woods <woods4s...@gmail.com>
Subject UnifiedHighlighter not respecting hl.fragsize?
Date Thu, 02 Aug 2018 09:59:07 GMT
Hi,

I'm trying to use UnifiedHighlighter with Solr 7.4.0 and it seem's it's not
respecting the hl.fragsize param?

I'm expecting the snippet length shouldn't be more than the hl.fragsize
value, is that correct?

query time params:
"hl": "on",
"hl.method": "unified"
"hl.offsetSource": "POSTINGS"
"hl.fragsize": "50",
"hl.snippets": "1",
"hl.q":"+funny+comic+characters",
"hl.fl":"contents",
"q": "id:1234",

Field definitions are

<field name="contents" type="myContent"  indexed="true"  stored="true"
 multiValued="true" required="false"
storeOffsetsWithPositions="true"/>

<fieldType name="myContent" class="solr.TextField" positionIncrementGap="0">
  <analyzer type="index">
    <charFilter class="solr.PatternReplaceCharFilterFactory"
pattern="[\'\u2019]" replacement=""/>
    <tokenizer class="solr.WhitespaceTokenizerFactory"/>
    <filter class="solr.WordDelimiterFilterFactory"
            generateWordParts="1"
            generateNumberParts="1"
            catenateWords="0"
            catenateNumbers="0"
            catenateAll="0"
            preserveOriginal="0"
            splitOnCaseChange="1"
            splitOnNumerics="1"
            stemEnglishPossessive="0"
            types="text_delimiters.txt"
    />
    <filter class="solr.ASCIIFoldingFilterFactory"/>
    <filter class="solr.LowerCaseFilterFactory"/>
    <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt"
expand="true"/>
    <filter class="solr.SnowballPorterFilterFactory" language="English"/>
    <filter class="solr.RemoveDuplicatesTokenFilterFactory" />
  </analyzer>
  <analyzer type="query">
    <tokenizer class="solr.WhitespaceTokenizerFactory"/>
    <filter class="solr.ASCIIFoldingFilterFactory"/>
    <filter class="solr.LowerCaseFilterFactory"/>
    <filter class="solr.SnowballPorterFilterFactory" language="English"/>
  </analyzer>
  <similarity class="solr.BM25SimilarityFactory">
    <float name="k1">1.2</float>
    <float name="b">0.0</float>
  </similarity>
</fieldType>

What am I missing here?

Thanks

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