Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions sdk/ai/azure-ai-agents/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release History

## 1.0.0b3 (2025-05-14)

### Features Added

- Internal updates based on TypeSpec finalization.

## 1.0.0b2 (2025-05-13)

### Breaking Changes
Expand Down
2 changes: 1 addition & 1 deletion sdk/ai/azure-ai-agents/apiview-properties.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
"CrossLanguagePackageId": "Azure.AI.Agents",
"CrossLanguageDefinitionId": {
"azure.ai.agents.models.Agent": "Azure.AI.Agents.Agent",
"azure.ai.agents.models.AgentErrorDetail": "Azure.AI.Agents.AgentErrorDetail",
"azure.ai.agents.models.AgentsNamedToolChoice": "Azure.AI.Agents.AgentsNamedToolChoice",
"azure.ai.agents.models.AgentsResponseFormat": "Azure.AI.Agents.AgentsResponseFormat",
"azure.ai.agents.models.AgentThread": "Azure.AI.Agents.AgentThread",
"azure.ai.agents.models.AgentThreadCreationOptions": "Azure.AI.Agents.AgentThreadCreationOptions",
"azure.ai.agents.models.AgentV1Error": "Azure.AI.Agents.AgentV1Error",
"azure.ai.agents.models.AgentV1ErrorError": "Azure.AI.Agents.AgentV1Error.error.anonymous",
"azure.ai.agents.models.AISearchIndexResource": "Azure.AI.Agents.AISearchIndexResource",
"azure.ai.agents.models.ToolDefinition": "Azure.AI.Agents.ToolDefinition",
"azure.ai.agents.models.AzureAISearchToolDefinition": "Azure.AI.Agents.AzureAISearchToolDefinition",
Expand Down
2 changes: 1 addition & 1 deletion sdk/ai/azure-ai-agents/azure/ai/agents/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

VERSION = "1.0.0b2"
VERSION = "1.0.0b3"
4 changes: 2 additions & 2 deletions sdk/ai/azure-ai-agents/azure/ai/agents/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@
from ._models import ( # type: ignore
AISearchIndexResource,
Agent,
AgentErrorDetail,
AgentThread,
AgentThreadCreationOptions,
AgentV1Error,
AgentV1ErrorError,
AgentsNamedToolChoice,
AgentsResponseFormat,
AzureAISearchToolDefinition,
Expand Down Expand Up @@ -207,10 +207,10 @@
__all__ = [
"AISearchIndexResource",
"Agent",
"AgentErrorDetail",
"AgentThread",
"AgentThreadCreationOptions",
"AgentV1Error",
"AgentV1ErrorError",
"AgentsNamedToolChoice",
"AgentsResponseFormat",
"AzureAISearchToolDefinition",
Expand Down
88 changes: 46 additions & 42 deletions sdk/ai/azure-ai-agents/azure/ai/agents/models/_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,49 @@ def __init__(self, *args: Any, **kwargs: Any) -> None:
self.object: Literal["assistant.deleted"] = "assistant.deleted"


class AgentErrorDetail(_Model):
"""Describes the error information returned by the agents API.

:ivar message: Human-readable description of the error.
:vartype message: str
:ivar type: Error type identifier (e.g. ``invalid_request_error``).
:vartype type: str
:ivar param: Name of the parameter that caused the error, if applicable.
:vartype param: str
:ivar code: Machine-readable error code.
:vartype code: str
"""

message: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
"""Human-readable description of the error."""
type: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
"""Error type identifier (e.g. ``invalid_request_error``)."""
param: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
"""Name of the parameter that caused the error, if applicable."""
code: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
"""Machine-readable error code."""

@overload
def __init__(
self,
*,
message: Optional[str] = None,
type: Optional[str] = None,
param: Optional[str] = None,
code: Optional[str] = None,
) -> None: ...

@overload
def __init__(self, mapping: Mapping[str, Any]) -> None:
"""
:param mapping: raw JSON to initialize the model.
:type mapping: Mapping[str, Any]
"""

def __init__(self, *args: Any, **kwargs: Any) -> None:
super().__init__(*args, **kwargs)


class AgentsNamedToolChoice(_Model):
"""Specifies a tool the model should use. Use to force the model to call a specific tool.

Expand Down Expand Up @@ -380,56 +423,17 @@ class AgentV1Error(_Model):
"""Error payload returned by the agents API.

:ivar error: Represents the error. Required.
:vartype error: ~azure.ai.agents.models.AgentV1ErrorError
:vartype error: ~azure.ai.agents.models.AgentErrorDetail
"""

error: "_models.AgentV1ErrorError" = rest_field(visibility=["read", "create", "update", "delete", "query"])
error: "_models.AgentErrorDetail" = rest_field(visibility=["read", "create", "update", "delete", "query"])
"""Represents the error. Required."""

@overload
def __init__(
self,
*,
error: "_models.AgentV1ErrorError",
) -> None: ...

@overload
def __init__(self, mapping: Mapping[str, Any]) -> None:
"""
:param mapping: raw JSON to initialize the model.
:type mapping: Mapping[str, Any]
"""

def __init__(self, *args: Any, **kwargs: Any) -> None:
super().__init__(*args, **kwargs)


class AgentV1ErrorError(_Model):
"""AgentV1ErrorError.

:ivar message:
:vartype message: str
:ivar type:
:vartype type: str
:ivar param:
:vartype param: str
:ivar code:
:vartype code: str
"""

message: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
type: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
param: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
code: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])

@overload
def __init__(
self,
*,
message: Optional[str] = None,
type: Optional[str] = None,
param: Optional[str] = None,
code: Optional[str] = None,
error: "_models.AgentErrorDetail",
) -> None: ...

@overload
Expand Down
2 changes: 1 addition & 1 deletion sdk/ai/azure-ai-agents/tsp-location.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
directory: specification/ai/Azure.AI.Agents
commit: fc0116e3fbb1ecd647a4f412f5e82eb30c11ad51
commit: b9b2b55cc99daf6e107471448a281a03e83884ec
repo: Azure/azure-rest-api-specs
additionalDirectories: