Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 73312 invoked from network); 7 Apr 2011 09:36:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 7 Apr 2011 09:36:50 -0000 Received: (qmail 91567 invoked by uid 500); 7 Apr 2011 09:36:48 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 91269 invoked by uid 500); 7 Apr 2011 09:36:47 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 91261 invoked by uid 99); 7 Apr 2011 09:36:47 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Apr 2011 09:36:47 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of solmyr72@gmail.com designates 209.85.210.176 as permitted sender) Received: from [209.85.210.176] (HELO mail-iy0-f176.google.com) (209.85.210.176) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Apr 2011 09:36:40 +0000 Received: by iym1 with SMTP id 1so3221684iym.35 for ; Thu, 07 Apr 2011 02:36:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=/R0GIUqxDNw9w/mdFtqqW5v1aN/xN8YxnhebFEskryQ=; b=H+QuVec8ep4F5OCaFzsYVpT4F8CaFPg+tWAEXWNEtnQVZ/pL3zHPG/4rrL4xuI+Lvx ODiDHxV1YP6ylZC3OfenY9Ft4YOogHDLmEvEasrM2ad7nLF4nmKN+tbJRWMvVCVh4wr6 XlSEsvX5pVwYN1nX4VyJ3OGqMRPmT4tDGZVwc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=QLJn24juj/4bOUo4XIJNbyOuuBlEPwQpNxbuKhwX2f7i5jwqnwfa0M0wbSUsigTKIl 4nuIQawvsJFAduQ9t9j5HNnaHRF2KytSglA6rq0DTjdLfk8lUu1RZWyxHE0gN7J48z+R iy6eQaYOn7GgSqu7+G5iCblXGvzdOy1cSAOXk= MIME-Version: 1.0 Received: by 10.42.1.12 with SMTP id 12mr1030555ice.366.1302168978975; Thu, 07 Apr 2011 02:36:18 -0700 (PDT) Received: by 10.231.206.81 with HTTP; Thu, 7 Apr 2011 02:36:18 -0700 (PDT) Date: Thu, 7 Apr 2011 12:36:18 +0300 Message-ID: Subject: PhraseQuery with huge "slop"? From: sol myr To: java-user@lucene.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org Hi, I need to run and "AND" query with a twist: give higher ranking for "exact match". So when searching for BIG BEN - Give high rank for the Document "BIG BEN is in London" - Lower rank for "It's a BIG day for my dear friend BEN" Following good advice from this list, I combined 2 separate queries (the query "+BIG +BEN" and the exact-phrase "\"BIG BEN\""). But someone suggested an alternative: PhraseQuery with a very large SLOP. Such SLOP would cover all appearances of theses words in the document (even far apart). While the PrahseQuery would automatically give higher ranking when words are close apart. Does that make sense? 1) What SLOP is required if my documents are about 100 words each? Is it simply SLOP=100, or would it be exponential ( like 100! ) 2) Will I get reasonable performace? Or would the large SLOP cause horrible performance degradation? Thanks :) --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org