Reinforcement Tuning String Match Reward Scorer
ReinforcementTuningStringMatchRewardScorer is used to score parsed responses for string matching use cases. For example, for math problems, users can use string match scorer to check if the correct exact answer is generated. Note: Reward returned by the string match reward function is clipped to be within [-1, 1] if wrongAnswerReward or correctAnswerReward are beyond the range, i.e., reward = max(min(reward, 1.0), -1.0). This data type is not supported in Gemini API.
Constructors
Properties
Correct answer rewawrd is returned if the parsed response is evaluated as true. All correct answers get the same reward.
Uses json match expression to evaluate parsed response.
Uses string match expression to evaluate parsed response.
Wrong answer reward is returned if the parsed response is evaluated as false. All wrong answers get the same reward.