MentorStructuredService class
The MentorStructuredService class of Novior.MentorAgent.Core: Default IMentorStructured implementation (roadmap #12). Uses the configured ChatClient's…
On this page
Default IMentorStructured implementation (roadmap #12). Uses the configured ChatClient's structured-output support (GetResponseAsync<T>) — the JSON schema is derived from the requested type T and the response is deserialized back to it.
Definition
Section titled “Definition”Namespace: Novior.MentorAgent.Core. Package: Novior.MentorAgent.
public sealed class MentorStructuredService : IMentorStructured
Implements IMentorStructured.
dotnet add package Novior.MentorAgentConstructors
Section titled “Constructors”public MentorStructuredService(IOptions<MentorOptions> options, ILogger<MentorStructuredService> logger)
Methods
Section titled “Methods”GenerateAsync
Section titled “GenerateAsync”public Task<T?> GenerateAsync<T>(string prompt, string? instructions = null, CancellationToken ct = default)
