Skip to content

Commit e436f2c

Browse files
authored
Update domain.py
Few more fixes were added based on the left comments
1 parent 3e848df commit e436f2c

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

src/yandex_cloud_ml_sdk/_files/domain.py

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,8 @@
2020

2121
class BaseFiles(BaseDomain, Generic[FileTypeT]):
2222
"""Files domain, which contains API for working with files.
23-
Files is a part of `Assistants API`_, which is the only place you could use it.
23+
Files is a part of :ref:`Assistants API`, which is the only place you could use it.
2424
Provides upload, get and list methods that allow you to work with remote file objects you created earlier.
25-
26-
.. _Assistants API: https://yandex.cloud/ru/docs/foundation-models/assistants/api-ref/Assistant/
2725
"""
2826
_file_impl: type[FileTypeT]
2927

@@ -42,14 +40,14 @@ async def _upload_bytes(
4240
"""Uploads a byte array as a file.
4341
4442
:param data: The byte data to upload.
45-
:param name: The name of the file.
43+
:param name: The name of the file on server.
4644
:param description: A description of the file.
4745
:param mime_type: The MIME type of the file.
4846
By default (i.e. when UNDEFINED) server will try to auto-detect mime-type and you could override this file.
4947
:param labels: Labels associated with the file.
5048
:param ttl_days: Time-to-live in days for the file.
5149
:param expiration_policy: Expiration policy for the file.
52-
Assepts for passing :static or :since_last_active strings. Should be defined if :ttl_days has been defined, otherwise both parameters should be underfined.
50+
Assepts for passing :ref:`static` or :ref:`since_last_active` strings. Should be defined if :ref:`ttl_days` has been defined, otherwise both parameters should be underfined.
5351
:param timeout: Timeout for the operation in seconds.
5452
Defaults to 60 seconds.
5553
"""
@@ -93,14 +91,14 @@ async def _upload(
9391
"""Uploads a file from a specified path.
9492
9593
:param path: The path of the file to upload.
96-
:param name: The name of the file.
94+
:param name: The name of the file on server.
9795
:param description: A description of the file.
9896
:param mime_type: The MIME type of the file.
9997
By default (i.e. when UNDEFINED) server will try to auto-detect mime-type and you could override this file.
10098
:param labels: Labels associated with the file.
10199
:param ttl_days: Time-to-live in days for the file.
102100
:param expiration_policy: Expiration policy for the file.
103-
Assepts for passing :static or :since_last_active strings.
101+
Assepts for passing :ref:`static` or :ref:`since_last_active` strings.
104102
:param timeout: Timeout for the operation in seconds.
105103
Defaults to 60.
106104
"""
@@ -148,7 +146,7 @@ async def _list(
148146
page_size: UndefinedOr[int] = UNDEFINED,
149147
timeout: float = 60
150148
) -> AsyncIterator[FileTypeT]:
151-
"""Lists files in the specified folder.
149+
"""Lists Files in the SDK folder.
152150
153151
:param page_size: The maximum number of files to return per page.
154152
:param timeout: Timeout for the operation in seconds.

0 commit comments

Comments
 (0)