Skip to content

Domain-specific content API call returns raw response #133

@wiazur

Description

@wiazur

Computer Vision

API Name (Kind)

ComputerVision

Issue Description

The AnalyzeImageByDomainAsync() function returns a DomainModelResults.Results, but it is raw JSON response, meaning the user does not know what it can get from this response, until they print the whole response as a JSON dump.

The other API calls do not have this, they have properties that represent the keys.
Requesting a fix so the user is not confused and this function is consistent with the other API calls.

Suggestion: return the properties of the results similar to the following examples:

results.Result.name - the name of the landmark or celebrity
results.Result.confidence - confidence of the correct name or face rectangle
results.Result.faceRectangle.width - gets the dimensions of the found face of a celebrity

https://docs.microsoft.com/en-us/dotnet/api/microsoft.azure.cognitiveservices.vision.computervision.computervisionclientextensions.analyzeimagebydomainasync?view=azure-dotnet#Microsoft_Azure_CognitiveServices_Vision_ComputerVision_ComputerVisionClientExtensions_AnalyzeImageByDomainAsync_Microsoft_Azure_CognitiveServices_Vision_ComputerVision_IComputerVisionClient_System_String_System_String_System_String_System_Threading_CancellationToken_

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions