Sorry Erik, I did not really get this about similarity, what/why should it be done?
We had a brief thread on something related a long while ago... on whether factors related to scoring should all go through Similarity so that there is a central place to tweak the factors. That seems a bit too inflexible in one sense, but discussing it hopefully at least keep the complexity understood and perhaps lead to taming it.
Probably the way this difference is used in the similarity calculation could be placed somewhere in the Similarity using the other method than setBoost(), but actual calculation of the distance is one level lower than this. At a moment I have no better ideas than to leave this as it is (via setBoost()).
Maybe come up with a FuzzyDistanceCalculator interface with a difference() method, and we pass that into FuzzyQuery so that it uses a "dependency injection" pattern allowing the outside world to customize the computation without having various FuzzyQuery-like cloned classes to tweak the forumla.
We can still use setBoost - I was merely bringing up Similarity as one idea of where to allow formula customizations.
Erik
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]