Method JudgeAsync
- Namespace
- IntentSharp.Verification
- Assembly
- IntentSharp.dll
JudgeAsync(PromptPlan, string, string?, CancellationToken)
Asks the provider whether candidateOutput satisfies the intent for the input, in one model call.
A reply that is not JSON passes, with a Warning logged, so a faulty judge never blocks a result.
public Task<(JudgeVerdict verdict, AIResponse response)> JudgeAsync(PromptPlan plan, string candidateOutput, string? model, CancellationToken cancellationToken)
Parameters
planPromptPlanThe operation being verified: its intent, input and output requirements.
candidateOutputstringThe model output, which has already passed the checks against the result type and the request's rules.
modelstringThe model to judge with; null uses the provider's default model.
cancellationTokenCancellationTokenCancels the judge call.
Returns
- Task<(JudgeVerdict verdict, AIResponse response)>