1818</ p >
1919< ul >
2020 < li >
21- Types: All rank feature values are floats . Integers are converted to exact whole value floats .
22- String values are converted to exact whole value floats using a hash function.
21+ Types: All rank feature values are doubles or tensors . Integers are converted to exact whole value doubles .
22+ String values are converted to exact whole value doubles using a hash function.
2323 String literals in ranking expressions are converted using the same hash function,
2424 to enable equality tests on string values.
25- </ li > < li >
25+ </ li >
26+ < li >
2627 Features which are < em > normalized</ em > are between 0 and 1, where 0 is always the minimum and 1 the maximum.
2728 Normalized features should normally be preferred because they are more easily combined by
2829 < a href ="ranking-expressions.html "> ranking expressions</ a > into a complete normalized score.
29- </ li > < li >
30+ </ li >
31+ < li >
3032 A query may override < em > any</ em > rank feature value by submitting that value as a feature with the query.
31- </ li > < li >
33+ </ li >
34+ < li >
3235 Some features have parameters. It is always allowed to quote parameters with < em > "</ em > .
3336 Nested quotes are not allowed and must be escaped using < em > \</ em > .
3437 Parameters that can be parsed as feature names may be left unquoted.
@@ -42,11 +45,7 @@ <h2 id="feature-list">Feature list</h2>
4245<!--table-to-list-->
4346< table class ="table " id ="rank-feature-table ">
4447
45-
46-
47-
48-
49- < tr > < td colspan ="3 "> </ td > </ tr >
48+ < tr > < td colspan ="3 "> </ td > </ tr >
5049< tr > < td colspan ="3 "> < h3 id ="query-features "> Query features</ h3 > </ td > </ tr >
5150< tr class ="trx "> < th class ="thx "> Feature name</ th > < th class ="thx "> Default</ th > < th class ="thx "> Description</ th > </ tr >
5251
@@ -381,7 +380,7 @@ <h2 id="feature-list">Feature list</h2>
381380 < td > 0</ td >
382381 < td > < p id ="fieldMatch(name).absoluteOccurrence ">
383382 Returns a normalized measure of the number of occurrence of the terms of the query:
384- </ p > < p class ="equation-container " class =" equation-container " > <!-- depends on mathjax -->
383+ </ p > < p class ="equation-container "> <!-- depends on mathjax -->
385384 $$\frac{\sum_{\text{all query terms}}(min(\text{number of occurrences of the term},maxOccurrences))}{(\text{query term count} × 100)}$$
386385 </ p > < p >
387386 This is 1 if there are many occurrences of the query terms, and 0 if there are none.
@@ -838,10 +837,8 @@ <h3 id="attribute-match-features-normalized">Attribute match features - normaliz
838837 < td > 0</ td >
839838 < td > < p id ="closeness(dimension,name) ">
840839 Used with the < a href ="../querying/yql.html#nearestneighbor "> nearestNeighbor</ a > query operator.
841- A number which is close to 1 when a point vector in the document is close
842- to a matching point vector in the query.
843- The document vectors and the query vector must be the same tensor
844- type, with one indexed dimension of size N, representing a point in an N-dimensional space.
840+ A number which is close to 1 when a vector in the document tensor is close to the vector given in the query.
841+ The indexed dimension representing a vector in document and query tensors must be identical.
845842 </ p >
846843 < ul >
847844 < li >
@@ -899,12 +896,12 @@ <h3 id="attribute-match-features-normalized">Attribute match features - normaliz
899896 < td > < p id ="freshness(name).logscale ">
900897 A logarithmic-shaped freshness; also goes from 1 to 0, but looks like < a href ="#freshness "> freshness plot</ a > .
901898 The function is based on < code > -log(age(name) + scale)</ code > and is calculated as:
902- </ p > < p class ="equation-container " class =" equation-container " > <!-- depends on mathjax -->
899+ </ p > < p class ="equation-container "> <!-- depends on mathjax -->
903900 $$\frac{log(maxAge + scale) - log(age(name) + scale)}{log(maxAge + scale) - log(scale)}$$
904901 </ p > < p >
905902 where scale is defined using
906903 < a href ="rank-feature-configuration.html#freshness "> halfResponse and maxAge</ a > :
907- </ p > < p class ="equation-container " class =" equation-container " > <!-- depends on mathjax -->
904+ </ p > < p class ="equation-container "> <!-- depends on mathjax -->
908905 $$\frac{-halfResponse^2}{2 × halfResponse - maxAge}$$
909906 </ p > < p >
910907 When < code > age(name) == halfResponse</ code > the function output is 0.5.</ p >
0 commit comments