IMentorStructured interface
The IMentorStructured interface of Novior.MentorAgent.Abstractions.Interfaces: Typed / structured generation (roadmap #12). Asks the model for a…
On this page
Typed / structured generation (roadmap #12). Asks the model for a strongly-typed result whose JSON schema is derived from the requested type T, so you get back a deserialized object — ideal for auto-filling forms, extracting entities, or building typed generative UI outside the chat flow. Requires a configured ChatClient (Path A) whose provider supports structured outputs (OpenAI / Azure OpenAI).
Definition
Section titled “Definition”Namespace: Novior.MentorAgent.Abstractions.Interfaces. Package: Novior.MentorAgent.Abstractions.
public interface IMentorStructured
dotnet add package Novior.MentorAgent.AbstractionsMethods
Section titled “Methods”GenerateAsync
Section titled “GenerateAsync”Task<T?> GenerateAsync<T>(string prompt, string? instructions = null, CancellationToken ct = default)
Generates a typed T from prompt (with optional system instructions). Returns default if the model output could not be parsed or no ChatClient is configured.
