llama-cloud 0.0.11__py3-none-any.whl → 0.0.12__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.
Potentially problematic release.
This version of llama-cloud might be problematic. Click here for more details.
- llama_cloud/__init__.py +72 -10
- llama_cloud/client.py +3 -0
- llama_cloud/resources/__init__.py +11 -1
- llama_cloud/resources/auth/__init__.py +2 -0
- llama_cloud/resources/auth/client.py +124 -0
- llama_cloud/resources/data_sinks/types/data_sink_update_component_one.py +4 -0
- llama_cloud/resources/pipelines/__init__.py +12 -2
- llama_cloud/resources/pipelines/client.py +9 -47
- llama_cloud/resources/pipelines/types/__init__.py +11 -1
- llama_cloud/resources/pipelines/types/pipeline_update_transform_config.py +31 -0
- llama_cloud/types/__init__.py +70 -10
- llama_cloud/types/advanced_mode_transform_config.py +38 -0
- llama_cloud/types/advanced_mode_transform_config_chunking_config.py +67 -0
- llama_cloud/types/advanced_mode_transform_config_segmentation_config.py +45 -0
- llama_cloud/types/character_chunking_config.py +32 -0
- llama_cloud/types/{html_node_parser.py → character_splitter.py} +9 -9
- llama_cloud/types/chat_data.py +2 -0
- llama_cloud/types/cloud_az_storage_blob_data_source.py +11 -2
- llama_cloud/types/{transform_config.py → cloud_milvus_vector_store.py} +11 -7
- llama_cloud/types/cloud_mongo_db_atlas_vector_search.py +51 -0
- llama_cloud/types/configurable_data_sink_names.py +8 -0
- llama_cloud/types/configurable_transformation_names.py +8 -12
- llama_cloud/types/configured_transformation_item_component_one.py +4 -6
- llama_cloud/types/custom_claims.py +61 -0
- llama_cloud/types/data_sink_component_one.py +4 -0
- llama_cloud/types/data_sink_create_component_one.py +4 -0
- llama_cloud/types/element_segmentation_config.py +29 -0
- llama_cloud/types/embedding_config_component.py +2 -14
- llama_cloud/types/embedding_config_component_one.py +19 -0
- llama_cloud/types/eval_dataset_job_record.py +1 -0
- llama_cloud/types/ingestion_error_response.py +34 -0
- llama_cloud/types/job_name_mapping.py +45 -0
- llama_cloud/types/llama_parse_supported_file_extensions.py +32 -0
- llama_cloud/types/{simple_file_node_parser.py → llm_parameters.py} +6 -14
- llama_cloud/types/managed_ingestion_status_response.py +6 -0
- llama_cloud/types/none_chunking_config.py +29 -0
- llama_cloud/types/none_segmentation_config.py +29 -0
- llama_cloud/types/page_segmentation_config.py +29 -0
- llama_cloud/types/{json_node_parser.py → page_splitter_node_parser.py} +3 -8
- llama_cloud/types/parsing_job.py +2 -0
- llama_cloud/types/pipeline_create.py +2 -2
- llama_cloud/types/pipeline_create_transform_config.py +31 -0
- llama_cloud/types/semantic_chunking_config.py +32 -0
- llama_cloud/types/sentence_chunking_config.py +34 -0
- llama_cloud/types/token_chunking_config.py +33 -0
- llama_cloud/types/user.py +35 -0
- {llama_cloud-0.0.11.dist-info → llama_cloud-0.0.12.dist-info}/METADATA +1 -1
- {llama_cloud-0.0.11.dist-info → llama_cloud-0.0.12.dist-info}/RECORD +50 -30
- llama_cloud/types/transform_config_mode.py +0 -21
- {llama_cloud-0.0.11.dist-info → llama_cloud-0.0.12.dist-info}/LICENSE +0 -0
- {llama_cloud-0.0.11.dist-info → llama_cloud-0.0.12.dist-info}/WHEEL +0 -0
llama_cloud/__init__.py
CHANGED
|
@@ -1,11 +1,24 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
3
|
from .types import (
|
|
4
|
+
AdvancedModeTransformConfig,
|
|
5
|
+
AdvancedModeTransformConfigChunkingConfig,
|
|
6
|
+
AdvancedModeTransformConfigChunkingConfig_Character,
|
|
7
|
+
AdvancedModeTransformConfigChunkingConfig_None,
|
|
8
|
+
AdvancedModeTransformConfigChunkingConfig_Semantic,
|
|
9
|
+
AdvancedModeTransformConfigChunkingConfig_Sentence,
|
|
10
|
+
AdvancedModeTransformConfigChunkingConfig_Token,
|
|
11
|
+
AdvancedModeTransformConfigSegmentationConfig,
|
|
12
|
+
AdvancedModeTransformConfigSegmentationConfig_Element,
|
|
13
|
+
AdvancedModeTransformConfigSegmentationConfig_None,
|
|
14
|
+
AdvancedModeTransformConfigSegmentationConfig_Page,
|
|
4
15
|
AutoTransformConfig,
|
|
5
16
|
AzureOpenAiEmbedding,
|
|
6
17
|
Base,
|
|
7
18
|
BasePromptTemplate,
|
|
8
19
|
BedrockEmbedding,
|
|
20
|
+
CharacterChunkingConfig,
|
|
21
|
+
CharacterSplitter,
|
|
9
22
|
ChatData,
|
|
10
23
|
ChatMessage,
|
|
11
24
|
CloudAzStorageBlobDataSource,
|
|
@@ -15,6 +28,8 @@ from .types import (
|
|
|
15
28
|
CloudDocument,
|
|
16
29
|
CloudDocumentCreate,
|
|
17
30
|
CloudJiraDataSource,
|
|
31
|
+
CloudMilvusVectorStore,
|
|
32
|
+
CloudMongoDbAtlasVectorSearch,
|
|
18
33
|
CloudNotionPageDataSource,
|
|
19
34
|
CloudOneDriveDataSource,
|
|
20
35
|
CloudPineconeVectorStore,
|
|
@@ -33,6 +48,7 @@ from .types import (
|
|
|
33
48
|
ConfiguredTransformationItem,
|
|
34
49
|
ConfiguredTransformationItemComponent,
|
|
35
50
|
ConfiguredTransformationItemComponentOne,
|
|
51
|
+
CustomClaims,
|
|
36
52
|
DataSink,
|
|
37
53
|
DataSinkComponent,
|
|
38
54
|
DataSinkComponentOne,
|
|
@@ -49,8 +65,10 @@ from .types import (
|
|
|
49
65
|
DataSourceCreateCustomMetadataValue,
|
|
50
66
|
DataSourceCustomMetadataValue,
|
|
51
67
|
DataSourceDefinition,
|
|
68
|
+
ElementSegmentationConfig,
|
|
52
69
|
EmbeddingConfig,
|
|
53
70
|
EmbeddingConfigComponent,
|
|
71
|
+
EmbeddingConfigComponentOne,
|
|
54
72
|
EmbeddingConfigType,
|
|
55
73
|
EvalDataset,
|
|
56
74
|
EvalDatasetJobParams,
|
|
@@ -71,14 +89,15 @@ from .types import (
|
|
|
71
89
|
FilterCondition,
|
|
72
90
|
FilterOperator,
|
|
73
91
|
GeminiEmbedding,
|
|
74
|
-
HtmlNodeParser,
|
|
75
92
|
HttpValidationError,
|
|
76
93
|
HuggingFaceInferenceApiEmbedding,
|
|
77
94
|
HuggingFaceInferenceApiEmbeddingToken,
|
|
78
|
-
|
|
95
|
+
IngestionErrorResponse,
|
|
96
|
+
JobNameMapping,
|
|
79
97
|
LlamaParseParameters,
|
|
80
98
|
LlamaParseSupportedFileExtensions,
|
|
81
99
|
Llm,
|
|
100
|
+
LlmParameters,
|
|
82
101
|
LocalEval,
|
|
83
102
|
LocalEvalResults,
|
|
84
103
|
LocalEvalSets,
|
|
@@ -93,10 +112,14 @@ from .types import (
|
|
|
93
112
|
MetadataFiltersFiltersItem,
|
|
94
113
|
MetricResult,
|
|
95
114
|
NodeParser,
|
|
115
|
+
NoneChunkingConfig,
|
|
116
|
+
NoneSegmentationConfig,
|
|
96
117
|
ObjectType,
|
|
97
118
|
OpenAiEmbedding,
|
|
98
119
|
Organization,
|
|
99
120
|
OrganizationCreate,
|
|
121
|
+
PageSegmentationConfig,
|
|
122
|
+
PageSplitterNodeParser,
|
|
100
123
|
ParserLanguages,
|
|
101
124
|
ParsingHistoryItem,
|
|
102
125
|
ParsingJob,
|
|
@@ -106,6 +129,9 @@ from .types import (
|
|
|
106
129
|
ParsingUsage,
|
|
107
130
|
Pipeline,
|
|
108
131
|
PipelineCreate,
|
|
132
|
+
PipelineCreateTransformConfig,
|
|
133
|
+
PipelineCreateTransformConfig_Advanced,
|
|
134
|
+
PipelineCreateTransformConfig_Auto,
|
|
109
135
|
PipelineDataSource,
|
|
110
136
|
PipelineDataSourceComponent,
|
|
111
137
|
PipelineDataSourceComponentOne,
|
|
@@ -129,18 +155,19 @@ from .types import (
|
|
|
129
155
|
RelatedNodeInfo,
|
|
130
156
|
RetrievalMode,
|
|
131
157
|
RetrieveResults,
|
|
158
|
+
SemanticChunkingConfig,
|
|
159
|
+
SentenceChunkingConfig,
|
|
132
160
|
SentenceSplitter,
|
|
133
|
-
SimpleFileNodeParser,
|
|
134
161
|
StatusEnum,
|
|
135
162
|
SupportedEvalLlmModel,
|
|
136
163
|
SupportedEvalLlmModelNames,
|
|
137
164
|
TextNode,
|
|
138
165
|
TextNodeRelationshipsValue,
|
|
139
166
|
TextNodeWithScore,
|
|
167
|
+
TokenChunkingConfig,
|
|
140
168
|
TokenTextSplitter,
|
|
141
|
-
TransformConfig,
|
|
142
|
-
TransformConfigMode,
|
|
143
169
|
TransformationCategoryNames,
|
|
170
|
+
User,
|
|
144
171
|
UserOrganization,
|
|
145
172
|
UserOrganizationCreate,
|
|
146
173
|
UserOrganizationDelete,
|
|
@@ -158,6 +185,10 @@ from .resources import (
|
|
|
158
185
|
ExtractionSchemaUpdateDataSchemaValue,
|
|
159
186
|
FileCreateResourceInfoValue,
|
|
160
187
|
PipelineFileUpdateCustomMetadataValue,
|
|
188
|
+
PipelineUpdateTransformConfig,
|
|
189
|
+
PipelineUpdateTransformConfig_Advanced,
|
|
190
|
+
PipelineUpdateTransformConfig_Auto,
|
|
191
|
+
auth,
|
|
161
192
|
component_definitions,
|
|
162
193
|
data_sinks,
|
|
163
194
|
data_sources,
|
|
@@ -172,11 +203,24 @@ from .resources import (
|
|
|
172
203
|
from .environment import LlamaCloudEnvironment
|
|
173
204
|
|
|
174
205
|
__all__ = [
|
|
206
|
+
"AdvancedModeTransformConfig",
|
|
207
|
+
"AdvancedModeTransformConfigChunkingConfig",
|
|
208
|
+
"AdvancedModeTransformConfigChunkingConfig_Character",
|
|
209
|
+
"AdvancedModeTransformConfigChunkingConfig_None",
|
|
210
|
+
"AdvancedModeTransformConfigChunkingConfig_Semantic",
|
|
211
|
+
"AdvancedModeTransformConfigChunkingConfig_Sentence",
|
|
212
|
+
"AdvancedModeTransformConfigChunkingConfig_Token",
|
|
213
|
+
"AdvancedModeTransformConfigSegmentationConfig",
|
|
214
|
+
"AdvancedModeTransformConfigSegmentationConfig_Element",
|
|
215
|
+
"AdvancedModeTransformConfigSegmentationConfig_None",
|
|
216
|
+
"AdvancedModeTransformConfigSegmentationConfig_Page",
|
|
175
217
|
"AutoTransformConfig",
|
|
176
218
|
"AzureOpenAiEmbedding",
|
|
177
219
|
"Base",
|
|
178
220
|
"BasePromptTemplate",
|
|
179
221
|
"BedrockEmbedding",
|
|
222
|
+
"CharacterChunkingConfig",
|
|
223
|
+
"CharacterSplitter",
|
|
180
224
|
"ChatData",
|
|
181
225
|
"ChatMessage",
|
|
182
226
|
"CloudAzStorageBlobDataSource",
|
|
@@ -186,6 +230,8 @@ __all__ = [
|
|
|
186
230
|
"CloudDocument",
|
|
187
231
|
"CloudDocumentCreate",
|
|
188
232
|
"CloudJiraDataSource",
|
|
233
|
+
"CloudMilvusVectorStore",
|
|
234
|
+
"CloudMongoDbAtlasVectorSearch",
|
|
189
235
|
"CloudNotionPageDataSource",
|
|
190
236
|
"CloudOneDriveDataSource",
|
|
191
237
|
"CloudPineconeVectorStore",
|
|
@@ -204,6 +250,7 @@ __all__ = [
|
|
|
204
250
|
"ConfiguredTransformationItem",
|
|
205
251
|
"ConfiguredTransformationItemComponent",
|
|
206
252
|
"ConfiguredTransformationItemComponentOne",
|
|
253
|
+
"CustomClaims",
|
|
207
254
|
"DataSink",
|
|
208
255
|
"DataSinkComponent",
|
|
209
256
|
"DataSinkComponentOne",
|
|
@@ -225,8 +272,10 @@ __all__ = [
|
|
|
225
272
|
"DataSourceUpdateComponent",
|
|
226
273
|
"DataSourceUpdateComponentOne",
|
|
227
274
|
"DataSourceUpdateCustomMetadataValue",
|
|
275
|
+
"ElementSegmentationConfig",
|
|
228
276
|
"EmbeddingConfig",
|
|
229
277
|
"EmbeddingConfigComponent",
|
|
278
|
+
"EmbeddingConfigComponentOne",
|
|
230
279
|
"EmbeddingConfigType",
|
|
231
280
|
"EvalDataset",
|
|
232
281
|
"EvalDatasetJobParams",
|
|
@@ -250,15 +299,16 @@ __all__ = [
|
|
|
250
299
|
"FilterCondition",
|
|
251
300
|
"FilterOperator",
|
|
252
301
|
"GeminiEmbedding",
|
|
253
|
-
"HtmlNodeParser",
|
|
254
302
|
"HttpValidationError",
|
|
255
303
|
"HuggingFaceInferenceApiEmbedding",
|
|
256
304
|
"HuggingFaceInferenceApiEmbeddingToken",
|
|
257
|
-
"
|
|
305
|
+
"IngestionErrorResponse",
|
|
306
|
+
"JobNameMapping",
|
|
258
307
|
"LlamaCloudEnvironment",
|
|
259
308
|
"LlamaParseParameters",
|
|
260
309
|
"LlamaParseSupportedFileExtensions",
|
|
261
310
|
"Llm",
|
|
311
|
+
"LlmParameters",
|
|
262
312
|
"LocalEval",
|
|
263
313
|
"LocalEvalResults",
|
|
264
314
|
"LocalEvalSets",
|
|
@@ -273,10 +323,14 @@ __all__ = [
|
|
|
273
323
|
"MetadataFiltersFiltersItem",
|
|
274
324
|
"MetricResult",
|
|
275
325
|
"NodeParser",
|
|
326
|
+
"NoneChunkingConfig",
|
|
327
|
+
"NoneSegmentationConfig",
|
|
276
328
|
"ObjectType",
|
|
277
329
|
"OpenAiEmbedding",
|
|
278
330
|
"Organization",
|
|
279
331
|
"OrganizationCreate",
|
|
332
|
+
"PageSegmentationConfig",
|
|
333
|
+
"PageSplitterNodeParser",
|
|
280
334
|
"ParserLanguages",
|
|
281
335
|
"ParsingHistoryItem",
|
|
282
336
|
"ParsingJob",
|
|
@@ -286,6 +340,9 @@ __all__ = [
|
|
|
286
340
|
"ParsingUsage",
|
|
287
341
|
"Pipeline",
|
|
288
342
|
"PipelineCreate",
|
|
343
|
+
"PipelineCreateTransformConfig",
|
|
344
|
+
"PipelineCreateTransformConfig_Advanced",
|
|
345
|
+
"PipelineCreateTransformConfig_Auto",
|
|
289
346
|
"PipelineDataSource",
|
|
290
347
|
"PipelineDataSourceComponent",
|
|
291
348
|
"PipelineDataSourceComponentOne",
|
|
@@ -299,6 +356,9 @@ __all__ = [
|
|
|
299
356
|
"PipelineFileResourceInfoValue",
|
|
300
357
|
"PipelineFileUpdateCustomMetadataValue",
|
|
301
358
|
"PipelineType",
|
|
359
|
+
"PipelineUpdateTransformConfig",
|
|
360
|
+
"PipelineUpdateTransformConfig_Advanced",
|
|
361
|
+
"PipelineUpdateTransformConfig_Auto",
|
|
302
362
|
"Pooling",
|
|
303
363
|
"PresetRetrievalParams",
|
|
304
364
|
"PresignedUrl",
|
|
@@ -310,24 +370,26 @@ __all__ = [
|
|
|
310
370
|
"RelatedNodeInfo",
|
|
311
371
|
"RetrievalMode",
|
|
312
372
|
"RetrieveResults",
|
|
373
|
+
"SemanticChunkingConfig",
|
|
374
|
+
"SentenceChunkingConfig",
|
|
313
375
|
"SentenceSplitter",
|
|
314
|
-
"SimpleFileNodeParser",
|
|
315
376
|
"StatusEnum",
|
|
316
377
|
"SupportedEvalLlmModel",
|
|
317
378
|
"SupportedEvalLlmModelNames",
|
|
318
379
|
"TextNode",
|
|
319
380
|
"TextNodeRelationshipsValue",
|
|
320
381
|
"TextNodeWithScore",
|
|
382
|
+
"TokenChunkingConfig",
|
|
321
383
|
"TokenTextSplitter",
|
|
322
|
-
"TransformConfig",
|
|
323
|
-
"TransformConfigMode",
|
|
324
384
|
"TransformationCategoryNames",
|
|
325
385
|
"UnprocessableEntityError",
|
|
386
|
+
"User",
|
|
326
387
|
"UserOrganization",
|
|
327
388
|
"UserOrganizationCreate",
|
|
328
389
|
"UserOrganizationDelete",
|
|
329
390
|
"ValidationError",
|
|
330
391
|
"ValidationErrorLocItem",
|
|
392
|
+
"auth",
|
|
331
393
|
"component_definitions",
|
|
332
394
|
"data_sinks",
|
|
333
395
|
"data_sources",
|
llama_cloud/client.py
CHANGED
|
@@ -6,6 +6,7 @@ import httpx
|
|
|
6
6
|
|
|
7
7
|
from .core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
|
|
8
8
|
from .environment import LlamaCloudEnvironment
|
|
9
|
+
from .resources.auth.client import AsyncAuthClient, AuthClient
|
|
9
10
|
from .resources.component_definitions.client import AsyncComponentDefinitionsClient, ComponentDefinitionsClient
|
|
10
11
|
from .resources.data_sinks.client import AsyncDataSinksClient, DataSinksClient
|
|
11
12
|
from .resources.data_sources.client import AsyncDataSourcesClient, DataSourcesClient
|
|
@@ -42,6 +43,7 @@ class LlamaCloud:
|
|
|
42
43
|
self.evals = EvalsClient(client_wrapper=self._client_wrapper)
|
|
43
44
|
self.parsing = ParsingClient(client_wrapper=self._client_wrapper)
|
|
44
45
|
self.component_definitions = ComponentDefinitionsClient(client_wrapper=self._client_wrapper)
|
|
46
|
+
self.auth = AuthClient(client_wrapper=self._client_wrapper)
|
|
45
47
|
self.extraction = ExtractionClient(client_wrapper=self._client_wrapper)
|
|
46
48
|
|
|
47
49
|
|
|
@@ -69,6 +71,7 @@ class AsyncLlamaCloud:
|
|
|
69
71
|
self.evals = AsyncEvalsClient(client_wrapper=self._client_wrapper)
|
|
70
72
|
self.parsing = AsyncParsingClient(client_wrapper=self._client_wrapper)
|
|
71
73
|
self.component_definitions = AsyncComponentDefinitionsClient(client_wrapper=self._client_wrapper)
|
|
74
|
+
self.auth = AsyncAuthClient(client_wrapper=self._client_wrapper)
|
|
72
75
|
self.extraction = AsyncExtractionClient(client_wrapper=self._client_wrapper)
|
|
73
76
|
|
|
74
77
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
3
|
from . import (
|
|
4
|
+
auth,
|
|
4
5
|
component_definitions,
|
|
5
6
|
data_sinks,
|
|
6
7
|
data_sources,
|
|
@@ -16,7 +17,12 @@ from .data_sinks import DataSinkUpdateComponent, DataSinkUpdateComponentOne
|
|
|
16
17
|
from .data_sources import DataSourceUpdateComponent, DataSourceUpdateComponentOne, DataSourceUpdateCustomMetadataValue
|
|
17
18
|
from .extraction import ExtractionSchemaCreateDataSchemaValue, ExtractionSchemaUpdateDataSchemaValue
|
|
18
19
|
from .files import FileCreateResourceInfoValue
|
|
19
|
-
from .pipelines import
|
|
20
|
+
from .pipelines import (
|
|
21
|
+
PipelineFileUpdateCustomMetadataValue,
|
|
22
|
+
PipelineUpdateTransformConfig,
|
|
23
|
+
PipelineUpdateTransformConfig_Advanced,
|
|
24
|
+
PipelineUpdateTransformConfig_Auto,
|
|
25
|
+
)
|
|
20
26
|
|
|
21
27
|
__all__ = [
|
|
22
28
|
"DataSinkUpdateComponent",
|
|
@@ -28,6 +34,10 @@ __all__ = [
|
|
|
28
34
|
"ExtractionSchemaUpdateDataSchemaValue",
|
|
29
35
|
"FileCreateResourceInfoValue",
|
|
30
36
|
"PipelineFileUpdateCustomMetadataValue",
|
|
37
|
+
"PipelineUpdateTransformConfig",
|
|
38
|
+
"PipelineUpdateTransformConfig_Advanced",
|
|
39
|
+
"PipelineUpdateTransformConfig_Auto",
|
|
40
|
+
"auth",
|
|
31
41
|
"component_definitions",
|
|
32
42
|
"data_sinks",
|
|
33
43
|
"data_sources",
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import urllib.parse
|
|
4
|
+
from json.decoder import JSONDecodeError
|
|
5
|
+
|
|
6
|
+
from ...core.api_error import ApiError
|
|
7
|
+
from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper
|
|
8
|
+
from ...errors.unprocessable_entity_error import UnprocessableEntityError
|
|
9
|
+
from ...types.http_validation_error import HttpValidationError
|
|
10
|
+
from ...types.user import User
|
|
11
|
+
|
|
12
|
+
try:
|
|
13
|
+
import pydantic
|
|
14
|
+
if pydantic.__version__.startswith("1."):
|
|
15
|
+
raise ImportError
|
|
16
|
+
import pydantic.v1 as pydantic # type: ignore
|
|
17
|
+
except ImportError:
|
|
18
|
+
import pydantic # type: ignore
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class AuthClient:
|
|
22
|
+
def __init__(self, *, client_wrapper: SyncClientWrapper):
|
|
23
|
+
self._client_wrapper = client_wrapper
|
|
24
|
+
|
|
25
|
+
def login(self) -> None:
|
|
26
|
+
"""
|
|
27
|
+
from llama_cloud.client import LlamaCloud
|
|
28
|
+
|
|
29
|
+
client = LlamaCloud(
|
|
30
|
+
token="YOUR_TOKEN",
|
|
31
|
+
)
|
|
32
|
+
client.auth.login()
|
|
33
|
+
"""
|
|
34
|
+
_response = self._client_wrapper.httpx_client.request(
|
|
35
|
+
"GET",
|
|
36
|
+
urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "api/v1/auth/login"),
|
|
37
|
+
headers=self._client_wrapper.get_headers(),
|
|
38
|
+
timeout=60,
|
|
39
|
+
)
|
|
40
|
+
if 200 <= _response.status_code < 300:
|
|
41
|
+
return
|
|
42
|
+
try:
|
|
43
|
+
_response_json = _response.json()
|
|
44
|
+
except JSONDecodeError:
|
|
45
|
+
raise ApiError(status_code=_response.status_code, body=_response.text)
|
|
46
|
+
raise ApiError(status_code=_response.status_code, body=_response_json)
|
|
47
|
+
|
|
48
|
+
def read_self(self) -> User:
|
|
49
|
+
"""
|
|
50
|
+
from llama_cloud.client import LlamaCloud
|
|
51
|
+
|
|
52
|
+
client = LlamaCloud(
|
|
53
|
+
token="YOUR_TOKEN",
|
|
54
|
+
)
|
|
55
|
+
client.auth.read_self()
|
|
56
|
+
"""
|
|
57
|
+
_response = self._client_wrapper.httpx_client.request(
|
|
58
|
+
"GET",
|
|
59
|
+
urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "api/v1/auth/me"),
|
|
60
|
+
headers=self._client_wrapper.get_headers(),
|
|
61
|
+
timeout=60,
|
|
62
|
+
)
|
|
63
|
+
if 200 <= _response.status_code < 300:
|
|
64
|
+
return pydantic.parse_obj_as(User, _response.json()) # type: ignore
|
|
65
|
+
if _response.status_code == 422:
|
|
66
|
+
raise UnprocessableEntityError(pydantic.parse_obj_as(HttpValidationError, _response.json())) # type: ignore
|
|
67
|
+
try:
|
|
68
|
+
_response_json = _response.json()
|
|
69
|
+
except JSONDecodeError:
|
|
70
|
+
raise ApiError(status_code=_response.status_code, body=_response.text)
|
|
71
|
+
raise ApiError(status_code=_response.status_code, body=_response_json)
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
class AsyncAuthClient:
|
|
75
|
+
def __init__(self, *, client_wrapper: AsyncClientWrapper):
|
|
76
|
+
self._client_wrapper = client_wrapper
|
|
77
|
+
|
|
78
|
+
async def login(self) -> None:
|
|
79
|
+
"""
|
|
80
|
+
from llama_cloud.client import AsyncLlamaCloud
|
|
81
|
+
|
|
82
|
+
client = AsyncLlamaCloud(
|
|
83
|
+
token="YOUR_TOKEN",
|
|
84
|
+
)
|
|
85
|
+
await client.auth.login()
|
|
86
|
+
"""
|
|
87
|
+
_response = await self._client_wrapper.httpx_client.request(
|
|
88
|
+
"GET",
|
|
89
|
+
urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "api/v1/auth/login"),
|
|
90
|
+
headers=self._client_wrapper.get_headers(),
|
|
91
|
+
timeout=60,
|
|
92
|
+
)
|
|
93
|
+
if 200 <= _response.status_code < 300:
|
|
94
|
+
return
|
|
95
|
+
try:
|
|
96
|
+
_response_json = _response.json()
|
|
97
|
+
except JSONDecodeError:
|
|
98
|
+
raise ApiError(status_code=_response.status_code, body=_response.text)
|
|
99
|
+
raise ApiError(status_code=_response.status_code, body=_response_json)
|
|
100
|
+
|
|
101
|
+
async def read_self(self) -> User:
|
|
102
|
+
"""
|
|
103
|
+
from llama_cloud.client import AsyncLlamaCloud
|
|
104
|
+
|
|
105
|
+
client = AsyncLlamaCloud(
|
|
106
|
+
token="YOUR_TOKEN",
|
|
107
|
+
)
|
|
108
|
+
await client.auth.read_self()
|
|
109
|
+
"""
|
|
110
|
+
_response = await self._client_wrapper.httpx_client.request(
|
|
111
|
+
"GET",
|
|
112
|
+
urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "api/v1/auth/me"),
|
|
113
|
+
headers=self._client_wrapper.get_headers(),
|
|
114
|
+
timeout=60,
|
|
115
|
+
)
|
|
116
|
+
if 200 <= _response.status_code < 300:
|
|
117
|
+
return pydantic.parse_obj_as(User, _response.json()) # type: ignore
|
|
118
|
+
if _response.status_code == 422:
|
|
119
|
+
raise UnprocessableEntityError(pydantic.parse_obj_as(HttpValidationError, _response.json())) # type: ignore
|
|
120
|
+
try:
|
|
121
|
+
_response_json = _response.json()
|
|
122
|
+
except JSONDecodeError:
|
|
123
|
+
raise ApiError(status_code=_response.status_code, body=_response.text)
|
|
124
|
+
raise ApiError(status_code=_response.status_code, body=_response_json)
|
|
@@ -4,6 +4,8 @@ import typing
|
|
|
4
4
|
|
|
5
5
|
from ....types.cloud_azure_ai_search_vector_store import CloudAzureAiSearchVectorStore
|
|
6
6
|
from ....types.cloud_chroma_vector_store import CloudChromaVectorStore
|
|
7
|
+
from ....types.cloud_milvus_vector_store import CloudMilvusVectorStore
|
|
8
|
+
from ....types.cloud_mongo_db_atlas_vector_search import CloudMongoDbAtlasVectorSearch
|
|
7
9
|
from ....types.cloud_pinecone_vector_store import CloudPineconeVectorStore
|
|
8
10
|
from ....types.cloud_postgres_vector_store import CloudPostgresVectorStore
|
|
9
11
|
from ....types.cloud_qdrant_vector_store import CloudQdrantVectorStore
|
|
@@ -16,4 +18,6 @@ DataSinkUpdateComponentOne = typing.Union[
|
|
|
16
18
|
CloudQdrantVectorStore,
|
|
17
19
|
CloudWeaviateVectorStore,
|
|
18
20
|
CloudAzureAiSearchVectorStore,
|
|
21
|
+
CloudMongoDbAtlasVectorSearch,
|
|
22
|
+
CloudMilvusVectorStore,
|
|
19
23
|
]
|
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
|
-
from .types import
|
|
3
|
+
from .types import (
|
|
4
|
+
PipelineFileUpdateCustomMetadataValue,
|
|
5
|
+
PipelineUpdateTransformConfig,
|
|
6
|
+
PipelineUpdateTransformConfig_Advanced,
|
|
7
|
+
PipelineUpdateTransformConfig_Auto,
|
|
8
|
+
)
|
|
4
9
|
|
|
5
|
-
__all__ = [
|
|
10
|
+
__all__ = [
|
|
11
|
+
"PipelineFileUpdateCustomMetadataValue",
|
|
12
|
+
"PipelineUpdateTransformConfig",
|
|
13
|
+
"PipelineUpdateTransformConfig_Advanced",
|
|
14
|
+
"PipelineUpdateTransformConfig_Auto",
|
|
15
|
+
]
|