File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -342,6 +342,7 @@ def upload_file(
342
342
display_name : Optional [str ] = None ,
343
343
description : Optional [str ] = None ,
344
344
transformation_config : Optional [TransformationConfig ] = None ,
345
+ timeout : int = 600 ,
345
346
) -> RagFile :
346
347
"""
347
348
Synchronous file upload to an existing RagCorpus.
@@ -379,6 +380,7 @@ def upload_file(
379
380
display_name: The display name of the data file.
380
381
description: The description of the RagFile.
381
382
transformation_config: The config for transforming the RagFile, like chunking.
383
+ timeout: Default is 600 seconds.
382
384
383
385
Returns:
384
386
RagFile.
@@ -433,6 +435,7 @@ def upload_file(
433
435
url = upload_request_uri ,
434
436
files = files ,
435
437
headers = headers ,
438
+ timeout = timeout ,
436
439
)
437
440
except Exception as e :
438
441
raise RuntimeError ("Failed in uploading the RagFile due to: " , e ) from e
You can’t perform that action at this time.
0 commit comments