Details
-
Improvement
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
The following functions all take exactly 2 arguments: a field name, and a term value...
- idf
- termfreq
- tf
- totaltermfreq
...we should consider adding an optional third argument to indicate if an analyzer for the specified field should be used on the input to find the real "Term" to consider.
For example, the following might all result in equivilent numeric values for all docs assuming simple plural stemming and lowercasing...
termfreq(foo_t,'Bicycles',query) // use the query analyzer for field foo_t on input Bicycles termfreq(foo_t,'Bicycles',index) // use the index analyzer for field foo_t on input Bicycles termfreq(foo_t,'bicycle',none) // no analyzer used to construct Term termfreq(foo_t,'bicycle') // legacy 2 arg syntax, same as 'none'
(Special error checking needed if analyzer creates more then one term for the given input string)