: aaah -- Just to be clear, if you could augment the doc list with a calculated
: field ('distance') you would not need to extend XMLWritter - correct?
:
: And then it would also work with the JSON/pyton/php etc writers.
i don't think i ever looked at the patch in question (is it in Jira?) but
i would definitely recommend going a route like this rather then adding a
new "primitive" type that all the ResponseWriters would need to know
about.
Personally: i don't even think "augmenting DocList" should be done ...
once the distance score calculations are done, and the documents are
ordered, returning the distance as numeric value for the clients is really
no different then returning highlighting info or score explanations ... it
should be a seperate piece of info in the response.
(i think if we had it to do all over again, i would suggest the same
approach for returning the "scores" of docs ... at the moment there is
ambiguity between the relevancy score and the possibility of a field named
"score")
-Hoss