Re: Leading wildcards

2007-05-02 Thread Michael Pelz Sherman
I just downloaded the latest nightly build of Lucene and compiled it with the 
solr 1.1.0 source, and now leading + trailing wildcards work like a charm.
   
  The only issue is, the lucene-core .jar file seems to have a runtime 
dependency on clover.jar. Does anyone know if this is intentional, or how I can 
get a lucene-core without the clover dependency?
   
  - mps


Re: Leading wildcards

2007-05-02 Thread Michael Pelz Sherman
Try it on the nightly build, dude:
   
  [EMAIL PROTECTED] tmp]# strings lucene-core-nightly.jar | grep -i clover|more
org/apache/lucene/LucenePackage$__CLOVER_0_0.class
org/apache/lucene/analysis/Analyzer$__CLOVER_1_0.class
org/apache/lucene/analysis/CachingTokenFilter$__CLOVER_2_0.class
org/apache/lucene/analysis/CharTokenizer$__CLOVER_3_0.class
org/apache/lucene/analysis/ISOLatin1AccentFilter$__CLOVER_4_0.class
org/apache/lucene/analysis/KeywordAnalyzer$__CLOVER_5_0.class
org/apache/lucene/analysis/KeywordTokenizer$__CLOVER_6_0.class
...

Otis Gospodnetic [EMAIL PROTECTED] wrote:
  As far as I know, there is no clover dependency, at least not in the trunk 
version of Solr. I tried this cheap trick:

$ strings lib/lucene-core-2.1.0.jar | grep -i clover

Otis 

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Simpy -- http://www.simpy.com/ - Tag - Search - Share

- Original Message 
From: Michael Pelz Sherman 
To: solr-user@lucene.apache.org
Sent: Wednesday, May 2, 2007 10:52:53 AM
Subject: Re: Leading wildcards

I just downloaded the latest nightly build of Lucene and compiled it with the 
solr 1.1.0 source, and now leading + trailing wildcards work like a charm.

The only issue is, the lucene-core .jar file seems to have a runtime dependency 
on clover.jar. Does anyone know if this is intentional, or how I can get a 
lucene-core without the clover dependency?

- mps






Re: Leading wildcards

2007-05-02 Thread Michael Pelz Sherman
I tried, but ran into a missing ant file:
   
  lucene-nightly\build.xml:7: Cannot find common-build.xml imported from 
C:\download\lucene-nightly\build.xml
   
  I've posted to the lucene dev list as well; will try the lucene user list too.
   
  - mps

Otis Gospodnetic [EMAIL PROTECTED] wrote:
  Try building your own jar (ant jar-core in lucene's trunk):

strings /home/otis/dev/repos/lucene/java/trunk/build/lucene-core-2.2-dev.jar | 
grep -i clover

I'll have a look at the nightly later, but you should also bring up that issue 
on [EMAIL PROTECTED] list.

Otis 

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Simpy -- http://www.simpy.com/ - Tag - Search - Share

- Original Message 
From: Michael Pelz Sherman 
To: solr-user@lucene.apache.org
Sent: Wednesday, May 2, 2007 12:11:45 PM
Subject: Re: Leading wildcards

Try it on the nightly build, dude:

[EMAIL PROTECTED] tmp]# strings lucene-core-nightly.jar | grep -i clover|more
org/apache/lucene/LucenePackage$__CLOVER_0_0.class
org/apache/lucene/analysis/Analyzer$__CLOVER_1_0.class
org/apache/lucene/analysis/CachingTokenFilter$__CLOVER_2_0.class
org/apache/lucene/analysis/CharTokenizer$__CLOVER_3_0.class
org/apache/lucene/analysis/ISOLatin1AccentFilter$__CLOVER_4_0.class
org/apache/lucene/analysis/KeywordAnalyzer$__CLOVER_5_0.class
org/apache/lucene/analysis/KeywordTokenizer$__CLOVER_6_0.class
...

Otis Gospodnetic wrote:
As far as I know, there is no clover dependency, at least not in the trunk 
version of Solr. I tried this cheap trick:

$ strings lib/lucene-core-2.1.0.jar | grep -i clover

Otis 

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Simpy -- http://www.simpy.com/ - Tag - Search - Share

- Original Message 
From: Michael Pelz Sherman 
To: solr-user@lucene.apache.org
Sent: Wednesday, May 2, 2007 10:52:53 AM
Subject: Re: Leading wildcards

I just downloaded the latest nightly build of Lucene and compiled it with the 
solr 1.1.0 source, and now leading + trailing wildcards work like a charm.

The only issue is, the lucene-core .jar file seems to have a runtime dependency 
on clover.jar. Does anyone know if this is intentional, or how I can get a 
lucene-core without the clover dependency?

- mps










Re: case sensitivity

2007-04-27 Thread Michael Pelz Sherman
In our experience, setting a LowercaseFilter in the query did not work; we had 
to call setLowercaseExpandedTerms(true) to get wildcard queries to be 
case-insensitive.
   
  Here's our analyzer definition from our solr schema:
   
analyzer type=query
tokenizer class=solr.WhitespaceTokenizerFactory/
filter class=solr.SynonymFilterFactory synonyms=synonyms.txt 
ignoreCase=true expand=true/
filter class=solr.StopFilterFactory ignoreCase=true 
words=stopwords.txt/
filter class=solr.WordDelimiterFilterFactory generateWordParts=1 
generateNumberParts=1 catenateWords=0 catenateNumbers=0 catenateAll=0/
filter class=solr.LowerCaseFilterFactory/
filter class=solr.EnglishPorterFilterFactory 
protected=protwords.txt/
filter class=solr.RemoveDuplicatesTokenFilterFactory/
  /analyzer
   
  If calling setLowercaseExpandedTerms(true) is *not* in fact necessary for 
case-insensitive wildcard queries, could you please provide an example of a 
solr schema that can achieve this?
   
  Thanks!
  - mps
  
Yonik Seeley [EMAIL PROTECTED] wrote:
  On 4/26/07, Michael Kimsal wrote:
 My colleague, after some digging, found in SolrQueryParser

 (around line 62)
 setLowercaseExpandedTerms(false);

 The default for Lucene is true. Was this intentional? Or an oversight?

Way back before Solr was opensourced, and Chris was the only
user, I thought he needed to do prefix queries where case sensitive
wildcard queries (hence I set it to false). I think I may have been
mistaken about that need, but by that time, I didn't know if anyone
depended on it, so I never changed it back.

A default of false is actually more powerful too. You can do prefix
queries on fields that have a LowercaseFilter in their analyzer, and
also fields that don't. If it's set to true, you can't reliably do
prefix queries on fields that don't have a LowercaseFilter.

-Yonik