usecortex-ai 0.2.1__py3-none-any.whl → 0.2.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. usecortex_ai/__init__.py +18 -3
  2. usecortex_ai/client.py +7 -78
  3. usecortex_ai/core/client_wrapper.py +6 -8
  4. usecortex_ai/document/__init__.py +4 -0
  5. usecortex_ai/document/client.py +139 -0
  6. usecortex_ai/document/raw_client.py +312 -0
  7. usecortex_ai/embeddings/client.py +40 -70
  8. usecortex_ai/embeddings/raw_client.py +40 -70
  9. usecortex_ai/fetch/client.py +10 -0
  10. usecortex_ai/fetch/raw_client.py +10 -0
  11. usecortex_ai/search/client.py +74 -80
  12. usecortex_ai/search/raw_client.py +74 -80
  13. usecortex_ai/sources/client.py +28 -83
  14. usecortex_ai/sources/raw_client.py +28 -259
  15. usecortex_ai/tenant/client.py +152 -4
  16. usecortex_ai/tenant/raw_client.py +502 -4
  17. usecortex_ai/types/__init__.py +16 -2
  18. usecortex_ai/types/add_user_memory_response.py +36 -0
  19. usecortex_ai/types/app_sources_upload_data.py +10 -2
  20. usecortex_ai/types/attachment_model.py +34 -7
  21. usecortex_ai/types/batch_upload_data.py +10 -2
  22. usecortex_ai/types/body_scrape_webpage_upload_scrape_webpage_post.py +0 -2
  23. usecortex_ai/types/body_update_scrape_job_upload_update_webpage_patch.py +0 -2
  24. usecortex_ai/types/content_model.py +33 -6
  25. usecortex_ai/types/delete_memory_request.py +14 -3
  26. usecortex_ai/types/delete_sources.py +20 -0
  27. usecortex_ai/types/delete_sub_tenant_data.py +42 -0
  28. usecortex_ai/types/delete_user_memory_response.py +31 -0
  29. usecortex_ai/types/embeddings_create_collection_data.py +19 -4
  30. usecortex_ai/types/embeddings_delete_data.py +19 -4
  31. usecortex_ai/types/embeddings_get_data.py +19 -4
  32. usecortex_ai/types/embeddings_search_data.py +19 -4
  33. usecortex_ai/types/error_response.py +0 -1
  34. usecortex_ai/types/fetch_content_data.py +19 -5
  35. usecortex_ai/types/file_upload_result.py +9 -2
  36. usecortex_ai/types/generate_user_memory_response.py +32 -0
  37. usecortex_ai/types/list_sources_response.py +14 -3
  38. usecortex_ai/types/list_user_memories_response.py +32 -0
  39. usecortex_ai/types/markdown_upload_request.py +18 -5
  40. usecortex_ai/types/processing_status.py +14 -3
  41. usecortex_ai/types/relations.py +9 -2
  42. usecortex_ai/types/retrieve_user_memory_response.py +32 -0
  43. usecortex_ai/types/search_chunk.py +54 -17
  44. usecortex_ai/types/single_upload_data.py +10 -2
  45. usecortex_ai/types/source.py +34 -15
  46. usecortex_ai/types/source_model.py +63 -14
  47. usecortex_ai/types/sub_tenant_ids_data.py +24 -5
  48. usecortex_ai/types/tenant_create_data.py +19 -4
  49. usecortex_ai/types/tenant_stats.py +24 -5
  50. usecortex_ai/types/user_memory.py +31 -0
  51. usecortex_ai/upload/client.py +394 -79
  52. usecortex_ai/upload/raw_client.py +398 -103
  53. usecortex_ai/user/client.py +14 -6
  54. usecortex_ai/user/raw_client.py +14 -6
  55. usecortex_ai/user_memory/client.py +184 -50
  56. usecortex_ai/user_memory/raw_client.py +905 -88
  57. {usecortex_ai-0.2.1.dist-info → usecortex_ai-0.2.2.dist-info}/METADATA +1 -1
  58. usecortex_ai-0.2.2.dist-info/RECORD +100 -0
  59. usecortex_ai/raw_client.py +0 -90
  60. usecortex_ai/types/source_content.py +0 -26
  61. usecortex_ai-0.2.1.dist-info/RECORD +0 -91
  62. {usecortex_ai-0.2.1.dist-info → usecortex_ai-0.2.2.dist-info}/WHEEL +0 -0
  63. {usecortex_ai-0.2.1.dist-info → usecortex_ai-0.2.2.dist-info}/licenses/LICENSE +0 -0
  64. {usecortex_ai-0.2.1.dist-info → usecortex_ai-0.2.2.dist-info}/top_level.txt +0 -0
@@ -8,7 +8,6 @@ from ..core.request_options import RequestOptions
8
8
  from ..types.app_sources_upload_data import AppSourcesUploadData
9
9
  from ..types.batch_upload_data import BatchUploadData
10
10
  from ..types.processing_status import ProcessingStatus
11
- from ..types.relations import Relations
12
11
  from ..types.single_upload_data import SingleUploadData
13
12
  from ..types.source_model import SourceModel
14
13
  from .raw_client import AsyncRawUploadClient, RawUploadClient
@@ -40,24 +39,38 @@ class UploadClient:
40
39
  sub_tenant_id: typing.Optional[str] = None,
41
40
  tenant_metadata: typing.Optional[str] = OMIT,
42
41
  document_metadata: typing.Optional[str] = OMIT,
43
- relations: typing.Optional[str] = OMIT,
44
42
  request_options: typing.Optional[RequestOptions] = None,
45
43
  ) -> BatchUploadData:
46
44
  """
45
+ Upload multiple documents simultaneously for efficient bulk processing.
46
+
47
+ This endpoint allows you to upload several files at once, which is ideal for large document collections or periodic data imports. Each file gets processed asynchronously, and you can track the progress of individual files using their returned file IDs.
48
+
49
+ The system automatically handles file parsing, content extraction, and indexing across all uploaded documents. You'll receive confirmation once all files are queued for processing.
50
+
47
51
  Parameters
48
52
  ----------
49
53
  tenant_id : str
54
+ Unique identifier for the tenant/organization
50
55
 
51
56
  files : typing.List[core.File]
52
57
  See core.File for more documentation
53
58
 
54
59
  sub_tenant_id : typing.Optional[str]
60
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
55
61
 
56
62
  tenant_metadata : typing.Optional[str]
63
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
64
+
65
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
66
+
57
67
 
58
68
  document_metadata : typing.Optional[str]
69
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
70
+
71
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
72
+
59
73
 
60
- relations : typing.Optional[str]
61
74
 
62
75
  request_options : typing.Optional[RequestOptions]
63
76
  Request-specific configuration.
@@ -80,7 +93,6 @@ class UploadClient:
80
93
  sub_tenant_id=sub_tenant_id,
81
94
  tenant_metadata=tenant_metadata,
82
95
  document_metadata=document_metadata,
83
- relations=relations,
84
96
  request_options=request_options,
85
97
  )
86
98
  return _response.data
@@ -94,26 +106,41 @@ class UploadClient:
94
106
  source_ids: typing.Optional[typing.List[str]] = OMIT,
95
107
  tenant_metadata: typing.Optional[str] = OMIT,
96
108
  document_metadata: typing.Optional[str] = OMIT,
97
- relations: typing.Optional[str] = OMIT,
98
109
  request_options: typing.Optional[RequestOptions] = None,
99
110
  ) -> BatchUploadData:
100
111
  """
112
+ Update multiple existing documents with new content and metadata.
113
+
114
+ Use this endpoint when you need to replace or modify several documents that are already in your knowledge base. Each file must correspond to an existing source ID, ensuring that updates are applied to the correct documents.
115
+
116
+ The system processes updates asynchronously, allowing you to continue working while your documents are re-indexed. Track the progress using the returned file IDs to know when updates are complete.
117
+
101
118
  Parameters
102
119
  ----------
103
120
  tenant_id : str
121
+ Unique identifier for the tenant/organization
104
122
 
105
123
  files : typing.List[core.File]
106
124
  See core.File for more documentation
107
125
 
108
126
  sub_tenant_id : typing.Optional[str]
127
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
109
128
 
110
129
  source_ids : typing.Optional[typing.List[str]]
130
+ List of source IDs corresponding to the files being updated
111
131
 
112
132
  tenant_metadata : typing.Optional[str]
133
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
134
+
135
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
136
+
113
137
 
114
138
  document_metadata : typing.Optional[str]
139
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
140
+
141
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
142
+
115
143
 
116
- relations : typing.Optional[str]
117
144
 
118
145
  request_options : typing.Optional[RequestOptions]
119
146
  Request-specific configuration.
@@ -137,7 +164,6 @@ class UploadClient:
137
164
  source_ids=source_ids,
138
165
  tenant_metadata=tenant_metadata,
139
166
  document_metadata=document_metadata,
140
- relations=relations,
141
167
  request_options=request_options,
142
168
  )
143
169
  return _response.data
@@ -150,24 +176,38 @@ class UploadClient:
150
176
  sub_tenant_id: typing.Optional[str] = None,
151
177
  tenant_metadata: typing.Optional[str] = OMIT,
152
178
  document_metadata: typing.Optional[str] = OMIT,
153
- relations: typing.Optional[str] = OMIT,
154
179
  request_options: typing.Optional[RequestOptions] = None,
155
180
  ) -> SingleUploadData:
156
181
  """
182
+ Upload a single document for processing and indexing into your knowledge base.
183
+
184
+ This endpoint accepts documents in various formats and processes them for search and retrieval. You can include custom metadata to help organize and categorize your content.
185
+
186
+ The system extracts text content, processes it asynchronously, and makes it available for search queries. You can track the processing status using the returned file ID.
187
+
157
188
  Parameters
158
189
  ----------
159
190
  tenant_id : str
191
+ Unique identifier for the tenant/organization
160
192
 
161
193
  file : core.File
162
194
  See core.File for more documentation
163
195
 
164
196
  sub_tenant_id : typing.Optional[str]
197
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
165
198
 
166
199
  tenant_metadata : typing.Optional[str]
200
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
201
+
202
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
203
+
167
204
 
168
205
  document_metadata : typing.Optional[str]
206
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
207
+
208
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
209
+
169
210
 
170
- relations : typing.Optional[str]
171
211
 
172
212
  request_options : typing.Optional[RequestOptions]
173
213
  Request-specific configuration.
@@ -190,7 +230,6 @@ class UploadClient:
190
230
  sub_tenant_id=sub_tenant_id,
191
231
  tenant_metadata=tenant_metadata,
192
232
  document_metadata=document_metadata,
193
- relations=relations,
194
233
  request_options=request_options,
195
234
  )
196
235
  return _response.data
@@ -204,26 +243,41 @@ class UploadClient:
204
243
  sub_tenant_id: typing.Optional[str] = None,
205
244
  tenant_metadata: typing.Optional[str] = OMIT,
206
245
  document_metadata: typing.Optional[str] = OMIT,
207
- relations: typing.Optional[str] = OMIT,
208
246
  request_options: typing.Optional[RequestOptions] = None,
209
247
  ) -> SingleUploadData:
210
248
  """
249
+ Replace an existing document with updated content.
250
+
251
+ This endpoint allows you to update a specific document that's already in your knowledge base. Provide the source ID of the document you want to modify, along with the new file content.
252
+
253
+ The system will process your update asynchronously and re-index the document with the new content. You can monitor the progress using the returned file ID.
254
+
211
255
  Parameters
212
256
  ----------
213
257
  source_id : str
258
+ The source ID of the document to update
214
259
 
215
260
  tenant_id : str
261
+ Unique identifier for the tenant/organization
216
262
 
217
263
  file : core.File
218
264
  See core.File for more documentation
219
265
 
220
266
  sub_tenant_id : typing.Optional[str]
267
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
221
268
 
222
269
  tenant_metadata : typing.Optional[str]
270
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
271
+
272
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
273
+
223
274
 
224
275
  document_metadata : typing.Optional[str]
276
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
277
+
278
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
279
+
225
280
 
226
- relations : typing.Optional[str]
227
281
 
228
282
  request_options : typing.Optional[RequestOptions]
229
283
  Request-specific configuration.
@@ -247,7 +301,6 @@ class UploadClient:
247
301
  sub_tenant_id=sub_tenant_id,
248
302
  tenant_metadata=tenant_metadata,
249
303
  document_metadata=document_metadata,
250
- relations=relations,
251
304
  request_options=request_options,
252
305
  )
253
306
  return _response.data
@@ -261,13 +314,21 @@ class UploadClient:
261
314
  request_options: typing.Optional[RequestOptions] = None,
262
315
  ) -> AppSourcesUploadData:
263
316
  """
317
+ Upload structured data from applications or APIs for indexing.
318
+
319
+ This endpoint is designed for importing data from applications. If you are specifically using Cortex to provide search to an application, you should prefer this endpoint. It accepts structured source objects and allows you to clearly define contents of attachments
320
+
321
+ The system processes each source asynchronously and makes the content available for search and retrieval. Use this when you need to integrate search and indexing from data in your applications into your knowledge base.
322
+
264
323
  Parameters
265
324
  ----------
266
325
  tenant_id : str
326
+ Unique identifier for the tenant/organization
267
327
 
268
328
  request : typing.Sequence[SourceModel]
269
329
 
270
330
  sub_tenant_id : typing.Optional[str]
331
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
271
332
 
272
333
  request_options : typing.Optional[RequestOptions]
273
334
  Request-specific configuration.
@@ -297,26 +358,36 @@ class UploadClient:
297
358
  sub_tenant_id: typing.Optional[str] = None,
298
359
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
299
360
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
300
- relations: typing.Optional[Relations] = OMIT,
301
361
  request_options: typing.Optional[RequestOptions] = None,
302
362
  ) -> SingleUploadData:
303
363
  """
304
- Upload markdown content. If request.document_metadata contains a 'file_id' key (non-empty), it will be used as the file ID;
305
- otherwise, a new file_id will be generated for that file. This allows file-specific IDs to be set directly in the metadata.
364
+ Upload text or markdown content directly for processing.
365
+
366
+ This endpoint accepts plain text or markdown-formatted content that you want to add to your knowledge base. It's perfect for notes, documentation, articles, or any text-based content you want to make searchable.
367
+
368
+ You can include custom metadata to help organize and categorize your content. You can track the processing status using the returned file ID.
306
369
 
307
370
  Parameters
308
371
  ----------
309
372
  tenant_id : str
373
+ Unique identifier for the tenant/organization
310
374
 
311
375
  content : str
376
+ The text or markdown content to upload
312
377
 
313
378
  sub_tenant_id : typing.Optional[str]
379
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
314
380
 
315
381
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
382
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
383
+
384
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
316
385
 
317
386
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
387
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
388
+
389
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
318
390
 
319
- relations : typing.Optional[Relations]
320
391
 
321
392
  request_options : typing.Optional[RequestOptions]
322
393
  Request-specific configuration.
@@ -339,7 +410,6 @@ class UploadClient:
339
410
  sub_tenant_id=sub_tenant_id,
340
411
  tenant_metadata=tenant_metadata,
341
412
  document_metadata=document_metadata,
342
- relations=relations,
343
413
  request_options=request_options,
344
414
  )
345
415
  return _response.data
@@ -352,26 +422,36 @@ class UploadClient:
352
422
  sub_tenant_id: typing.Optional[str] = None,
353
423
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
354
424
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
355
- relations: typing.Optional[Relations] = OMIT,
356
425
  request_options: typing.Optional[RequestOptions] = None,
357
426
  ) -> SingleUploadData:
358
427
  """
359
- Upload markdown content. If request.document_metadata contains a 'file_id' key (non-empty), it will be used as the file ID;
360
- otherwise, a new file_id will be generated for that file. This allows file-specific IDs to be set directly in the metadata.
428
+ Upload text or markdown content directly for processing.
429
+
430
+ This endpoint accepts plain text or markdown-formatted content that you want to add to your knowledge base. It's perfect for notes, documentation, articles, or any text-based content you want to make searchable.
431
+
432
+ You can include custom metadata to help organize and categorize your content. You can track the processing status using the returned file ID.
361
433
 
362
434
  Parameters
363
435
  ----------
364
436
  tenant_id : str
437
+ Unique identifier for the tenant/organization
365
438
 
366
439
  content : str
440
+ The text or markdown content to upload
367
441
 
368
442
  sub_tenant_id : typing.Optional[str]
443
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
369
444
 
370
445
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
446
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
447
+
448
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
371
449
 
372
450
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
451
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
452
+
453
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
373
454
 
374
- relations : typing.Optional[Relations]
375
455
 
376
456
  request_options : typing.Optional[RequestOptions]
377
457
  Request-specific configuration.
@@ -394,7 +474,6 @@ class UploadClient:
394
474
  sub_tenant_id=sub_tenant_id,
395
475
  tenant_metadata=tenant_metadata,
396
476
  document_metadata=document_metadata,
397
- relations=relations,
398
477
  request_options=request_options,
399
478
  )
400
479
  return _response.data
@@ -408,25 +487,39 @@ class UploadClient:
408
487
  sub_tenant_id: typing.Optional[str] = None,
409
488
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
410
489
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
411
- relations: typing.Optional[Relations] = OMIT,
412
490
  request_options: typing.Optional[RequestOptions] = None,
413
491
  ) -> SingleUploadData:
414
492
  """
493
+ Update existing text or markdown content with new information.
494
+
495
+ This endpoint allows you to modify text or markdown content that's already in your knowledge base. Provide the source ID of the content you want to update, along with the new text.
496
+
497
+ The system will reprocess and re-index the updated content asynchronously. Use this when you need to correct information, add details, or refresh existing documentation.
498
+
415
499
  Parameters
416
500
  ----------
417
501
  source_id : str
502
+ The source ID of the document to update
418
503
 
419
504
  tenant_id : str
505
+ Unique identifier for the tenant/organization
420
506
 
421
507
  content : str
508
+ The text or markdown content to upload
422
509
 
423
510
  sub_tenant_id : typing.Optional[str]
511
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
424
512
 
425
513
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
514
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
515
+
516
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
426
517
 
427
518
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
519
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
520
+
521
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
428
522
 
429
- relations : typing.Optional[Relations]
430
523
 
431
524
  request_options : typing.Optional[RequestOptions]
432
525
  Request-specific configuration.
@@ -450,7 +543,6 @@ class UploadClient:
450
543
  sub_tenant_id=sub_tenant_id,
451
544
  tenant_metadata=tenant_metadata,
452
545
  document_metadata=document_metadata,
453
- relations=relations,
454
546
  request_options=request_options,
455
547
  )
456
548
  return _response.data
@@ -464,25 +556,39 @@ class UploadClient:
464
556
  sub_tenant_id: typing.Optional[str] = None,
465
557
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
466
558
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
467
- relations: typing.Optional[Relations] = OMIT,
468
559
  request_options: typing.Optional[RequestOptions] = None,
469
560
  ) -> SingleUploadData:
470
561
  """
562
+ Update existing text or markdown content with new information.
563
+
564
+ This endpoint allows you to modify text or markdown content that's already in your knowledge base. Provide the source ID of the content you want to update, along with the new text.
565
+
566
+ The system will reprocess and re-index the updated content asynchronously. Use this when you need to correct information, add details, or refresh existing documentation.
567
+
471
568
  Parameters
472
569
  ----------
473
570
  source_id : str
571
+ The source ID of the document to update
474
572
 
475
573
  tenant_id : str
574
+ Unique identifier for the tenant/organization
476
575
 
477
576
  content : str
577
+ The text or markdown content to upload
478
578
 
479
579
  sub_tenant_id : typing.Optional[str]
580
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
480
581
 
481
582
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
583
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
584
+
585
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
482
586
 
483
587
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
588
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
589
+
590
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
484
591
 
485
- relations : typing.Optional[Relations]
486
592
 
487
593
  request_options : typing.Optional[RequestOptions]
488
594
  Request-specific configuration.
@@ -506,7 +612,6 @@ class UploadClient:
506
612
  sub_tenant_id=sub_tenant_id,
507
613
  tenant_metadata=tenant_metadata,
508
614
  document_metadata=document_metadata,
509
- relations=relations,
510
615
  request_options=request_options,
511
616
  )
512
617
  return _response.data
@@ -521,15 +626,25 @@ class UploadClient:
521
626
  request_options: typing.Optional[RequestOptions] = None,
522
627
  ) -> SingleUploadData:
523
628
  """
629
+ Upload pre-computed embeddings for advanced similarity search.
630
+
631
+ This endpoint accepts vector embeddings that you've generated externally, allowing you to integrate with custom embedding models or existing vector databases. The embeddings represent chunks of your content as numerical vectors.
632
+
633
+ The system stores these embeddings and makes them available for semantic search and similarity matching. Use this when you want to leverage specialized embedding models or have existing vector representations.
634
+
524
635
  Parameters
525
636
  ----------
526
637
  tenant_id : str
638
+ Unique identifier for the tenant/organization
527
639
 
528
640
  embeddings : typing.Sequence[typing.Sequence[float]]
641
+ The embeddings of source you want to index
529
642
 
530
643
  sub_tenant_id : typing.Optional[str]
644
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
531
645
 
532
646
  file_id : typing.Optional[str]
647
+ The Source ID of the target source you want to index
533
648
 
534
649
  request_options : typing.Optional[RequestOptions]
535
650
  Request-specific configuration.
@@ -564,13 +679,22 @@ class UploadClient:
564
679
  request_options: typing.Optional[RequestOptions] = None,
565
680
  ) -> SingleUploadData:
566
681
  """
682
+ Update existing embeddings with new vector representations.
683
+
684
+ This endpoint allows you to modify embeddings that are already stored in your knowledge base. Provide updated vector representations for specific chunks of content, identified by their chunk IDs.
685
+
686
+ The system will replace the existing embeddings with your new ones, ensuring that similarity searches reflect the most current vector representations. Use this when you need to update embeddings due to model improvements or content changes.
687
+
567
688
  Parameters
568
689
  ----------
569
690
  tenant_id : str
691
+ Unique identifier for the tenant/organization
570
692
 
571
693
  sub_tenant_id : typing.Optional[str]
694
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
572
695
 
573
696
  embeddings : typing.Optional[typing.Dict[str, typing.Sequence[float]]]
697
+ The embeddings of source you want to index
574
698
 
575
699
  request_options : typing.Optional[RequestOptions]
576
700
  Request-specific configuration.
@@ -599,21 +723,28 @@ class UploadClient:
599
723
  tenant_id: str,
600
724
  sub_tenant_id: typing.Optional[str] = None,
601
725
  file_id: typing.Optional[str] = None,
602
- relations: typing.Optional[str] = OMIT,
603
726
  request_options: typing.Optional[RequestOptions] = None,
604
727
  ) -> SingleUploadData:
605
728
  """
729
+ Extract and index content from web pages automatically.
730
+
731
+ This endpoint initiates web scraping for the specified URL, extracting the main content, text, and structure from the webpage. It's perfect for capturing articles, documentation, or any web content you want to include in your knowledge base.
732
+
733
+ The system processes the webpage content asynchronously, cleaning and structuring the information for optimal search and retrieval. Use this when you need to add web content without manual copying and pasting.
734
+
606
735
  Parameters
607
736
  ----------
608
737
  web_url : str
738
+ The URL of the webpage to scrape and index
609
739
 
610
740
  tenant_id : str
741
+ Unique identifier for the tenant/organization
611
742
 
612
743
  sub_tenant_id : typing.Optional[str]
744
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
613
745
 
614
746
  file_id : typing.Optional[str]
615
-
616
- relations : typing.Optional[str]
747
+ Optional custom file ID for the scraped content. If not provided, a unique ID will be generated
617
748
 
618
749
  request_options : typing.Optional[RequestOptions]
619
750
  Request-specific configuration.
@@ -635,7 +766,6 @@ class UploadClient:
635
766
  tenant_id=tenant_id,
636
767
  sub_tenant_id=sub_tenant_id,
637
768
  file_id=file_id,
638
- relations=relations,
639
769
  request_options=request_options,
640
770
  )
641
771
  return _response.data
@@ -647,21 +777,28 @@ class UploadClient:
647
777
  source_id: str,
648
778
  tenant_id: str,
649
779
  sub_tenant_id: typing.Optional[str] = None,
650
- relations: typing.Optional[str] = OMIT,
651
780
  request_options: typing.Optional[RequestOptions] = None,
652
781
  ) -> SingleUploadData:
653
782
  """
783
+ Update web scraping content with fresh data from the source URL.
784
+
785
+ This endpoint refreshes the content for an existing web scraping job. Provide the source ID of the webpage content you want to update, and the system will re-scrape the URL to capture any changes.
786
+
787
+ The updated content gets processed asynchronously and re-indexed in your knowledge base. Use this to keep web content current when the source pages are frequently updated.
788
+
654
789
  Parameters
655
790
  ----------
656
791
  web_url : str
792
+ The URL of the webpage to re-scrape
657
793
 
658
794
  source_id : str
795
+ The file ID of the existing web scraping job to update
659
796
 
660
797
  tenant_id : str
798
+ Unique identifier for the tenant/organization
661
799
 
662
800
  sub_tenant_id : typing.Optional[str]
663
-
664
- relations : typing.Optional[str]
801
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
665
802
 
666
803
  request_options : typing.Optional[RequestOptions]
667
804
  Request-specific configuration.
@@ -683,7 +820,6 @@ class UploadClient:
683
820
  source_id=source_id,
684
821
  tenant_id=tenant_id,
685
822
  sub_tenant_id=sub_tenant_id,
686
- relations=relations,
687
823
  request_options=request_options,
688
824
  )
689
825
  return _response.data
@@ -697,13 +833,22 @@ class UploadClient:
697
833
  request_options: typing.Optional[RequestOptions] = None,
698
834
  ) -> typing.Optional[typing.Any]:
699
835
  """
836
+ Remove documents and content from your knowledge base.
837
+
838
+ This endpoint permanently deletes the specified sources from your knowledge base. Once deleted, the content will no longer be available for search or retrieval.
839
+
840
+ Use this carefully as the action cannot be undone. The system will confirm successful deletion of each source ID you specify.
841
+
700
842
  Parameters
701
843
  ----------
702
844
  tenant_id : str
845
+ Unique identifier for the tenant/organization
703
846
 
704
847
  source_ids : typing.Sequence[str]
848
+ List of source IDs to delete
705
849
 
706
850
  sub_tenant_id : typing.Optional[str]
851
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
707
852
 
708
853
  request_options : typing.Optional[RequestOptions]
709
854
  Request-specific configuration.
@@ -734,13 +879,22 @@ class UploadClient:
734
879
  request_options: typing.Optional[RequestOptions] = None,
735
880
  ) -> typing.Optional[typing.Any]:
736
881
  """
882
+ Remove documents and content from your knowledge base.
883
+
884
+ This endpoint permanently deletes the specified sources from your knowledge base. Once deleted, the content will no longer be available for search or retrieval.
885
+
886
+ Use this carefully as the action cannot be undone. The system will confirm successful deletion of each source ID you specify.
887
+
737
888
  Parameters
738
889
  ----------
739
890
  tenant_id : str
891
+ Unique identifier for the tenant/organization
740
892
 
741
893
  source_ids : typing.Sequence[str]
894
+ List of source IDs to delete
742
895
 
743
896
  sub_tenant_id : typing.Optional[str]
897
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
744
898
 
745
899
  request_options : typing.Optional[RequestOptions]
746
900
  Request-specific configuration.
@@ -770,16 +924,19 @@ class UploadClient:
770
924
  request_options: typing.Optional[RequestOptions] = None,
771
925
  ) -> ProcessingStatus:
772
926
  """
773
- Verify the processing status of an uploaded file.
927
+ Check the current processing status of your uploaded content.
928
+
929
+ This endpoint allows you to monitor the progress of documents, text, or other content you've uploaded. Simply provide the file ID to see whether processing is complete, still in progress, or if any errors occurred.
774
930
 
775
- Returns:
776
- ProcessingStatusResponse: Processing status information
931
+ Use this to determine when your content is ready for search and retrieval, or to troubleshoot any processing issues.
777
932
 
778
933
  Parameters
779
934
  ----------
780
935
  file_id : str
936
+ The file ID to check processing status for
781
937
 
782
938
  tenant_id : typing.Optional[str]
939
+ Unique identifier for the tenant/organization
783
940
 
784
941
  request_options : typing.Optional[RequestOptions]
785
942
  Request-specific configuration.
@@ -825,24 +982,38 @@ class AsyncUploadClient:
825
982
  sub_tenant_id: typing.Optional[str] = None,
826
983
  tenant_metadata: typing.Optional[str] = OMIT,
827
984
  document_metadata: typing.Optional[str] = OMIT,
828
- relations: typing.Optional[str] = OMIT,
829
985
  request_options: typing.Optional[RequestOptions] = None,
830
986
  ) -> BatchUploadData:
831
987
  """
988
+ Upload multiple documents simultaneously for efficient bulk processing.
989
+
990
+ This endpoint allows you to upload several files at once, which is ideal for large document collections or periodic data imports. Each file gets processed asynchronously, and you can track the progress of individual files using their returned file IDs.
991
+
992
+ The system automatically handles file parsing, content extraction, and indexing across all uploaded documents. You'll receive confirmation once all files are queued for processing.
993
+
832
994
  Parameters
833
995
  ----------
834
996
  tenant_id : str
997
+ Unique identifier for the tenant/organization
835
998
 
836
999
  files : typing.List[core.File]
837
1000
  See core.File for more documentation
838
1001
 
839
1002
  sub_tenant_id : typing.Optional[str]
1003
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
840
1004
 
841
1005
  tenant_metadata : typing.Optional[str]
1006
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1007
+
1008
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1009
+
842
1010
 
843
1011
  document_metadata : typing.Optional[str]
1012
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1013
+
1014
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1015
+
844
1016
 
845
- relations : typing.Optional[str]
846
1017
 
847
1018
  request_options : typing.Optional[RequestOptions]
848
1019
  Request-specific configuration.
@@ -869,7 +1040,6 @@ class AsyncUploadClient:
869
1040
  sub_tenant_id=sub_tenant_id,
870
1041
  tenant_metadata=tenant_metadata,
871
1042
  document_metadata=document_metadata,
872
- relations=relations,
873
1043
  request_options=request_options,
874
1044
  )
875
1045
  return _response.data
@@ -883,26 +1053,41 @@ class AsyncUploadClient:
883
1053
  source_ids: typing.Optional[typing.List[str]] = OMIT,
884
1054
  tenant_metadata: typing.Optional[str] = OMIT,
885
1055
  document_metadata: typing.Optional[str] = OMIT,
886
- relations: typing.Optional[str] = OMIT,
887
1056
  request_options: typing.Optional[RequestOptions] = None,
888
1057
  ) -> BatchUploadData:
889
1058
  """
1059
+ Update multiple existing documents with new content and metadata.
1060
+
1061
+ Use this endpoint when you need to replace or modify several documents that are already in your knowledge base. Each file must correspond to an existing source ID, ensuring that updates are applied to the correct documents.
1062
+
1063
+ The system processes updates asynchronously, allowing you to continue working while your documents are re-indexed. Track the progress using the returned file IDs to know when updates are complete.
1064
+
890
1065
  Parameters
891
1066
  ----------
892
1067
  tenant_id : str
1068
+ Unique identifier for the tenant/organization
893
1069
 
894
1070
  files : typing.List[core.File]
895
1071
  See core.File for more documentation
896
1072
 
897
1073
  sub_tenant_id : typing.Optional[str]
1074
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
898
1075
 
899
1076
  source_ids : typing.Optional[typing.List[str]]
1077
+ List of source IDs corresponding to the files being updated
900
1078
 
901
1079
  tenant_metadata : typing.Optional[str]
1080
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1081
+
1082
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1083
+
902
1084
 
903
1085
  document_metadata : typing.Optional[str]
1086
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1087
+
1088
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1089
+
904
1090
 
905
- relations : typing.Optional[str]
906
1091
 
907
1092
  request_options : typing.Optional[RequestOptions]
908
1093
  Request-specific configuration.
@@ -930,7 +1115,6 @@ class AsyncUploadClient:
930
1115
  source_ids=source_ids,
931
1116
  tenant_metadata=tenant_metadata,
932
1117
  document_metadata=document_metadata,
933
- relations=relations,
934
1118
  request_options=request_options,
935
1119
  )
936
1120
  return _response.data
@@ -943,24 +1127,38 @@ class AsyncUploadClient:
943
1127
  sub_tenant_id: typing.Optional[str] = None,
944
1128
  tenant_metadata: typing.Optional[str] = OMIT,
945
1129
  document_metadata: typing.Optional[str] = OMIT,
946
- relations: typing.Optional[str] = OMIT,
947
1130
  request_options: typing.Optional[RequestOptions] = None,
948
1131
  ) -> SingleUploadData:
949
1132
  """
1133
+ Upload a single document for processing and indexing into your knowledge base.
1134
+
1135
+ This endpoint accepts documents in various formats and processes them for search and retrieval. You can include custom metadata to help organize and categorize your content.
1136
+
1137
+ The system extracts text content, processes it asynchronously, and makes it available for search queries. You can track the processing status using the returned file ID.
1138
+
950
1139
  Parameters
951
1140
  ----------
952
1141
  tenant_id : str
1142
+ Unique identifier for the tenant/organization
953
1143
 
954
1144
  file : core.File
955
1145
  See core.File for more documentation
956
1146
 
957
1147
  sub_tenant_id : typing.Optional[str]
1148
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
958
1149
 
959
1150
  tenant_metadata : typing.Optional[str]
1151
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1152
+
1153
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1154
+
960
1155
 
961
1156
  document_metadata : typing.Optional[str]
1157
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1158
+
1159
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1160
+
962
1161
 
963
- relations : typing.Optional[str]
964
1162
 
965
1163
  request_options : typing.Optional[RequestOptions]
966
1164
  Request-specific configuration.
@@ -987,7 +1185,6 @@ class AsyncUploadClient:
987
1185
  sub_tenant_id=sub_tenant_id,
988
1186
  tenant_metadata=tenant_metadata,
989
1187
  document_metadata=document_metadata,
990
- relations=relations,
991
1188
  request_options=request_options,
992
1189
  )
993
1190
  return _response.data
@@ -1001,26 +1198,41 @@ class AsyncUploadClient:
1001
1198
  sub_tenant_id: typing.Optional[str] = None,
1002
1199
  tenant_metadata: typing.Optional[str] = OMIT,
1003
1200
  document_metadata: typing.Optional[str] = OMIT,
1004
- relations: typing.Optional[str] = OMIT,
1005
1201
  request_options: typing.Optional[RequestOptions] = None,
1006
1202
  ) -> SingleUploadData:
1007
1203
  """
1204
+ Replace an existing document with updated content.
1205
+
1206
+ This endpoint allows you to update a specific document that's already in your knowledge base. Provide the source ID of the document you want to modify, along with the new file content.
1207
+
1208
+ The system will process your update asynchronously and re-index the document with the new content. You can monitor the progress using the returned file ID.
1209
+
1008
1210
  Parameters
1009
1211
  ----------
1010
1212
  source_id : str
1213
+ The source ID of the document to update
1011
1214
 
1012
1215
  tenant_id : str
1216
+ Unique identifier for the tenant/organization
1013
1217
 
1014
1218
  file : core.File
1015
1219
  See core.File for more documentation
1016
1220
 
1017
1221
  sub_tenant_id : typing.Optional[str]
1222
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1018
1223
 
1019
1224
  tenant_metadata : typing.Optional[str]
1225
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1226
+
1227
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1228
+
1020
1229
 
1021
1230
  document_metadata : typing.Optional[str]
1231
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1232
+
1233
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1234
+
1022
1235
 
1023
- relations : typing.Optional[str]
1024
1236
 
1025
1237
  request_options : typing.Optional[RequestOptions]
1026
1238
  Request-specific configuration.
@@ -1048,7 +1260,6 @@ class AsyncUploadClient:
1048
1260
  sub_tenant_id=sub_tenant_id,
1049
1261
  tenant_metadata=tenant_metadata,
1050
1262
  document_metadata=document_metadata,
1051
- relations=relations,
1052
1263
  request_options=request_options,
1053
1264
  )
1054
1265
  return _response.data
@@ -1062,13 +1273,21 @@ class AsyncUploadClient:
1062
1273
  request_options: typing.Optional[RequestOptions] = None,
1063
1274
  ) -> AppSourcesUploadData:
1064
1275
  """
1276
+ Upload structured data from applications or APIs for indexing.
1277
+
1278
+ This endpoint is designed for importing data from applications. If you are specifically using Cortex to provide search to an application, you should prefer this endpoint. It accepts structured source objects and allows you to clearly define contents of attachments
1279
+
1280
+ The system processes each source asynchronously and makes the content available for search and retrieval. Use this when you need to integrate search and indexing from data in your applications into your knowledge base.
1281
+
1065
1282
  Parameters
1066
1283
  ----------
1067
1284
  tenant_id : str
1285
+ Unique identifier for the tenant/organization
1068
1286
 
1069
1287
  request : typing.Sequence[SourceModel]
1070
1288
 
1071
1289
  sub_tenant_id : typing.Optional[str]
1290
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1072
1291
 
1073
1292
  request_options : typing.Optional[RequestOptions]
1074
1293
  Request-specific configuration.
@@ -1102,26 +1321,36 @@ class AsyncUploadClient:
1102
1321
  sub_tenant_id: typing.Optional[str] = None,
1103
1322
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1104
1323
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1105
- relations: typing.Optional[Relations] = OMIT,
1106
1324
  request_options: typing.Optional[RequestOptions] = None,
1107
1325
  ) -> SingleUploadData:
1108
1326
  """
1109
- Upload markdown content. If request.document_metadata contains a 'file_id' key (non-empty), it will be used as the file ID;
1110
- otherwise, a new file_id will be generated for that file. This allows file-specific IDs to be set directly in the metadata.
1327
+ Upload text or markdown content directly for processing.
1328
+
1329
+ This endpoint accepts plain text or markdown-formatted content that you want to add to your knowledge base. It's perfect for notes, documentation, articles, or any text-based content you want to make searchable.
1330
+
1331
+ You can include custom metadata to help organize and categorize your content. You can track the processing status using the returned file ID.
1111
1332
 
1112
1333
  Parameters
1113
1334
  ----------
1114
1335
  tenant_id : str
1336
+ Unique identifier for the tenant/organization
1115
1337
 
1116
1338
  content : str
1339
+ The text or markdown content to upload
1117
1340
 
1118
1341
  sub_tenant_id : typing.Optional[str]
1342
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1119
1343
 
1120
1344
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1345
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1346
+
1347
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1121
1348
 
1122
1349
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1350
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1351
+
1352
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1123
1353
 
1124
- relations : typing.Optional[Relations]
1125
1354
 
1126
1355
  request_options : typing.Optional[RequestOptions]
1127
1356
  Request-specific configuration.
@@ -1148,7 +1377,6 @@ class AsyncUploadClient:
1148
1377
  sub_tenant_id=sub_tenant_id,
1149
1378
  tenant_metadata=tenant_metadata,
1150
1379
  document_metadata=document_metadata,
1151
- relations=relations,
1152
1380
  request_options=request_options,
1153
1381
  )
1154
1382
  return _response.data
@@ -1161,26 +1389,36 @@ class AsyncUploadClient:
1161
1389
  sub_tenant_id: typing.Optional[str] = None,
1162
1390
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1163
1391
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1164
- relations: typing.Optional[Relations] = OMIT,
1165
1392
  request_options: typing.Optional[RequestOptions] = None,
1166
1393
  ) -> SingleUploadData:
1167
1394
  """
1168
- Upload markdown content. If request.document_metadata contains a 'file_id' key (non-empty), it will be used as the file ID;
1169
- otherwise, a new file_id will be generated for that file. This allows file-specific IDs to be set directly in the metadata.
1395
+ Upload text or markdown content directly for processing.
1396
+
1397
+ This endpoint accepts plain text or markdown-formatted content that you want to add to your knowledge base. It's perfect for notes, documentation, articles, or any text-based content you want to make searchable.
1398
+
1399
+ You can include custom metadata to help organize and categorize your content. You can track the processing status using the returned file ID.
1170
1400
 
1171
1401
  Parameters
1172
1402
  ----------
1173
1403
  tenant_id : str
1404
+ Unique identifier for the tenant/organization
1174
1405
 
1175
1406
  content : str
1407
+ The text or markdown content to upload
1176
1408
 
1177
1409
  sub_tenant_id : typing.Optional[str]
1410
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1178
1411
 
1179
1412
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1413
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1414
+
1415
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1180
1416
 
1181
1417
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1418
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1419
+
1420
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1182
1421
 
1183
- relations : typing.Optional[Relations]
1184
1422
 
1185
1423
  request_options : typing.Optional[RequestOptions]
1186
1424
  Request-specific configuration.
@@ -1207,7 +1445,6 @@ class AsyncUploadClient:
1207
1445
  sub_tenant_id=sub_tenant_id,
1208
1446
  tenant_metadata=tenant_metadata,
1209
1447
  document_metadata=document_metadata,
1210
- relations=relations,
1211
1448
  request_options=request_options,
1212
1449
  )
1213
1450
  return _response.data
@@ -1221,25 +1458,39 @@ class AsyncUploadClient:
1221
1458
  sub_tenant_id: typing.Optional[str] = None,
1222
1459
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1223
1460
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1224
- relations: typing.Optional[Relations] = OMIT,
1225
1461
  request_options: typing.Optional[RequestOptions] = None,
1226
1462
  ) -> SingleUploadData:
1227
1463
  """
1464
+ Update existing text or markdown content with new information.
1465
+
1466
+ This endpoint allows you to modify text or markdown content that's already in your knowledge base. Provide the source ID of the content you want to update, along with the new text.
1467
+
1468
+ The system will reprocess and re-index the updated content asynchronously. Use this when you need to correct information, add details, or refresh existing documentation.
1469
+
1228
1470
  Parameters
1229
1471
  ----------
1230
1472
  source_id : str
1473
+ The source ID of the document to update
1231
1474
 
1232
1475
  tenant_id : str
1476
+ Unique identifier for the tenant/organization
1233
1477
 
1234
1478
  content : str
1479
+ The text or markdown content to upload
1235
1480
 
1236
1481
  sub_tenant_id : typing.Optional[str]
1482
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1237
1483
 
1238
1484
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1485
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1486
+
1487
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1239
1488
 
1240
1489
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1490
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1491
+
1492
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1241
1493
 
1242
- relations : typing.Optional[Relations]
1243
1494
 
1244
1495
  request_options : typing.Optional[RequestOptions]
1245
1496
  Request-specific configuration.
@@ -1267,7 +1518,6 @@ class AsyncUploadClient:
1267
1518
  sub_tenant_id=sub_tenant_id,
1268
1519
  tenant_metadata=tenant_metadata,
1269
1520
  document_metadata=document_metadata,
1270
- relations=relations,
1271
1521
  request_options=request_options,
1272
1522
  )
1273
1523
  return _response.data
@@ -1281,25 +1531,39 @@ class AsyncUploadClient:
1281
1531
  sub_tenant_id: typing.Optional[str] = None,
1282
1532
  tenant_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1283
1533
  document_metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
1284
- relations: typing.Optional[Relations] = OMIT,
1285
1534
  request_options: typing.Optional[RequestOptions] = None,
1286
1535
  ) -> SingleUploadData:
1287
1536
  """
1537
+ Update existing text or markdown content with new information.
1538
+
1539
+ This endpoint allows you to modify text or markdown content that's already in your knowledge base. Provide the source ID of the content you want to update, along with the new text.
1540
+
1541
+ The system will reprocess and re-index the updated content asynchronously. Use this when you need to correct information, add details, or refresh existing documentation.
1542
+
1288
1543
  Parameters
1289
1544
  ----------
1290
1545
  source_id : str
1546
+ The source ID of the document to update
1291
1547
 
1292
1548
  tenant_id : str
1549
+ Unique identifier for the tenant/organization
1293
1550
 
1294
1551
  content : str
1552
+ The text or markdown content to upload
1295
1553
 
1296
1554
  sub_tenant_id : typing.Optional[str]
1555
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1297
1556
 
1298
1557
  tenant_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1558
+ JSON string containing tenant-level document metadata (e.g., department, compliance_tag)
1559
+
1560
+ Example: > "{"department":"Finance","compliance_tag":"GDPR"}"
1299
1561
 
1300
1562
  document_metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
1563
+ JSON string containing document-specific metadata (e.g., title, author, file_id). If file_id is not provided, the system will generate an ID automatically.
1564
+
1565
+ Example: > "{"title":"Q1 Report.pdf","author":"Alice Smith","file_id":"custom_file_123"}"
1301
1566
 
1302
- relations : typing.Optional[Relations]
1303
1567
 
1304
1568
  request_options : typing.Optional[RequestOptions]
1305
1569
  Request-specific configuration.
@@ -1327,7 +1591,6 @@ class AsyncUploadClient:
1327
1591
  sub_tenant_id=sub_tenant_id,
1328
1592
  tenant_metadata=tenant_metadata,
1329
1593
  document_metadata=document_metadata,
1330
- relations=relations,
1331
1594
  request_options=request_options,
1332
1595
  )
1333
1596
  return _response.data
@@ -1342,15 +1605,25 @@ class AsyncUploadClient:
1342
1605
  request_options: typing.Optional[RequestOptions] = None,
1343
1606
  ) -> SingleUploadData:
1344
1607
  """
1608
+ Upload pre-computed embeddings for advanced similarity search.
1609
+
1610
+ This endpoint accepts vector embeddings that you've generated externally, allowing you to integrate with custom embedding models or existing vector databases. The embeddings represent chunks of your content as numerical vectors.
1611
+
1612
+ The system stores these embeddings and makes them available for semantic search and similarity matching. Use this when you want to leverage specialized embedding models or have existing vector representations.
1613
+
1345
1614
  Parameters
1346
1615
  ----------
1347
1616
  tenant_id : str
1617
+ Unique identifier for the tenant/organization
1348
1618
 
1349
1619
  embeddings : typing.Sequence[typing.Sequence[float]]
1620
+ The embeddings of source you want to index
1350
1621
 
1351
1622
  sub_tenant_id : typing.Optional[str]
1623
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1352
1624
 
1353
1625
  file_id : typing.Optional[str]
1626
+ The Source ID of the target source you want to index
1354
1627
 
1355
1628
  request_options : typing.Optional[RequestOptions]
1356
1629
  Request-specific configuration.
@@ -1389,13 +1662,22 @@ class AsyncUploadClient:
1389
1662
  request_options: typing.Optional[RequestOptions] = None,
1390
1663
  ) -> SingleUploadData:
1391
1664
  """
1665
+ Update existing embeddings with new vector representations.
1666
+
1667
+ This endpoint allows you to modify embeddings that are already stored in your knowledge base. Provide updated vector representations for specific chunks of content, identified by their chunk IDs.
1668
+
1669
+ The system will replace the existing embeddings with your new ones, ensuring that similarity searches reflect the most current vector representations. Use this when you need to update embeddings due to model improvements or content changes.
1670
+
1392
1671
  Parameters
1393
1672
  ----------
1394
1673
  tenant_id : str
1674
+ Unique identifier for the tenant/organization
1395
1675
 
1396
1676
  sub_tenant_id : typing.Optional[str]
1677
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1397
1678
 
1398
1679
  embeddings : typing.Optional[typing.Dict[str, typing.Sequence[float]]]
1680
+ The embeddings of source you want to index
1399
1681
 
1400
1682
  request_options : typing.Optional[RequestOptions]
1401
1683
  Request-specific configuration.
@@ -1428,21 +1710,28 @@ class AsyncUploadClient:
1428
1710
  tenant_id: str,
1429
1711
  sub_tenant_id: typing.Optional[str] = None,
1430
1712
  file_id: typing.Optional[str] = None,
1431
- relations: typing.Optional[str] = OMIT,
1432
1713
  request_options: typing.Optional[RequestOptions] = None,
1433
1714
  ) -> SingleUploadData:
1434
1715
  """
1716
+ Extract and index content from web pages automatically.
1717
+
1718
+ This endpoint initiates web scraping for the specified URL, extracting the main content, text, and structure from the webpage. It's perfect for capturing articles, documentation, or any web content you want to include in your knowledge base.
1719
+
1720
+ The system processes the webpage content asynchronously, cleaning and structuring the information for optimal search and retrieval. Use this when you need to add web content without manual copying and pasting.
1721
+
1435
1722
  Parameters
1436
1723
  ----------
1437
1724
  web_url : str
1725
+ The URL of the webpage to scrape and index
1438
1726
 
1439
1727
  tenant_id : str
1728
+ Unique identifier for the tenant/organization
1440
1729
 
1441
1730
  sub_tenant_id : typing.Optional[str]
1731
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1442
1732
 
1443
1733
  file_id : typing.Optional[str]
1444
-
1445
- relations : typing.Optional[str]
1734
+ Optional custom file ID for the scraped content. If not provided, a unique ID will be generated
1446
1735
 
1447
1736
  request_options : typing.Optional[RequestOptions]
1448
1737
  Request-specific configuration.
@@ -1468,7 +1757,6 @@ class AsyncUploadClient:
1468
1757
  tenant_id=tenant_id,
1469
1758
  sub_tenant_id=sub_tenant_id,
1470
1759
  file_id=file_id,
1471
- relations=relations,
1472
1760
  request_options=request_options,
1473
1761
  )
1474
1762
  return _response.data
@@ -1480,21 +1768,28 @@ class AsyncUploadClient:
1480
1768
  source_id: str,
1481
1769
  tenant_id: str,
1482
1770
  sub_tenant_id: typing.Optional[str] = None,
1483
- relations: typing.Optional[str] = OMIT,
1484
1771
  request_options: typing.Optional[RequestOptions] = None,
1485
1772
  ) -> SingleUploadData:
1486
1773
  """
1774
+ Update web scraping content with fresh data from the source URL.
1775
+
1776
+ This endpoint refreshes the content for an existing web scraping job. Provide the source ID of the webpage content you want to update, and the system will re-scrape the URL to capture any changes.
1777
+
1778
+ The updated content gets processed asynchronously and re-indexed in your knowledge base. Use this to keep web content current when the source pages are frequently updated.
1779
+
1487
1780
  Parameters
1488
1781
  ----------
1489
1782
  web_url : str
1783
+ The URL of the webpage to re-scrape
1490
1784
 
1491
1785
  source_id : str
1786
+ The file ID of the existing web scraping job to update
1492
1787
 
1493
1788
  tenant_id : str
1789
+ Unique identifier for the tenant/organization
1494
1790
 
1495
1791
  sub_tenant_id : typing.Optional[str]
1496
-
1497
- relations : typing.Optional[str]
1792
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1498
1793
 
1499
1794
  request_options : typing.Optional[RequestOptions]
1500
1795
  Request-specific configuration.
@@ -1520,7 +1815,6 @@ class AsyncUploadClient:
1520
1815
  source_id=source_id,
1521
1816
  tenant_id=tenant_id,
1522
1817
  sub_tenant_id=sub_tenant_id,
1523
- relations=relations,
1524
1818
  request_options=request_options,
1525
1819
  )
1526
1820
  return _response.data
@@ -1534,13 +1828,22 @@ class AsyncUploadClient:
1534
1828
  request_options: typing.Optional[RequestOptions] = None,
1535
1829
  ) -> typing.Optional[typing.Any]:
1536
1830
  """
1831
+ Remove documents and content from your knowledge base.
1832
+
1833
+ This endpoint permanently deletes the specified sources from your knowledge base. Once deleted, the content will no longer be available for search or retrieval.
1834
+
1835
+ Use this carefully as the action cannot be undone. The system will confirm successful deletion of each source ID you specify.
1836
+
1537
1837
  Parameters
1538
1838
  ----------
1539
1839
  tenant_id : str
1840
+ Unique identifier for the tenant/organization
1540
1841
 
1541
1842
  source_ids : typing.Sequence[str]
1843
+ List of source IDs to delete
1542
1844
 
1543
1845
  sub_tenant_id : typing.Optional[str]
1846
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1544
1847
 
1545
1848
  request_options : typing.Optional[RequestOptions]
1546
1849
  Request-specific configuration.
@@ -1575,13 +1878,22 @@ class AsyncUploadClient:
1575
1878
  request_options: typing.Optional[RequestOptions] = None,
1576
1879
  ) -> typing.Optional[typing.Any]:
1577
1880
  """
1881
+ Remove documents and content from your knowledge base.
1882
+
1883
+ This endpoint permanently deletes the specified sources from your knowledge base. Once deleted, the content will no longer be available for search or retrieval.
1884
+
1885
+ Use this carefully as the action cannot be undone. The system will confirm successful deletion of each source ID you specify.
1886
+
1578
1887
  Parameters
1579
1888
  ----------
1580
1889
  tenant_id : str
1890
+ Unique identifier for the tenant/organization
1581
1891
 
1582
1892
  source_ids : typing.Sequence[str]
1893
+ List of source IDs to delete
1583
1894
 
1584
1895
  sub_tenant_id : typing.Optional[str]
1896
+ Optional sub-tenant identifier for organizing data within a tenant. If not provided, defaults to tenant_id
1585
1897
 
1586
1898
  request_options : typing.Optional[RequestOptions]
1587
1899
  Request-specific configuration.
@@ -1615,16 +1927,19 @@ class AsyncUploadClient:
1615
1927
  request_options: typing.Optional[RequestOptions] = None,
1616
1928
  ) -> ProcessingStatus:
1617
1929
  """
1618
- Verify the processing status of an uploaded file.
1930
+ Check the current processing status of your uploaded content.
1931
+
1932
+ This endpoint allows you to monitor the progress of documents, text, or other content you've uploaded. Simply provide the file ID to see whether processing is complete, still in progress, or if any errors occurred.
1619
1933
 
1620
- Returns:
1621
- ProcessingStatusResponse: Processing status information
1934
+ Use this to determine when your content is ready for search and retrieval, or to troubleshoot any processing issues.
1622
1935
 
1623
1936
  Parameters
1624
1937
  ----------
1625
1938
  file_id : str
1939
+ The file ID to check processing status for
1626
1940
 
1627
1941
  tenant_id : typing.Optional[str]
1942
+ Unique identifier for the tenant/organization
1628
1943
 
1629
1944
  request_options : typing.Optional[RequestOptions]
1630
1945
  Request-specific configuration.