Skip to content

Empty answers in the chat due to the filtered model output #2076

@advanced-flow

Description

@advanced-flow

This issue is for a:

- [x] bug report 
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression 

I noticed completely empty responses for certain user queries (which led to the retrieval of certain documents). I found out via Application Insights that the model output was being filtered by the OpenAi Content Filter. I increased the filter threshold with a custom filter. That worked. However, I think an error message should be issued to the user.

Any log messages given by the failure

Extract of the end-to-end transaction details in Application Insights; here you can see that the model output has been labelled ‘Violence Medium’ and therefore filtered.
image

Expected/desired behavior

Error message to the user informing them that the model output has been flagged by the OpenAI content filter.

OS and Version?

macOS

azd version?

azd version 1.10.3 (commit 0595f33fe948ee6df3da492567e3e7943cb9a733)

Versions

#2045

Metadata

Metadata

Assignees

No one assigned

    Labels

    more info neededAn issue that needs more information from the reporter before it can be addressed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions