Class ReinforcementTuningStringMatchRewardScorer
Scores parsed responses for string matching use cases.
public record ReinforcementTuningStringMatchRewardScorer : IEquatable<ReinforcementTuningStringMatchRewardScorer>
- Inheritance
-
ReinforcementTuningStringMatchRewardScorer
- Implements
- Inherited Members
Properties
CorrectAnswerReward
Correct answer reward is returned if evaluator evaluates to true. All correct answers get
the same reward.
[JsonPropertyName("correctAnswerReward")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public double? CorrectAnswerReward { get; set; }
Property Value
JsonMatchExpression
Uses json match expression to evaluate parsed response.
[JsonPropertyName("jsonMatchExpression")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public ReinforcementTuningStringMatchRewardScorerJsonMatchExpression? JsonMatchExpression { get; set; }
Property Value
StringMatchExpression
Uses string match expression to evaluate parsed response.
[JsonPropertyName("stringMatchExpression")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public ReinforcementTuningStringMatchRewardScorerStringMatchExpression? StringMatchExpression { get; set; }
Property Value
WrongAnswerReward
Wrong answer reward is returned if evaluator evaluates to false. All wrong answers get the
same reward.
[JsonPropertyName("wrongAnswerReward")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public double? WrongAnswerReward { get; set; }
Property Value
Methods
FromJson(string, JsonSerializerOptions?)
Deserializes a JSON string to a ReinforcementTuningStringMatchRewardScorer object.
public static ReinforcementTuningStringMatchRewardScorer? FromJson(string jsonString, JsonSerializerOptions? options = null)
Parameters
jsonStringstringThe JSON string to deserialize.
optionsJsonSerializerOptionsOptional JsonSerializerOptions.
Returns
- ReinforcementTuningStringMatchRewardScorer
The deserialized ReinforcementTuningStringMatchRewardScorer object, or null if deserialization fails.