Skip to content

Python: [Bug]: model_id versus model_deployment_name is confusing in Azure AI Agents #3147

Description

@tonybaloney

Description

In Foundry agents, the inconsistency between model_id and model_deployment_name is confusing. For example, if you don't provide the model_deployment_name argument to AzureAIClient it reports a ValueError when running an agent because model_id isn't set on the client object, even if it was set on the call to AzureAIClient.create_agent. model_id is accepted as a kwarg so you don't get a linter error.

AzureAIClient.create_agent takes model_id as a parameter instead of model_deployment_name.

Code Sample

Error Messages / Stack Traces

Package Versions

main

Python Version

No response

Additional Context

No response

Metadata

Metadata

Labels

agentsUsage: [Issues, PRs], Target: Single agentbugUsage: [Issues], Target: all issues (Legacy, prefer issue type: bug)pythonUsage: [Issues, PRs], Target: Python

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions