search for: topdocs

Displaying 20 results from an estimated 28 matches for "topdocs".

2006 Jan 02
11
aligning Ferret''s IndexSearcher.search API with Lucene''s
...er understanding of how Java Lucene implements its search methods, I realized that one level of abstraction is not present in the Ferret classes/methods. Here are the relevant method signatures: Ferret''s search methods: in Ferret::Index::Index: search(query, options = {}) -> returns a TopDocs search_each(query, options = {}) {|doc, score| ...} -> yields to context w/ doc and score for each hit in Ferret::Search::IndexSearcher: search(query, options = {}) -> returns a TopDocs search_each(query, filter = nil) {|doc, score| ...} -> yields to context w/ doc and score for each hit...
2006 Oct 10
5
oddness when adding to index -
...walker", "Top daw g dog walker"].each {|text| i << text } => ["While you were out pet care", "Eastside dog walker", "Top dawg dog walker"] *** Now let''s do some searches *** irb(main):006:0> puts i.search(''pet'') TopDocs: total_hits = 1, max_score = 0.878416 [ 0 "While you were out pet care": 0.878416 ] => nil irb(main):007:0> puts i.search(''dog'') TopDocs: total_hits = 2, max_score = 0.500000 [ 1 "Eastside dog walker": 0.500000 2 "Top dawg dog walker": 0.500...
2007 May 03
1
Numeric Range or comparision doesn''t work
...uot;}, {:num => 1000, :data => "yes"}, {:num => 1000, :data => "no"} ] ?> puts index.process_query(''data:yes AND num:[10 100]'') +data:yes +num:[10 100] => nil >> puts index.search(''d:data:yes AND num:[10 100]'') TopDocs: total_hits = 2, max_score = 1.777895 [ 2 "": 1.777895 4 "": 1.777895 ] => nil >> puts index.process_query(''data:yes AND num:[2 100]'') num:"data yes <> num 2 100"~4 => nil >> puts index.process_query(...
2006 Oct 10
4
Need help for coding an extension to ferret
Hi, i''m working on a project using Ferret for indexing it''s datas. I''m very happy with it but i need to code an extension to implement a .to_json method to TopDocs class, because ruby''s json implementation is really really slow... It''s my second (the first was the tutorial :/ ) ruby C extension, so i''m not really at ease with ruby C bindings, even with the C experience... Here is my problem : I would like to load each document...
2006 Sep 23
0
TermQuery problem
...ng a search string seems to always work whereas using a TermQuery often doesn''t return any entries. For example: > x=@i[450][:message_id] => "9e7db9110509070759732b21c4 at mail.gmail.com" > @i.search("message_id:#{x}") => #<struct Ferret::Search::TopDocs total_hits=1, hits=[#<struct Ferret::Search::Hit doc=450, score=6.51688194274902>], max_score=6.51688194274902> > @i.search(Ferret::Search::TermQuery.new(:message_id, x)) => #<struct Ferret::Search::TopDocs total_hits=0, hits=[], max_score=0.0> But sometimes it works fine:...
2007 Apr 28
6
Determine how many documents a term occurs in
Is there a fast way to determine how many documents a term occurs in, besides iterating through every document with TermDocEnum? -- Best regards, Stian Gryt?yr
2005 Dec 02
4
How to get the count of matching documents
I''m trying to generate a rails pagination helper for some ferret search results, and I need to know how many total matches there are to my search query. I don''t see an obvious way of finding this. Any help would be appreciated. Thanks, Carl Youngblood
2017 Jun 05
2
Logging the click data
Hi James, > ID: some identifier for each query > QUERY: text of the query (when the query is run) > URLs: every URL displayed (or alternatively, the Xapian docid — this > might be easier) > OFFSET: otherwise you'll have difficulty coping with result pages other > than the first page (when this happens, the query ID should probably > remain the same, and when you aggregate
2006 Sep 23
8
svn problems
I can consistently segfault the 0.10.4 gem, so I''m trying to get the subversion version working with hopes towards tracking the problem down. I have a fresh SVN checkout but: a) the version (in ferret.rb) claims to be 0.9.6; and b) Ferret::Index::FieldInfos and a couple other classes are missing at run time. It looks like this is because they''re not exported in the C
2017 Jun 08
2
Logging the click data
> In case I wasn't clear: I don't think you have to modify the command > at all. Just create a template that uses the command as it currently > works. I thought we needed a new template only for the second log file? To generate the first log file using the existing $log command, I have introduced another $log command in query template that looks like:
2007 Feb 16
1
Bug in IndexSearcher with limit => all and any offset
Here''s the deal: static TopDocs *isea_search_w(Searcher *self, Weight *weight, int first_doc, // OFFSET int num_docs, // LIMIT Filter *filter, Sort *sort,...
2008 Jan 09
5
Parallel indexing doesn''t work?
...Writer.new(:path => "/tmp/test") index_writer.add_readers(readers) index_writer.close() readers.each {|reader| reader.close()} i = Ferret::I.new(:path => ''/tmp/test'') res = i.search(''name*'') puts res.inspect # gives me: #<struct Ferret::Search::TopDocs total_hits=0, hits=[], max_score=0.0, searcher=#<Ferret::Search::Searcher:0x58a6ec>> puts res.hits.size # gives me: 0
2006 Jan 03
1
opensearch template
I've just noticed the Omega "opensearch" template seems to lack escaping for URLs in <link> tags: $httpheader{Content-Type,application/xml}<?xml version="1.0"?> <rss version="2.0" xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/"> <channel> <title>Xapian search results</title>
2006 Aug 06
1
How to use omega to search remote back end?
Folks, Having trouble getting this to work. OMEGA cgi is not reading my stub file properly because it is trying to read it as a directory instead of a file. Is there an easy fix? Here is a transcript. Thanks, OSC oscar@epsilon:/svr/xapian/beta$ ls -aFl total 21335200 drwxr-xr-x 2 oscar oscar 4096 Aug 6 10:15 ./ drwxr-xr-x 5 oscar oscar 4096 Aug 6 12:59 ../ lrwxrwxrwx 1 oscar
2017 Jun 06
2
Logging the click data
> > I'm not clear on what the OFFSET really represents. Could you > > please explain a bit? > > Omega paginates results (as does Xapian's MSet, internally). So if > you're displaying the second page of results, you'll need to know > that when building training data. It's affected by TOPDOC and also > by the <>[# CGI variables, but internally to
2017 Jun 06
2
Logging the click data
> There's a lot of flexibility already, because the log format is just > omegascript. So I don't think you need to implement a new command to > achieve this. (Although you might need a command to generate the query > id. It depends on how you're going to do that.) Ok, I'll try adapting the existing log command to achieve the kind of logging we want. And, about the
2006 Oct 09
2
hello, acts_as_ferret questions, any help greatly appreciate
hi, ive been reading up on ferret, acts_as_ferret, and other search plugins for rails. after reading about ferret, i found out about the acts_as_ferrt plugin. my first question about acts_as_ferret: 1. from reading about ferret, do i still need to manually save the IDX and add a IDX column field to my model table for acts_as_ferret to work? they say that acts_as_ferret handles everything,
2007 Mar 07
0
A note about #search vs #search_each
...erialized, such that a long search would cause others to wait noticeably. Anyhow, after coding both :limit and applying homegrown thread time limit monitoring, I discovered that Searcher#search_each uses rb_thread_critical = Qtrue whereas Searcher#search doesn''t. I changed my code to use TopDocs and Searcher#search and viola, concurrent searches! Cheers, Nevill
2007 Jan 23
2
Exact phrase score
Sorry if this has been beaten to death here but I couldn''t find the exact answer I was looking for. In the app I''m writing, we convert the score to a percentage and display it with the search results. The problem is when you search for an exact phrase (for example) and it matches the title of a document exactly, you only get a 17% match. Has anyone seen a way to either curve
2006 Oct 11
0
Memory allocation bug with index.search
...type => hardware or mixed datas. We''ve got around 12400 docs with this type, here are the queries (THEY ARE ALL LAUNCHED IN A _NEW_ INSTANCE OF FERRET ! (with the same index of course)): this one works fine : >> INDEX.search(''type:hardware'').to_s => "TopDocs: total_hits = 12490, max_score = 1.751220 [\n\t13997 \"61426\": 1.751220\n\t13998 \"61427\": 1.751220\n\t13999 \"61428\": 1.751220\n\t14000 \"61429\": 1.751220\n\t14001 \"61430\": 1.751220\n\t14002 \"61431\": 1.751220\n\t14003 \"61...