Debugging the Score Function
You can debug the score functions using the debug_info(str message, float var)
function. The function allows to create and store tuples of messages and numeric values, as part of the query results.
Input
message(str) - the message to be printed after the run
var(float or int) - a variable to be stored as part of the message
Output
(str) - a message that includes the printed output.
Example:
In the above example -
The search results will include two additional keys per candidate, stored under the "similarity" key, corresponding to the messages created using debug_info in the score function.
Last updated