Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Language API 2022-03-01-preview #18443

Closed

Conversation

abhahn
Copy link
Member

@abhahn abhahn commented Mar 28, 2022

MSFT employees can try out our new experience at OpenAPI Hub - one location for using our validation tools and finding your workflow.

Changelog

Add a changelog entry for this PR by answering the following questions:

  1. What's the purpose of the update?
    • new service onboarding
    • new API version
    • update existing version for new feature
    • update existing version to fix swagger quality issue in s360
    • Other, please clarify
  2. When are you targeting to deploy the new service/feature to public regions? Please provide the date or, if the date is not yet available, the month.
  3. When do you expect to publish the swagger? Please provide date or, the the date is not yet available, the month.
  4. If updating an existing version, please select the specific language SDKs and CLIs that must be refreshed after the swagger is published.
    • SDK of .NET (need service team to ensure code readiness)
    • SDK of Python
    • SDK of Java
    • SDK of Js
    • SDK of Go
    • PowerShell
    • CLI
    • Terraform
    • No refresh required for updates in this PR

Contribution checklist:

If any further question about AME onboarding or validation tools, please view the FAQ.

ARM API Review Checklist

Applicability: ⚠️

If your changes encompass only the following scenarios, you should SKIP this section, as these scenarios do not require ARM review.

  • Change to data plane APIs
  • Adding new properties
  • All removals

Otherwise your PR may be subject to ARM review requirements. Complete the following:

  • Check this box if any of the following apply to the PR so that label "WaitForARMFeedback" will be added automatically to begin ARM API Review. Failure to comply may result in delays to the manifest.

    • Adding a new service
    • Adding new API(s)
    • Adding a new API version
      -[ ] To review changes efficiently, ensure you are using OpenAPIHub to initialize the PR for adding a new version. More details, refer to the wiki.
  • Ensure you've reviewed following guidelines including ARM resource provider contract and REST guidelines. Estimated time (4 hours). This is required before you can request review from ARM API Review board.

  • If you are blocked on ARM review and want to get the PR merged with urgency, please get the ARM oncall for reviews (RP Manifest Approvers team under Azure Resource Manager service) from IcM and reach out to them.

Breaking Change Review Checklist

If any of the following scenarios apply to the PR, request approval from the Breaking Change Review Board as defined in the Breaking Change Policy.

  • Removing API(s) in a stable version
  • Removing properties in a stable version
  • Removing API version(s) in a stable version
  • Updating API in a stable or public preview version with Breaking Change Validation errors
  • Updating API(s) in public preview over 1 year (refer to Retirement of Previews)

Action: to initiate an evaluation of the breaking change, create a new intake using the template for breaking changes. Addition details on the process and office hours are on the Breaking change Wiki.

Please follow the link to find more details on PR review process.

abhahn and others added 5 commits February 3, 2022 15:44
* Add Swagger files for CLU 2022-03-01-preview

* Fix prettier errors

* Fix sub id description

* Try to fix the missing API error

* Try to resolve the error of missing APIs in the default tag

* Remove 2022-02-01 CLU files

* Resolve comments

* Resolve comments

* Resolve more comments

Co-authored-by: Chong Tang <chot@microsoft.com>
* Add blockchain to latest profile

* Add additional types

* WIP for language api spec for TA

* Updated preview version number; finished up async definitions

* Finished first draft of full spec

* Finished first draft of full spec, minus FHIR structuring in HC output

* Removed features not included in 2021-11-01 preview

* Update custom text tasks TODOs

* Moved common definitions to TA-specific definitions

* Added custom text tasks to JobManifest

* Addressing feedback from PR comments and internal review

* Addressed some PR comments

* Updated some remaining references to documents

* PR comments

* Updated a previous change

* Reverted references to 'records' back to 'documents'

* A few small updates to examples; removed base Task type to simplify structure

* PR comments

* Addressed TODO items; removed LD-related objects (will be added in another preview)

* Fixed anonymous types

* Removed required field for body in POST request

* Fix prettier check

* Added a few more details; experimental change for documents property

* Ran prettier

* Correction to AnalysisInput object

* Merged changes from 2021-11-01-preview and moved new changes to 2022-02-01

* PR comments

* Updates to the design for tasks

* Added custom entities task to examples

* Updates

* Finished implementation of discriminator pattern and added some exmaples

* Updates

* Prettier

* Fixed semantic validation errors

* Fixed model validation

* Another model validation fix

* Debugging model validation errors

* Using a different discriminator enum for output schemas

* Fixed some missing discriminator updates

* More semantic validation fixes

* Fixed model validation errors; updated sample names

* Fixed linting errors and addressed some warnings in the linter output

* Ran prettier on examples

* PR comments and some minor restructuring

* Ran prettier

* Removed a duplicate schema from CustomEntitiesTaskParameters

* PR comments

* PR comments

* PR comments

* Added missing job task status 'partiallySucceeded'

* Added preview folder for 2022-03-01-preview

* Added delete and cancel operations for jobs

* Added some examples for delete and cancel; updated samples for new preview

* Incorporating feedback from the API review

* fix naming consistency (#1)

* naming updates

* fix typo

* Fixed one last merge conflict

* naming fix (#2)

* Fixed a ref

* Ran prettier on all files

Co-authored-by: Mark Cowlishaw <markcowl@microsoft.com>
Co-authored-by: Abigail Hartman <Abigail.Hartman@microsoft.com>
Co-authored-by: Kareem Yousef <kayousef@microsoft.com>
Co-authored-by: Abby Hartman <abhahn@microsoft.com>
Co-authored-by: Mohamed Shaban <official.mohamedshaban@gmail.com>
@abhahn abhahn requested a review from a team as a code owner March 28, 2022 23:10
@abhahn abhahn requested review from markweitzel and johanste and removed request for a team March 28, 2022 23:10
@openapi-pipeline-app
Copy link

Swagger pipeline can not start as the pull request has merge conflicts.

@openapi-workflow-bot
Copy link

Hi, @abhahn Thanks for your PR. I am workflow bot for review process. Here are some small tips.

  • Please ensure to do self-check against checklists in first PR comment.
  • PR assignee is the person auto-assigned and responsible for your current PR reviewing and merging.
  • For specs comparison cross API versions, Use API Specs Comparison Report Generator
  • If there is CI failure(s), to fix CI error(s) is mandatory for PR merging; or you need to provide justification in PR comment for explanation. How to fix?

  • Any feedback about review process or workflow bot, pls contact swagger and tools team. vscswagger@microsoft.com

    @openapi-pipeline-app
    Copy link

    Swagger pipeline can not start as the pull request has merge conflicts.

    @openapi-workflow-bot
    Copy link

    [Call for Action] To better understand Azure service dev/test scenario, and support Azure service developer better on Swagger and REST API related tests in early phase, please help to fill in with this survey https://aka.ms/SurveyForEarlyPhase. It will take 5 to 10 minutes. If you already complete survey, please neglect this comment. Thanks.

    Copy link
    Member

    @heaths heaths left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    I think all the changes mentioned below in my findings based on semantic diffs are expected, but do keep in mind the old enum values should be supported for that api-version (2022-02-01-preview) for 90d after deprecation notice. Our generated SDK, though, won't support them.

    Rather than comment on individual lines in the swaggers, here's my documented findings from OpenAPI Hub:

    common.json

    2021-11-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/main/specification/cognitiveservices/data-plane/Language/preview/2021-11-01-preview/common.json
    2022-02-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/main/specification/cognitiveservices/data-plane/Language/preview/2022-02-01-preview/common.json
    2022-03-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/472892b0addc164993e68f48fb2629c664c08065/specification/cognitiveservices/data-plane/Language/preview/2022-03-01-preview/common.json
    Diff 2021-11-01-preview to 2022-02-01-preview (no changes): https://portal.azure-devex-tools.com/tools/diff/eyJzb3VyY2VVcmwiOiJodHRwczovL3Jhdy5naXRodWJ1c2VyY29udGVudC5jb20vQXp1cmUvYXp1cmUtcmVzdC1hcGktc3BlY3MvbWFpbi9zcGVjaWZpY2F0aW9uL2NvZ25pdGl2ZXNlcnZpY2VzL2RhdGEtcGxhbmUvTGFuZ3VhZ2UvcHJldmlldy8yMDIxLTExLTAxLXByZXZpZXcvY29tbW9uLmpzb24iLCJ0YXJnZXRVcmwiOiJodHRwczovL3Jhdy5naXRodWJ1c2VyY29udGVudC5jb20vQXp1cmUvYXp1cmUtcmVzdC1hcGktc3BlY3MvbWFpbi9zcGVjaWZpY2F0aW9uL2NvZ25pdGl2ZXNlcnZpY2VzL2RhdGEtcGxhbmUvTGFuZ3VhZ2UvcHJldmlldy8yMDIyLTAyLTAxLXByZXZpZXcvY29tbW9uLmpzb24ifQ==
    Diff 2022-02-01-preview to 2022-03-01-preview (expected changes): https://portal.azure-devex-tools.com/tools/diff/eyJzb3VyY2VVcmwiOiJodHRwczovL3Jhdy5naXRodWJ1c2VyY29udGVudC5jb20vQXp1cmUvYXp1cmUtcmVzdC1hcGktc3BlY3MvbWFpbi9zcGVjaWZpY2F0aW9uL2NvZ25pdGl2ZXNlcnZpY2VzL2RhdGEtcGxhbmUvTGFuZ3VhZ2UvcHJldmlldy8yMDIyLTAyLTAxLXByZXZpZXcvY29tbW9uLmpzb24iLCJ0YXJnZXRVcmwiOiJodHRwczovL3Jhdy5naXRodWJ1c2VyY29udGVudC5jb20vQXp1cmUvYXp1cmUtcmVzdC1hcGktc3BlY3MvNDcyODkyYjBhZGRjMTY0OTkzZTY4ZjQ4ZmIyNjI5YzY2NGMwODA2NS9zcGVjaWZpY2F0aW9uL2NvZ25pdGl2ZXNlcnZpY2VzL2RhdGEtcGxhbmUvTGFuZ3VhZ2UvcHJldmlldy8yMDIyLTAzLTAxLXByZXZpZXcvY29tbW9uLmpzb24ifQ==

    analyzeconversations.json

    2021-11-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/main/specification/cognitiveservices/data-plane/Language/preview/2021-11-01-preview/analyzeconversations.json
    2022-03-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/472892b0addc164993e68f48fb2629c664c08065/specification/cognitiveservices/data-plane/Language/preview/2022-03-01-preview/analyzeconversations.json
    Diff: https://portal.azure-devex-tools.com/tools/diff/eyJzb3VyY2VVcmwiOiJodHRwczovL3Jhdy5naXRodWJ1c2VyY29udGVudC5jb20vQXp1cmUvYXp1cmUtcmVzdC1hcGktc3BlY3MvbWFpbi9zcGVjaWZpY2F0aW9uL2NvZ25pdGl2ZXNlcnZpY2VzL2RhdGEtcGxhbmUvTGFuZ3VhZ2UvcHJldmlldy8yMDIxLTExLTAxLXByZXZpZXcvYW5hbHl6ZWNvbnZlcnNhdGlvbnMuanNvbiIsInRhcmdldFVybCI6Imh0dHBzOi8vcmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbS9BenVyZS9henVyZS1yZXN0LWFwaS1zcGVjcy80NzI4OTJiMGFkZGMxNjQ5OTNlNjhmNDhmYjI2MjljNjY0YzA4MDY1L3NwZWNpZmljYXRpb24vY29nbml0aXZlc2VydmljZXMvZGF0YS1wbGFuZS9MYW5ndWFnZS9wcmV2aWV3LzIwMjItMDMtMDEtcHJldmlldy9hbmFseXplY29udmVyc2F0aW9ucy5qc29uIn0=

    • Expected change: Endpoint /:analyze-conversations now takes a JSON body with more properties than previous parameters.
    • Supported change: Model AnalyzeConversationResult -> AnalyzeConversationTaskResult
    • Actually quite a few changes, but because these are between prereleases are of little consequence.

    textanalytics.json

    2022-02-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/main/specification/cognitiveservices/data-plane/Language/preview/2022-02-01-preview/textanalytics.json
    2022-03-01-preview: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/472892b0addc164993e68f48fb2629c664c08065/specification/cognitiveservices/data-plane/Language/preview/2022-03-01-preview/textanalytics.json
    Diff: https://portal.azure-devex-tools.com/tools/diff/eyJzb3VyY2VVcmwiOiJodHRwczovL3Jhdy5naXRodWJ1c2VyY29udGVudC5jb20vQXp1cmUvYXp1cmUtcmVzdC1hcGktc3BlY3MvbWFpbi9zcGVjaWZpY2F0aW9uL2NvZ25pdGl2ZXNlcnZpY2VzL2RhdGEtcGxhbmUvTGFuZ3VhZ2UvcHJldmlldy8yMDIyLTAyLTAxLXByZXZpZXcvdGV4dGFuYWx5dGljcy5qc29uIiwidGFyZ2V0VXJsIjoiaHR0cHM6Ly9yYXcuZ2l0aHVidXNlcmNvbnRlbnQuY29tL0F6dXJlL2F6dXJlLXJlc3QtYXBpLXNwZWNzLzQ3Mjg5MmIwYWRkYzE2NDk5M2U2OGY0OGZiMjYyOWM2NjRjMDgwNjUvc3BlY2lmaWNhdGlvbi9jb2duaXRpdmVzZXJ2aWNlcy9kYXRhLXBsYW5lL0xhbmd1YWdlL3ByZXZpZXcvMjAyMi0wMy0wMS1wcmV2aWV3L3RleHRhbmFseXRpY3MuanNvbiJ9

    • New endpoint: /analyze-text/jobs/{jobId}:cancel
    • Breaking change: AnalyzeTextLROTaskKind.CustomSingleClassification -> AnalyzeTextLROTaskKind.CustomSingleLabelClassification
    • Breaking change: AnalyzeTextLROTaskKind.CustomMultiClassification -> AnalyzeTextLROTaskKind.CustomMultiLabelClassification
    • Breaking change: AnalyzeTextLROResultsKind.CustomSingleClassificationLROResults -> AnalyzeTextLROResultsKind.CustomSingleLabelClassificationLROResults
    • Breaking change: AnalyzeTextLROResultsKind.CustomMultiClassificationLROResults -> AnalyzeTextLROResultsKind.CustomMultiLabelClassificationLROResults
    • Breaking change: For the discriminating enum values above, the model names also changed accordingly.

    Comment on lines +13 to +21
    ```yaml
    tag: release_2022_03_01_preview
    add-credentials: true
    clear-output-folder: true
    openapi-type: data-plane
    directive:
    - suppress: LongRunningResponseStatusCode
    reason: The validation tools do not properly recognize 202 as a supported response code.
    ```
    Copy link
    Member

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    These are top-level statements and there can be only one. Please remove new lines 23 through 56 inclusively.

    Copy link
    Member

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    In the future, you only need to update the top-level tag: property.

    @heaths
    Copy link
    Member

    heaths commented Mar 29, 2022

    @weshaggard this branch was created with OpenAPI Hub and has a specific branch policy on it. Can you remove it so that the dev-* branch policy applies instead and @abhahn can force push her rebased commits?

    @openapi-pipeline-app
    Copy link

    Swagger pipeline can not start as the pull request has merge conflicts.

    1 similar comment
    @openapi-pipeline-app
    Copy link

    Swagger pipeline can not start as the pull request has merge conflicts.

    @openapi-pipeline-app
    Copy link

    Swagger pipeline can not start as the pull request has merge conflicts.

    1 similar comment
    @openapi-pipeline-app
    Copy link

    Swagger pipeline can not start as the pull request has merge conflicts.

    @heaths
    Copy link
    Member

    heaths commented Apr 4, 2022

    We may want to close this one in favor of #18541 since we can't force push a rebase. Though, the real problem is when people do a normal merge commit from main that it introduces hundreds of commits and thousands of files (depending on the feature branch's lifetime). The two files conflicting could be edited manually instead of rebasing, but I created #18541 to try out another documented workflow.

    /cc @abhahn

    @heaths
    Copy link
    Member

    heaths commented Apr 6, 2022

    Closing this now that #18541 is merged.

    @heaths heaths closed this Apr 6, 2022
    @heaths heaths deleted the dev-cognitiveservices-Language-2022-03-01-preview branch April 6, 2022 23:24
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    None yet
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    4 participants