You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "Mark Miller (JIRA)" <ji...@apache.org> on 2008/08/11 19:58:46 UTC

[jira] Commented: (SOLR-575) Highlighting spans should merge across phrase query

    [ https://issues.apache.org/jira/browse/SOLR-575?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12621525#action_12621525 ] 

Mark Miller commented on SOLR-575:
----------------------------------

With the current API, I just don't see this happening. Tokens are given one at a time to be 'lit and returned - these formatted pieces are used to build up the fragments. Even trying to play tricks, I just don't think this issue is cleanly doable.

With an alternate approach (one that didn't hand off individual tokens for highlighting) its easy enough, but I don't see the approach changing soon.

It would almost be less of a hassle, if for some reason you really needed this, to just post process and merge continuous spans with regex or something. You still have the issue of stopwords that are not 'lit, etc but they are a lot easier to overcome than the API limitations of the Highlighter framework.

> Highlighting spans should merge across phrase query
> ---------------------------------------------------
>
>                 Key: SOLR-575
>                 URL: https://issues.apache.org/jira/browse/SOLR-575
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>    Affects Versions: 1.2
>            Reporter: Brian Whitman
>
> Somewhat related to but separate from SOLR-553,
> It would be nice if the highlighter component "joined" the formatter tags across an entire PhraseQuery.
> e.g. 
> Lights (Live) : <span>I</span> <span>Love</span> <span>You</span> But <span>I've</span> <span>Chosen</span> <span>Darkness</span> :
> should really be
> Lights (Live) : <span>I Love You But I've Chosen Darkness</span> :
> assuming the query that generated these fragments was "I Love You But I've Chosen Darkness"
> I assume there's issues with stopwords (the But in the name was not formatted)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.