File tree Expand file tree Collapse file tree 5 files changed +70
-0
lines changed
google/genai/_interactions/types Expand file tree Collapse file tree 5 files changed +70
-0
lines changed Original file line number Diff line number Diff line change 3232from .tool_choice import ToolChoice as ToolChoice
3333from .usage_param import UsageParam as UsageParam
3434from .content_stop import ContentStop as ContentStop
35+ from .image_config import ImageConfig as ImageConfig
3536from .text_content import TextContent as TextContent
3637from .allowed_tools import AllowedTools as AllowedTools
3738from .audio_content import AudioContent as AudioContent
5455from .interaction_event import InteractionEvent as InteractionEvent
5556from .tool_choice_param import ToolChoiceParam as ToolChoiceParam
5657from .document_mime_type import DocumentMimeType as DocumentMimeType
58+ from .image_config_param import ImageConfigParam as ImageConfigParam
5759from .text_content_param import TextContentParam as TextContentParam
5860from .tool_choice_config import ToolChoiceConfig as ToolChoiceConfig
5961from .url_context_result import URLContextResult as URLContextResult
Original file line number Diff line number Diff line change 2020
2121from .._models import BaseModel
2222from .tool_choice import ToolChoice
23+ from .image_config import ImageConfig
2324from .speech_config import SpeechConfig
2425from .thinking_level import ThinkingLevel
2526
2930class GenerationConfig (BaseModel ):
3031 """Configuration parameters for model interactions."""
3132
33+ image_config : Optional [ImageConfig ] = None
34+ """Configuration for image interaction."""
35+
3236 max_output_tokens : Optional [int ] = None
3337 """The maximum number of tokens to include in the response."""
3438
Original file line number Diff line number Diff line change 2323from .._types import SequenceNotStr
2424from .thinking_level import ThinkingLevel
2525from .tool_choice_param import ToolChoiceParam
26+ from .image_config_param import ImageConfigParam
2627from .speech_config_param import SpeechConfigParam
2728
2829__all__ = ["GenerationConfigParam" ]
3132class GenerationConfigParam (TypedDict , total = False ):
3233 """Configuration parameters for model interactions."""
3334
35+ image_config : ImageConfigParam
36+ """Configuration for image interaction."""
37+
3438 max_output_tokens : int
3539 """The maximum number of tokens to include in the response."""
3640
Original file line number Diff line number Diff line change 1+ # Copyright 2025 Google LLC
2+ #
3+ # Licensed under the Apache License, Version 2.0 (the "License");
4+ # you may not use this file except in compliance with the License.
5+ # You may obtain a copy of the License at
6+ #
7+ # http://www.apache.org/licenses/LICENSE-2.0
8+ #
9+ # Unless required by applicable law or agreed to in writing, software
10+ # distributed under the License is distributed on an "AS IS" BASIS,
11+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+ # See the License for the specific language governing permissions and
13+ # limitations under the License.
14+ #
15+
16+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
17+
18+ from typing import Optional
19+
20+ from .._models import BaseModel
21+
22+ __all__ = ["ImageConfig" ]
23+
24+
25+ class ImageConfig (BaseModel ):
26+ """The configuration for image interaction."""
27+
28+ aspect_ratio : Optional [str ] = None
29+
30+ image_size : Optional [str ] = None
Original file line number Diff line number Diff line change 1+ # Copyright 2025 Google LLC
2+ #
3+ # Licensed under the Apache License, Version 2.0 (the "License");
4+ # you may not use this file except in compliance with the License.
5+ # You may obtain a copy of the License at
6+ #
7+ # http://www.apache.org/licenses/LICENSE-2.0
8+ #
9+ # Unless required by applicable law or agreed to in writing, software
10+ # distributed under the License is distributed on an "AS IS" BASIS,
11+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+ # See the License for the specific language governing permissions and
13+ # limitations under the License.
14+ #
15+
16+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
17+
18+ from __future__ import annotations
19+
20+ from typing_extensions import TypedDict
21+
22+ __all__ = ["ImageConfigParam" ]
23+
24+
25+ class ImageConfigParam (TypedDict , total = False ):
26+ """The configuration for image interaction."""
27+
28+ aspect_ratio : str
29+
30+ image_size : str
You can’t perform that action at this time.
0 commit comments