4 Replies Latest reply on Oct 1, 2010 6:23 AM by rgurganus

    weighting fields in verity

    rgurganus Level 1

      I have a verity collection that indexes title, summary, and body fields from a table.  If I copy & paste an article's title into the search (without quotes), I get over 1,000 search results, and the article is in there somewhere.  But if the title is an exact match, I would think this should be at the top of the list?  So is there a way to tell it "this is the title field, it should have a higher rank"?


      If I put the title in quotes, it is the only one returned -- so I know it's in the collection somewhere.


      Running CF8.  Thanks.

        • 1. Re: weighting fields in verity
          rgurganus Level 1

          No one has an answer?  If it's not possible, that would be good to know so that I stop looking, or look for different methods of searching.  But if it is possible, it seems like someone would know how.  Thanks.

          • 2. Re: weighting fields in verity
            Adam Cameron. Level 5

            I've never had to do this, but is this link any use to you: http://help.adobe.com/en_US/ColdFusion/9.0/Developing/WSc3ff6d0ea77859461172e0811cbec22c24 -7b18.html


            CF's support for Verity is not fantastically well-defined, and as Verity doesn't actually exist any more, there's none of its own docs to read (and I could never find them even when it did exist... it's funny... the most impentrable search interfaces I have ever experienced have been those provided by search engine companies...)


            You've basically got what's in Livedocs to go on.


            Have you looked at what one can do with Solr?  Is Solr an option for you?





            • 3. Re: weighting fields in verity
              rgurganus Level 1

              I came up with a workaround -- after the cfsearch, I loop through the search results and compare all of the words of the search phrase to the title of the articles, and for each word matching, I bump the score manually.


              But this brought to light another issue -- before bumping the scores, I noticed that they're all "1.000", which shows that the title wasn't being weighted.  Where is this "1.000" coming from, and is there any way to get a real score instead?  Then maybe the title bumping won't be needed...

              • 4. Re: weighting fields in verity
                rgurganus Level 1

                Another pitfall I've found:  In what I inherited, the search expression had an operator of <SUM>.  Reading the documentation, this sounds logical.  But the result was that the score for ALL results was "1.000".  Thus the results that should have had a higher score had no more weight than anything else.  Taking out the <SUM> brings back actual scores and helps the weighting.