Re: [External] Re: How to highlight fields that are not stored?

2023-02-16 Thread Shifflett, David [USA]
indexing. I would be happy to be directed to another way to get 2+ GB files indexed. > highlighting requires > the document in its uninverted form. Otherwise what text would you > highlight? Highlighting the, possibly changed, terms from the index is my goal if I can't store the entir

Re: How to highlight fields that are not stored?

2023-02-16 Thread Michael Sokolov
uninverted form. Otherwise what text would you highlight? On Mon, Feb 13, 2023 at 3:46 PM Shifflett, David [USA] wrote: > > Hi, > I am converting my application from > reading documents into memory, then indexing the documents > to streaming the documents to be indexed. &g

How to highlight fields that are not stored?

2023-02-13 Thread Shifflett, David [USA]
Hi, I am converting my application from reading documents into memory, then indexing the documents to streaming the documents to be indexed. I quickly found out this required that the field NOT be stored. I then quickly found out that my highlighting code requires the field to

How to highlight and fragment Multi-value field

2016-12-11 Thread V. Svetov
Hi all How to provide highlighting for fragmented string which is created from multi-value field using Lucene 5.3.2 ? Is any known solution for it? 1. Or first approach - merge all multi-value into one single value and apply highlighter.getBestTextFragments(tokenStream, text, false, maxNumFragm

Re: Only highlight terms that caused a search hit/match

2014-02-19 Thread Steve Davids
sively, the branches of the query tree were getting trimmed as expected. This actually worked great for the simple "a OR (b AND z)" case! Though, the entire thing came to a grinding halt with the realization that I needed to continue to support other fielded searches. When attempting to high

RE: Only highlight terms that caused a search hit/match

2014-02-16 Thread Rose, Stuart J
x27;, but might have matched for the wrong reason and therefore have mismatched highlighting. Stuart -Original Message- From: Michael McCandless [mailto:luc...@mikemccandless.com] Sent: Saturday, February 15, 2014 2:54 AM To: Lucene Users Cc: sdav...@gmail.com Subject: Re: Only highl

Re: Only highlight terms that caused a search hit/match

2014-02-15 Thread Michael McCandless
Unfortunately, all Lucene's highlighters are "approximate" in this regard: there is no guarantee that the shown snippets, if they were a single little document, would have matched the query. Even the newest highlighter, PostingsHighlighter, doesn't look at positions, e.g. a P

Only highlight terms that caused a search hit/match

2014-02-14 Thread Steve Davids
Hello, I have recently been given a requirement to improve document highlights within our system. Unfortunately, the current functionality gives more of a best-guess on what terms to highlight vs the actual terms to highlight that actually did perform the match. A couple examples of issues

Re: Phrase highlight

2013-11-26 Thread Koji Sekiguchi
score); ht.setTextFragmenter(new NullFragmenter()); markedString = ht.getBestFragment(ctf, myText); However, if myQuery has a phrase like "john smith", then it will highlight "john" every place it sees it and "smith" everyplace it sees it regardless of w

Phrase highlight

2013-11-26 Thread Scott Smith
enter()); markedString = ht.getBestFragment(ctf, myText); However, if myQuery has a phrase like "john smith", then it will highlight "john" every place it sees it and "smith" everyplace it sees it regardless of whether they are together. Is this expected

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-22 Thread Michael McCandless
the document. > > In that document ,i need to highlight only the first sentence which > matches the search query "Android".say in first page. > > is it possible to use PostingsHighlighter to acheive this functionality. Yes. PostingsHighlighter lets you specify your own P

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-22 Thread VIGNESH S
Hi Mike, I am indexing at the document level that is full book to a field.For Example iam indexing the full book which contains some term say Android at the first page,last page. when i do a search,I will get the document. In that document ,i need to highlight only the first sentence which

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-18 Thread Michael McCandless
gt; > Sentence as highlighted text whether the sentence contains Searched >> keyword >> > or not.. >> > >> > >> > >> > >> > On Wed, Jul 17, 2013 at 3:48 PM, VIGNESH S >> wrote: >> > >> >> >> >> Hi

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-17 Thread VIGNESH S
ighlighted text whether the sentence contains Searched > keyword > > or not.. > > > > > > > > > > On Wed, Jul 17, 2013 at 3:48 PM, VIGNESH S > wrote: > > > >> > >> Hi, > >> > >> I need to do highlight the first sen

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-17 Thread VIGNESH S
he sentence contains Searched > keyword > > or not.. > > > > > > > > > > On Wed, Jul 17, 2013 at 3:48 PM, VIGNESH S > wrote: > > > >> > >> Hi, > >> > >> I need to do highlight the first sentence which matches the

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-17 Thread Michael McCandless
er the sentence contains Searched keyword > or not.. > > > > > On Wed, Jul 17, 2013 at 3:48 PM, VIGNESH S wrote: > >> >> Hi, >> >> I need to do highlight the first sentence which matches the search keyword >> in a document using PostingsHighlighte

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-17 Thread VIGNESH S
H S wrote: > > Hi, > > I need to do highlight the first sentence which matches the search keyword > in a document using PostingsHighlighter. > > How can i do this > > Any Help or suggestions welcome > -- > Thanks and Regards > Vignesh Srinivasan > > -- Thanks and Regards Vignesh Srinivasan 9739135640

Re: PostingsHighlighter to highlight the first Match ion the document

2013-07-17 Thread Michael McCandless
You might be able to make a custom scorer that assigns an insanely great score to the first sentence it's asked to score? Mike McCandless http://blog.mikemccandless.com On Wed, Jul 17, 2013 at 6:18 AM, VIGNESH S wrote: > Hi, > > I need to do highlight the first sentence whi

PostingsHighlighter to highlight the first Match ion the document

2013-07-17 Thread VIGNESH S
Hi, I need to do highlight the first sentence which matches the search keyword in a document using PostingsHighlighter. How can i do this Any Help or suggestions welcome -- Thanks and Regards Vignesh Srinivasan

How to extract only highlight spans?

2012-07-03 Thread Raf
Hi, is it possibile to use Lucene Highlighter classes to extract highlight spans instead of getting the "highlighted" string? I am using lucene 3.0.3 (and I cannot upgrade version for now). I have the following snippet of code: QueryScorer scorer = new QueryScorer(highlightQuery);

Re: PDF Highlighting using PDF Highlight File

2011-05-12 Thread Dawn Zoë Raison
files... It would be very useful. That said being able to highlight words in any pictorial representation of a document would be a huge bonus. As starting point I quarried out from org.apache.lucene.search.highlight.Highlighter the class below which just returns the Tokens contributing to the

Re: PDF Highlighting using PDF Highlight File

2011-05-12 Thread Wulf Berschin
NullFragmenter, but ther seems to be nothing for highlighting PDF files... As starting point I quarried out from org.apache.lucene.search.highlight.Highlighter the class below which just returns the Tokens contributing to the hit. Using the returned tokens a PDF highlight file could be easily

PDF Highlighting using PDF Highlight File

2011-05-10 Thread Wulf Berschin
Hi all, in our Lucene 3.0.3-based web application when a user clicks on a hit link the targeted PDF should be opened in the browser with highlighted hits. For this purpose using the Acrobat Highlight File (Parameter xml, see http://www.pdfbox.org/userguide/highlighting.html and http

Re: About ComplexPhraseQueryParser highlight prob

2011-03-15 Thread Ahmet Arslan
--- On Tue, 3/15/11, Cescy wrote: > From: Cescy > Subject: About ComplexPhraseQueryParser highlight prob > To: "java-user" > Date: Tuesday, March 15, 2011, 11:44 PM > hi > > > My app can find the document but cannot highlight the > keywords. > >

About ComplexPhraseQueryParser highlight prob

2011-03-15 Thread Cescy
hi My app can find the document but cannot highlight the keywords. ComplexPhraseQueryParser parser = new ComplexPhraseQueryParser(Version.LUCENE_30, "contents", analyzer); Query query = parser.parse("\"(great~) sum*\""); QueryScorer scorer = new QueryS

RE: Highlight Wildcard Queries: Scores

2011-01-26 Thread Uwe Schindler
r [mailto:u...@thetaphi.de] > Sent: Wednesday, January 26, 2011 5:34 PM > To: java-user@lucene.apache.org > Subject: RE: Highlight Wildcard Queries: Scores > > You can always decompose because QueryParser will also decompose and > will do-the-right-thing (internal using a Ph

RE: Highlight Wildcard Queries: Scores

2011-01-26 Thread Uwe Schindler
- > From: Wulf Berschin [mailto:bersc...@dosco.de] > Sent: Wednesday, January 26, 2011 5:07 PM > To: java-user@lucene.apache.org > Subject: Re: Highlight Wildcard Queries: Scores > > Hallo Uwe, > > yes, thanks for the hint, that sounds good, but it seems to me I would the

Re: Highlight Wildcard Queries: Scores

2011-01-26 Thread Wulf Berschin
men http://www.thetaphi.de eMail: u...@thetaphi.de -Original Message- From: Wulf Berschin [mailto:bersc...@dosco.de] Sent: Wednesday, January 26, 2011 3:56 PM To: java-user@lucene.apache.org Subject: Re: SPAM(5.0) Re: Highlight Wildcard Queries: Scores Hi Erick, good points, but:

RE: ****SPAM(5.0)**** Re: Highlight Wildcard Queries: Scores

2011-01-26 Thread Uwe Schindler
o: java-user@lucene.apache.org > Subject: Re: SPAM(5.0)**** Re: Highlight Wildcard Queries: Scores > > Hi Erick, > > good points, but: > > our index is fed with german text. In german (in contrast to english) nouns > are just appended to create new word

Re: ****SPAM(5.0)**** Re: Highlight Wildcard Queries: Scores

2011-01-26 Thread Wulf Berschin
Hi Erick, good points, but: our index is fed with german text. In german (in contrast to english) nouns are just appended to create new words. E.g. Kaffee Kaffeemaschine Kaffeemaschinensatzbehälter In our scenario standard fulltext search on "Maschine" shall present all of these nouns. That

RE: Highlight Wildcard Queries: Scores

2011-01-26 Thread Uwe Schindler
sco.de] > Sent: Wednesday, January 26, 2011 3:24 PM > To: java-user@lucene.apache.org > Subject: Re: Highlight Wildcard Queries: Scores > > Sorry for bothering, that was my fault: I my subclass of QueryParser which > wraps * around the terms I had not yet considered the new > mu

Re: Highlight Wildcard Queries: Scores

2011-01-26 Thread Wulf Berschin
Sorry for bothering, that was my fault: I my subclass of QueryParser which wraps * around the terms I had not yet considered the new multiTermRewriteMethod. After adding these scoring seems to work and even the rewrite is possible again. Wulf Am 26.01.2011 15:10, schrieb Wulf Berschin: Now I

Re: Highlight Wildcard Queries: Scores

2011-01-26 Thread Erick Erickson
It is, I think, a legitimate question to ask whether scoring is worthwhile on wildcards. That is, does it really improve the user experience? Because the MaxBooleanClause gets tripped pretty quickly if you add the terms back in, so you'd have to deal with that. Would your users be satisfied with s

Re: Highlight Wildcard Queries: Scores

2011-01-26 Thread Wulf Berschin
Now I have the highlighted wildcards but obviously the scoring is lost. I see that a rewrite of the wildcard query produces a constant score query. I added setMultiTermRewriteMethod(MultiTermQuery.SCORING_BOOLEAN_QUERY_REWRITE); to my QueryParser instance but no effect. What's to be done now?

RE: Highlight Wildcard Queries

2011-01-26 Thread Wulf Berschin
Thank you Alexander and Uwe, for your help. I read Marks explanation but it seems to me that his changes are not contained in Lucene-3.0.3. So I commented out the rewrite, changed QueryTermScorer back to QueryScorer and now I got the wildcard queries highlighted again. Wulf --

Re: Highlight Wildcard Queries

2011-01-26 Thread Dawn Zoë Raison
Removing redundant calls to rewrite was the key when I had this issue moving from 2.3.x to 3.0.x... Dawn On 25/01/2011 20:04, Uwe Schindler wrote: And: you don't need to rewrite queries before highlighting, highlighter does this automatically internally if needed. - Uwe Schindler

RE: Highlight Wildcard Queries

2011-01-25 Thread Uwe Schindler
r [mailto:u...@thetaphi.de] > Sent: Tuesday, January 25, 2011 9:02 PM > To: java-user@lucene.apache.org > Subject: RE: Highlight Wildcard Queries > > You can set setExpandMultiTermQuery(true) on QueryScorer (or > WeightedSpanTermExtractor), which is needed by the Highlighter CTOR - > tha

RE: Highlight Wildcard Queries

2011-01-25 Thread Uwe Schindler
...@thetaphi.de > -Original Message- > From: Alexander Kanarsky [mailto:kanarsky2...@gmail.com] > Sent: Tuesday, January 25, 2011 8:44 PM > To: java-user@lucene.apache.org > Subject: Re: Highlight Wildcard Queries > > Hi Wulf, > > Check the http://www.lucidimagination.c

Re: Highlight Wildcard Queries

2011-01-25 Thread Alexander Kanarsky
Hi Wulf, Check the http://www.lucidimagination.com/blog/2009/06/08/bringing-the-highlighter-back-to-wildcard-queries-in-solr-14/ this may help. I do not know what of Mark's changes are in Lucene 3.x, but most likely you will just need to set a proper RewriteMethod for the MultiTermQuery somewhere

Highlight Wildcard Queries

2011-01-25 Thread Wulf Berschin
Hi, I'm just migrating our small search customization from Lucene version 2.3 to the current version (3.0.3) and wonder why, in contrast to the old version, we no longer get the Wildcard Queries (which are default, since surround the search string with asterisks) highlighted. We're using the

Re: Sorting case insensitive wildcard query (with highlight)

2010-03-12 Thread Ian Lea
Can you just lowercase a dedicated sort field and leave the others alone. -- Ian. On Fri, Mar 12, 2010 at 10:47 AM, Kev Kilroy wrote: > > Hi, > > I'm using Lucene 2.4.1 with Hibernate Search 3.1.1. I have objects in the > index, for each field I index as follows: > > @Fields( value = { >    

Sorting case insensitive wildcard query (with highlight)

2010-03-12 Thread Kev Kilroy
Hi, I'm using Lucene 2.4.1 with Hibernate Search 3.1.1. I have objects in the index, for each field I index as follows: @Fields( value = { @Field(index = Index.TOKENIZED, store = Store.YES), @Field(name = "name_forSort", index = Index.UN_TOKENIZED, store = Store.NO), }) T

Re: Highlight the whole sentence instead of the partial matching terms

2010-01-11 Thread Sanne Grinovero
If you're searching for terms "giving" and "and", it will only highlight those terms, not the whole sentence.. that's how the highlighter is meant to work: highlight what the user did query. Also there's no built-in concept of sentence. regards, Sanne 201

Re: Highlighter doesn't highlight wildcard queries after updating to 2.9.1/3.0.0

2010-01-11 Thread Mohsen Saboorian
ermExtractor.extract(Query, >> Map) >> >> The query passed to this method is of type >> org.apache.lucene.search.ConstantScoreQuery, but it matches non of >> 'instanceof' checkings in this method, so no WeightedSpanTerm is >> extracted. >> >> It this a bug

Re: Highlighter doesn't highlight wildcard queries after updating to 2.9.1/3.0.0

2010-01-10 Thread Mohsen Saboorian
anceof' checkings in this method, so no WeightedSpanTerm is > extracted. > > It this a bug? > > Thanks, > Mohsen > -- View this message in context: http://old.nabble.com/Highlighter-doesn%27t-highlight-wildcard-queries-after-updating-to-2.9.1-3.0.0-tp26969517p271067

Re: Highlight the whole sentence instead of the partial matching terms

2010-01-10 Thread Li Leon
Just figured out, missed "lucene-memory-2.4.1.jar" external jar inclusion. With that jar included, "\"Giving and\"~11" only got "Giving" & "and" highlighted but not the whole sentence, any ideas? Thanks, 2010/1/11 Li Leon > *Hi all,* &

Highlight the whole sentence instead of the partial matching terms

2010-01-10 Thread Li Leon
*Hi all,* ** *I wanted to use to following code to highlight the whole sentence with "\"something\"~n" to be parsed.* ** *The QueryParser part worked well, but when integrated with Highlighter, it ended up with exception. * ** *Does anyone have any clue as I'm investiga

Re: Highlighter doesn't highlight wildcard queries after updating to 2.9.1/3.0.0

2010-01-10 Thread Mohsen Saboorian
>> >> http://www.lucidimagination.com >> >> >> >> >> - >> To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org >> For additional commands, e-mail: java-user-h...@lu

Re: Highlighter doesn't highlight wildcard queries after updating to 2.9.1/3.0.0

2009-12-30 Thread Mohsen Saboorian
t; > > > > - > To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org > For additional commands, e-mail: java-user-h...@lucene.apache.org > > > -- View this message in c

Re: Highlighter doesn't highlight wildcard queries after updating to 2.9.1/3.0.0

2009-12-30 Thread Mark Miller
Mohsen Saboorian wrote: > After updating to 2.9.x or 3.0, highlighter doesn't work on wildcard queries > like "abc*". I thought that it would be because of scoring, so I also set > myIndexSearcher.setDefaultFieldSortScoring(true, true) before searching. > I tested with both QueryScorer and QueryTer

Highlighter doesn't highlight wildcard queries after updating to 2.9.1/3.0.0

2009-12-30 Thread Mohsen Saboorian
. In my custom highlightTerm(String originalText, TokenGroup tokenGroup) method, tokenGroup.getTotalScore() is always <= 0 for these queries. Mohsen -- View this message in context: http://old.nabble.com/Highlighter-doesn%27t-highlight-wildcard-queries-after-updating-to-2.9.1-3.0.0-tp26969517p26969

Re: Problems with fragments size on highlight.

2009-11-18 Thread Mark Harwood
It could be the "merge contiguous fragments" feature that attempts to do exactly this to improve readability It's an option you can turn off. On 15 Nov 2009, at 01:21, Felipe Lobo wrote: Hi, i'm having some problems with the size of the fragmentes when i'm doing

Problems with fragments size on highlight.

2009-11-14 Thread Felipe Lobo
Hi, i'm having some problems with the size of the fragmentes when i'm doing the highlight. I pass on the constructor of the SimpleSpanFragmenter a size of 80, but i'm having some fragments of 500. But it only happen when i do searches with 3 or more words. What i notice is that he t

Re: ComplexPhraseQueryParser highlight problem

2009-11-03 Thread Mark Miller
AHMET ARSLAN wrote: >> Looks like its because the query >> coming in is a ComplexPhraseQuery and >> the Highlighter doesn't current know how to handle that >> type. >> >> It would need to be rewritten first barring the special >> handling it >> needs - but unfortunately, that will break multi-term

Re: ComplexPhraseQueryParser highlight problem

2009-11-03 Thread AHMET ARSLAN
> Looks like its because the query > coming in is a ComplexPhraseQuery and > the Highlighter doesn't current know how to handle that > type. > > It would need to be rewritten first barring the special > handling it > needs - but unfortunately, that will break multi-term query > highlighting > unle

Re: ComplexPhraseQueryParser highlight problem

2009-11-02 Thread Mark Miller
the same query string is >> parsed by Lucene's default QueryParser highlighting comes. >> >> I am trying to highlight full original text, preserving >> proximity criteria. >> Choice of FastVectorHighlighter or Highlighter is not >> important for me. >&

Re: ComplexPhraseQueryParser highlight problem

2009-11-02 Thread AHMET ARSLAN
hting comes. > > I am trying to highlight full original text, preserving > proximity criteria. > Choice of FastVectorHighlighter or Highlighter is not > important for me. > > I was using ComplexPhraseQueryParser with solr 1.3.0, > without problems with PhraseHighlighter

Re: ComplexPhraseQueryParser highlight problem

2009-11-02 Thread AHMET ARSLAN
cene's default QueryParser highlighting comes. I am trying to highlight full original text, preserving proximity criteria. Choice of FastVectorHighlighter or Highlighter is not important for me. I was using ComplexPhraseQueryParser with solr 1.3.0, without problems with PhraseHighlighter. But

Re: ComplexPhraseQueryParser highlight problem

2009-11-02 Thread Mark Miller
eople that can possibly help or add valuable input. -- - Mark http://www.lucidimagination.com AHMET ARSLAN wrote: > Hi Mark, > > I am using LUCENE-1486. I am having highlighting problems with it. > With solr 1.3.0 it was working with hl.usePhraseHighlighter=true which uses > Spa

lucene highligher snowball analyzer highlight stem words

2009-06-15 Thread faisalloe
I am having the following method to highlight the terms. public static String getHighlighter(String colName, Highlighter highlighter,IndexSearcher searcher,int id, Analyzer analyzer) throws IOException { String highlightTerm; TokenStream tokenStream

Re: Highlight - SimpleSpanFragment

2009-06-13 Thread Radha Sreedharan
Currently I am following a long drawn approach where 1) I find index of the matching text in the original 2) For a list of words to the left of index and to the right of index+length of matching text 3) Then a pick some words from the 1st list and prepend to my matching text text and from my secon

Highlight - SimpleSpanFragment

2009-06-12 Thread Radha Sreedharan
Hi all, I am using *SimpleSpanFragment *to find the words a few positions around the match. I am specifying the number of characters, which is the second parameter of the *SimpleSpanFragment *constructor . However, it always gives the words to the right of the match and does not give me the word

One character highlight

2009-06-05 Thread Piotr Jakubowski
Hello, I am wondering whether using Lucene Highlighter it is possible to highlight parts of words. So for instance, if I type A then in word America I would have America or if I type er I would get America Thanks for replies -- View this message in context: http://www.nabble.com/One-character

Re: how to get the "highlight" code for v 2.2.0 (or any prior version)?

2008-10-16 Thread Chris Hostetter
located in the highlighter contrib jar... [EMAIL PROTECTED]:~/tmp/lucene-old$ tar -xzf lucene-2.2.0.tar.gz [EMAIL PROTECTED]:~/tmp/lucene-old$ find lucene-2.2.0 | grep highlight | grep jar lucene-2.2.0/contrib/highlighter/lucene-highlighter-2.

RE: how to get the "highlight" code for v 2.2.0 (or any prior version)?

2008-10-16 Thread Steven A Rowe
gt; > b) but none of those contain the package > "org.apache.lucene.search.highlight" > > c) I can get the HEAD stream code for the package >"org.apache.lucene.search.highlight" by checking out the "highlight" >project through SVN, but that

how to get the "highlight" code for v 2.2.0 (or any prior version)?

2008-10-16 Thread rolarenfan
ot; c) I can get the HEAD stream code for the package "org.apache.lucene.search.highlight" by checking out the "highlight" project through SVN, but that gets me 2.4-level code (using http://svn.apache.org/repos/asf). How can I get the 2.2.0-level &q

Re: Re: Highlight huge documents

2008-08-11 Thread jim
it works!! Thanks I believe Highlighter.setMaxDocBytesToAnalyze(int byteCount) should be used for this. On Mon, Aug 11, 2008 at 11:40 AM, <[EMAIL PROTECTED]> wrote: > Hello > > I am using Highlighter to highlight query terms in documents getting from a > database founded

Re: Highlight huge documents

2008-08-11 Thread Doron Cohen
I believe Highlighter.setMaxDocBytesToAnalyze(int byteCount) should be used for this. On Mon, Aug 11, 2008 at 11:40 AM, <[EMAIL PROTECTED]> wrote: > Hello > > I am using Highlighter to highlight query terms in documents getting from a > database founded from lucene search. &g

Highlight huge documents

2008-08-11 Thread jim
Hello I am using Highlighter to highlight query terms in documents getting from a database founded from lucene search. My problem is that when i display the full document, highlighter works fine for most of documents but if the document is huge the highlighter returns only a part of

Re: Highlight an Greek

2008-06-30 Thread jim
and then the to get the corresponding record from database. My problem is that: i want to highlight the field with HTML query string that using on searching. Is it possible to do with Hightlighter or i must write my own class? Grant Ingersoll wrote: Because there are no matches? Have

Re: Highlight an Greek

2008-06-30 Thread Eleanor Joslin
highlight a text public String highlight(String text, String query ) throws IOException { TermQuery query = new TermQuery(new Term("f", query)); QueryScorer scorer = new QueryScorer(query); SimpleHTMLFormatter formatter = new SimpleHTMLFormatter("",

Re: Highlight an Greek

2008-06-26 Thread Grant Ingersoll
Coast US time. It just clutters email and makes it less likely that you will get a response. -Grant On Jun 26, 2008, at 3:48 AM, [EMAIL PROTECTED] wrote: Hello i am having the following code to highlight a text public String highlight(String text, String query ) throws IOException { T

Highlight and greek characters

2008-06-26 Thread jim
Hello i am having the following code to highlight a text public String highlight(String text, String query ) throws IOException { TermQuery query = new TermQuery(new Term("f", query)); QueryScorer scorer = new QueryScorer(query); SimpleHTMLFormatter formatter =

Highlight an Greek

2008-06-26 Thread jim
Hello i am having the following code to highlight a text public String highlight(String text, String query ) throws IOException { TermQuery query = new TermQuery(new Term("f", query)); QueryScorer scorer = new QueryScorer(query); SimpleHTMLFormatter formatter =

RE: Lucene-Highlight words in a searched docs

2008-02-28 Thread Mitchell, Erica
Hi Ravinder Checkout Highlighter.test in lucene-2.3.1\contrib\highlighter\src\test\org\apache\lucene\search\highl ight\ folder -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 28 February 2008 11:03 To: java-user@lucene.apache.org Subject: Lucene-Highlight

Lucene-Highlight words in a searched docs

2008-02-28 Thread Ravinder.Teepiredddy
Hi All, How do we Highlight words in a searched docs. Please give inputs on "rewritten query as the input for the highlighter, i.e. call rewrite() on the query". Thanks, Ravinder DISCLAIMER: This message contains privileged and confidential information and is intended o

Offsets-highlight newbie question

2008-02-10 Thread Katya
rough them. Lucene works great! I create index, analyzer, send query, get hits... The problem is that one of the text of the collection is always displayed in a JTextArea, and I want to be able to highlight, mark out in color, the words that match the query. Now, there is the Highlighter in Java

highlight only some terms from query string?

2007-09-06 Thread newbieoflucene
in [Name] and [Title] fields? -- View this message in context: http://www.nabble.com/highlight-only-some-terms-from-query-string--tf4392290.html#a12522976 Sent from the Lucene - Java Users mailing list archive at Nabble.com. - To

Re: highlight optimization

2006-10-09 Thread Erick Erickson
The fastest way to see if opening/closing your searcher is a problem would be to write a tiny little program that opened the index, fired off a few queries and timed each one. The queries can be canned, of course. I'm thinking this is, say, less that 20 lines (including imports). If you're familia

highlight optimization

2006-10-09 Thread Stelios Eliakis
Hi, I have a collection of 500 txt documents and I implement a web application(JSP) for searching these documents. In addition, the application shows the BestFragment of each result and highlights the query terms. My application is slow enough (about 2,5-3 seconds for each query) even if I run it

Re: highlight using a MemoryIndex

2006-09-28 Thread Wolfgang Hoschek
tokenStream, text, maxNumFragmentsRequired, fragmentSeparator); } } else { System.out.println("No Matches found to highl

Re: [Lucene2.0]How to not highlight keywords in some fields?

2006-09-26 Thread zhu jiang
Thx a lot! 2006/9/26, markharw00d <[EMAIL PROTECTED]>: Pass a field name to the QueryScorer constructor. See "testFieldSpecificHighlighting" method in the Junit test for the highlighter for an example. Cheers Mark zhu jiang wrote: > Hi all, > >For example, if I have a document with two f

Re: [Lucene2.0]How to not highlight keywords in some fields?

2006-09-26 Thread markharw00d
Pass a field name to the QueryScorer constructor. See "testFieldSpecificHighlighting" method in the Junit test for the highlighter for an example. Cheers Mark zhu jiang wrote: Hi all, For example, if I have a document with two fields text and num like this: text:foo bar

[Lucene2.0]How to not highlight keywords in some fields?

2006-09-25 Thread zhu jiang
Hi all, For example, if I have a document with two fields text and num like this: text:foo bar 1 num:1 When users query "foo", I changed the query to "text:foo AND num:1", both "foo" and "1" in the text field will be highlighted. I don't wanna the word "1" in

Re: Highlight specific occurence

2006-09-25 Thread Erik Hatcher
(for example "w1 w2 WITHIN 4" to find all documents where the distance between w1 and w2 and less or equals to 4) For all documents matching the query, I need to know the corresponding occurences (w1, w2) to highlight them (and so exclude all other w1 and w2 which are no r

Highlight specific occurence

2006-09-25 Thread Virlouvet Olivier
Hi All, I use proximity operator in my queries (for example "w1 w2 WITHIN 4" to find all documents where the distance between w1 and w2 and less or equals to 4) For all documents matching the query, I need to know the corresponding occurences (w1, w2) to highlight th

highlight using a MemoryIndex

2006-08-31 Thread Daniel J. Williams
returnString = highlighter.getBestFragments( tokenStream, text, maxNumFragmentsRequired, fragmentSeparator); } } else

Re: HELP: how to highlight the search key word in lucene's search results?

2006-08-17 Thread kelvin pang
er jar from the lucene-sandbox and see the examples from this downloaded folder. Get the Search Results from the Hits and pass this string to the highlighter class. if you still need help... please ping, i can pass you some code on. On Sat, 2006-08-12 at 00:33 +0800, kevin wrote: Hi, how t

Re: HELP: how to highlight the search key word in lucene's search results?

2006-08-16 Thread Ramesh Salla
need help... please ping, i can pass you some code on. On Sat, 2006-08-12 at 00:33 +0800, kevin wrote: Hi, how to highlight the search key word in lucene's search results? pls give advise,thanks! - To unsubscribe, e

Re: HELP: how to highlight the search key word in lucene's search results?

2006-08-11 Thread Ronnie Kolehmainen
This is in the FAQ: http://wiki.apache.org/jakarta-lucene/LuceneFAQ#head-75566820ee94a425c7e2950ac61d24e405fbd914 Citerar kevin <[EMAIL PROTECTED]>: > Hi, > how to highlight the search key word in lucene's search results? pls >

HELP: how to highlight the search key word in lucene's search results?

2006-08-11 Thread kevin
Hi, how to highlight the search key word in lucene's search results? pls give advise,thanks! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Highlight

2006-04-26 Thread anton feldmann
Hi I wrote a program that make a pdf document to an Lucene document. The field ate "contents", "sentence", : How do i display the sentence the query String is in? and how do I Highlight the String? cheers anton feldmann package de.coli.seek.lucene; import

Re: Highlight the searched word when full-text searching performed

2005-11-27 Thread Jerry Stern
Thanks! Yes you're right. Highlight all hits at one time may cause problems. A hits paging method is needed to avoid this. Another, if we read the contents of the original file into a string, passing it to the highlighter at the searching stage, this also could cause problems when

Re: Highlight the searched word when full-text searching performed

2005-11-27 Thread Erik Hatcher
On 27 Nov 2005, at 00:24, Jerry Stern wrote: I wonder how to highlight the searched word when full-text searching performed based on Lucene. At the indexing stage, the contents of a original file is regarded as a FIELD of a Lucene document: private static void indexFile(File file

Highlight the searched word when full-text searching performed

2005-11-26 Thread Jerry Stern
Hi all, I wonder how to highlight the searched word when full-text searching performed based on Lucene. At the indexing stage, the contents of a original file is regarded as a FIELD of a Lucene document: private static void indexFile(File file, IndexWriter idxWriter) throws IOException

Re: highlight only one field

2005-11-11 Thread Ernesto De Santis
--- Ernesto De Santis <[EMAIL PROTECTED]> wrote: Hi Mark This don't work, because WeightedTerm[] weightedTerm = QueryTermExtractor.getTerms(query); return query terms values , not the fields names. example: for "body:mark title:highlight" return [mark, highlight], I

Re: highlight only one field

2005-11-11 Thread mark harwood
ry); > > return query terms values , not the fields names. > example: > for "body:mark title:highlight" > > return [mark, highlight], I can't compare this > values with "body" field. > > Ernesto. > > mark harwood escribió: > > >Ah. Yo

Re: highlight only one field

2005-11-11 Thread Ernesto De Santis
Hi Mark This don't work, because WeightedTerm[] weightedTerm = QueryTermExtractor.getTerms(query); return query terms values , not the fields names. example: for "body:mark title:highlight" return [mark, highlight], I can't compare this values with "body"

Re: highlight only one field

2005-11-11 Thread mark harwood
Ah. You're right. Looks like the current highlighter api doesn't offer you that degree of control. The way to fix it is probably to tweak the list of WeightedTerms you give the highlighter: [psuedo code follows...] terms=QueryTermExtractor.getTerms(query); bodyQueryTerms=new ArrayList(); for all

highlight only one field

2005-11-11 Thread Ernesto De Santis
Hi I'm using highlighter and have this problem: The query is over two or more fields, like: *body:home AND title:sale* I want to highlight over body field, but not highlight "sale" if "sale" is in body. How I can do this? When I create a Highlighter instance, t

  1   2   >