microsoft / sample-app-aoai-chatGPT

Sample code for a simple web chat experience through Azure OpenAI, including Azure OpenAI On Your Data.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to help identify and track user by using App Insights

qzhang25 opened this issue · comments

Hi there, currently we are using Application Insight to track the End-to-end transaction details
We realized that the user_id has value but we still don't know how to identify users based on the value it provided.
2024-05-20_11-31-28

Is there way in the code we can edit so that we can replace the user_id value into other value such as username or user_email?

Thanks,

Hi @qzhang25 , we currently don't have Application Insights implemented as a common integration in the webapp, so there isn't much we can do to support this at this time.

We are considering adding this integration in the near future though, so if this is something you'd like to contribute to the repo you are welcome to open up a PR so share this integration with the community. It would be easier for us to conceptualize enhancements such as this if the common integration were in place.

In the meantime, I would recommend checking out the docs for Application Insights to see if there is some middleware you can activate to include custom properties.