26 references to Throw
Microsoft.Extensions.AI.Evaluation.Safety (26)
CodeVulnerabilityEvaluator.cs (2)
53_ = Throw.IfNull(chatConfiguration); 54_ = Throw.IfNull(modelResponse);
ContentHarmEvaluator.cs (2)
55_ = Throw.IfNull(chatConfiguration); 56_ = Throw.IfNull(modelResponse);
ContentSafetyChatClient.cs (3)
148Throw.ArgumentException(nameof(messages), ErrorMessage); 156Throw.ArgumentException(nameof(messages), ErrorMessage); 172Throw.ArgumentNullException(nameof(_originalChatClient), errorMessage);
ContentSafetyEvaluator.cs (3)
50_ = Throw.IfNull(chatConfiguration); 97_ = Throw.IfNull(contentSafetyServiceChatClient); 98_ = Throw.IfNull(modelResponse);
ContentSafetyServiceConfiguration.cs (7)
135Credential = Throw.IfNull(credential); 136SubscriptionId = Throw.IfNullOrWhitespace(subscriptionId); 137ResourceGroupName = Throw.IfNullOrWhitespace(resourceGroupName); 138ProjectName = Throw.IfNullOrWhitespace(projectName); 178Credential = Throw.IfNull(credential); 179Endpoint = Throw.IfNull(endpoint); 220endpoint: new Uri(Throw.IfNullOrWhitespace(endpointUrl)),
ContentSafetyServiceConfigurationExtensions.cs (2)
38_ = Throw.IfNull(contentSafetyServiceConfiguration); 75_ = Throw.IfNull(contentSafetyServiceConfiguration);
EvaluationMetricExtensions.cs (1)
91Throw.ArgumentException(paramName: nameof(data), message);
GroundednessProEvaluator.cs (2)
54_ = Throw.IfNull(chatConfiguration); 55_ = Throw.IfNull(modelResponse);
ProtectedMaterialEvaluator.cs (2)
73_ = Throw.IfNull(chatConfiguration); 74_ = Throw.IfNull(modelResponse);
UngroundedAttributesEvaluator.cs (2)
58_ = Throw.IfNull(chatConfiguration); 59_ = Throw.IfNull(modelResponse);