I am interested in using payloads in the following way. I store Func(index-term) as a payload at index-term when indexing. When querying I want to compute Func(query-term) as well. Then my similarity returns some other function, Gunc(Func(index-term1),Func(query-term)).
As an example, maybe I'm stripping plural-s and I want to index the singular along with the payload true/false as to whether the original term was plural or not. Then when I query with a term I have a true/false value for it as well. My similarity score can then rank plurals higher when plurals are queried and visa versa. As another example, say, I have a part of speech tagger and I'm lucky enough to get long queries that I can also pos tag. I would think the normal symmetry of query/index would make this usage just fall out of the code but I only see the use case of index payloads. I could hack something so that, for example, I don't use a filter to strip plural s, and instead do it later in the query object. Then I could calculate my Func(query-term) and pass back a similarity that knows about the query payload. Is there a better way? -- View this message in context: http://n3.nabble.com/How-to-calculate-payloads-in-queries-too-tp712743p712743.html Sent from the Lucene - Java Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org