MentorAgent Docs
Menu

Questa pagina non è ancora tradotta in italiano: qui la trovi in inglese.

ReferencePackage: Novior.MentorAgent.Abstractions

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).

Namespace: Novior.MentorAgent.Abstractions.Interfaces. Package: Novior.MentorAgent.Abstractions.

public interface IMentorStructured

Terminal
dotnet add package Novior.MentorAgent.Abstractions

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.