types-boto3-bedrock-runtime 1.36.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- types_boto3_bedrock_runtime/__init__.py +29 -0
- types_boto3_bedrock_runtime/__init__.pyi +28 -0
- types_boto3_bedrock_runtime/__main__.py +43 -0
- types_boto3_bedrock_runtime/client.py +202 -0
- types_boto3_bedrock_runtime/client.pyi +199 -0
- types_boto3_bedrock_runtime/literals.py +556 -0
- types_boto3_bedrock_runtime/literals.pyi +554 -0
- types_boto3_bedrock_runtime/paginator.py +61 -0
- types_boto3_bedrock_runtime/paginator.pyi +57 -0
- types_boto3_bedrock_runtime/py.typed +0 -0
- types_boto3_bedrock_runtime/type_defs.py +1032 -0
- types_boto3_bedrock_runtime/type_defs.pyi +915 -0
- types_boto3_bedrock_runtime/version.py +7 -0
- types_boto3_bedrock_runtime-1.36.0.dist-info/LICENSE +21 -0
- types_boto3_bedrock_runtime-1.36.0.dist-info/METADATA +482 -0
- types_boto3_bedrock_runtime-1.36.0.dist-info/RECORD +18 -0
- types_boto3_bedrock_runtime-1.36.0.dist-info/WHEEL +5 -0
- types_boto3_bedrock_runtime-1.36.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Main interface for bedrock-runtime service.
|
|
3
|
+
|
|
4
|
+
Usage::
|
|
5
|
+
|
|
6
|
+
```python
|
|
7
|
+
from boto3.session import Session
|
|
8
|
+
from types_boto3_bedrock_runtime import (
|
|
9
|
+
BedrockRuntimeClient,
|
|
10
|
+
Client,
|
|
11
|
+
ListAsyncInvokesPaginator,
|
|
12
|
+
)
|
|
13
|
+
|
|
14
|
+
session = Session()
|
|
15
|
+
client: BedrockRuntimeClient = session.client("bedrock-runtime")
|
|
16
|
+
|
|
17
|
+
list_async_invokes_paginator: ListAsyncInvokesPaginator = client.get_paginator("list_async_invokes")
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
Copyright 2025 Vlad Emelianov
|
|
21
|
+
"""
|
|
22
|
+
|
|
23
|
+
from .client import BedrockRuntimeClient
|
|
24
|
+
from .paginator import ListAsyncInvokesPaginator
|
|
25
|
+
|
|
26
|
+
Client = BedrockRuntimeClient
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
__all__ = ("BedrockRuntimeClient", "Client", "ListAsyncInvokesPaginator")
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Main interface for bedrock-runtime service.
|
|
3
|
+
|
|
4
|
+
Usage::
|
|
5
|
+
|
|
6
|
+
```python
|
|
7
|
+
from boto3.session import Session
|
|
8
|
+
from types_boto3_bedrock_runtime import (
|
|
9
|
+
BedrockRuntimeClient,
|
|
10
|
+
Client,
|
|
11
|
+
ListAsyncInvokesPaginator,
|
|
12
|
+
)
|
|
13
|
+
|
|
14
|
+
session = Session()
|
|
15
|
+
client: BedrockRuntimeClient = session.client("bedrock-runtime")
|
|
16
|
+
|
|
17
|
+
list_async_invokes_paginator: ListAsyncInvokesPaginator = client.get_paginator("list_async_invokes")
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
Copyright 2025 Vlad Emelianov
|
|
21
|
+
"""
|
|
22
|
+
|
|
23
|
+
from .client import BedrockRuntimeClient
|
|
24
|
+
from .paginator import ListAsyncInvokesPaginator
|
|
25
|
+
|
|
26
|
+
Client = BedrockRuntimeClient
|
|
27
|
+
|
|
28
|
+
__all__ = ("BedrockRuntimeClient", "Client", "ListAsyncInvokesPaginator")
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Main CLI entrypoint.
|
|
3
|
+
|
|
4
|
+
Copyright 2025 Vlad Emelianov
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
import sys
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def print_info() -> None:
|
|
11
|
+
"""
|
|
12
|
+
Print package info to stdout.
|
|
13
|
+
"""
|
|
14
|
+
sys.stdout.write(
|
|
15
|
+
"Type annotations for boto3 BedrockRuntime 1.36.0\n"
|
|
16
|
+
"Version: 1.36.0\n"
|
|
17
|
+
"Builder version: 8.8.0\n"
|
|
18
|
+
"Docs: https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime//\n"
|
|
19
|
+
"Boto3 docs: https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime.html#bedrockruntime\n"
|
|
20
|
+
"Other services: https://pypi.org/project/boto3-stubs/\n"
|
|
21
|
+
"Changelog: https://github.com/youtype/mypy_boto3_builder/releases\n"
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
def print_version() -> None:
|
|
26
|
+
"""
|
|
27
|
+
Print package version to stdout.
|
|
28
|
+
"""
|
|
29
|
+
sys.stdout.write("1.36.0\n")
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def main() -> None:
|
|
33
|
+
"""
|
|
34
|
+
Main CLI entrypoint.
|
|
35
|
+
"""
|
|
36
|
+
if "--version" in sys.argv:
|
|
37
|
+
print_version()
|
|
38
|
+
return
|
|
39
|
+
print_info()
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
if __name__ == "__main__":
|
|
43
|
+
main()
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Type annotations for bedrock-runtime service Client.
|
|
3
|
+
|
|
4
|
+
[Documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/)
|
|
5
|
+
|
|
6
|
+
Usage::
|
|
7
|
+
|
|
8
|
+
```python
|
|
9
|
+
from boto3.session import Session
|
|
10
|
+
from types_boto3_bedrock_runtime.client import BedrockRuntimeClient
|
|
11
|
+
|
|
12
|
+
session = Session()
|
|
13
|
+
client: BedrockRuntimeClient = session.client("bedrock-runtime")
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Copyright 2025 Vlad Emelianov
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
from __future__ import annotations
|
|
20
|
+
|
|
21
|
+
import sys
|
|
22
|
+
from typing import Any
|
|
23
|
+
|
|
24
|
+
from botocore.client import BaseClient, ClientMeta
|
|
25
|
+
from botocore.errorfactory import BaseClientExceptions
|
|
26
|
+
from botocore.exceptions import ClientError as BotocoreClientError
|
|
27
|
+
|
|
28
|
+
from .paginator import ListAsyncInvokesPaginator
|
|
29
|
+
from .type_defs import (
|
|
30
|
+
ApplyGuardrailRequestRequestTypeDef,
|
|
31
|
+
ApplyGuardrailResponseTypeDef,
|
|
32
|
+
ConverseRequestRequestTypeDef,
|
|
33
|
+
ConverseResponseTypeDef,
|
|
34
|
+
ConverseStreamRequestRequestTypeDef,
|
|
35
|
+
ConverseStreamResponseTypeDef,
|
|
36
|
+
GetAsyncInvokeRequestRequestTypeDef,
|
|
37
|
+
GetAsyncInvokeResponseTypeDef,
|
|
38
|
+
InvokeModelRequestRequestTypeDef,
|
|
39
|
+
InvokeModelResponseTypeDef,
|
|
40
|
+
InvokeModelWithResponseStreamRequestRequestTypeDef,
|
|
41
|
+
InvokeModelWithResponseStreamResponseTypeDef,
|
|
42
|
+
ListAsyncInvokesRequestRequestTypeDef,
|
|
43
|
+
ListAsyncInvokesResponseTypeDef,
|
|
44
|
+
StartAsyncInvokeRequestRequestTypeDef,
|
|
45
|
+
StartAsyncInvokeResponseTypeDef,
|
|
46
|
+
)
|
|
47
|
+
|
|
48
|
+
if sys.version_info >= (3, 9):
|
|
49
|
+
from builtins import type as Type
|
|
50
|
+
from collections.abc import Mapping
|
|
51
|
+
else:
|
|
52
|
+
from typing import Mapping, Type
|
|
53
|
+
if sys.version_info >= (3, 12):
|
|
54
|
+
from typing import Literal, Unpack
|
|
55
|
+
else:
|
|
56
|
+
from typing_extensions import Literal, Unpack
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
__all__ = ("BedrockRuntimeClient",)
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
class Exceptions(BaseClientExceptions):
|
|
63
|
+
AccessDeniedException: Type[BotocoreClientError]
|
|
64
|
+
ClientError: Type[BotocoreClientError]
|
|
65
|
+
ConflictException: Type[BotocoreClientError]
|
|
66
|
+
InternalServerException: Type[BotocoreClientError]
|
|
67
|
+
ModelErrorException: Type[BotocoreClientError]
|
|
68
|
+
ModelNotReadyException: Type[BotocoreClientError]
|
|
69
|
+
ModelStreamErrorException: Type[BotocoreClientError]
|
|
70
|
+
ModelTimeoutException: Type[BotocoreClientError]
|
|
71
|
+
ResourceNotFoundException: Type[BotocoreClientError]
|
|
72
|
+
ServiceQuotaExceededException: Type[BotocoreClientError]
|
|
73
|
+
ServiceUnavailableException: Type[BotocoreClientError]
|
|
74
|
+
ThrottlingException: Type[BotocoreClientError]
|
|
75
|
+
ValidationException: Type[BotocoreClientError]
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
class BedrockRuntimeClient(BaseClient):
|
|
79
|
+
"""
|
|
80
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime.html#BedrockRuntime.Client)
|
|
81
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/)
|
|
82
|
+
"""
|
|
83
|
+
|
|
84
|
+
meta: ClientMeta
|
|
85
|
+
|
|
86
|
+
@property
|
|
87
|
+
def exceptions(self) -> Exceptions:
|
|
88
|
+
"""
|
|
89
|
+
BedrockRuntimeClient exceptions.
|
|
90
|
+
|
|
91
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime.html#BedrockRuntime.Client)
|
|
92
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#exceptions)
|
|
93
|
+
"""
|
|
94
|
+
|
|
95
|
+
def can_paginate(self, operation_name: str) -> bool:
|
|
96
|
+
"""
|
|
97
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/can_paginate.html)
|
|
98
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#can_paginate)
|
|
99
|
+
"""
|
|
100
|
+
|
|
101
|
+
def generate_presigned_url(
|
|
102
|
+
self,
|
|
103
|
+
ClientMethod: str,
|
|
104
|
+
Params: Mapping[str, Any] = ...,
|
|
105
|
+
ExpiresIn: int = 3600,
|
|
106
|
+
HttpMethod: str = ...,
|
|
107
|
+
) -> str:
|
|
108
|
+
"""
|
|
109
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/generate_presigned_url.html)
|
|
110
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#generate_presigned_url)
|
|
111
|
+
"""
|
|
112
|
+
|
|
113
|
+
def apply_guardrail(
|
|
114
|
+
self, **kwargs: Unpack[ApplyGuardrailRequestRequestTypeDef]
|
|
115
|
+
) -> ApplyGuardrailResponseTypeDef:
|
|
116
|
+
"""
|
|
117
|
+
The action to apply a guardrail.
|
|
118
|
+
|
|
119
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/apply_guardrail.html)
|
|
120
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#apply_guardrail)
|
|
121
|
+
"""
|
|
122
|
+
|
|
123
|
+
def converse(self, **kwargs: Unpack[ConverseRequestRequestTypeDef]) -> ConverseResponseTypeDef:
|
|
124
|
+
"""
|
|
125
|
+
Sends messages to the specified Amazon Bedrock model.
|
|
126
|
+
|
|
127
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/converse.html)
|
|
128
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#converse)
|
|
129
|
+
"""
|
|
130
|
+
|
|
131
|
+
def converse_stream(
|
|
132
|
+
self, **kwargs: Unpack[ConverseStreamRequestRequestTypeDef]
|
|
133
|
+
) -> ConverseStreamResponseTypeDef:
|
|
134
|
+
"""
|
|
135
|
+
Sends messages to the specified Amazon Bedrock model and returns the response
|
|
136
|
+
in a stream.
|
|
137
|
+
|
|
138
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/converse_stream.html)
|
|
139
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#converse_stream)
|
|
140
|
+
"""
|
|
141
|
+
|
|
142
|
+
def get_async_invoke(
|
|
143
|
+
self, **kwargs: Unpack[GetAsyncInvokeRequestRequestTypeDef]
|
|
144
|
+
) -> GetAsyncInvokeResponseTypeDef:
|
|
145
|
+
"""
|
|
146
|
+
Retrieve information about an asynchronous invocation.
|
|
147
|
+
|
|
148
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/get_async_invoke.html)
|
|
149
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#get_async_invoke)
|
|
150
|
+
"""
|
|
151
|
+
|
|
152
|
+
def invoke_model(
|
|
153
|
+
self, **kwargs: Unpack[InvokeModelRequestRequestTypeDef]
|
|
154
|
+
) -> InvokeModelResponseTypeDef:
|
|
155
|
+
"""
|
|
156
|
+
Invokes the specified Amazon Bedrock model to run inference using the prompt
|
|
157
|
+
and inference parameters provided in the request body.
|
|
158
|
+
|
|
159
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/invoke_model.html)
|
|
160
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#invoke_model)
|
|
161
|
+
"""
|
|
162
|
+
|
|
163
|
+
def invoke_model_with_response_stream(
|
|
164
|
+
self, **kwargs: Unpack[InvokeModelWithResponseStreamRequestRequestTypeDef]
|
|
165
|
+
) -> InvokeModelWithResponseStreamResponseTypeDef:
|
|
166
|
+
"""
|
|
167
|
+
Invoke the specified Amazon Bedrock model to run inference using the prompt and
|
|
168
|
+
inference parameters provided in the request body.
|
|
169
|
+
|
|
170
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/invoke_model_with_response_stream.html)
|
|
171
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#invoke_model_with_response_stream)
|
|
172
|
+
"""
|
|
173
|
+
|
|
174
|
+
def list_async_invokes(
|
|
175
|
+
self, **kwargs: Unpack[ListAsyncInvokesRequestRequestTypeDef]
|
|
176
|
+
) -> ListAsyncInvokesResponseTypeDef:
|
|
177
|
+
"""
|
|
178
|
+
Lists asynchronous invocations.
|
|
179
|
+
|
|
180
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/list_async_invokes.html)
|
|
181
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#list_async_invokes)
|
|
182
|
+
"""
|
|
183
|
+
|
|
184
|
+
def start_async_invoke(
|
|
185
|
+
self, **kwargs: Unpack[StartAsyncInvokeRequestRequestTypeDef]
|
|
186
|
+
) -> StartAsyncInvokeResponseTypeDef:
|
|
187
|
+
"""
|
|
188
|
+
Starts an asynchronous invocation.
|
|
189
|
+
|
|
190
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/start_async_invoke.html)
|
|
191
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#start_async_invoke)
|
|
192
|
+
"""
|
|
193
|
+
|
|
194
|
+
def get_paginator( # type: ignore[override]
|
|
195
|
+
self, operation_name: Literal["list_async_invokes"]
|
|
196
|
+
) -> ListAsyncInvokesPaginator:
|
|
197
|
+
"""
|
|
198
|
+
Create a paginator for an operation.
|
|
199
|
+
|
|
200
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/get_paginator.html)
|
|
201
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#get_paginator)
|
|
202
|
+
"""
|
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Type annotations for bedrock-runtime service Client.
|
|
3
|
+
|
|
4
|
+
[Documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/)
|
|
5
|
+
|
|
6
|
+
Usage::
|
|
7
|
+
|
|
8
|
+
```python
|
|
9
|
+
from boto3.session import Session
|
|
10
|
+
from types_boto3_bedrock_runtime.client import BedrockRuntimeClient
|
|
11
|
+
|
|
12
|
+
session = Session()
|
|
13
|
+
client: BedrockRuntimeClient = session.client("bedrock-runtime")
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Copyright 2025 Vlad Emelianov
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
from __future__ import annotations
|
|
20
|
+
|
|
21
|
+
import sys
|
|
22
|
+
from typing import Any
|
|
23
|
+
|
|
24
|
+
from botocore.client import BaseClient, ClientMeta
|
|
25
|
+
from botocore.errorfactory import BaseClientExceptions
|
|
26
|
+
from botocore.exceptions import ClientError as BotocoreClientError
|
|
27
|
+
|
|
28
|
+
from .paginator import ListAsyncInvokesPaginator
|
|
29
|
+
from .type_defs import (
|
|
30
|
+
ApplyGuardrailRequestRequestTypeDef,
|
|
31
|
+
ApplyGuardrailResponseTypeDef,
|
|
32
|
+
ConverseRequestRequestTypeDef,
|
|
33
|
+
ConverseResponseTypeDef,
|
|
34
|
+
ConverseStreamRequestRequestTypeDef,
|
|
35
|
+
ConverseStreamResponseTypeDef,
|
|
36
|
+
GetAsyncInvokeRequestRequestTypeDef,
|
|
37
|
+
GetAsyncInvokeResponseTypeDef,
|
|
38
|
+
InvokeModelRequestRequestTypeDef,
|
|
39
|
+
InvokeModelResponseTypeDef,
|
|
40
|
+
InvokeModelWithResponseStreamRequestRequestTypeDef,
|
|
41
|
+
InvokeModelWithResponseStreamResponseTypeDef,
|
|
42
|
+
ListAsyncInvokesRequestRequestTypeDef,
|
|
43
|
+
ListAsyncInvokesResponseTypeDef,
|
|
44
|
+
StartAsyncInvokeRequestRequestTypeDef,
|
|
45
|
+
StartAsyncInvokeResponseTypeDef,
|
|
46
|
+
)
|
|
47
|
+
|
|
48
|
+
if sys.version_info >= (3, 9):
|
|
49
|
+
from builtins import type as Type
|
|
50
|
+
from collections.abc import Mapping
|
|
51
|
+
else:
|
|
52
|
+
from typing import Mapping, Type
|
|
53
|
+
if sys.version_info >= (3, 12):
|
|
54
|
+
from typing import Literal, Unpack
|
|
55
|
+
else:
|
|
56
|
+
from typing_extensions import Literal, Unpack
|
|
57
|
+
|
|
58
|
+
__all__ = ("BedrockRuntimeClient",)
|
|
59
|
+
|
|
60
|
+
class Exceptions(BaseClientExceptions):
|
|
61
|
+
AccessDeniedException: Type[BotocoreClientError]
|
|
62
|
+
ClientError: Type[BotocoreClientError]
|
|
63
|
+
ConflictException: Type[BotocoreClientError]
|
|
64
|
+
InternalServerException: Type[BotocoreClientError]
|
|
65
|
+
ModelErrorException: Type[BotocoreClientError]
|
|
66
|
+
ModelNotReadyException: Type[BotocoreClientError]
|
|
67
|
+
ModelStreamErrorException: Type[BotocoreClientError]
|
|
68
|
+
ModelTimeoutException: Type[BotocoreClientError]
|
|
69
|
+
ResourceNotFoundException: Type[BotocoreClientError]
|
|
70
|
+
ServiceQuotaExceededException: Type[BotocoreClientError]
|
|
71
|
+
ServiceUnavailableException: Type[BotocoreClientError]
|
|
72
|
+
ThrottlingException: Type[BotocoreClientError]
|
|
73
|
+
ValidationException: Type[BotocoreClientError]
|
|
74
|
+
|
|
75
|
+
class BedrockRuntimeClient(BaseClient):
|
|
76
|
+
"""
|
|
77
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime.html#BedrockRuntime.Client)
|
|
78
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/)
|
|
79
|
+
"""
|
|
80
|
+
|
|
81
|
+
meta: ClientMeta
|
|
82
|
+
|
|
83
|
+
@property
|
|
84
|
+
def exceptions(self) -> Exceptions:
|
|
85
|
+
"""
|
|
86
|
+
BedrockRuntimeClient exceptions.
|
|
87
|
+
|
|
88
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime.html#BedrockRuntime.Client)
|
|
89
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#exceptions)
|
|
90
|
+
"""
|
|
91
|
+
|
|
92
|
+
def can_paginate(self, operation_name: str) -> bool:
|
|
93
|
+
"""
|
|
94
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/can_paginate.html)
|
|
95
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#can_paginate)
|
|
96
|
+
"""
|
|
97
|
+
|
|
98
|
+
def generate_presigned_url(
|
|
99
|
+
self,
|
|
100
|
+
ClientMethod: str,
|
|
101
|
+
Params: Mapping[str, Any] = ...,
|
|
102
|
+
ExpiresIn: int = 3600,
|
|
103
|
+
HttpMethod: str = ...,
|
|
104
|
+
) -> str:
|
|
105
|
+
"""
|
|
106
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/generate_presigned_url.html)
|
|
107
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#generate_presigned_url)
|
|
108
|
+
"""
|
|
109
|
+
|
|
110
|
+
def apply_guardrail(
|
|
111
|
+
self, **kwargs: Unpack[ApplyGuardrailRequestRequestTypeDef]
|
|
112
|
+
) -> ApplyGuardrailResponseTypeDef:
|
|
113
|
+
"""
|
|
114
|
+
The action to apply a guardrail.
|
|
115
|
+
|
|
116
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/apply_guardrail.html)
|
|
117
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#apply_guardrail)
|
|
118
|
+
"""
|
|
119
|
+
|
|
120
|
+
def converse(self, **kwargs: Unpack[ConverseRequestRequestTypeDef]) -> ConverseResponseTypeDef:
|
|
121
|
+
"""
|
|
122
|
+
Sends messages to the specified Amazon Bedrock model.
|
|
123
|
+
|
|
124
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/converse.html)
|
|
125
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#converse)
|
|
126
|
+
"""
|
|
127
|
+
|
|
128
|
+
def converse_stream(
|
|
129
|
+
self, **kwargs: Unpack[ConverseStreamRequestRequestTypeDef]
|
|
130
|
+
) -> ConverseStreamResponseTypeDef:
|
|
131
|
+
"""
|
|
132
|
+
Sends messages to the specified Amazon Bedrock model and returns the response
|
|
133
|
+
in a stream.
|
|
134
|
+
|
|
135
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/converse_stream.html)
|
|
136
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#converse_stream)
|
|
137
|
+
"""
|
|
138
|
+
|
|
139
|
+
def get_async_invoke(
|
|
140
|
+
self, **kwargs: Unpack[GetAsyncInvokeRequestRequestTypeDef]
|
|
141
|
+
) -> GetAsyncInvokeResponseTypeDef:
|
|
142
|
+
"""
|
|
143
|
+
Retrieve information about an asynchronous invocation.
|
|
144
|
+
|
|
145
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/get_async_invoke.html)
|
|
146
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#get_async_invoke)
|
|
147
|
+
"""
|
|
148
|
+
|
|
149
|
+
def invoke_model(
|
|
150
|
+
self, **kwargs: Unpack[InvokeModelRequestRequestTypeDef]
|
|
151
|
+
) -> InvokeModelResponseTypeDef:
|
|
152
|
+
"""
|
|
153
|
+
Invokes the specified Amazon Bedrock model to run inference using the prompt
|
|
154
|
+
and inference parameters provided in the request body.
|
|
155
|
+
|
|
156
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/invoke_model.html)
|
|
157
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#invoke_model)
|
|
158
|
+
"""
|
|
159
|
+
|
|
160
|
+
def invoke_model_with_response_stream(
|
|
161
|
+
self, **kwargs: Unpack[InvokeModelWithResponseStreamRequestRequestTypeDef]
|
|
162
|
+
) -> InvokeModelWithResponseStreamResponseTypeDef:
|
|
163
|
+
"""
|
|
164
|
+
Invoke the specified Amazon Bedrock model to run inference using the prompt and
|
|
165
|
+
inference parameters provided in the request body.
|
|
166
|
+
|
|
167
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/invoke_model_with_response_stream.html)
|
|
168
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#invoke_model_with_response_stream)
|
|
169
|
+
"""
|
|
170
|
+
|
|
171
|
+
def list_async_invokes(
|
|
172
|
+
self, **kwargs: Unpack[ListAsyncInvokesRequestRequestTypeDef]
|
|
173
|
+
) -> ListAsyncInvokesResponseTypeDef:
|
|
174
|
+
"""
|
|
175
|
+
Lists asynchronous invocations.
|
|
176
|
+
|
|
177
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/list_async_invokes.html)
|
|
178
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#list_async_invokes)
|
|
179
|
+
"""
|
|
180
|
+
|
|
181
|
+
def start_async_invoke(
|
|
182
|
+
self, **kwargs: Unpack[StartAsyncInvokeRequestRequestTypeDef]
|
|
183
|
+
) -> StartAsyncInvokeResponseTypeDef:
|
|
184
|
+
"""
|
|
185
|
+
Starts an asynchronous invocation.
|
|
186
|
+
|
|
187
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/start_async_invoke.html)
|
|
188
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#start_async_invoke)
|
|
189
|
+
"""
|
|
190
|
+
|
|
191
|
+
def get_paginator( # type: ignore[override]
|
|
192
|
+
self, operation_name: Literal["list_async_invokes"]
|
|
193
|
+
) -> ListAsyncInvokesPaginator:
|
|
194
|
+
"""
|
|
195
|
+
Create a paginator for an operation.
|
|
196
|
+
|
|
197
|
+
[Show boto3 documentation](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/bedrock-runtime/client/get_paginator.html)
|
|
198
|
+
[Show types-boto3 documentation](https://youtype.github.io/types_boto3_docs/types_boto3_bedrock_runtime/client/#get_paginator)
|
|
199
|
+
"""
|