Method AIFilterAsync
- Namespace
- IntentSharp.Extensions
- Assembly
- IntentSharp.dll
AIFilterAsync<T>(IEnumerable<T>, IntentClient, string, AIRequestOptions?, CancellationToken)
Keeps the elements that satisfy the intent. The model returns zero-based indices; the original objects are returned unchanged, so identity and unserialized state are preserved.
public static Task<AIResult<List<T>>> AIFilterAsync<T>(this IEnumerable<T> input, IntentClient client, string intent, AIRequestOptions? options = null, CancellationToken cancellationToken = default)
Parameters
inputIEnumerable<T>clientIntentClientintentstringoptionsAIRequestOptionscancellationTokenCancellationToken
Returns
- Task<AIResult<List<T>>>
Type Parameters
T