[AutoPR azure-ai-contentunderstanding]-generated-from-SDK Generation - Java-5634426#47441
Closed
azure-sdk wants to merge 123 commits intoAzure:mainfrom
Closed
[AutoPR azure-ai-contentunderstanding]-generated-from-SDK Generation - Java-5634426#47441azure-sdk wants to merge 123 commits intoAzure:mainfrom
azure-sdk wants to merge 123 commits intoAzure:mainfrom
Conversation
…', API Version: 2025-11-01, SDK Release Type: beta, and CommitSHA: 'd0cd556bd91d2dda700e983c0d253fa025b324c0' in SpecRepo: 'https://github.com/Azure/azure-rest-api-specs' Pipeline run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=5634426 Refer to https://eng.ms/docs/products/azure-developer-experience/develop/sdk-release/sdk-release-prerequisites to prepare for SDK release.
Contributor
API Change CheckAPIView identified API level changes in this PR and created the following API reviews |
…entunderstanding-5634426
…nts in Content Understanding SDK
… from .NET SDK - Sample00_ConfigureDefaults: Demonstrates configuration management (get/update defaults) - Sample01_AnalyzeBinary: Binary PDF analysis from local file - Sample02_AnalyzeUrl: Analyze documents from URL - Sample03_AnalyzeInvoice: Extract structured invoice fields with nested objects and arrays - Sample04_CreateAnalyzer: Create and use custom analyzer with field schema (Extract/Generate/Classify methods) Key features: - All samples use DefaultAzureCredentialBuilder for authentication - Environment variable based configuration (ENDPOINT) - Comprehensive JUnit 5 tests with assertions - GitHub public URLs for test data - Proper field access patterns with type casting (ContentField, StringField, NumberField, ObjectField, ArrayField) - All tests passing (6/6 = 100% success rate) Technical implementation: - Fixed API differences from C# SDK (ContentSpan, ContentField, 5-parameter beginAnalyze) - Proper null checking and type casting for all field access - Detailed validation assertions for all document properties - Clean resource management with @AfterEach cleanup Module-info.java formatting cleanup included.
- Sample05_CreateClassifier: Create classifier analyzer with multiple classification fields (document_type, industry, urgency) - Sample06_GetAnalyzer: Get analyzer information including configuration and field schema Key features: - Sample05: Demonstrates classification-only analyzer with 3 classifiers - Sample06: Shows how to retrieve and inspect analyzer properties including prebuilt analyzers - Fixed API usage: getAnalyzerId(), getCreatedAt(), getLastModified At() instead of getId(), getCreatedDateTime(), getUpdatedDateTime() - Comprehensive field schema inspection with all 31 prebuilt-invoice fields - All tests passing with real Azure service
- Sample07_ListAnalyzers: List and filter all available analyzers (prebuilt and custom) * testListAnalyzersAsync: Lists all 134 analyzers (87 prebuilt, 47 custom) * testListReadyAnalyzersAsync: Filters for ready analyzers only - Sample08_UpdateAnalyzer: Update existing analyzer properties * Demonstrates updating description, configuration, and field schema * Uses @beforeeach to create test analyzer and @AfterEach for cleanup * Shows how to add new fields while preserving existing ones All tests passing with real Azure service
Fixed Sample08_UpdateAnalyzer to avoid 409 conflict error: - Delete existing analyzer before recreating with updated configuration - Added note about using updateAnalyzerWithResponse for atomic updates in production - All 12 tests now passing (Sample00-08 with multiple test methods) Test results: 12/12 passed (100% success rate)
…eAnalyzerWithLabels
…iables and Improve Test Patterns - Updated environment variable names from "ENDPOINT" and "CONTENTUNDERSTANDING_API_KEY" to "CONTENTUNDERSTANDING_ENDPOINT" and "AZURE_CONTENT_UNDERSTANDING_KEY" across multiple sample test files. - Modified sample tests to load local files instead of using publicly accessible URLs for document analysis. - Enhanced assertions and logging for better clarity and debugging. - Improved API usage patterns in tests for creating, copying, and deleting analyzers, including async patterns. - Added model mappings for analyzers in relevant samples to demonstrate configuration capabilities.
…e validation of source and copied analyzers
… Azure Credential Authentication - Updated Sample03_AnalyzeInvoice, Sample04_CreateAnalyzer, Sample05_CreateClassifier, Sample06_GetAnalyzer, Sample07_ListAnalyzers, Sample08_UpdateAnalyzer, Sample09_DeleteAnalyzer, Sample10_AnalyzeConfigs, Sample11_AnalyzeReturnRawJson, Sample12_GetResultFile, Sample13_DeleteResult, Sample14_CopyAnalyzer, Sample15_GrantCopyAuth, and Sample16_CreateAnalyzerWithLabels to include logic for initializing the Content Understanding client with either an API key or the Default Azure Credential. - Added assertions to verify client initialization in each sample. - Improved code readability and maintainability by consolidating client creation logic.
…Builder Initialization
- Sample12_GetResultFile: Demonstrates how to retrieve keyframe images from video analysis operations. - Sample13_DeleteResult: Shows how to delete analysis results after they are no longer needed. - Sample14_CopyAnalyzer: Illustrates how to copy an analyzer within the same resource. - Sample15_GrantCopyAuth: Demonstrates granting copy authorization for cross-resource analyzer copying. - Sample16_CreateAnalyzerWithLabels: Shows how to create an analyzer with labeled training data from Azure Blob Storage.
7bedda6 to
e2af7aa
Compare
- Delete 13 @disabled test files (replaced by Sample tests) - Modify Sample00-Sample16 to extend ContentUnderstandingClientTestBase - Add testResourceNamer for reproducible random IDs in PLAYBACK mode - Remove problematic sanitizers (AZSDK2003, AZSDK2030, AZSDK3423, AZSDK3430, AZSDK3493) - Configure maven-surefire-plugin to include Sample*.java - Use AZURE_CONTENT_UNDERSTANDING_ENDPOINT env var (matches .NET naming)
bojunehsu
reviewed
Feb 2, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Outdated
Show resolved
Hide resolved
bojunehsu
reviewed
Feb 2, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Show resolved
Hide resolved
bojunehsu
reviewed
Feb 2, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Show resolved
Hide resolved
bojunehsu
reviewed
Feb 2, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Outdated
Show resolved
Hide resolved
bojunehsu
reviewed
Feb 2, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Show resolved
Hide resolved
bojunehsu
reviewed
Feb 2, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Outdated
Show resolved
Hide resolved
bojunehsu
reviewed
Feb 2, 2026
bojunehsu
reviewed
Feb 2, 2026
bojunehsu
reviewed
Feb 2, 2026
bojunehsu
reviewed
Feb 2, 2026
bojunehsu
reviewed
Feb 2, 2026
Member
bojunehsu
left a comment
There was a problem hiding this comment.
Reviewed customizations and README.md. Skimmed some samples. Skipped others.
Member
|
/azp run prepare-pipelines |
|
Azure Pipelines successfully started running 1 pipeline(s). |
…ence methods. Added type-safe getValue() methods for ContentField, ObjectField, and ArrayField to simplify value retrieval without casting. Updated beginAnalyzeBinary convenience overloads to remove unnecessary parameters and enhance usability.
…://github.com/azure-sdk/azure-sdk-for-java into sdkauto/azure-ai-contentunderstanding-5634426
…ency and enhance README.md with clarifications on LLM requirements for analyzers.
…and remove obsolete sample files. Updated paths in Sample01, Sample10, and Sample11 test classes to point to 'src/samples/resources/'. Deleted unused PDF files from 'src/test/resources/'.
…://github.com/azure-sdk/azure-sdk-for-java into sdkauto/azure-ai-contentunderstanding-5634426
bojunehsu
reviewed
Feb 6, 2026
...-ai-contentunderstanding/customization/src/main/java/ContentUnderstandingCustomizations.java
Show resolved
Hide resolved
bojunehsu
approved these changes
Feb 6, 2026
auto-merge was automatically disabled
February 28, 2026 05:50
Pull request was closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Configurations: 'specification/ai/ContentUnderstanding/tspconfig.yaml', API Version: 2025-11-01, SDK Release Type: beta, and CommitSHA: 'd0cd556bd91d2dda700e983c0d253fa025b324c0' in SpecRepo: 'https://github.com/Azure/azure-rest-api-specs' Pipeline run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=5634426 Refer to https://eng.ms/docs/products/azure-developer-experience/develop/sdk-release/sdk-release-prerequisites to prepare for SDK release. Release plan link: Submitted by: