Table of Contents

Method OnCompletionAsync

Namespace
LMKit.TextGeneration.Filters
Assembly
LM-Kit.NET.dll

OnCompletionAsync(CompletionFilterContext, Func<CompletionFilterContext, Task>)

Called when a completion result is being finalized.

Task OnCompletionAsync(CompletionFilterContext context, Func<CompletionFilterContext, Task> next)

Parameters

context CompletionFilterContext

The filter context. After calling next, inspect or replace Result to transform the output.

next Func<CompletionFilterContext, Task>

The next filter in the pipeline, or the finalization step if this is the last filter. Call await next(context) to continue the pipeline.

Returns

Task

A task representing the asynchronous operation.