Skip to content

Commit 246b576

Browse files
MarkDaoustcopybara-github
authored andcommitted
chore: Remove experimental warnings for interactions
PiperOrigin-RevId: 911649702
1 parent 04bf0b8 commit 246b576

3 files changed

Lines changed: 1 addition & 34 deletions

File tree

README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1486,8 +1486,6 @@ print(response.text)
14861486

14871487
## Interactions (Preview)
14881488

1489-
> **Warning:** The Interactions API is in **Beta**. This is a preview of an experimental feature. Features and schemas are subject to **breaking changes**.
1490-
14911489
The Interactions API is a unified interface for interacting with Gemini models and agents. It simplifies state management, tool orchestration, and long-running tasks.
14921490

14931491
See the [documentation site](https://ai.google.dev/gemini-api/docs/interactions) for more details.

google/genai/client.py

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747

4848
from ._interactions.resources import AsyncInteractionsResource as AsyncNextGenInteractionsResource, InteractionsResource as NextGenInteractionsResource
4949
from ._interactions.resources import WebhooksResource, AsyncWebhooksResource
50-
_interactions_experimental_warned = False
50+
5151

5252
class AsyncGeminiNextGenAPIClientAdapter(_interactions.AsyncGeminiNextGenAPIClientAdapter):
5353
"""Adapter for the Gemini NextGen API Client."""
@@ -189,14 +189,6 @@ def _nextgen_client(self) -> AsyncGeminiNextGenAPIClient:
189189

190190
@property
191191
def interactions(self) -> AsyncNextGenInteractionsResource:
192-
global _interactions_experimental_warned
193-
if not _interactions_experimental_warned:
194-
_interactions_experimental_warned = True
195-
warnings.warn(
196-
'Interactions usage is experimental and may change in future versions.',
197-
category=UserWarning,
198-
stacklevel=1,
199-
)
200192
return self._nextgen_client.interactions
201193

202194
@property
@@ -554,14 +546,6 @@ def _nextgen_client(self) -> GeminiNextGenAPIClient:
554546

555547
@property
556548
def interactions(self) -> NextGenInteractionsResource:
557-
global _interactions_experimental_warned
558-
if not _interactions_experimental_warned:
559-
_interactions_experimental_warned = True
560-
warnings.warn(
561-
'Interactions usage is experimental and may change in future versions.',
562-
category=UserWarning,
563-
stacklevel=2,
564-
)
565549
return self._nextgen_client.interactions
566550

567551
@property

google/genai/tests/interactions/test_integration.py

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,21 +19,6 @@
1919
pytest_plugins = ("pytest_asyncio",)
2020

2121

22-
def test_client_future_warning():
23-
with mock.patch.object(
24-
client_lib, "_interactions_experimental_warned", new=False
25-
):
26-
client = client_lib.Client(
27-
api_key="placeholder",
28-
http_options={
29-
"api_version": "v1alpha",
30-
}
31-
)
32-
with pytest.warns(
33-
UserWarning, match="Interactions.*experimental"
34-
):
35-
_ = client.interactions
36-
3722

3823
def test_client_timeout():
3924
with mock.patch.object(

0 commit comments

Comments
 (0)