Skip to content

Commit db0faab

Browse files
authored
Merge pull request #82 from DataMini/release-please--branches--main--changes--next
release: 3.9.0
2 parents f35f085 + 275cde5 commit db0faab

20 files changed

+542
-42
lines changed

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "3.8.0"
2+
".": "3.9.0"
33
}

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
configured_endpoints: 90
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/datamini%2Fasktable-9685a6d1ce0077c478727502e935941fe3e5740d45549e3693d29941b462d31a.yml
1+
configured_endpoints: 92
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/datamini%2Fasktable-bb6c8be98a7d3c5109b7def15a21653d7bade60a2b6939157361c3fe9ef049d9.yml

CHANGELOG.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
# Changelog
22

3+
## 3.9.0 (2024-12-29)
4+
5+
Full Changelog: [v3.8.0...v3.9.0](https://github.com/DataMini/asktable-python/compare/v3.8.0...v3.9.0)
6+
7+
### Features
8+
9+
* **api:** add model groups ([#87](https://github.com/DataMini/asktable-python/issues/87)) ([c3aee20](https://github.com/DataMini/asktable-python/commit/c3aee2011aec41dee09a00184844315638ad6b9d))
10+
* **api:** api update ([#81](https://github.com/DataMini/asktable-python/issues/81)) ([60bc504](https://github.com/DataMini/asktable-python/commit/60bc504c4e9ed57580b789306ebf27dc338084ff))
11+
* **api:** api update ([#86](https://github.com/DataMini/asktable-python/issues/86)) ([07ca394](https://github.com/DataMini/asktable-python/commit/07ca394da227e2b3bab90d97e4133db56c4b1675))
12+
13+
14+
### Chores
15+
16+
* **internal:** codegen related update ([#83](https://github.com/DataMini/asktable-python/issues/83)) ([b0e0f6f](https://github.com/DataMini/asktable-python/commit/b0e0f6f3c3bb393985b59735423ae57fa6c986b0))
17+
* **internal:** codegen related update ([#84](https://github.com/DataMini/asktable-python/issues/84)) ([1734cd8](https://github.com/DataMini/asktable-python/commit/1734cd83b34b8e33af03d463425ff06be1333955))
18+
* **internal:** fix some typos ([#85](https://github.com/DataMini/asktable-python/issues/85)) ([f6b99d8](https://github.com/DataMini/asktable-python/commit/f6b99d8e501b5bc5e91b4ece711ab5fc17a82b4d))
19+
320
## 3.8.0 (2024-12-17)
421

522
Full Changelog: [v3.7.0...v3.8.0](https://github.com/DataMini/asktable-python/compare/v3.7.0...v3.8.0)

api.md

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,20 @@ Methods:
103103
Types:
104104

105105
```python
106-
from asktable.types import AIMessage, Chat, ToolMessage, UserMessage, ChatSendMessageResponse
106+
from asktable.types import (
107+
AIMessage,
108+
Chat,
109+
ToolMessage,
110+
UserMessage,
111+
ChatRetrieveResponse,
112+
ChatSendMessageResponse,
113+
)
107114
```
108115

109116
Methods:
110117

111118
- <code title="post /chats">client.chats.<a href="./src/asktable/resources/chats/chats.py">create</a>(\*\*<a href="src/asktable/types/chat_create_params.py">params</a>) -> <a href="./src/asktable/types/chat.py">Chat</a></code>
112-
- <code title="get /chats/{chat_id}">client.chats.<a href="./src/asktable/resources/chats/chats.py">retrieve</a>(chat_id) -> <a href="./src/asktable/types/chat.py">Chat</a></code>
119+
- <code title="get /chats/{chat_id}">client.chats.<a href="./src/asktable/resources/chats/chats.py">retrieve</a>(chat_id) -> <a href="./src/asktable/types/chat_retrieve_response.py">ChatRetrieveResponse</a></code>
113120
- <code title="get /chats">client.chats.<a href="./src/asktable/resources/chats/chats.py">list</a>(\*\*<a href="src/asktable/types/chat_list_params.py">params</a>) -> <a href="./src/asktable/types/chat.py">SyncPage[Chat]</a></code>
114121
- <code title="delete /chats/{chat_id}">client.chats.<a href="./src/asktable/resources/chats/chats.py">delete</a>(chat_id) -> None</code>
115122
- <code title="post /chats/{chat_id}">client.chats.<a href="./src/asktable/resources/chats/chats.py">send_message</a>(chat_id, \*\*<a href="src/asktable/types/chat_send_message_params.py">params</a>) -> <a href="./src/asktable/types/chat_send_message_response.py">ChatSendMessageResponse</a></code>
@@ -367,6 +374,19 @@ Methods:
367374
- <code title="get /training">client.trainings.<a href="./src/asktable/resources/trainings.py">list</a>(\*\*<a href="src/asktable/types/training_list_params.py">params</a>) -> <a href="./src/asktable/types/training_list_response.py">SyncPage[TrainingListResponse]</a></code>
368375
- <code title="delete /training/{id}">client.trainings.<a href="./src/asktable/resources/trainings.py">delete</a>(id, \*\*<a href="src/asktable/types/training_delete_params.py">params</a>) -> <a href="./src/asktable/types/training_delete_response.py">object</a></code>
369376

377+
# Project
378+
379+
Types:
380+
381+
```python
382+
from asktable.types import ProjectListModelGroupsResponse
383+
```
384+
385+
Methods:
386+
387+
- <code title="patch /project">client.project.<a href="./src/asktable/resources/project.py">update</a>(\*\*<a href="src/asktable/types/project_update_params.py">params</a>) -> <a href="./src/asktable/types/sys/project.py">Project</a></code>
388+
- <code title="get /project/model-groups">client.project.<a href="./src/asktable/resources/project.py">list_model_groups</a>() -> <a href="./src/asktable/types/project_list_model_groups_response.py">ProjectListModelGroupsResponse</a></code>
389+
370390
# Scores
371391

372392
Types:

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "asktable"
3-
version = "3.8.0"
3+
version = "3.9.0"
44
description = "The official Python library for the asktable API"
55
dynamic = ["readme"]
66
license = "Apache-2.0"

src/asktable/_client.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
roles,
3131
caches,
3232
scores,
33+
project,
3334
policies,
3435
trainings,
3536
integration,
@@ -78,6 +79,7 @@ class Asktable(SyncAPIClient):
7879
business_glossary: business_glossary.BusinessGlossaryResource
7980
preferences: preferences.PreferencesResource
8081
trainings: trainings.TrainingsResource
82+
project: project.ProjectResource
8183
scores: scores.ScoresResource
8284
with_raw_response: AsktableWithRawResponse
8385
with_streaming_response: AsktableWithStreamedResponse
@@ -151,6 +153,7 @@ def __init__(
151153
self.business_glossary = business_glossary.BusinessGlossaryResource(self)
152154
self.preferences = preferences.PreferencesResource(self)
153155
self.trainings = trainings.TrainingsResource(self)
156+
self.project = project.ProjectResource(self)
154157
self.scores = scores.ScoresResource(self)
155158
self.with_raw_response = AsktableWithRawResponse(self)
156159
self.with_streaming_response = AsktableWithStreamedResponse(self)
@@ -276,6 +279,7 @@ class AsyncAsktable(AsyncAPIClient):
276279
business_glossary: business_glossary.AsyncBusinessGlossaryResource
277280
preferences: preferences.AsyncPreferencesResource
278281
trainings: trainings.AsyncTrainingsResource
282+
project: project.AsyncProjectResource
279283
scores: scores.AsyncScoresResource
280284
with_raw_response: AsyncAsktableWithRawResponse
281285
with_streaming_response: AsyncAsktableWithStreamedResponse
@@ -349,6 +353,7 @@ def __init__(
349353
self.business_glossary = business_glossary.AsyncBusinessGlossaryResource(self)
350354
self.preferences = preferences.AsyncPreferencesResource(self)
351355
self.trainings = trainings.AsyncTrainingsResource(self)
356+
self.project = project.AsyncProjectResource(self)
352357
self.scores = scores.AsyncScoresResource(self)
353358
self.with_raw_response = AsyncAsktableWithRawResponse(self)
354359
self.with_streaming_response = AsyncAsktableWithStreamedResponse(self)
@@ -475,6 +480,7 @@ def __init__(self, client: Asktable) -> None:
475480
self.business_glossary = business_glossary.BusinessGlossaryResourceWithRawResponse(client.business_glossary)
476481
self.preferences = preferences.PreferencesResourceWithRawResponse(client.preferences)
477482
self.trainings = trainings.TrainingsResourceWithRawResponse(client.trainings)
483+
self.project = project.ProjectResourceWithRawResponse(client.project)
478484
self.scores = scores.ScoresResourceWithRawResponse(client.scores)
479485

480486

@@ -497,6 +503,7 @@ def __init__(self, client: AsyncAsktable) -> None:
497503
)
498504
self.preferences = preferences.AsyncPreferencesResourceWithRawResponse(client.preferences)
499505
self.trainings = trainings.AsyncTrainingsResourceWithRawResponse(client.trainings)
506+
self.project = project.AsyncProjectResourceWithRawResponse(client.project)
500507
self.scores = scores.AsyncScoresResourceWithRawResponse(client.scores)
501508

502509

@@ -519,6 +526,7 @@ def __init__(self, client: Asktable) -> None:
519526
)
520527
self.preferences = preferences.PreferencesResourceWithStreamingResponse(client.preferences)
521528
self.trainings = trainings.TrainingsResourceWithStreamingResponse(client.trainings)
529+
self.project = project.ProjectResourceWithStreamingResponse(client.project)
522530
self.scores = scores.ScoresResourceWithStreamingResponse(client.scores)
523531

524532

@@ -541,6 +549,7 @@ def __init__(self, client: AsyncAsktable) -> None:
541549
)
542550
self.preferences = preferences.AsyncPreferencesResourceWithStreamingResponse(client.preferences)
543551
self.trainings = trainings.AsyncTrainingsResourceWithStreamingResponse(client.trainings)
552+
self.project = project.AsyncProjectResourceWithStreamingResponse(client.project)
544553
self.scores = scores.AsyncScoresResourceWithStreamingResponse(client.scores)
545554

546555

src/asktable/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
22

33
__title__ = "asktable"
4-
__version__ = "3.8.0" # x-release-please-version
4+
__version__ = "3.9.0" # x-release-please-version

src/asktable/resources/__init__.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,14 @@
6464
ExtapisResourceWithStreamingResponse,
6565
AsyncExtapisResourceWithStreamingResponse,
6666
)
67+
from .project import (
68+
ProjectResource,
69+
AsyncProjectResource,
70+
ProjectResourceWithRawResponse,
71+
AsyncProjectResourceWithRawResponse,
72+
ProjectResourceWithStreamingResponse,
73+
AsyncProjectResourceWithStreamingResponse,
74+
)
6775
from .policies import (
6876
PoliciesResource,
6977
AsyncPoliciesResource,
@@ -220,6 +228,12 @@
220228
"AsyncTrainingsResourceWithRawResponse",
221229
"TrainingsResourceWithStreamingResponse",
222230
"AsyncTrainingsResourceWithStreamingResponse",
231+
"ProjectResource",
232+
"AsyncProjectResource",
233+
"ProjectResourceWithRawResponse",
234+
"AsyncProjectResourceWithRawResponse",
235+
"ProjectResourceWithStreamingResponse",
236+
"AsyncProjectResourceWithStreamingResponse",
223237
"ScoresResource",
224238
"AsyncScoresResource",
225239
"ScoresResourceWithRawResponse",

src/asktable/resources/chats/chats.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
from ...pagination import SyncPage, AsyncPage
3232
from ...types.chat import Chat
3333
from ..._base_client import AsyncPaginator, make_request_options
34+
from ...types.chat_retrieve_response import ChatRetrieveResponse
3435
from ...types.chat_send_message_response import ChatSendMessageResponse
3536

3637
__all__ = ["ChatsResource", "AsyncChatsResource"]
@@ -127,7 +128,7 @@ def retrieve(
127128
extra_query: Query | None = None,
128129
extra_body: Body | None = None,
129130
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
130-
) -> Chat:
131+
) -> ChatRetrieveResponse:
131132
"""
132133
获取某个对话
133134
@@ -147,7 +148,7 @@ def retrieve(
147148
options=make_request_options(
148149
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
149150
),
150-
cast_to=Chat,
151+
cast_to=ChatRetrieveResponse,
151152
)
152153

153154
def list(
@@ -366,7 +367,7 @@ async def retrieve(
366367
extra_query: Query | None = None,
367368
extra_body: Body | None = None,
368369
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
369-
) -> Chat:
370+
) -> ChatRetrieveResponse:
370371
"""
371372
获取某个对话
372373
@@ -386,7 +387,7 @@ async def retrieve(
386387
options=make_request_options(
387388
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
388389
),
389-
cast_to=Chat,
390+
cast_to=ChatRetrieveResponse,
390391
)
391392

392393
def list(

src/asktable/resources/integration.py

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,6 @@ def excel_csv_ask(
9494
*,
9595
file_url: str,
9696
question: str,
97-
value_index: bool | NotGiven = NOT_GIVEN,
9897
with_json: Optional[bool] | NotGiven = NOT_GIVEN,
9998
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
10099
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -132,13 +131,7 @@ def excel_csv_ask(
132131
integration_excel_csv_ask_params.IntegrationExcelCsvAskParams,
133132
),
134133
options=make_request_options(
135-
extra_headers=extra_headers,
136-
extra_query=extra_query,
137-
extra_body=extra_body,
138-
timeout=timeout,
139-
query=maybe_transform(
140-
{"value_index": value_index}, integration_excel_csv_ask_params.IntegrationExcelCsvAskParams
141-
),
134+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
142135
),
143136
cast_to=FileAskResponse,
144137
)
@@ -211,7 +204,6 @@ async def excel_csv_ask(
211204
*,
212205
file_url: str,
213206
question: str,
214-
value_index: bool | NotGiven = NOT_GIVEN,
215207
with_json: Optional[bool] | NotGiven = NOT_GIVEN,
216208
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
217209
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -249,13 +241,7 @@ async def excel_csv_ask(
249241
integration_excel_csv_ask_params.IntegrationExcelCsvAskParams,
250242
),
251243
options=make_request_options(
252-
extra_headers=extra_headers,
253-
extra_query=extra_query,
254-
extra_body=extra_body,
255-
timeout=timeout,
256-
query=await async_maybe_transform(
257-
{"value_index": value_index}, integration_excel_csv_ask_params.IntegrationExcelCsvAskParams
258-
),
244+
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
259245
),
260246
cast_to=FileAskResponse,
261247
)

0 commit comments

Comments
 (0)