llama-cloud 0.0.2__py3-none-any.whl → 0.0.4__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.

Files changed (104) hide show
  1. llama_cloud/__init__.py +2 -0
  2. llama_cloud/client.py +16 -4
  3. llama_cloud/core/jsonable_encoder.py +3 -0
  4. llama_cloud/environment.py +7 -0
  5. llama_cloud/resources/api_keys/client.py +11 -16
  6. llama_cloud/resources/billing/client.py +9 -12
  7. llama_cloud/resources/component_definitions/client.py +9 -12
  8. llama_cloud/resources/data_sinks/client.py +21 -30
  9. llama_cloud/resources/data_sources/client.py +21 -30
  10. llama_cloud/resources/deprecated/client.py +27 -48
  11. llama_cloud/resources/evals/client.py +27 -44
  12. llama_cloud/resources/files/client.py +15 -24
  13. llama_cloud/resources/parsing/client.py +27 -48
  14. llama_cloud/resources/pipelines/client.py +73 -128
  15. llama_cloud/resources/projects/client.py +43 -72
  16. llama_cloud/types/api_key.py +3 -0
  17. llama_cloud/types/azure_open_ai_embedding.py +3 -0
  18. llama_cloud/types/base.py +3 -0
  19. llama_cloud/types/base_prompt_template.py +3 -0
  20. llama_cloud/types/bedrock_embedding.py +3 -0
  21. llama_cloud/types/chat_message.py +3 -0
  22. llama_cloud/types/cloud_az_storage_blob_data_source.py +3 -0
  23. llama_cloud/types/cloud_chroma_vector_store.py +3 -0
  24. llama_cloud/types/cloud_document.py +3 -0
  25. llama_cloud/types/cloud_document_create.py +3 -0
  26. llama_cloud/types/cloud_gcs_data_source.py +3 -0
  27. llama_cloud/types/cloud_google_drive_data_source.py +3 -0
  28. llama_cloud/types/cloud_one_drive_data_source.py +3 -0
  29. llama_cloud/types/cloud_pinecone_vector_store.py +3 -0
  30. llama_cloud/types/cloud_postgres_vector_store.py +3 -0
  31. llama_cloud/types/cloud_qdrant_vector_store.py +3 -0
  32. llama_cloud/types/cloud_s_3_data_source.py +3 -0
  33. llama_cloud/types/cloud_sharepoint_data_source.py +3 -0
  34. llama_cloud/types/cloud_weaviate_vector_store.py +3 -0
  35. llama_cloud/types/code_splitter.py +3 -0
  36. llama_cloud/types/cohere_embedding.py +3 -0
  37. llama_cloud/types/configurable_transformation_definition.py +3 -0
  38. llama_cloud/types/configured_transformation_item.py +3 -0
  39. llama_cloud/types/data_sink.py +3 -0
  40. llama_cloud/types/data_sink_create.py +3 -0
  41. llama_cloud/types/data_sink_definition.py +3 -0
  42. llama_cloud/types/data_source.py +3 -0
  43. llama_cloud/types/data_source_create.py +3 -0
  44. llama_cloud/types/data_source_definition.py +3 -0
  45. llama_cloud/types/eval_dataset.py +3 -0
  46. llama_cloud/types/eval_dataset_job_params.py +3 -0
  47. llama_cloud/types/eval_dataset_job_record.py +3 -0
  48. llama_cloud/types/eval_execution_params.py +3 -0
  49. llama_cloud/types/eval_execution_params_override.py +3 -0
  50. llama_cloud/types/eval_llm_model_data.py +3 -0
  51. llama_cloud/types/eval_question.py +3 -0
  52. llama_cloud/types/eval_question_create.py +3 -0
  53. llama_cloud/types/eval_question_result.py +3 -0
  54. llama_cloud/types/file.py +3 -0
  55. llama_cloud/types/gemini_embedding.py +3 -0
  56. llama_cloud/types/html_node_parser.py +3 -0
  57. llama_cloud/types/http_validation_error.py +3 -0
  58. llama_cloud/types/hugging_face_inference_api_embedding.py +3 -0
  59. llama_cloud/types/json_node_parser.py +3 -0
  60. llama_cloud/types/llm.py +3 -0
  61. llama_cloud/types/local_eval.py +3 -0
  62. llama_cloud/types/local_eval_results.py +3 -0
  63. llama_cloud/types/local_eval_sets.py +3 -0
  64. llama_cloud/types/markdown_element_node_parser.py +3 -0
  65. llama_cloud/types/markdown_node_parser.py +3 -0
  66. llama_cloud/types/metadata_filter.py +3 -0
  67. llama_cloud/types/metadata_filters.py +3 -0
  68. llama_cloud/types/metric_result.py +3 -0
  69. llama_cloud/types/node_parser.py +3 -0
  70. llama_cloud/types/open_ai_embedding.py +3 -0
  71. llama_cloud/types/parsing_history_item.py +3 -0
  72. llama_cloud/types/parsing_job.py +3 -0
  73. llama_cloud/types/parsing_job_json_result.py +3 -0
  74. llama_cloud/types/parsing_job_markdown_result.py +3 -0
  75. llama_cloud/types/parsing_job_text_result.py +3 -0
  76. llama_cloud/types/parsing_usage.py +3 -0
  77. llama_cloud/types/pipeline.py +3 -0
  78. llama_cloud/types/pipeline_create.py +3 -0
  79. llama_cloud/types/pipeline_data_source.py +3 -0
  80. llama_cloud/types/pipeline_data_source_create.py +3 -0
  81. llama_cloud/types/pipeline_deployment.py +3 -0
  82. llama_cloud/types/pipeline_file.py +3 -0
  83. llama_cloud/types/pipeline_file_create.py +3 -0
  84. llama_cloud/types/pipeline_file_status_response.py +3 -0
  85. llama_cloud/types/preset_retrieval_params.py +3 -0
  86. llama_cloud/types/presigned_url.py +3 -0
  87. llama_cloud/types/project.py +3 -0
  88. llama_cloud/types/project_create.py +3 -0
  89. llama_cloud/types/prompt_mixin_prompts.py +3 -0
  90. llama_cloud/types/prompt_spec.py +3 -0
  91. llama_cloud/types/related_node_info.py +3 -0
  92. llama_cloud/types/retrieve_results.py +3 -0
  93. llama_cloud/types/sentence_splitter.py +3 -0
  94. llama_cloud/types/simple_file_node_parser.py +3 -0
  95. llama_cloud/types/supported_eval_llm_model.py +3 -0
  96. llama_cloud/types/text_node.py +3 -0
  97. llama_cloud/types/text_node_with_score.py +3 -0
  98. llama_cloud/types/token_text_splitter.py +3 -0
  99. llama_cloud/types/validation_error.py +3 -0
  100. {llama_cloud-0.0.2.dist-info → llama_cloud-0.0.4.dist-info}/METADATA +1 -1
  101. llama_cloud-0.0.4.dist-info/RECORD +174 -0
  102. llama_cloud-0.0.2.dist-info/RECORD +0 -173
  103. {llama_cloud-0.0.2.dist-info → llama_cloud-0.0.4.dist-info}/LICENSE +0 -0
  104. {llama_cloud-0.0.2.dist-info → llama_cloud-0.0.4.dist-info}/WHEEL +0 -0
@@ -19,6 +19,9 @@ from ...types.project_create import ProjectCreate
19
19
  from ...types.prompt_mixin_prompts import PromptMixinPrompts
20
20
 
21
21
  try:
22
+ import pydantic
23
+ if pydantic.__version__.startswith("1."):
24
+ raise ImportError
22
25
  import pydantic.v1 as pydantic # type: ignore
23
26
  except ImportError:
24
27
  import pydantic # type: ignore
@@ -38,11 +41,10 @@ class ProjectsClient:
38
41
  Parameters:
39
42
  - project_name: typing.Optional[str].
40
43
  ---
41
- from platform.client import LlamaCloud
44
+ from llama_cloud.client import LlamaCloud
42
45
 
43
46
  client = LlamaCloud(
44
47
  token="YOUR_TOKEN",
45
- base_url="https://yourhost.com/path/to/api",
46
48
  )
47
49
  client.projects.list_projects()
48
50
  """
@@ -70,12 +72,11 @@ class ProjectsClient:
70
72
  Parameters:
71
73
  - request: ProjectCreate.
72
74
  ---
73
- from platform import ProjectCreate
74
- from platform.client import LlamaCloud
75
+ from llama_cloud import ProjectCreate
76
+ from llama_cloud.client import LlamaCloud
75
77
 
76
78
  client = LlamaCloud(
77
79
  token="YOUR_TOKEN",
78
- base_url="https://yourhost.com/path/to/api",
79
80
  )
80
81
  client.projects.create_project(
81
82
  request=ProjectCreate(
@@ -108,12 +109,11 @@ class ProjectsClient:
108
109
  Parameters:
109
110
  - request: ProjectCreate.
110
111
  ---
111
- from platform import ProjectCreate
112
- from platform.client import LlamaCloud
112
+ from llama_cloud import ProjectCreate
113
+ from llama_cloud.client import LlamaCloud
113
114
 
114
115
  client = LlamaCloud(
115
116
  token="YOUR_TOKEN",
116
- base_url="https://yourhost.com/path/to/api",
117
117
  )
118
118
  client.projects.upsert_project(
119
119
  request=ProjectCreate(
@@ -145,11 +145,10 @@ class ProjectsClient:
145
145
  Parameters:
146
146
  - project_id: str.
147
147
  ---
148
- from platform.client import LlamaCloud
148
+ from llama_cloud.client import LlamaCloud
149
149
 
150
150
  client = LlamaCloud(
151
151
  token="YOUR_TOKEN",
152
- base_url="https://yourhost.com/path/to/api",
153
152
  )
154
153
  client.projects.get_project(
155
154
  project_id="string",
@@ -180,11 +179,10 @@ class ProjectsClient:
180
179
 
181
180
  - name: str.
182
181
  ---
183
- from platform.client import LlamaCloud
182
+ from llama_cloud.client import LlamaCloud
184
183
 
185
184
  client = LlamaCloud(
186
185
  token="YOUR_TOKEN",
187
- base_url="https://yourhost.com/path/to/api",
188
186
  )
189
187
  client.projects.update_existing_project(
190
188
  project_id="string",
@@ -215,11 +213,10 @@ class ProjectsClient:
215
213
  Parameters:
216
214
  - project_id: str.
217
215
  ---
218
- from platform.client import LlamaCloud
216
+ from llama_cloud.client import LlamaCloud
219
217
 
220
218
  client = LlamaCloud(
221
219
  token="YOUR_TOKEN",
222
- base_url="https://yourhost.com/path/to/api",
223
220
  )
224
221
  client.projects.delete_project(
225
222
  project_id="string",
@@ -248,11 +245,10 @@ class ProjectsClient:
248
245
  Parameters:
249
246
  - project_id: str.
250
247
  ---
251
- from platform.client import LlamaCloud
248
+ from llama_cloud.client import LlamaCloud
252
249
 
253
250
  client = LlamaCloud(
254
251
  token="YOUR_TOKEN",
255
- base_url="https://yourhost.com/path/to/api",
256
252
  )
257
253
  client.projects.get_datasets_for_project(
258
254
  project_id="string",
@@ -285,11 +281,10 @@ class ProjectsClient:
285
281
 
286
282
  - name: str. The name of the EvalDataset.
287
283
  ---
288
- from platform.client import LlamaCloud
284
+ from llama_cloud.client import LlamaCloud
289
285
 
290
286
  client = LlamaCloud(
291
287
  token="YOUR_TOKEN",
292
- base_url="https://yourhost.com/path/to/api",
293
288
  )
294
289
  client.projects.create_eval_dataset_for_project(
295
290
  project_id="string",
@@ -328,11 +323,10 @@ class ProjectsClient:
328
323
 
329
324
  - results: typing.Dict[str, typing.List[LocalEval]]. The eval results.
330
325
  ---
331
- from platform.client import LlamaCloud
326
+ from llama_cloud.client import LlamaCloud
332
327
 
333
328
  client = LlamaCloud(
334
329
  token="YOUR_TOKEN",
335
- base_url="https://yourhost.com/path/to/api",
336
330
  )
337
331
  client.projects.create_local_eval_set_for_project(
338
332
  project_id="string",
@@ -366,11 +360,10 @@ class ProjectsClient:
366
360
  Parameters:
367
361
  - project_id: str.
368
362
  ---
369
- from platform.client import LlamaCloud
363
+ from llama_cloud.client import LlamaCloud
370
364
 
371
365
  client = LlamaCloud(
372
366
  token="YOUR_TOKEN",
373
- base_url="https://yourhost.com/path/to/api",
374
367
  )
375
368
  client.projects.get_local_evals_for_project(
376
369
  project_id="string",
@@ -399,11 +392,10 @@ class ProjectsClient:
399
392
  Parameters:
400
393
  - project_id: str.
401
394
  ---
402
- from platform.client import LlamaCloud
395
+ from llama_cloud.client import LlamaCloud
403
396
 
404
397
  client = LlamaCloud(
405
398
  token="YOUR_TOKEN",
406
- base_url="https://yourhost.com/path/to/api",
407
399
  )
408
400
  client.projects.get_local_eval_sets_for_project(
409
401
  project_id="string",
@@ -436,11 +428,10 @@ class ProjectsClient:
436
428
 
437
429
  - local_eval_set_id: str.
438
430
  ---
439
- from platform.client import LlamaCloud
431
+ from llama_cloud.client import LlamaCloud
440
432
 
441
433
  client = LlamaCloud(
442
434
  token="YOUR_TOKEN",
443
- base_url="https://yourhost.com/path/to/api",
444
435
  )
445
436
  client.projects.delete_local_eval_set(
446
437
  project_id="string",
@@ -473,11 +464,10 @@ class ProjectsClient:
473
464
  Parameters:
474
465
  - project_id: str.
475
466
  ---
476
- from platform.client import LlamaCloud
467
+ from llama_cloud.client import LlamaCloud
477
468
 
478
469
  client = LlamaCloud(
479
470
  token="YOUR_TOKEN",
480
- base_url="https://yourhost.com/path/to/api",
481
471
  )
482
472
  client.projects.get_promptmixin_prompts(
483
473
  project_id="string",
@@ -508,12 +498,11 @@ class ProjectsClient:
508
498
 
509
499
  - request: PromptMixinPrompts.
510
500
  ---
511
- from platform import PromptMixinPrompts
512
- from platform.client import LlamaCloud
501
+ from llama_cloud import PromptMixinPrompts
502
+ from llama_cloud.client import LlamaCloud
513
503
 
514
504
  client = LlamaCloud(
515
505
  token="YOUR_TOKEN",
516
- base_url="https://yourhost.com/path/to/api",
517
506
  )
518
507
  client.projects.create_prompt_mixin_prompts(
519
508
  project_id="string",
@@ -554,12 +543,11 @@ class ProjectsClient:
554
543
 
555
544
  - request: PromptMixinPrompts.
556
545
  ---
557
- from platform import PromptMixinPrompts
558
- from platform.client import LlamaCloud
546
+ from llama_cloud import PromptMixinPrompts
547
+ from llama_cloud.client import LlamaCloud
559
548
 
560
549
  client = LlamaCloud(
561
550
  token="YOUR_TOKEN",
562
- base_url="https://yourhost.com/path/to/api",
563
551
  )
564
552
  client.projects.update_promptmixin_prompts(
565
553
  project_id="string",
@@ -599,11 +587,10 @@ class ProjectsClient:
599
587
 
600
588
  - prompt_set_id: str.
601
589
  ---
602
- from platform.client import LlamaCloud
590
+ from llama_cloud.client import LlamaCloud
603
591
 
604
592
  client = LlamaCloud(
605
593
  token="YOUR_TOKEN",
606
- base_url="https://yourhost.com/path/to/api",
607
594
  )
608
595
  client.projects.delete_prompt_mixin_prompts(
609
596
  project_id="string",
@@ -640,11 +627,10 @@ class AsyncProjectsClient:
640
627
  Parameters:
641
628
  - project_name: typing.Optional[str].
642
629
  ---
643
- from platform.client import AsyncLlamaCloud
630
+ from llama_cloud.client import AsyncLlamaCloud
644
631
 
645
632
  client = AsyncLlamaCloud(
646
633
  token="YOUR_TOKEN",
647
- base_url="https://yourhost.com/path/to/api",
648
634
  )
649
635
  await client.projects.list_projects()
650
636
  """
@@ -672,12 +658,11 @@ class AsyncProjectsClient:
672
658
  Parameters:
673
659
  - request: ProjectCreate.
674
660
  ---
675
- from platform import ProjectCreate
676
- from platform.client import AsyncLlamaCloud
661
+ from llama_cloud import ProjectCreate
662
+ from llama_cloud.client import AsyncLlamaCloud
677
663
 
678
664
  client = AsyncLlamaCloud(
679
665
  token="YOUR_TOKEN",
680
- base_url="https://yourhost.com/path/to/api",
681
666
  )
682
667
  await client.projects.create_project(
683
668
  request=ProjectCreate(
@@ -710,12 +695,11 @@ class AsyncProjectsClient:
710
695
  Parameters:
711
696
  - request: ProjectCreate.
712
697
  ---
713
- from platform import ProjectCreate
714
- from platform.client import AsyncLlamaCloud
698
+ from llama_cloud import ProjectCreate
699
+ from llama_cloud.client import AsyncLlamaCloud
715
700
 
716
701
  client = AsyncLlamaCloud(
717
702
  token="YOUR_TOKEN",
718
- base_url="https://yourhost.com/path/to/api",
719
703
  )
720
704
  await client.projects.upsert_project(
721
705
  request=ProjectCreate(
@@ -747,11 +731,10 @@ class AsyncProjectsClient:
747
731
  Parameters:
748
732
  - project_id: str.
749
733
  ---
750
- from platform.client import AsyncLlamaCloud
734
+ from llama_cloud.client import AsyncLlamaCloud
751
735
 
752
736
  client = AsyncLlamaCloud(
753
737
  token="YOUR_TOKEN",
754
- base_url="https://yourhost.com/path/to/api",
755
738
  )
756
739
  await client.projects.get_project(
757
740
  project_id="string",
@@ -782,11 +765,10 @@ class AsyncProjectsClient:
782
765
 
783
766
  - name: str.
784
767
  ---
785
- from platform.client import AsyncLlamaCloud
768
+ from llama_cloud.client import AsyncLlamaCloud
786
769
 
787
770
  client = AsyncLlamaCloud(
788
771
  token="YOUR_TOKEN",
789
- base_url="https://yourhost.com/path/to/api",
790
772
  )
791
773
  await client.projects.update_existing_project(
792
774
  project_id="string",
@@ -817,11 +799,10 @@ class AsyncProjectsClient:
817
799
  Parameters:
818
800
  - project_id: str.
819
801
  ---
820
- from platform.client import AsyncLlamaCloud
802
+ from llama_cloud.client import AsyncLlamaCloud
821
803
 
822
804
  client = AsyncLlamaCloud(
823
805
  token="YOUR_TOKEN",
824
- base_url="https://yourhost.com/path/to/api",
825
806
  )
826
807
  await client.projects.delete_project(
827
808
  project_id="string",
@@ -850,11 +831,10 @@ class AsyncProjectsClient:
850
831
  Parameters:
851
832
  - project_id: str.
852
833
  ---
853
- from platform.client import AsyncLlamaCloud
834
+ from llama_cloud.client import AsyncLlamaCloud
854
835
 
855
836
  client = AsyncLlamaCloud(
856
837
  token="YOUR_TOKEN",
857
- base_url="https://yourhost.com/path/to/api",
858
838
  )
859
839
  await client.projects.get_datasets_for_project(
860
840
  project_id="string",
@@ -887,11 +867,10 @@ class AsyncProjectsClient:
887
867
 
888
868
  - name: str. The name of the EvalDataset.
889
869
  ---
890
- from platform.client import AsyncLlamaCloud
870
+ from llama_cloud.client import AsyncLlamaCloud
891
871
 
892
872
  client = AsyncLlamaCloud(
893
873
  token="YOUR_TOKEN",
894
- base_url="https://yourhost.com/path/to/api",
895
874
  )
896
875
  await client.projects.create_eval_dataset_for_project(
897
876
  project_id="string",
@@ -930,11 +909,10 @@ class AsyncProjectsClient:
930
909
 
931
910
  - results: typing.Dict[str, typing.List[LocalEval]]. The eval results.
932
911
  ---
933
- from platform.client import AsyncLlamaCloud
912
+ from llama_cloud.client import AsyncLlamaCloud
934
913
 
935
914
  client = AsyncLlamaCloud(
936
915
  token="YOUR_TOKEN",
937
- base_url="https://yourhost.com/path/to/api",
938
916
  )
939
917
  await client.projects.create_local_eval_set_for_project(
940
918
  project_id="string",
@@ -968,11 +946,10 @@ class AsyncProjectsClient:
968
946
  Parameters:
969
947
  - project_id: str.
970
948
  ---
971
- from platform.client import AsyncLlamaCloud
949
+ from llama_cloud.client import AsyncLlamaCloud
972
950
 
973
951
  client = AsyncLlamaCloud(
974
952
  token="YOUR_TOKEN",
975
- base_url="https://yourhost.com/path/to/api",
976
953
  )
977
954
  await client.projects.get_local_evals_for_project(
978
955
  project_id="string",
@@ -1001,11 +978,10 @@ class AsyncProjectsClient:
1001
978
  Parameters:
1002
979
  - project_id: str.
1003
980
  ---
1004
- from platform.client import AsyncLlamaCloud
981
+ from llama_cloud.client import AsyncLlamaCloud
1005
982
 
1006
983
  client = AsyncLlamaCloud(
1007
984
  token="YOUR_TOKEN",
1008
- base_url="https://yourhost.com/path/to/api",
1009
985
  )
1010
986
  await client.projects.get_local_eval_sets_for_project(
1011
987
  project_id="string",
@@ -1038,11 +1014,10 @@ class AsyncProjectsClient:
1038
1014
 
1039
1015
  - local_eval_set_id: str.
1040
1016
  ---
1041
- from platform.client import AsyncLlamaCloud
1017
+ from llama_cloud.client import AsyncLlamaCloud
1042
1018
 
1043
1019
  client = AsyncLlamaCloud(
1044
1020
  token="YOUR_TOKEN",
1045
- base_url="https://yourhost.com/path/to/api",
1046
1021
  )
1047
1022
  await client.projects.delete_local_eval_set(
1048
1023
  project_id="string",
@@ -1075,11 +1050,10 @@ class AsyncProjectsClient:
1075
1050
  Parameters:
1076
1051
  - project_id: str.
1077
1052
  ---
1078
- from platform.client import AsyncLlamaCloud
1053
+ from llama_cloud.client import AsyncLlamaCloud
1079
1054
 
1080
1055
  client = AsyncLlamaCloud(
1081
1056
  token="YOUR_TOKEN",
1082
- base_url="https://yourhost.com/path/to/api",
1083
1057
  )
1084
1058
  await client.projects.get_promptmixin_prompts(
1085
1059
  project_id="string",
@@ -1110,12 +1084,11 @@ class AsyncProjectsClient:
1110
1084
 
1111
1085
  - request: PromptMixinPrompts.
1112
1086
  ---
1113
- from platform import PromptMixinPrompts
1114
- from platform.client import AsyncLlamaCloud
1087
+ from llama_cloud import PromptMixinPrompts
1088
+ from llama_cloud.client import AsyncLlamaCloud
1115
1089
 
1116
1090
  client = AsyncLlamaCloud(
1117
1091
  token="YOUR_TOKEN",
1118
- base_url="https://yourhost.com/path/to/api",
1119
1092
  )
1120
1093
  await client.projects.create_prompt_mixin_prompts(
1121
1094
  project_id="string",
@@ -1156,12 +1129,11 @@ class AsyncProjectsClient:
1156
1129
 
1157
1130
  - request: PromptMixinPrompts.
1158
1131
  ---
1159
- from platform import PromptMixinPrompts
1160
- from platform.client import AsyncLlamaCloud
1132
+ from llama_cloud import PromptMixinPrompts
1133
+ from llama_cloud.client import AsyncLlamaCloud
1161
1134
 
1162
1135
  client = AsyncLlamaCloud(
1163
1136
  token="YOUR_TOKEN",
1164
- base_url="https://yourhost.com/path/to/api",
1165
1137
  )
1166
1138
  await client.projects.update_promptmixin_prompts(
1167
1139
  project_id="string",
@@ -1201,11 +1173,10 @@ class AsyncProjectsClient:
1201
1173
 
1202
1174
  - prompt_set_id: str.
1203
1175
  ---
1204
- from platform.client import AsyncLlamaCloud
1176
+ from llama_cloud.client import AsyncLlamaCloud
1205
1177
 
1206
1178
  client = AsyncLlamaCloud(
1207
1179
  token="YOUR_TOKEN",
1208
- base_url="https://yourhost.com/path/to/api",
1209
1180
  )
1210
1181
  await client.projects.delete_prompt_mixin_prompts(
1211
1182
  project_id="string",
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
llama_cloud/types/base.py CHANGED
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -7,6 +7,9 @@ from ..core.datetime_utils import serialize_datetime
7
7
  from .message_role import MessageRole
8
8
 
9
9
  try:
10
+ import pydantic
11
+ if pydantic.__version__.startswith("1."):
12
+ raise ImportError
10
13
  import pydantic.v1 as pydantic # type: ignore
11
14
  except ImportError:
12
15
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -6,6 +6,9 @@ import typing
6
6
  from ..core.datetime_utils import serialize_datetime
7
7
 
8
8
  try:
9
+ import pydantic
10
+ if pydantic.__version__.startswith("1."):
11
+ raise ImportError
9
12
  import pydantic.v1 as pydantic # type: ignore
10
13
  except ImportError:
11
14
  import pydantic # type: ignore
@@ -8,6 +8,9 @@ from .configurable_transformation_names import ConfigurableTransformationNames
8
8
  from .transformation_category_names import TransformationCategoryNames
9
9
 
10
10
  try:
11
+ import pydantic
12
+ if pydantic.__version__.startswith("1."):
13
+ raise ImportError
11
14
  import pydantic.v1 as pydantic # type: ignore
12
15
  except ImportError:
13
16
  import pydantic # type: ignore