Skip to content

Commit 756cacf

Browse files
committed
Merge 'integration_2025-03-06_779347461634' into 'master'
merge branch integration_2025-03-06_779347461634 into master See merge request: !531
2 parents 53f5bd8 + 549bfc7 commit 756cacf

File tree

13 files changed

+99
-6
lines changed

13 files changed

+99
-6
lines changed

meta.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
2-
"lasted": "1.0.127",
3-
"meta_commit": "aab29deec4400a0c26fb7c8794f29adb59a4e29f"
2+
"lasted": "1.0.128",
3+
"meta_commit": "57fd53d9441d28feeac7486db2bd9892a3cedc05"
44
}

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
from setuptools import setup, find_packages # noqa: H301
44

55
NAME = "volcengine-python-sdk"
6-
VERSION = "1.0.127"
6+
VERSION = "1.0.128"
77
# To install the library, run the following
88
#
99
# python setup.py install

volcenginesdkarkruntime/resources/batch_chat/completions.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from datetime import timedelta, datetime
66
from random import random
77
from typing import Dict, List, Union, Iterable, Optional, Callable
8+
from typing_extensions import Literal
89

910
import httpx
1011

@@ -130,6 +131,8 @@ def create(
130131
top_p: Optional[float] | None = None,
131132
repetition_penalty: Optional[float] | None = None,
132133
n: Optional[int] | None = None,
134+
parallel_tool_calls: Optional[bool] | None = None,
135+
service_tier: Optional[Literal["auto", "default"]] | None = None,
133136
tool_choice: ChatCompletionToolChoiceOptionParam | None = None,
134137
response_format: completion_create_params.ResponseFormat | None = None,
135138
user: str | None = None,
@@ -172,6 +175,8 @@ def create(
172175
"user": user,
173176
"repetition_penalty": repetition_penalty,
174177
"n": n,
178+
"parallel_tool_calls": parallel_tool_calls,
179+
"service_tier": service_tier,
175180
"tool_choice": tool_choice,
176181
"response_format": response_format,
177182
},
@@ -272,6 +277,8 @@ async def create(
272277
user: str | None = None,
273278
repetition_penalty: Optional[float] | None = None,
274279
n: Optional[int] | None = None,
280+
parallel_tool_calls: Optional[bool] | None = None,
281+
service_tier: Optional[Literal["auto", "default"]] | None = None,
275282
tool_choice: ChatCompletionToolChoiceOptionParam | None = None,
276283
response_format: completion_create_params.ResponseFormat | None = None,
277284
extra_headers: Headers | None = None,
@@ -314,6 +321,8 @@ async def create(
314321
"user": user,
315322
"repetition_penalty": repetition_penalty,
316323
"n": n,
324+
"parallel_tool_calls": parallel_tool_calls,
325+
"service_tier": service_tier,
317326
"tool_choice": tool_choice,
318327
"response_format": response_format,
319328
},

volcenginesdkarkruntime/resources/bot/completions.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,8 @@ def create(
6363
top_p: Optional[float] | None = None,
6464
repetition_penalty: Optional[float] | None = None,
6565
n: Optional[int] | None = None,
66+
parallel_tool_calls: Optional[bool] | None = None,
67+
service_tier: Optional[Literal["auto", "default"]] | None = None,
6668
tool_choice: ChatCompletionToolChoiceOptionParam | None = None,
6769
response_format: completion_create_params.ResponseFormat | None = None,
6870
user: str | None = None,
@@ -93,6 +95,8 @@ def create(
9395
"user": user,
9496
"repetition_penalty": repetition_penalty,
9597
"n": n,
98+
"parallel_tool_calls": parallel_tool_calls,
99+
"service_tier": service_tier,
96100
"tool_choice": tool_choice,
97101
"response_format": response_format,
98102
"metadata": metadata,
@@ -139,6 +143,8 @@ async def create(
139143
top_p: Optional[float] | None = None,
140144
repetition_penalty: Optional[float] | None = None,
141145
n: Optional[int] | None = None,
146+
parallel_tool_calls: Optional[bool] | None = None,
147+
service_tier: Optional[Literal["auto", "default"]] | None = None,
142148
tool_choice: ChatCompletionToolChoiceOptionParam | None = None,
143149
response_format: completion_create_params.ResponseFormat | None = None,
144150
user: str | None = None,
@@ -169,6 +175,8 @@ async def create(
169175
"user": user,
170176
"repetition_penalty": repetition_penalty,
171177
"n": n,
178+
"parallel_tool_calls": parallel_tool_calls,
179+
"service_tier": service_tier,
172180
"tool_choice": tool_choice,
173181
"response_format": response_format,
174182
"metadata": metadata,

volcenginesdkarkruntime/resources/chat/completions.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,8 @@ def create(
158158
top_p: Optional[float] | None = None,
159159
repetition_penalty: Optional[float] | None = None,
160160
n: Optional[int] | None = None,
161+
parallel_tool_calls: Optional[bool] | None = None,
162+
service_tier: Optional[Literal["auto", "default"]] | None = None,
161163
tool_choice: ChatCompletionToolChoiceOptionParam | None = None,
162164
response_format: completion_create_params.ResponseFormat | None = None,
163165
user: str | None = None,
@@ -195,6 +197,8 @@ def create(
195197
"user": user,
196198
"repetition_penalty": repetition_penalty,
197199
"n": n,
200+
"parallel_tool_calls": parallel_tool_calls,
201+
"service_tier": service_tier,
198202
"tool_choice": tool_choice,
199203
"response_format": response_format,
200204
},
@@ -296,6 +300,8 @@ async def create(
296300
user: str | None = None,
297301
repetition_penalty: Optional[float] | None = None,
298302
n: Optional[int] | None = None,
303+
parallel_tool_calls: Optional[bool] | None = None,
304+
service_tier: Optional[Literal["auto", "default"]] | None = None,
299305
tool_choice: ChatCompletionToolChoiceOptionParam | None = None,
300306
response_format: completion_create_params.ResponseFormat | None = None,
301307
extra_headers: Headers | None = None,
@@ -332,6 +338,8 @@ async def create(
332338
"user": user,
333339
"repetition_penalty": repetition_penalty,
334340
"n": n,
341+
"parallel_tool_calls": parallel_tool_calls,
342+
"service_tier": service_tier,
335343
"tool_choice": tool_choice,
336344
"response_format": response_format,
337345
},

volcenginesdkarkruntime/types/chat/chat_completion.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,24 @@ class ChatCompletion(BaseModel):
5959
model: str
6060
"""The model used for the chat completion."""
6161

62+
service_tier: Optional[Literal["auto", "default"]]
63+
"""Specifies the latency tier to use for processing the request.
64+
65+
This parameter is relevant for customers subscribed to the scale tier service:
66+
67+
- If set to 'auto', and the endpoint is Scale tier enabled, the system will
68+
utilize scale tier credits until they are exhausted.
69+
- If set to 'auto', and the endpoint is not Scale tier enabled, the request will
70+
be processed using the default service tier with a lower uptime SLA and no
71+
latency guarentee.
72+
- If set to 'default', the request will be processed using the default service
73+
tier with a lower uptime SLA and no latency guarentee.
74+
- When not set, the default behavior is 'auto'.
75+
76+
When this parameter is set, the response body will include the `service_tier`
77+
utilized.
78+
"""
79+
6280
object: Literal["chat.completion"]
6381
"""The object type, which is always `chat.completion`."""
6482

volcenginesdkarkruntime/types/chat/chat_completion_assistant_message_param.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,13 @@ class ChatCompletionAssistantMessageParam(TypedDict, total=False):
3131
Required unless `tool_calls` or `function_call` is specified.
3232
"""
3333

34+
name: Optional[str]
35+
"""An optional name for the participant.
36+
37+
Provides the model information to differentiate between participants of the same
38+
role.
39+
"""
40+
3441
function_call: FunctionCall
3542
"""Deprecated and replaced by `tool_calls`.
3643

volcenginesdkarkruntime/types/chat/chat_completion_chunk.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,24 @@ class ChatCompletionChunk(BaseModel):
126126
model: str
127127
"""The model to generate the completion."""
128128

129+
service_tier: Optional[Literal["auto", "default"]]
130+
"""Specifies the latency tier to use for processing the request.
131+
132+
This parameter is relevant for customers subscribed to the scale tier service:
133+
134+
- If set to 'auto', and the endpoint is Scale tier enabled, the system will
135+
utilize scale tier credits until they are exhausted.
136+
- If set to 'auto', and the endpoint is not Scale tier enabled, the request will
137+
be processed using the default service tier with a lower uptime SLA and no
138+
latency guarentee.
139+
- If set to 'default', the request will be processed using the default service
140+
tier with a lower uptime SLA and no latency guarentee.
141+
- When not set, the default behavior is 'auto'.
142+
143+
When this parameter is set, the response body will include the `service_tier`
144+
utilized.
145+
"""
146+
129147
object: Literal["chat.completion.chunk"]
130148
"""The object type, which is always `chat.completion.chunk`."""
131149

volcenginesdkarkruntime/types/chat/chat_completion_system_message_param.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
from __future__ import annotations
22

3+
from typing import Optional
4+
35
from typing_extensions import Literal, Required, TypedDict
46

57
__all__ = ["ChatCompletionSystemMessageParam"]
@@ -11,3 +13,10 @@ class ChatCompletionSystemMessageParam(TypedDict, total=False):
1113

1214
role: Required[Literal["system"]]
1315
"""The role of the messages author, in this case `system`."""
16+
17+
name: Optional[str]
18+
"""An optional name for the participant.
19+
20+
Provides the model information to differentiate between participants of the same
21+
role.
22+
"""

volcenginesdkarkruntime/types/chat/chat_completion_tool_message_param.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
from __future__ import annotations
22

3+
from typing import Optional
4+
35
from typing_extensions import Literal, Required, TypedDict
46

57
__all__ = ["ChatCompletionToolMessageParam"]
@@ -12,5 +14,12 @@ class ChatCompletionToolMessageParam(TypedDict, total=False):
1214
role: Required[Literal["tool"]]
1315
"""The role of the messages author, in this case `tool`."""
1416

17+
name: Optional[str]
18+
"""An optional name for the participant.
19+
20+
Provides the model information to differentiate between participants of the same
21+
role.
22+
"""
23+
1524
tool_call_id: Required[str]
1625
"""Tool call that this message is responding to."""

0 commit comments

Comments
 (0)