Utility Selector

Utility selector is a tool responsible for selecting one of evaluated Contexts based on scores produced by evaluators. Selector Context can take form of any built-in or user-defined data type.

For utility selector to work, a user must provide it with a collection of evaluated Contexts and their evaluators. Also the selector’s Context type needs to match the type of all given evaluators.

Public Interface

Evaluate Object Weight

Return weight of a given Context.

Evaluate Object Rank

Returns rank of a given Context.

Get Best Option

Returns the most suitable Context based on data fed to the function.

Selector will consider only Contexts with highest rank and choose most suitable one depending on selection method provided by user.

User should pass following arguments to this method
  1. the selection method - MAX or ROULETTE

  2. a collection of Contexts and corresponding evaluators

  3. validator - a function determining whether an evaluated Context is valid and can be chosen at the moment of selection

API Reference

  • C++

  • C#