Method Cancelled
- Namespace
- LMKit.Agents.Orchestration
- Assembly
- LM-Kit.NET.dll
Cancelled(IReadOnlyList<AgentExecutionResult>, TimeSpan, int)
Creates a cancelled orchestration result.
public static OrchestrationResult Cancelled(IReadOnlyList<AgentExecutionResult> agentResults = null, TimeSpan duration = default, int totalInferenceCount = 0)
Parameters
agentResultsIReadOnlyList<AgentExecutionResult>durationTimeSpantotalInferenceCountint
Returns
Examples
Returning a cancelled result on cooperative shutdown:
catch (OperationCanceledException)
{
return OrchestrationResult.Cancelled(
agentResults: collectedSoFar,
duration: stopwatch.Elapsed);
}