semantic-kernel
semantic-kernel copied to clipboard
Initial pass at AppInsights sending custom events
Motivation and Context
Tracking high level user engagement of features can direct further development and enable measurements of active user counts. It is important to note that completions and conversations themselves should not be logged, just data useful in aggregate.
Description
This is an initial pass for review by the team.
Motivation and Context
- This change is essential for tracking user engagement and creating an audit trail of user activity.
- This change adds a basic framework for tracking key telemetry events
- This scenario enables management of those teams deploying instances to understand how their deployment is being used by their team.
- This is not related to an open issue.
Description
The overall design is to add a service accessible to controllers and other services that enables telemetry to be fired with minimal context. For this an abstract ITelemetryService interface was added, allowing systems to fire events on this from across the kernel without any dependencies on a specific implementation.
Contribution Checklist
- [X] The code builds clean without any errors or warnings
- [X] The PR follows SK Contribution Guidelines (https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md)
- [X] The code follows the .NET coding conventions (https://learn.microsoft.com/dotnet/csharp/fundamentals/coding-style/coding-conventions) verified with
dotnet format
- [] All unit tests pass, and I have added new tests where possible - tests appear to fail locally for config related reasons.
- [ ] I didn't break anyone :smile: - maybe myself, a bit...
Apologies for the delay on this, hoping to get back to fixing the defects mid next week.
I've added some docs around using this including some example queries to get people started (as this may be the first time many people are experiencing KQL). I'm not sure if this is too verbose or not. Perhaps if the readme gets much longer we might want to pull the docs out into separate files