Class OllamaMessageConnector
public class OllamaMessageConnector : IStreamingMiddleware, IMiddleware
- Inheritance
-
OllamaMessageConnector
- Implements
- Inherited Members
Properties
Name
the name of the middleware
public string Name { get; }
Property Value
Methods
InvokeAsync(MiddlewareContext, IAgent, CancellationToken)
The method to invoke the middleware
public Task<IMessage> InvokeAsync(MiddlewareContext context, IAgent agent, CancellationToken cancellationToken = default)
Parameters
context
MiddlewareContextagent
IAgentcancellationToken
CancellationToken
Returns
InvokeAsync(MiddlewareContext, IStreamingAgent, CancellationToken)
The streaming version of InvokeAsync(MiddlewareContext, IAgent, CancellationToken).
public IAsyncEnumerable<IMessage> InvokeAsync(MiddlewareContext context, IStreamingAgent agent, CancellationToken cancellationToken = default)
Parameters
context
MiddlewareContextagent
IStreamingAgentcancellationToken
CancellationToken