-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Python SDK emitted from latest TypeSpec that depends on @azure-tools/openai-typespec 0.1.9 #44580
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
base: main
Are you sure you want to change the base?
Python SDK emitted from latest TypeSpec that depends on @azure-tools/openai-typespec 0.1.9 #44580
Conversation
sdk/ai/azure-ai-projects/tests/agents/telemetry/test_ai_agents_instrumentor.py
Show resolved
Hide resolved
There was a problem hiding this 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 PR emits Python SDK code from a new TypeSpec branch and updates samples and tests to accommodate the removal and renaming of OpenAI classes. The changes include:
- Updated TypeSpec location from
Azure.AI.ProjectstoFoundrywith a new commit - Major class renames:
ItemContentType→InputContentType,ResponsesMessageRole→ string literals,CodeInterpreterToolAuto→CodeInterpreterContainerAuto,ResponseTextFormatConfigurationJsonSchema→TextResponseFormatJsonSchema, etc. - Removal of
ResponseStreamEventTypeenum (replaced with string literals) - Addition of new model classes for conversation items and various tool call types
- Updated dependency:
azure-core>=1.36.0and addedtyping-extensions>=4.6.0
Reviewed changes
Copilot reviewed 40 out of 41 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| tsp-location.yaml | Updates TypeSpec directory and commit reference |
| test_base.py | Updates imports and method signatures for renamed types |
| test_finetuning*.py | Adds pylint suppressions for line length |
| conftest.py | Adds blank line formatting |
| test_agent_tools_with_conversations.py | Renames CodeInterpreterToolAuto → CodeInterpreterContainerAuto, adds pylint suppression |
| test_agent_code_interpreter*.py | Renames CodeInterpreterToolAuto → CodeInterpreterContainerAuto |
| test_agent_*_function.py | Updates tool class names across multiple test files |
| test_conversation_items_crud*.py | Replaces enum with string literals for roles and content types, adds ConversationItem import |
| test_agent_responses_crud*.py | Renames ResponseTextFormatConfigurationJsonSchema → TextResponseFormatJsonSchema |
| test_responses_instrumentor.py | Replaces ResponseStreamEventType enum with string literals |
| test_ai_agents_instrumentor*.py | Renames model classes, comments out failing test assertions |
| sample_memory_basic.py | Replaces ResponsesUserMessageItemParam with EasyInputMessage |
| sample_agent_*.py | Updates class names and adds pylint suppressions |
| sample_workflow_multi_agent*.py | Replaces ResponseStreamEventType enum with string literals |
| sample_agent_structured_output*.py | Renames ResponseTextFormatConfigurationJsonSchema → TextResponseFormatJsonSchema |
| pyproject.toml | Updates azure-core version and adds typing-extensions dependency |
| post-emitter-fixes.cmd | Comments out a fix with unclear status |
| _patch_memories*.py | Updates model class names for token details |
| _operations.py | Changes order parameter type and items parameter type |
| _enums.py | Major refactoring with many removed/added enums |
| models/init.py | Updates model exports reflecting new class structure |
| _utils/serialization.py | Replaces eval() with explicit type checks for security |
| _utils/model_base.py | Adds array encoding support and deserialization caching |
| _types.py | Adds ComparisonFilterValueItems type |
| apiview-properties.json | Updates all model-to-TypeSpec mappings |
sdk/ai/azure-ai-projects/tests/agents/telemetry/test_ai_agents_instrumentor.py
Outdated
Show resolved
Hide resolved
sdk/ai/azure-ai-projects/tests/agents/telemetry/test_ai_agents_instrumentor_async.py
Outdated
Show resolved
Hide resolved
sdk/ai/azure-ai-projects/tests/agents/telemetry/test_ai_agents_instrumentor.py
Outdated
Show resolved
Hide resolved
API Change CheckAPIView identified API level changes in this PR and created the following API reviews |
…-typespec-with-openai-package
glecaros/openai-spec. See TypeSpec PR: Switching to consume new OpenAI TypeSpec package. azure-rest-api-specs#39479All test pass, except a few telemetry tests related to Responses with JSON schema. I'm looking into those now.