All Downloads are FREE. Search and download functionalities are using the official Maven repository.

hover.rankExpression.foreach(dimension,variable,feature,condition,operation).md Maven / Gradle / Ivy

foreach iterates over a set of feature output values and performs an operation on them.
Only the values where the condition evaluates to true are considered for the operation.
The result of this operation is returned.


dimension: Specifies what to iterate over. This can be:

terms: All query term indices, from 0 and up to
[maxTerms](https://docs.vespa.ai/en/reference/rank-feature-configuration.html#foreach).
fields: All index field names.
attributes: All attribute field names.

variable: The name of the variable 'storing' each of the items you are iterating over.
feature: The name of the feature you want to use the output value from. Use the variable as part of the feature name, and for each item you iterate over this variable is replaced with the actual item.
Note that the variable replacement is a simple string replace, so you should use a variable name
that is not in conflict with the feature name.
condition: The condition used on each feature output value to find out if the value should be considered by the operation. The condition can be:

>a: Use feature output if greater than number a.
0", average)`.

Note that when using the conditions >a and 




© 2015 - 2025 Weber Informatics LLC | Privacy Policy