llama-cloud 0.1.8__py3-none-any.whl → 0.1.10__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 (51) hide show
  1. llama_cloud/__init__.py +32 -22
  2. llama_cloud/client.py +0 -3
  3. llama_cloud/resources/__init__.py +14 -8
  4. llama_cloud/resources/chat_apps/client.py +99 -133
  5. llama_cloud/resources/files/client.py +34 -6
  6. llama_cloud/resources/llama_extract/__init__.py +16 -2
  7. llama_cloud/resources/llama_extract/client.py +238 -366
  8. llama_cloud/resources/llama_extract/types/__init__.py +14 -3
  9. llama_cloud/resources/llama_extract/types/extract_agent_create_data_schema.py +9 -0
  10. llama_cloud/resources/llama_extract/types/{extract_agent_create_data_schema_value.py → extract_agent_create_data_schema_zero_value.py} +1 -1
  11. llama_cloud/resources/llama_extract/types/extract_agent_update_data_schema.py +9 -0
  12. llama_cloud/resources/{extraction/types/extraction_schema_create_data_schema_value.py → llama_extract/types/extract_agent_update_data_schema_zero_value.py} +1 -1
  13. llama_cloud/resources/llama_extract/types/extract_schema_validate_request_data_schema.py +9 -0
  14. llama_cloud/resources/llama_extract/types/extract_schema_validate_request_data_schema_zero_value.py +7 -0
  15. llama_cloud/resources/organizations/client.py +8 -12
  16. llama_cloud/resources/parsing/client.py +146 -18
  17. llama_cloud/resources/reports/client.py +30 -26
  18. llama_cloud/resources/retrievers/client.py +16 -4
  19. llama_cloud/types/__init__.py +20 -12
  20. llama_cloud/types/chat_app.py +11 -9
  21. llama_cloud/types/chat_app_response.py +12 -10
  22. llama_cloud/types/cloud_mongo_db_atlas_vector_search.py +1 -0
  23. llama_cloud/types/extract_job.py +3 -1
  24. llama_cloud/types/extract_job_create.py +4 -2
  25. llama_cloud/types/extract_job_create_data_schema_override.py +9 -0
  26. llama_cloud/{resources/extraction/types/extraction_schema_update_data_schema_value.py → types/extract_job_create_data_schema_override_zero_value.py} +1 -1
  27. llama_cloud/types/extract_resultset.py +2 -6
  28. llama_cloud/types/extract_run.py +5 -0
  29. llama_cloud/types/extract_run_data.py +11 -0
  30. llama_cloud/types/extract_run_data_item_value.py +5 -0
  31. llama_cloud/types/extract_run_data_zero_value.py +5 -0
  32. llama_cloud/{resources/llama_extract/types/extract_agent_update_data_schema_value.py → types/extract_run_extraction_metadata_value.py} +1 -1
  33. llama_cloud/types/{extraction_job.py → extract_schema_validate_response.py} +3 -6
  34. llama_cloud/types/extract_schema_validate_response_data_schema_value.py +7 -0
  35. llama_cloud/types/extract_state.py +4 -4
  36. llama_cloud/types/llama_extract_settings.py +4 -0
  37. llama_cloud/types/llama_parse_parameters.py +11 -0
  38. llama_cloud/types/plan.py +4 -0
  39. llama_cloud/types/{extraction_result.py → preset_composite_retrieval_params.py} +5 -14
  40. llama_cloud/types/{extraction_schema.py → report_file_info.py} +5 -9
  41. llama_cloud/types/report_metadata.py +2 -1
  42. {llama_cloud-0.1.8.dist-info → llama_cloud-0.1.10.dist-info}/METADATA +2 -1
  43. {llama_cloud-0.1.8.dist-info → llama_cloud-0.1.10.dist-info}/RECORD +45 -42
  44. {llama_cloud-0.1.8.dist-info → llama_cloud-0.1.10.dist-info}/WHEEL +1 -1
  45. llama_cloud/resources/extraction/__init__.py +0 -5
  46. llama_cloud/resources/extraction/client.py +0 -756
  47. llama_cloud/resources/extraction/types/__init__.py +0 -6
  48. llama_cloud/types/extract_job_create_data_schema_override_value.py +0 -7
  49. llama_cloud/types/extraction_result_data_value.py +0 -5
  50. llama_cloud/types/extraction_schema_data_schema_value.py +0 -7
  51. {llama_cloud-0.1.8.dist-info → llama_cloud-0.1.10.dist-info}/LICENSE +0 -0
@@ -187,6 +187,7 @@ class FilesClient:
187
187
  def generate_presigned_url(
188
188
  self,
189
189
  *,
190
+ expires_at_seconds: typing.Optional[int] = None,
190
191
  project_id: typing.Optional[str] = None,
191
192
  organization_id: typing.Optional[str] = None,
192
193
  name: str,
@@ -201,6 +202,8 @@ class FilesClient:
201
202
  Create a presigned url for uploading a file.
202
203
 
203
204
  Parameters:
205
+ - expires_at_seconds: typing.Optional[int].
206
+
204
207
  - project_id: typing.Optional[str].
205
208
 
206
209
  - organization_id: typing.Optional[str].
@@ -244,7 +247,9 @@ class FilesClient:
244
247
  _response = self._client_wrapper.httpx_client.request(
245
248
  "PUT",
246
249
  urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "api/v1/files"),
247
- params=remove_none_from_dict({"project_id": project_id, "organization_id": organization_id}),
250
+ params=remove_none_from_dict(
251
+ {"expires_at_seconds": expires_at_seconds, "project_id": project_id, "organization_id": organization_id}
252
+ ),
248
253
  json=jsonable_encoder(_request),
249
254
  headers=self._client_wrapper.get_headers(),
250
255
  timeout=60,
@@ -370,7 +375,12 @@ class FilesClient:
370
375
  raise ApiError(status_code=_response.status_code, body=_response_json)
371
376
 
372
377
  def read_file_content(
373
- self, id: str, *, project_id: typing.Optional[str] = None, organization_id: typing.Optional[str] = None
378
+ self,
379
+ id: str,
380
+ *,
381
+ expires_at_seconds: typing.Optional[int] = None,
382
+ project_id: typing.Optional[str] = None,
383
+ organization_id: typing.Optional[str] = None,
374
384
  ) -> PresignedUrl:
375
385
  """
376
386
  Returns a presigned url to read the file content.
@@ -378,6 +388,8 @@ class FilesClient:
378
388
  Parameters:
379
389
  - id: str.
380
390
 
391
+ - expires_at_seconds: typing.Optional[int].
392
+
381
393
  - project_id: typing.Optional[str].
382
394
 
383
395
  - organization_id: typing.Optional[str].
@@ -394,7 +406,9 @@ class FilesClient:
394
406
  _response = self._client_wrapper.httpx_client.request(
395
407
  "GET",
396
408
  urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", f"api/v1/files/{id}/content"),
397
- params=remove_none_from_dict({"project_id": project_id, "organization_id": organization_id}),
409
+ params=remove_none_from_dict(
410
+ {"expires_at_seconds": expires_at_seconds, "project_id": project_id, "organization_id": organization_id}
411
+ ),
398
412
  headers=self._client_wrapper.get_headers(),
399
413
  timeout=60,
400
414
  )
@@ -788,6 +802,7 @@ class AsyncFilesClient:
788
802
  async def generate_presigned_url(
789
803
  self,
790
804
  *,
805
+ expires_at_seconds: typing.Optional[int] = None,
791
806
  project_id: typing.Optional[str] = None,
792
807
  organization_id: typing.Optional[str] = None,
793
808
  name: str,
@@ -802,6 +817,8 @@ class AsyncFilesClient:
802
817
  Create a presigned url for uploading a file.
803
818
 
804
819
  Parameters:
820
+ - expires_at_seconds: typing.Optional[int].
821
+
805
822
  - project_id: typing.Optional[str].
806
823
 
807
824
  - organization_id: typing.Optional[str].
@@ -845,7 +862,9 @@ class AsyncFilesClient:
845
862
  _response = await self._client_wrapper.httpx_client.request(
846
863
  "PUT",
847
864
  urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", "api/v1/files"),
848
- params=remove_none_from_dict({"project_id": project_id, "organization_id": organization_id}),
865
+ params=remove_none_from_dict(
866
+ {"expires_at_seconds": expires_at_seconds, "project_id": project_id, "organization_id": organization_id}
867
+ ),
849
868
  json=jsonable_encoder(_request),
850
869
  headers=self._client_wrapper.get_headers(),
851
870
  timeout=60,
@@ -971,7 +990,12 @@ class AsyncFilesClient:
971
990
  raise ApiError(status_code=_response.status_code, body=_response_json)
972
991
 
973
992
  async def read_file_content(
974
- self, id: str, *, project_id: typing.Optional[str] = None, organization_id: typing.Optional[str] = None
993
+ self,
994
+ id: str,
995
+ *,
996
+ expires_at_seconds: typing.Optional[int] = None,
997
+ project_id: typing.Optional[str] = None,
998
+ organization_id: typing.Optional[str] = None,
975
999
  ) -> PresignedUrl:
976
1000
  """
977
1001
  Returns a presigned url to read the file content.
@@ -979,6 +1003,8 @@ class AsyncFilesClient:
979
1003
  Parameters:
980
1004
  - id: str.
981
1005
 
1006
+ - expires_at_seconds: typing.Optional[int].
1007
+
982
1008
  - project_id: typing.Optional[str].
983
1009
 
984
1010
  - organization_id: typing.Optional[str].
@@ -995,7 +1021,9 @@ class AsyncFilesClient:
995
1021
  _response = await self._client_wrapper.httpx_client.request(
996
1022
  "GET",
997
1023
  urllib.parse.urljoin(f"{self._client_wrapper.get_base_url()}/", f"api/v1/files/{id}/content"),
998
- params=remove_none_from_dict({"project_id": project_id, "organization_id": organization_id}),
1024
+ params=remove_none_from_dict(
1025
+ {"expires_at_seconds": expires_at_seconds, "project_id": project_id, "organization_id": organization_id}
1026
+ ),
999
1027
  headers=self._client_wrapper.get_headers(),
1000
1028
  timeout=60,
1001
1029
  )
@@ -1,5 +1,19 @@
1
1
  # This file was auto-generated by Fern from our API Definition.
2
2
 
3
- from .types import ExtractAgentCreateDataSchemaValue, ExtractAgentUpdateDataSchemaValue
3
+ from .types import (
4
+ ExtractAgentCreateDataSchema,
5
+ ExtractAgentCreateDataSchemaZeroValue,
6
+ ExtractAgentUpdateDataSchema,
7
+ ExtractAgentUpdateDataSchemaZeroValue,
8
+ ExtractSchemaValidateRequestDataSchema,
9
+ ExtractSchemaValidateRequestDataSchemaZeroValue,
10
+ )
4
11
 
5
- __all__ = ["ExtractAgentCreateDataSchemaValue", "ExtractAgentUpdateDataSchemaValue"]
12
+ __all__ = [
13
+ "ExtractAgentCreateDataSchema",
14
+ "ExtractAgentCreateDataSchemaZeroValue",
15
+ "ExtractAgentUpdateDataSchema",
16
+ "ExtractAgentUpdateDataSchemaZeroValue",
17
+ "ExtractSchemaValidateRequestDataSchema",
18
+ "ExtractSchemaValidateRequestDataSchemaZeroValue",
19
+ ]