Ex:
Request post URL: https://westus.api.cognitive.microsoft.com/contentmoderator/moderate/v1.0/ProcessText/Screen?autocorrect=false&PII=false&classify=True
Note that listID is not included
But in the response you see the 'terms' having objects showing one of my created lists.
"Terms": [
{
"Index": 0,
"OriginalIndex": 0,
"ListId": 661,
"Term": "1 800"
},
{
"Index": 11,
"OriginalIndex": 11,
"ListId": 661,
"Term": "stupid"
}
],
⚠Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
@skantipu Thanks for the question. We are investigating the issue and will update you shortly.
@skantipu Could you please share request body that you are trying.
@PatrickFarley Can you please confirm on this response.
@ram-msft This is an issue with product behavior, not documentation. Please unassign me
@skantipu Could you please share request body that you are trying.
@PatrickFarley Can you please confirm on this response.
Here is the curl:
curl -X POST \
'https://westus.api.cognitive.microsoft.com/contentmoderator/moderate/v1.0/ProcessText/Screen?autocorrect=false&PII=false&classify=True' \
-H 'Accept: */*' \
-H 'Accept-Encoding: gzip, deflate' \
-H 'Cache-Control: no-cache' \
-H 'Connection: keep-alive' \
-H 'Content-Length: 18' \
-H 'Content-Type: text/plain' \
-H 'Host: westus.api.cognitive.microsoft.com' \
-H 'Postman-Token: a477b3d6-f0e9-4964-bf90-b6b861154d7c,eb527ed8-0d1a-47c1-9c80-dba784dbf0b9' \
-H 'User-Agent: PostmanRuntime/7.19.0' \
-H 'cache-control: no-cache' \
-d '1 800 1801 stupid '
Here is the response:
{
"OriginalText": "1 800 1801 stupid ",
"NormalizedText": "1 800 1801 stupid ",
"Misrepresentation": null,
"Classification": {
"ReviewRecommended": true,
"Category1": {
"Score": 0.0071512144058942795
},
"Category2": {
"Score": 0.21704921126365662
},
"Category3": {
"Score": 0.98799997568130493
}
},
"Language": "eng",
"Terms": [
{
"Index": 0,
"OriginalIndex": 0,
"ListId": 661,
"Term": "1 800"
},
{
"Index": 11,
"OriginalIndex": 11,
"ListId": 661,
"Term": "stupid"
}
],
"Status": {
"Code": 3000,
"Description": "OK",
"Exception": null
},
"TrackingId": "WU_ibiza_dc460e07-1efe-4c0c-a07f-623eac4b6304_ContentModerator.F0_ff219c61-6c70-4570-a62d-a3846b522678"
}
I don't understand how it takes ListId: 661 when the request does not mention/suggest to use any pre-created list id.
We're planning to integrate the API into our product with the Standard plan, but looks like the API is not stable enough with the unresolved bugs in it. I filed another one here - https://github.com/MicrosoftDocs/azure-docs/issues/42243. Would appreciate if you guys can take it on priority.
This is a product issue not a doc issue. Please file this with the appropriate product forum: https://cognitive.uservoice.com/forums/559960-content-moderator and close this issue.
Thank you
@skantipu Please file the issue in the following content-moderator user voice forum so the community can vote and provide their feedback,the product team then checks this feedback and implements this in future releases.
We will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and we will reopen the issue.
Thanks, posted in the requested place here - https://cognitive.uservoice.com/forums/559960-content-moderator/suggestions/39027517-screen-api-even-though-the-listid-query-param