Skip to content

Commit 865fb4c

Browse files
chore(internal): codegen related update
1 parent f3aa13b commit 865fb4c

66 files changed

Lines changed: 3198 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/gradient/_client.py

Lines changed: 300 additions & 0 deletions
Large diffs are not rendered by default.

src/gradient/resources/agents/agents.py

Lines changed: 170 additions & 0 deletions
Large diffs are not rendered by default.

src/gradient/resources/agents/api_keys.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@
2626

2727

2828
class APIKeysResource(SyncAPIResource):
29+
"""
30+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
31+
"""
32+
2933
@cached_property
3034
def with_raw_response(self) -> APIKeysResourceWithRawResponse:
3135
"""
@@ -282,6 +286,10 @@ def regenerate(
282286

283287

284288
class AsyncAPIKeysResource(AsyncAPIResource):
289+
"""
290+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
291+
"""
292+
285293
@cached_property
286294
def with_raw_response(self) -> AsyncAPIKeysResourceWithRawResponse:
287295
"""

src/gradient/resources/agents/chat/chat.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
class ChatResource(SyncAPIResource):
2020
@cached_property
2121
def completions(self) -> CompletionsResource:
22+
"""
23+
Given a list of messages comprising a conversation, the model will return a response.
24+
"""
2225
return CompletionsResource(self._client)
2326

2427
@cached_property
@@ -44,6 +47,9 @@ def with_streaming_response(self) -> ChatResourceWithStreamingResponse:
4447
class AsyncChatResource(AsyncAPIResource):
4548
@cached_property
4649
def completions(self) -> AsyncCompletionsResource:
50+
"""
51+
Given a list of messages comprising a conversation, the model will return a response.
52+
"""
4753
return AsyncCompletionsResource(self._client)
4854

4955
@cached_property
@@ -72,6 +78,9 @@ def __init__(self, chat: ChatResource) -> None:
7278

7379
@cached_property
7480
def completions(self) -> CompletionsResourceWithRawResponse:
81+
"""
82+
Given a list of messages comprising a conversation, the model will return a response.
83+
"""
7584
return CompletionsResourceWithRawResponse(self._chat.completions)
7685

7786

@@ -81,6 +90,9 @@ def __init__(self, chat: AsyncChatResource) -> None:
8190

8291
@cached_property
8392
def completions(self) -> AsyncCompletionsResourceWithRawResponse:
93+
"""
94+
Given a list of messages comprising a conversation, the model will return a response.
95+
"""
8496
return AsyncCompletionsResourceWithRawResponse(self._chat.completions)
8597

8698

@@ -90,6 +102,9 @@ def __init__(self, chat: ChatResource) -> None:
90102

91103
@cached_property
92104
def completions(self) -> CompletionsResourceWithStreamingResponse:
105+
"""
106+
Given a list of messages comprising a conversation, the model will return a response.
107+
"""
93108
return CompletionsResourceWithStreamingResponse(self._chat.completions)
94109

95110

@@ -99,4 +114,7 @@ def __init__(self, chat: AsyncChatResource) -> None:
99114

100115
@cached_property
101116
def completions(self) -> AsyncCompletionsResourceWithStreamingResponse:
117+
"""
118+
Given a list of messages comprising a conversation, the model will return a response.
119+
"""
102120
return AsyncCompletionsResourceWithStreamingResponse(self._chat.completions)

src/gradient/resources/agents/chat/completions.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@
2727

2828

2929
class CompletionsResource(SyncAPIResource):
30+
"""
31+
Given a list of messages comprising a conversation, the model will return a response.
32+
"""
33+
3034
@cached_property
3135
def with_raw_response(self) -> CompletionsResourceWithRawResponse:
3236
"""
@@ -516,6 +520,10 @@ def create(
516520

517521

518522
class AsyncCompletionsResource(AsyncAPIResource):
523+
"""
524+
Given a list of messages comprising a conversation, the model will return a response.
525+
"""
526+
519527
@cached_property
520528
def with_raw_response(self) -> AsyncCompletionsResourceWithRawResponse:
521529
"""

src/gradient/resources/agents/evaluation_datasets.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@
3232

3333

3434
class EvaluationDatasetsResource(SyncAPIResource):
35+
"""
36+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
37+
"""
38+
3539
@cached_property
3640
def with_raw_response(self) -> EvaluationDatasetsResourceWithRawResponse:
3741
"""
@@ -144,6 +148,10 @@ def create_file_upload_presigned_urls(
144148

145149

146150
class AsyncEvaluationDatasetsResource(AsyncAPIResource):
151+
"""
152+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
153+
"""
154+
147155
@cached_property
148156
def with_raw_response(self) -> AsyncEvaluationDatasetsResourceWithRawResponse:
149157
"""

src/gradient/resources/agents/evaluation_metrics/anthropic/anthropic.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
class AnthropicResource(SyncAPIResource):
2020
@cached_property
2121
def keys(self) -> KeysResource:
22+
"""
23+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
24+
"""
2225
return KeysResource(self._client)
2326

2427
@cached_property
@@ -44,6 +47,9 @@ def with_streaming_response(self) -> AnthropicResourceWithStreamingResponse:
4447
class AsyncAnthropicResource(AsyncAPIResource):
4548
@cached_property
4649
def keys(self) -> AsyncKeysResource:
50+
"""
51+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
52+
"""
4753
return AsyncKeysResource(self._client)
4854

4955
@cached_property
@@ -72,6 +78,9 @@ def __init__(self, anthropic: AnthropicResource) -> None:
7278

7379
@cached_property
7480
def keys(self) -> KeysResourceWithRawResponse:
81+
"""
82+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
83+
"""
7584
return KeysResourceWithRawResponse(self._anthropic.keys)
7685

7786

@@ -81,6 +90,9 @@ def __init__(self, anthropic: AsyncAnthropicResource) -> None:
8190

8291
@cached_property
8392
def keys(self) -> AsyncKeysResourceWithRawResponse:
93+
"""
94+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
95+
"""
8496
return AsyncKeysResourceWithRawResponse(self._anthropic.keys)
8597

8698

@@ -90,6 +102,9 @@ def __init__(self, anthropic: AnthropicResource) -> None:
90102

91103
@cached_property
92104
def keys(self) -> KeysResourceWithStreamingResponse:
105+
"""
106+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
107+
"""
93108
return KeysResourceWithStreamingResponse(self._anthropic.keys)
94109

95110

@@ -99,4 +114,7 @@ def __init__(self, anthropic: AsyncAnthropicResource) -> None:
99114

100115
@cached_property
101116
def keys(self) -> AsyncKeysResourceWithStreamingResponse:
117+
"""
118+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
119+
"""
102120
return AsyncKeysResourceWithStreamingResponse(self._anthropic.keys)

src/gradient/resources/agents/evaluation_metrics/anthropic/keys.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@
3232

3333

3434
class KeysResource(SyncAPIResource):
35+
"""
36+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
37+
"""
38+
3539
@cached_property
3640
def with_raw_response(self) -> KeysResourceWithRawResponse:
3741
"""
@@ -324,6 +328,10 @@ def list_agents(
324328

325329

326330
class AsyncKeysResource(AsyncAPIResource):
331+
"""
332+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
333+
"""
334+
327335
@cached_property
328336
def with_raw_response(self) -> AsyncKeysResourceWithRawResponse:
329337
"""

src/gradient/resources/agents/evaluation_metrics/evaluation_metrics.py

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,15 @@
6363

6464

6565
class EvaluationMetricsResource(SyncAPIResource):
66+
"""
67+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
68+
"""
69+
6670
@cached_property
6771
def workspaces(self) -> WorkspacesResource:
72+
"""
73+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
74+
"""
6875
return WorkspacesResource(self._client)
6976

7077
@cached_property
@@ -77,10 +84,16 @@ def openai(self) -> OpenAIResource:
7784

7885
@cached_property
7986
def oauth2(self) -> Oauth2Resource:
87+
"""
88+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
89+
"""
8090
return Oauth2Resource(self._client)
8191

8292
@cached_property
8393
def scheduled_indexing(self) -> ScheduledIndexingResource:
94+
"""
95+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
96+
"""
8497
return ScheduledIndexingResource(self._client)
8598

8699
@cached_property
@@ -176,8 +189,15 @@ def list_regions(
176189

177190

178191
class AsyncEvaluationMetricsResource(AsyncAPIResource):
192+
"""
193+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
194+
"""
195+
179196
@cached_property
180197
def workspaces(self) -> AsyncWorkspacesResource:
198+
"""
199+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
200+
"""
181201
return AsyncWorkspacesResource(self._client)
182202

183203
@cached_property
@@ -190,10 +210,16 @@ def openai(self) -> AsyncOpenAIResource:
190210

191211
@cached_property
192212
def oauth2(self) -> AsyncOauth2Resource:
213+
"""
214+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
215+
"""
193216
return AsyncOauth2Resource(self._client)
194217

195218
@cached_property
196219
def scheduled_indexing(self) -> AsyncScheduledIndexingResource:
220+
"""
221+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
222+
"""
197223
return AsyncScheduledIndexingResource(self._client)
198224

199225
@cached_property
@@ -301,6 +327,9 @@ def __init__(self, evaluation_metrics: EvaluationMetricsResource) -> None:
301327

302328
@cached_property
303329
def workspaces(self) -> WorkspacesResourceWithRawResponse:
330+
"""
331+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
332+
"""
304333
return WorkspacesResourceWithRawResponse(self._evaluation_metrics.workspaces)
305334

306335
@cached_property
@@ -313,10 +342,16 @@ def openai(self) -> OpenAIResourceWithRawResponse:
313342

314343
@cached_property
315344
def oauth2(self) -> Oauth2ResourceWithRawResponse:
345+
"""
346+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
347+
"""
316348
return Oauth2ResourceWithRawResponse(self._evaluation_metrics.oauth2)
317349

318350
@cached_property
319351
def scheduled_indexing(self) -> ScheduledIndexingResourceWithRawResponse:
352+
"""
353+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
354+
"""
320355
return ScheduledIndexingResourceWithRawResponse(self._evaluation_metrics.scheduled_indexing)
321356

322357

@@ -333,6 +368,9 @@ def __init__(self, evaluation_metrics: AsyncEvaluationMetricsResource) -> None:
333368

334369
@cached_property
335370
def workspaces(self) -> AsyncWorkspacesResourceWithRawResponse:
371+
"""
372+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
373+
"""
336374
return AsyncWorkspacesResourceWithRawResponse(self._evaluation_metrics.workspaces)
337375

338376
@cached_property
@@ -345,10 +383,16 @@ def openai(self) -> AsyncOpenAIResourceWithRawResponse:
345383

346384
@cached_property
347385
def oauth2(self) -> AsyncOauth2ResourceWithRawResponse:
386+
"""
387+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
388+
"""
348389
return AsyncOauth2ResourceWithRawResponse(self._evaluation_metrics.oauth2)
349390

350391
@cached_property
351392
def scheduled_indexing(self) -> AsyncScheduledIndexingResourceWithRawResponse:
393+
"""
394+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
395+
"""
352396
return AsyncScheduledIndexingResourceWithRawResponse(self._evaluation_metrics.scheduled_indexing)
353397

354398

@@ -365,6 +409,9 @@ def __init__(self, evaluation_metrics: EvaluationMetricsResource) -> None:
365409

366410
@cached_property
367411
def workspaces(self) -> WorkspacesResourceWithStreamingResponse:
412+
"""
413+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
414+
"""
368415
return WorkspacesResourceWithStreamingResponse(self._evaluation_metrics.workspaces)
369416

370417
@cached_property
@@ -377,10 +424,16 @@ def openai(self) -> OpenAIResourceWithStreamingResponse:
377424

378425
@cached_property
379426
def oauth2(self) -> Oauth2ResourceWithStreamingResponse:
427+
"""
428+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
429+
"""
380430
return Oauth2ResourceWithStreamingResponse(self._evaluation_metrics.oauth2)
381431

382432
@cached_property
383433
def scheduled_indexing(self) -> ScheduledIndexingResourceWithStreamingResponse:
434+
"""
435+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
436+
"""
384437
return ScheduledIndexingResourceWithStreamingResponse(self._evaluation_metrics.scheduled_indexing)
385438

386439

@@ -397,6 +450,9 @@ def __init__(self, evaluation_metrics: AsyncEvaluationMetricsResource) -> None:
397450

398451
@cached_property
399452
def workspaces(self) -> AsyncWorkspacesResourceWithStreamingResponse:
453+
"""
454+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
455+
"""
400456
return AsyncWorkspacesResourceWithStreamingResponse(self._evaluation_metrics.workspaces)
401457

402458
@cached_property
@@ -409,8 +465,14 @@ def openai(self) -> AsyncOpenAIResourceWithStreamingResponse:
409465

410466
@cached_property
411467
def oauth2(self) -> AsyncOauth2ResourceWithStreamingResponse:
468+
"""
469+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
470+
"""
412471
return AsyncOauth2ResourceWithStreamingResponse(self._evaluation_metrics.oauth2)
413472

414473
@cached_property
415474
def scheduled_indexing(self) -> AsyncScheduledIndexingResourceWithStreamingResponse:
475+
"""
476+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
477+
"""
416478
return AsyncScheduledIndexingResourceWithStreamingResponse(self._evaluation_metrics.scheduled_indexing)

src/gradient/resources/agents/evaluation_metrics/oauth2/dropbox.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,10 @@
2222

2323

2424
class DropboxResource(SyncAPIResource):
25+
"""
26+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
27+
"""
28+
2529
@cached_property
2630
def with_raw_response(self) -> DropboxResourceWithRawResponse:
2731
"""
@@ -90,6 +94,10 @@ def create_tokens(
9094

9195

9296
class AsyncDropboxResource(AsyncAPIResource):
97+
"""
98+
The API lets you build GPU-powered AI agents with pre-built or custom foundation models, function and agent routes, and RAG pipelines with knowledge bases.
99+
"""
100+
93101
@cached_property
94102
def with_raw_response(self) -> AsyncDropboxResourceWithRawResponse:
95103
"""

0 commit comments

Comments
 (0)