Skip to content

Adding split argument in document intelligence sample #41618

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Abhishek0075
Copy link

Description

Added split mode argument in sdk/documentintelligence/azure-ai-documentintelligence/samples to mention to user about the argument

@Copilot Copilot AI review requested due to automatic review settings June 17, 2025 13:57
@Abhishek0075 Abhishek0075 requested a review from bojunehsu as a code owner June 17, 2025 13:57
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request updates the document classification sample by adding a split mode argument to the classifier call.

  • Updated the call to begin_classify_document to include the "split" keyword argument with the value "perPage".
  • Enhances the sample by showing how to control document splitting behavior.
Comments suppressed due to low confidence (1)

sdk/documentintelligence/azure-ai-documentintelligence/samples/sample_classify_document.py:54

  • [nitpick] Consider adding an inline comment explaining the purpose of the 'split' argument and describing valid values (e.g., 'perPage') to better inform users of how to adjust the sample behavior.
        poller = document_intelligence_client.begin_classify_document(classifier_id, split="perPage", body=f)

@github-actions github-actions bot added Community Contribution Community members are working on the issue customer-reported Issues that are reported by GitHub users external to the Azure organization. Document Intelligence labels Jun 17, 2025
Copy link

Thank you for your contribution @Abhishek0075! We will review the pull request and get back to you soon.

@bojunehsu bojunehsu requested a review from yungshinlintw June 17, 2025 16:25
@yungshinlintw
Copy link

Hi @Abhishek0075, thanks a lot for your contribution! Your code change does look good and it helps the quality of the sample.

However, your contribution exposes an issue in the current build that is not related to your contribution:
https://github.com/Azure/azure-sdk-for-python/pull/41618/checks?check_run_id=44264857120

From a quick traige, it appears that this is a false postive on pylint. However, we need to update SDK to be able to supress the false positive correctly. We will look into updating the SDK in the near future. Please stay tuned on this. Thanks for your patience!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Community Contribution Community members are working on the issue customer-reported Issues that are reported by GitHub users external to the Azure organization. Document Intelligence
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants