Example of Telemetry in ASP.NET Core AI AssistView Control
This sample demonstrates the telemetry functionality in the AI AssistView. When enabled, it captures per-turn metrics such as response duration, streaming chunks, model identifier, and token usage, and reports them on every response.
DEMO
SOURCE
In this example, the telemetrySettings enable property is set to true, so each prompt/response turn automatically reports its metrics. Additionally, the bannerTemplate customizes the banner content, and toolbarSettings adds custom toolbar items like a right-aligned Refresh button. The promptSuggestions provides AI prompt suggestions, and promptRequest handles prompt requests when triggered. Hover the duration chip shown in the response toolbar to inspect the metric breakdown for that turn.