Hi
Can u share the searcher.search(query, hitCollector); [light weight paging
api ]
Code on the form ,may be somebody like me need's it.
; )
Karthik
-Original Message-
From: Praveen Peddi [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 22, 2004 1:24 AM
To:
Marco Schmidt writes:
I'm trying to find out whether Lucene is an option for a project of
mine. I have texts which also have a date and a list of numbers
associated with each of them. These numbers are ID values which connect
the article to certain categories. So a particular article X
Hi,
I know this is probably a common question and I've found a couple of posts
about it in the archive but none with a complete answer. If there is one
please point me to it!
The question is that I want to discard the default scoring and implement my
own. I want all the the hits to be sorted
You need your own Similarity implementation and you need to set it as
shown in this javadoc:
http://jakarta.apache.org/lucene/docs/api/org/apache/lucene/search/Similarity.html
Otis
--- [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Hi,
I know this is probably a common question and I've found a
Yes thanks,
I implemented my own Similarity class that returns 1.0f from lengthNorm()
and idf() then I use setBoost when writing the document. However I get some
small round errors. When I boost with 0.7 that document gets the score
0.625. I've found that this has to do with the encode/decode norm
Actually what William should use is the new Sort facility to order
results by a field. Doing this with a Similarity would be much
trickier. Look at the IndexSearcher.sort() methods which take a Sort
and follow the Javadocs from there. Let us know if you have any
questions on sorting.
Thanks for the reply,
I've looked in to the search method that takes a Sort object as argument.
As I understand it the sorting is only done on the best matches (100 by
default)? I don't want the default score to have any impact at all. I want
to sort all hits on popularity not just the best
Sorting is done however you specify, by field, with secondary fields
specified, by document id, by score/relevance, or even by a custom
implementation to sort by something else (in Lucene in Action we
provide an implementation that sorts by two-dimensional distance from a
given location,
Hi ,
I think it doesn't have anything to do with number of characters
with a wildcard. Because 'z*' works and 'a*' does not.
Does lucene have a limitation on the number of hits fetched ?
The error that I get is
org.apache.lucene.search.BooleanQuery$TooManyClauses
at
I have test my app with snowball for english. But I'm doing something
wrong because I can't get any result from hit.
If I index lazy with English snowball when I see the word in Luke it
shows lazy (I've read that Luke show the file as is). When I do the
search for the word laziness the snowball
Hello,
In my testing, it seems like if the searcher (in my
case ParallelMultiSearcher) is not closed, the
searcher will not pick up any new data that has been
added to the index since it was opened. I'm wondering
if this is a correct statement.
Assuming the above is true, I went about closing
Sure I can share parts of the code.
LuceneSearchResults class extends HitCollector and overrides collect() method and
takes care of paging stuff. The class roughly looks as follows. I didn't add un
necessary methods for simplicity. collect method just reads the doc ids and score, but
not the
hi all,
i have a strange problem with the get and setBoost functions
(lucene-1.4.1). i am trying the following code:
[...]
Document d1 = new Document();
Field f1 = Field.Text(field, word);
f1.setBoost(2.0f);
d1.add(f1);
d1.setBoost(3.0f);
writer.addDocument(d1);
[...]
so if i'am right, this must
You need to search useing a snowball analayzer and also index using the
same analyzer.
John
Wermus Fernando wrote:
I have test my app with snowball for english. But I'm doing something
wrong because I can't get any result from hit.
If I index lazy with English snowball when I see the word in
On Wednesday 22 September 2004 18:44, Bastian Grimm [Eastbeam GmbH] wrote:
if i set the d1 and f1 boost to 1.0f (default) the score returned by
the HitCollector is 0.3xxx - shouldn't it be exactly 1.0 ?
See the documentation for getBoost:
Note: this value is not stored directly with the
Can anyone help me with code to get the topterms of a given field for a
query resultset?
Here is code modified from Luke to get the topterms for a field:
public TermInfo[] mostCommonTerms( String fieldName, int numberOfTerms )
{
//make sure min will get a positive number
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Erik Hatcher wrote:
On Sep 15, 2004, at 1:45 PM, Karthik N S wrote:
1) Is a there a PHP version of Lucene Implemantation avaliable , If so
Where?
Using the Java version of Lucene from PHP is my recommendation. There
is not a PHP version.
David,
I tried your technique, i am directly streaminf the pdf file in to
Lucene highlighter as below and i get a NPE in
highlighter.getBestFragments(tokenStream, docAsString, 3, ...);
API doc is not very clear here, i fed the contents of query string
(instead of docAsString)to this method and
Hi Luceners!
I am trying to use transcations in the Berkeley DB + Lucene package
from the sandbox. Has anyone done this succesfully? I dont see any
transactions being commited or aborted in the code, so I wonder if
transactions actually work (shouldnt the main transaction that is used
for opening
Hi,
I've been working with the HTML parser demo that comes with
Lucene and I'm trying to understand why it's multi-threaded,
and, more importantly, how to exit gracefully on errors.
I've discovered if I throw an exception in the front-end static
code (main(), etc.), the JVM hangs instead of
Thanks a lot Paul , for solving the problem.
I added booleanQuery.setMaxClauseCount(1) and there was no prob
after that.
Regards,
Robin
-Original Message-
From: Raju, Robinson (Cognizant)
Sent: Wednesday, September 22, 2004 8:01 PM
To: 'Lucene Users List'
Subject: RE: WildCardQuery
21 matches
Mail list logo