Skip to content

Commit 677b754

Browse files
authored
Remove Reminder Tool and add missing draft argument to Agent create_version method (#47786)
1 parent 331a022 commit 677b754

7 files changed

Lines changed: 56 additions & 81 deletions

File tree

sdk/ai/azure-ai-projects/api.md

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ namespace azure.ai.projects.aio.operations
129129
content_type: str = "application/json",
130130
definition: AgentDefinition,
131131
description: Optional[str] = ...,
132+
draft: Optional[bool] = ...,
132133
metadata: Optional[dict[str, str]] = ...,
133134
**kwargs: Any
134135
) -> AgentVersionDetails: ...
@@ -7642,23 +7643,6 @@ namespace azure.ai.projects.models
76427643
def __init__(self, mapping: Mapping[str, Any]) -> None: ...
76437644

76447645

7645-
class azure.ai.projects.models.ReminderPreviewTool(Tool, discriminator='reminder_preview'):
7646-
description: Optional[str]
7647-
name: Optional[str]
7648-
type: Literal[ToolType.REMINDER_PREVIEW]
7649-
7650-
@overload
7651-
def __init__(
7652-
self,
7653-
*,
7654-
description: Optional[str] = ...,
7655-
name: Optional[str] = ...
7656-
) -> None: ...
7657-
7658-
@overload
7659-
def __init__(self, mapping: Mapping[str, Any]) -> None: ...
7660-
7661-
76627646
class azure.ai.projects.models.ReminderPreviewToolboxTool(ToolboxTool, discriminator='reminder_preview'):
76637647
description: str
76647648
name: str
@@ -8780,7 +8764,6 @@ namespace azure.ai.projects.models
87808764
MEMORY_SEARCH_PREVIEW = "memory_search_preview"
87818765
NAMESPACE = "namespace"
87828766
OPENAPI = "openapi"
8783-
REMINDER_PREVIEW = "reminder_preview"
87848767
SHAREPOINT_GROUNDING_PREVIEW = "sharepoint_grounding_preview"
87858768
SHELL = "shell"
87868769
TOOLBOX_SEARCH_PREVIEW = "toolbox_search_preview"
@@ -9437,6 +9420,7 @@ namespace azure.ai.projects.operations
94379420
content_type: str = "application/json",
94389421
definition: AgentDefinition,
94399422
description: Optional[str] = ...,
9423+
draft: Optional[bool] = ...,
94409424
metadata: Optional[dict[str, str]] = ...,
94419425
**kwargs: Any
94429426
) -> AgentVersionDetails: ...
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
apiMdSha256: 28e27d35c13ceeb5c5599d5770812703b1157547762a5433722a41e8a2da57b6
1+
apiMdSha256: 3769cdd6d12da4829d90f71066b705ee8951c33eac0288d5a5cc3ebc002e6df0
22
parserVersion: 0.3.28
33
pythonVersion: 3.14.3

sdk/ai/azure-ai-projects/azure/ai/projects/aio/operations/_patch_agents_async.py

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,12 @@ async def create_version(
4343
metadata: Optional[dict[str, str]] = None,
4444
description: Optional[str] = None,
4545
blueprint_reference: Optional[_models.AgentBlueprintReference] = None,
46+
draft: Optional[bool] = None,
4647
**kwargs: Any,
4748
) -> _models.AgentVersionDetails:
48-
"""Create a new agent version.
49+
"""Create an agent version.
50+
51+
Creates a new version for the specified agent and returns the created version resource.
4952
5053
:param agent_name: The unique name that identifies the agent. Name can be used to
5154
retrieve/update/delete the agent.
@@ -71,17 +74,23 @@ async def create_version(
7174
:paramtype description: str
7275
:keyword blueprint_reference: The blueprint reference for the agent. Default value is None.
7376
:paramtype blueprint_reference: ~azure.ai.projects.models.AgentBlueprintReference
77+
:keyword draft: (Preview) Whether this agent version is a draft (candidate) rather than a
78+
release. The service defaults to ``false`` if a value is not specified by the caller. Draft
79+
versions are recorded but excluded from default 'latest' resolution and are not auto-promoted.
80+
Default value is None.
81+
:paramtype draft: bool
7482
:return: AgentVersionDetails. The AgentVersionDetails is compatible with MutableMapping
7583
:rtype: ~azure.ai.projects.models.AgentVersionDetails
7684
:raises ~azure.core.exceptions.HttpResponseError:
7785
"""
78-
...
7986

8087
@overload
8188
async def create_version(
8289
self, agent_name: str, body: JSON, *, content_type: str = "application/json", **kwargs: Any
8390
) -> _models.AgentVersionDetails:
84-
"""Create a new agent version.
91+
"""Create an agent version.
92+
93+
Creates a new version for the specified agent and returns the created version resource.
8594
8695
:param agent_name: The unique name that identifies the agent. Name can be used to
8796
retrieve/update/delete the agent.
@@ -99,13 +108,14 @@ async def create_version(
99108
:rtype: ~azure.ai.projects.models.AgentVersionDetails
100109
:raises ~azure.core.exceptions.HttpResponseError:
101110
"""
102-
...
103111

104112
@overload
105113
async def create_version(
106114
self, agent_name: str, body: IO[bytes], *, content_type: str = "application/json", **kwargs: Any
107115
) -> _models.AgentVersionDetails:
108-
"""Create a new agent version.
116+
"""Create an agent version.
117+
118+
Creates a new version for the specified agent and returns the created version resource.
109119
110120
:param agent_name: The unique name that identifies the agent. Name can be used to
111121
retrieve/update/delete the agent.
@@ -123,7 +133,6 @@ async def create_version(
123133
:rtype: ~azure.ai.projects.models.AgentVersionDetails
124134
:raises ~azure.core.exceptions.HttpResponseError:
125135
"""
126-
...
127136

128137
@distributed_trace_async
129138
async def create_version(
@@ -135,9 +144,12 @@ async def create_version(
135144
metadata: Optional[dict[str, str]] = None,
136145
description: Optional[str] = None,
137146
blueprint_reference: Optional[_models.AgentBlueprintReference] = None,
147+
draft: Optional[bool] = None,
138148
**kwargs: Any,
139149
) -> _models.AgentVersionDetails:
140-
"""Create a new agent version.
150+
"""Create an agent version.
151+
152+
Creates a new version for the specified agent and returns the created version resource.
141153
142154
:param agent_name: The unique name that identifies the agent. Name can be used to
143155
retrieve/update/delete the agent.
@@ -162,6 +174,11 @@ async def create_version(
162174
:paramtype description: str
163175
:keyword blueprint_reference: The blueprint reference for the agent. Default value is None.
164176
:paramtype blueprint_reference: ~azure.ai.projects.models.AgentBlueprintReference
177+
:keyword draft: (Preview) Whether this agent version is a draft (candidate) rather than a
178+
release. The service defaults to ``false`` if a value is not specified by the caller. Draft
179+
versions are recorded but excluded from default 'latest' resolution and are not auto-promoted.
180+
Default value is None.
181+
:paramtype draft: bool
165182
:return: AgentVersionDetails. The AgentVersionDetails is compatible with MutableMapping
166183
:rtype: ~azure.ai.projects.models.AgentVersionDetails
167184
:raises ~azure.core.exceptions.HttpResponseError:
@@ -183,6 +200,7 @@ async def create_version(
183200
metadata=metadata,
184201
description=description,
185202
blueprint_reference=blueprint_reference,
203+
draft=draft,
186204
**kwargs,
187205
)
188206
except HttpResponseError as exc:

sdk/ai/azure-ai-projects/azure/ai/projects/models/__init__.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,6 @@
282282
RecurrenceTrigger,
283283
RedTeam,
284284
RedTeamTargetConfig,
285-
ReminderPreviewTool,
286285
ReminderPreviewToolboxTool,
287286
ResponseUsageInputTokensDetails,
288287
ResponseUsageOutputTokensDetails,
@@ -732,7 +731,6 @@
732731
"RecurrenceTrigger",
733732
"RedTeam",
734733
"RedTeamTargetConfig",
735-
"ReminderPreviewTool",
736734
"ReminderPreviewToolboxTool",
737735
"ResponseUsageInputTokensDetails",
738736
"ResponseUsageOutputTokensDetails",

sdk/ai/azure-ai-projects/azure/ai/projects/models/_enums.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1142,8 +1142,6 @@ class ToolType(str, Enum, metaclass=CaseInsensitiveEnumMeta):
11421142
"""SHAREPOINT_GROUNDING_PREVIEW."""
11431143
MEMORY_SEARCH_PREVIEW = "memory_search_preview"
11441144
"""MEMORY_SEARCH_PREVIEW."""
1145-
REMINDER_PREVIEW = "reminder_preview"
1146-
"""REMINDER_PREVIEW."""
11471145
WORK_IQ_PREVIEW = "work_iq_preview"
11481146
"""WORK_IQ_PREVIEW."""
11491147
FABRIC_IQ_PREVIEW = "fabric_iq_preview"

sdk/ai/azure-ai-projects/azure/ai/projects/models/_models.py

Lines changed: 3 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -161,15 +161,15 @@ class Tool(_Model):
161161
CaptureStructuredOutputsTool, CodeInterpreterTool, ComputerTool, ComputerUsePreviewTool,
162162
CustomToolParam, MicrosoftFabricPreviewTool, FabricIQPreviewTool, FileSearchTool, FunctionTool,
163163
ImageGenTool, LocalShellToolParam, MCPTool, MemorySearchPreviewTool, NamespaceToolParam,
164-
OpenApiTool, ReminderPreviewTool, SharepointPreviewTool, FunctionShellToolParam,
164+
OpenApiTool, SharepointPreviewTool, FunctionShellToolParam,
165165
ToolSearchToolParam, WebSearchTool, WebSearchPreviewTool, WorkIQPreviewTool
166166

167167
:ivar type: Required. Known values are: "function", "file_search", "computer",
168168
"computer_use_preview", "web_search", "mcp", "code_interpreter", "image_generation",
169169
"local_shell", "shell", "custom", "namespace", "tool_search", "web_search_preview",
170170
"apply_patch", "a2a_preview", "bing_custom_search_preview", "browser_automation_preview",
171171
"fabric_dataagent_preview", "sharepoint_grounding_preview", "memory_search_preview",
172-
"reminder_preview", "work_iq_preview", "fabric_iq_preview", "toolbox_search_preview",
172+
"work_iq_preview", "fabric_iq_preview", "toolbox_search_preview",
173173
"azure_ai_search", "azure_function", "bing_grounding", "capture_structured_outputs", and
174174
"openapi".
175175
:vartype type: str or ~azure.ai.projects.models.ToolType
@@ -182,7 +182,7 @@ class Tool(_Model):
182182
\"local_shell\", \"shell\", \"custom\", \"namespace\", \"tool_search\", \"web_search_preview\",
183183
\"apply_patch\", \"a2a_preview\", \"bing_custom_search_preview\",
184184
\"browser_automation_preview\", \"fabric_dataagent_preview\", \"sharepoint_grounding_preview\",
185-
\"memory_search_preview\", \"reminder_preview\", \"work_iq_preview\", \"fabric_iq_preview\",
185+
\"memory_search_preview\", \"work_iq_preview\", \"fabric_iq_preview\",
186186
\"toolbox_search_preview\", \"azure_ai_search\", \"azure_function\", \"bing_grounding\",
187187
\"capture_structured_outputs\", and \"openapi\"."""
188188

@@ -12625,47 +12625,6 @@ def __init__(self, *args: Any, **kwargs: Any) -> None:
1262512625
super().__init__(*args, **kwargs)
1262612626

1262712627

12628-
class ReminderPreviewTool(Tool, discriminator="reminder_preview"):
12629-
"""A built-in tool that schedules the agent to re-invoke itself after a delay. The model passes a
12630-
single ``minutes`` argument (positive integer) when calling this tool. The service creates a
12631-
one-shot timer routine that fires after the specified delay and re-invokes the agent on the
12632-
same conversation thread. No pre-created routine is required.
12633-
12634-
:ivar type: The type of the tool. Always ``reminder_preview``. Required. REMINDER_PREVIEW.
12635-
:vartype type: str or ~azure.ai.projects.models.REMINDER_PREVIEW
12636-
:ivar name: Optional user-defined name for this tool or configuration.
12637-
:vartype name: str
12638-
:ivar description: Optional user-defined description for this tool or configuration.
12639-
:vartype description: str
12640-
"""
12641-
12642-
type: Literal[ToolType.REMINDER_PREVIEW] = rest_discriminator(name="type", visibility=["read", "create", "update", "delete", "query"]) # type: ignore
12643-
"""The type of the tool. Always ``reminder_preview``. Required. REMINDER_PREVIEW."""
12644-
name: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
12645-
"""Optional user-defined name for this tool or configuration."""
12646-
description: Optional[str] = rest_field(visibility=["read", "create", "update", "delete", "query"])
12647-
"""Optional user-defined description for this tool or configuration."""
12648-
12649-
@overload
12650-
def __init__(
12651-
self,
12652-
*,
12653-
name: Optional[str] = None,
12654-
description: Optional[str] = None,
12655-
) -> None: ...
12656-
12657-
@overload
12658-
def __init__(self, mapping: Mapping[str, Any]) -> None:
12659-
"""
12660-
:param mapping: raw JSON to initialize the model.
12661-
:type mapping: Mapping[str, Any]
12662-
"""
12663-
12664-
def __init__(self, *args: Any, **kwargs: Any) -> None:
12665-
super().__init__(*args, **kwargs)
12666-
self.type = ToolType.REMINDER_PREVIEW # type: ignore
12667-
12668-
1266912628
class ReminderPreviewToolboxTool(ToolboxTool, discriminator="reminder_preview"):
1267012629
"""A reminder tool stored in a toolbox.
1267112630

sdk/ai/azure-ai-projects/azure/ai/projects/operations/_patch_agents.py

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,12 @@ def create_version(
6161
metadata: Optional[dict[str, str]] = None,
6262
description: Optional[str] = None,
6363
blueprint_reference: Optional[_models.AgentBlueprintReference] = None,
64+
draft: Optional[bool] = None,
6465
**kwargs: Any,
6566
) -> _models.AgentVersionDetails:
66-
"""Create a new agent version.
67+
"""Create an agent version.
68+
69+
Creates a new version for the specified agent and returns the created version resource.
6770
6871
:param agent_name: The unique name that identifies the agent. Name can be used to
6972
retrieve/update/delete the agent.
@@ -89,17 +92,23 @@ def create_version(
8992
:paramtype description: str
9093
:keyword blueprint_reference: The blueprint reference for the agent. Default value is None.
9194
:paramtype blueprint_reference: ~azure.ai.projects.models.AgentBlueprintReference
95+
:keyword draft: (Preview) Whether this agent version is a draft (candidate) rather than a
96+
release. The service defaults to ``false`` if a value is not specified by the caller. Draft
97+
versions are recorded but excluded from default 'latest' resolution and are not auto-promoted.
98+
Default value is None.
99+
:paramtype draft: bool
92100
:return: AgentVersionDetails. The AgentVersionDetails is compatible with MutableMapping
93101
:rtype: ~azure.ai.projects.models.AgentVersionDetails
94102
:raises ~azure.core.exceptions.HttpResponseError:
95103
"""
96-
...
97104

98105
@overload
99106
def create_version(
100107
self, agent_name: str, body: JSON, *, content_type: str = "application/json", **kwargs: Any
101108
) -> _models.AgentVersionDetails:
102-
"""Create a new agent version.
109+
"""Create an agent version.
110+
111+
Creates a new version for the specified agent and returns the created version resource.
103112
104113
:param agent_name: The unique name that identifies the agent. Name can be used to
105114
retrieve/update/delete the agent.
@@ -117,13 +126,14 @@ def create_version(
117126
:rtype: ~azure.ai.projects.models.AgentVersionDetails
118127
:raises ~azure.core.exceptions.HttpResponseError:
119128
"""
120-
...
121129

122130
@overload
123131
def create_version(
124132
self, agent_name: str, body: IO[bytes], *, content_type: str = "application/json", **kwargs: Any
125133
) -> _models.AgentVersionDetails:
126-
"""Create a new agent version.
134+
"""Create an agent version.
135+
136+
Creates a new version for the specified agent and returns the created version resource.
127137
128138
:param agent_name: The unique name that identifies the agent. Name can be used to
129139
retrieve/update/delete the agent.
@@ -141,7 +151,6 @@ def create_version(
141151
:rtype: ~azure.ai.projects.models.AgentVersionDetails
142152
:raises ~azure.core.exceptions.HttpResponseError:
143153
"""
144-
...
145154

146155
@distributed_trace
147156
def create_version(
@@ -153,9 +162,12 @@ def create_version(
153162
metadata: Optional[dict[str, str]] = None,
154163
description: Optional[str] = None,
155164
blueprint_reference: Optional[_models.AgentBlueprintReference] = None,
165+
draft: Optional[bool] = None,
156166
**kwargs: Any,
157167
) -> _models.AgentVersionDetails:
158-
"""Create a new agent version.
168+
"""Create an agent version.
169+
170+
Creates a new version for the specified agent and returns the created version resource.
159171
160172
:param agent_name: The unique name that identifies the agent. Name can be used to
161173
retrieve/update/delete the agent.
@@ -180,6 +192,11 @@ def create_version(
180192
:paramtype description: str
181193
:keyword blueprint_reference: The blueprint reference for the agent. Default value is None.
182194
:paramtype blueprint_reference: ~azure.ai.projects.models.AgentBlueprintReference
195+
:keyword draft: (Preview) Whether this agent version is a draft (candidate) rather than a
196+
release. The service defaults to ``false`` if a value is not specified by the caller. Draft
197+
versions are recorded but excluded from default 'latest' resolution and are not auto-promoted.
198+
Default value is None.
199+
:paramtype draft: bool
183200
:return: AgentVersionDetails. The AgentVersionDetails is compatible with MutableMapping
184201
:rtype: ~azure.ai.projects.models.AgentVersionDetails
185202
:raises ~azure.core.exceptions.HttpResponseError:
@@ -202,6 +219,7 @@ def create_version(
202219
metadata=metadata,
203220
description=description,
204221
blueprint_reference=blueprint_reference,
222+
draft=draft,
205223
**kwargs,
206224
)
207225
except HttpResponseError as exc:

0 commit comments

Comments
 (0)