vellum-ai 0.14.5__py3-none-any.whl → 0.14.7__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 (68) hide show
  1. vellum/__init__.py +18 -0
  2. vellum/client/__init__.py +8 -8
  3. vellum/client/core/client_wrapper.py +1 -1
  4. vellum/client/resources/__init__.py +2 -0
  5. vellum/client/resources/workflow_sandboxes/__init__.py +3 -0
  6. vellum/client/resources/workflow_sandboxes/client.py +146 -0
  7. vellum/client/resources/workflow_sandboxes/types/__init__.py +5 -0
  8. vellum/client/resources/workflow_sandboxes/types/list_workflow_sandbox_examples_request_tag.py +5 -0
  9. vellum/client/types/__init__.py +16 -0
  10. vellum/client/types/array_chat_message_content_item.py +6 -1
  11. vellum/client/types/array_chat_message_content_item_request.py +2 -0
  12. vellum/client/types/chat_message_content.py +2 -0
  13. vellum/client/types/chat_message_content_request.py +2 -0
  14. vellum/client/types/document_chat_message_content.py +25 -0
  15. vellum/client/types/document_chat_message_content_request.py +25 -0
  16. vellum/client/types/document_vellum_value.py +25 -0
  17. vellum/client/types/document_vellum_value_request.py +25 -0
  18. vellum/client/types/paginated_workflow_sandbox_example_list.py +23 -0
  19. vellum/client/types/vellum_document.py +20 -0
  20. vellum/client/types/vellum_document_request.py +20 -0
  21. vellum/client/types/vellum_value.py +2 -0
  22. vellum/client/types/vellum_value_request.py +2 -0
  23. vellum/client/types/vellum_variable_type.py +1 -0
  24. vellum/client/types/workflow_sandbox_example.py +22 -0
  25. vellum/resources/workflow_sandboxes/types/__init__.py +3 -0
  26. vellum/resources/workflow_sandboxes/types/list_workflow_sandbox_examples_request_tag.py +3 -0
  27. vellum/types/document_chat_message_content.py +3 -0
  28. vellum/types/document_chat_message_content_request.py +3 -0
  29. vellum/types/document_vellum_value.py +3 -0
  30. vellum/types/document_vellum_value_request.py +3 -0
  31. vellum/types/paginated_workflow_sandbox_example_list.py +3 -0
  32. vellum/types/vellum_document.py +3 -0
  33. vellum/types/vellum_document_request.py +3 -0
  34. vellum/types/workflow_sandbox_example.py +3 -0
  35. vellum/workflows/exceptions.py +18 -0
  36. vellum/workflows/inputs/base.py +27 -1
  37. vellum/workflows/inputs/tests/__init__.py +0 -0
  38. vellum/workflows/inputs/tests/test_inputs.py +49 -0
  39. vellum/workflows/nodes/core/inline_subworkflow_node/node.py +1 -1
  40. vellum/workflows/nodes/core/map_node/node.py +7 -7
  41. vellum/workflows/nodes/core/try_node/node.py +1 -1
  42. vellum/workflows/nodes/displayable/bases/base_prompt_node/node.py +2 -2
  43. vellum/workflows/nodes/displayable/bases/inline_prompt_node/node.py +5 -3
  44. vellum/workflows/nodes/displayable/bases/prompt_deployment_node.py +5 -4
  45. vellum/workflows/nodes/displayable/inline_prompt_node/tests/test_node.py +4 -4
  46. vellum/workflows/nodes/displayable/subworkflow_deployment_node/node.py +49 -15
  47. vellum/workflows/nodes/displayable/subworkflow_deployment_node/tests/test_node.py +165 -0
  48. vellum/workflows/nodes/displayable/tests/test_text_prompt_deployment_node.py +3 -1
  49. vellum/workflows/outputs/base.py +1 -1
  50. vellum/workflows/runner/runner.py +16 -10
  51. vellum/workflows/state/context.py +7 -7
  52. vellum/workflows/workflows/base.py +61 -59
  53. vellum/workflows/workflows/tests/test_base_workflow.py +131 -40
  54. {vellum_ai-0.14.5.dist-info → vellum_ai-0.14.7.dist-info}/METADATA +1 -1
  55. {vellum_ai-0.14.5.dist-info → vellum_ai-0.14.7.dist-info}/RECORD +68 -44
  56. vellum_cli/__init__.py +36 -0
  57. vellum_cli/init.py +128 -0
  58. vellum_cli/pull.py +6 -3
  59. vellum_cli/tests/test_init.py +355 -0
  60. vellum_cli/tests/test_pull.py +127 -0
  61. vellum_ee/workflows/display/nodes/base_node_display.py +4 -4
  62. vellum_ee/workflows/display/nodes/vellum/tests/test_utils.py +31 -0
  63. vellum_ee/workflows/display/nodes/vellum/utils.py +8 -0
  64. vellum_ee/workflows/display/vellum.py +0 -4
  65. vellum_ee/workflows/display/workflows/tests/test_workflow_display.py +29 -0
  66. {vellum_ai-0.14.5.dist-info → vellum_ai-0.14.7.dist-info}/LICENSE +0 -0
  67. {vellum_ai-0.14.5.dist-info → vellum_ai-0.14.7.dist-info}/WHEEL +0 -0
  68. {vellum_ai-0.14.5.dist-info → vellum_ai-0.14.7.dist-info}/entry_points.txt +0 -0
vellum/__init__.py CHANGED
@@ -74,6 +74,8 @@ from .types import (
74
74
  DeploymentReleaseTagDeploymentHistoryItem,
75
75
  DeploymentReleaseTagRead,
76
76
  DockerServiceToken,
77
+ DocumentChatMessageContent,
78
+ DocumentChatMessageContentRequest,
77
79
  DocumentDocumentToDocumentIndex,
78
80
  DocumentIndexChunking,
79
81
  DocumentIndexChunkingRequest,
@@ -83,6 +85,8 @@ from .types import (
83
85
  DocumentProcessingState,
84
86
  DocumentRead,
85
87
  DocumentStatus,
88
+ DocumentVellumValue,
89
+ DocumentVellumValueRequest,
86
90
  EnrichedNormalizedCompletion,
87
91
  EntityStatus,
88
92
  EntityVisibility,
@@ -259,6 +263,7 @@ from .types import (
259
263
  PaginatedTestSuiteRunExecutionList,
260
264
  PaginatedTestSuiteTestCaseList,
261
265
  PaginatedWorkflowReleaseTagReadList,
266
+ PaginatedWorkflowSandboxExampleList,
262
267
  PdfSearchResultMetaSource,
263
268
  PdfSearchResultMetaSourceRequest,
264
269
  PlainTextPromptBlock,
@@ -437,6 +442,8 @@ from .types import (
437
442
  VariablePromptBlock,
438
443
  VellumAudio,
439
444
  VellumAudioRequest,
445
+ VellumDocument,
446
+ VellumDocumentRequest,
440
447
  VellumError,
441
448
  VellumErrorCodeEnum,
442
449
  VellumErrorRequest,
@@ -495,6 +502,7 @@ from .types import (
495
502
  WorkflowResultEventOutputDataNumber,
496
503
  WorkflowResultEventOutputDataSearchResults,
497
504
  WorkflowResultEventOutputDataString,
505
+ WorkflowSandboxExample,
498
506
  WorkflowStreamEvent,
499
507
  WorkspaceRead,
500
508
  WorkspaceSecretRead,
@@ -506,6 +514,7 @@ from .resources import (
506
514
  FolderEntitiesListRequestEntityStatus,
507
515
  ListDeploymentReleaseTagsRequestSource,
508
516
  ListWorkflowReleaseTagsRequestSource,
517
+ ListWorkflowSandboxExamplesRequestTag,
509
518
  WorkflowDeploymentsListRequestStatus,
510
519
  WorkflowsPullRequestFormat,
511
520
  ad_hoc,
@@ -604,6 +613,8 @@ __all__ = [
604
613
  "DeploymentReleaseTagRead",
605
614
  "DeploymentsListRequestStatus",
606
615
  "DockerServiceToken",
616
+ "DocumentChatMessageContent",
617
+ "DocumentChatMessageContentRequest",
607
618
  "DocumentDocumentToDocumentIndex",
608
619
  "DocumentIndexChunking",
609
620
  "DocumentIndexChunkingRequest",
@@ -614,6 +625,8 @@ __all__ = [
614
625
  "DocumentProcessingState",
615
626
  "DocumentRead",
616
627
  "DocumentStatus",
628
+ "DocumentVellumValue",
629
+ "DocumentVellumValueRequest",
617
630
  "EnrichedNormalizedCompletion",
618
631
  "EntityStatus",
619
632
  "EntityVisibility",
@@ -713,6 +726,7 @@ __all__ = [
713
726
  "JsonVellumValueRequest",
714
727
  "ListDeploymentReleaseTagsRequestSource",
715
728
  "ListWorkflowReleaseTagsRequestSource",
729
+ "ListWorkflowSandboxExamplesRequestTag",
716
730
  "LogicalOperator",
717
731
  "LogprobsEnum",
718
732
  "MapNodeResult",
@@ -796,6 +810,7 @@ __all__ = [
796
810
  "PaginatedTestSuiteRunExecutionList",
797
811
  "PaginatedTestSuiteTestCaseList",
798
812
  "PaginatedWorkflowReleaseTagReadList",
813
+ "PaginatedWorkflowSandboxExampleList",
799
814
  "PdfSearchResultMetaSource",
800
815
  "PdfSearchResultMetaSourceRequest",
801
816
  "PlainTextPromptBlock",
@@ -975,6 +990,8 @@ __all__ = [
975
990
  "Vellum",
976
991
  "VellumAudio",
977
992
  "VellumAudioRequest",
993
+ "VellumDocument",
994
+ "VellumDocumentRequest",
978
995
  "VellumEnvironment",
979
996
  "VellumError",
980
997
  "VellumErrorCodeEnum",
@@ -1035,6 +1052,7 @@ __all__ = [
1035
1052
  "WorkflowResultEventOutputDataNumber",
1036
1053
  "WorkflowResultEventOutputDataSearchResults",
1037
1054
  "WorkflowResultEventOutputDataString",
1055
+ "WorkflowSandboxExample",
1038
1056
  "WorkflowStreamEvent",
1039
1057
  "WorkflowsPullRequestFormat",
1040
1058
  "WorkspaceRead",
vellum/client/__init__.py CHANGED
@@ -360,7 +360,7 @@ class Vellum:
360
360
  Optionally specify a release tag if you want to pin to a specific release of the Prompt Deployment
361
361
 
362
362
  external_id : typing.Optional[str]
363
- Optionally include a unique identifier for tracking purposes. Must be unique within a given Prompt Deployment.
363
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
364
364
 
365
365
  expand_meta : typing.Optional[PromptDeploymentExpandMetaRequest]
366
366
  An optionally specified configuration used to opt in to including additional metadata about this prompt execution in the API response. Corresponding values will be returned under the `meta` key of the API response.
@@ -508,7 +508,7 @@ class Vellum:
508
508
  Optionally specify a release tag if you want to pin to a specific release of the Prompt Deployment
509
509
 
510
510
  external_id : typing.Optional[str]
511
- Optionally include a unique identifier for tracking purposes. Must be unique within a given Prompt Deployment.
511
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
512
512
 
513
513
  expand_meta : typing.Optional[PromptDeploymentExpandMetaRequest]
514
514
  An optionally specified configuration used to opt in to including additional metadata about this prompt execution in the API response. Corresponding values will be returned under the `meta` key of the API response.
@@ -667,7 +667,7 @@ class Vellum:
667
667
  Optionally specify a release tag if you want to pin to a specific release of the Workflow Deployment
668
668
 
669
669
  external_id : typing.Optional[str]
670
- Optionally include a unique identifier for tracking purposes. Must be unique for a given workflow deployment.
670
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
671
671
 
672
672
  metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
673
673
  Arbitrary JSON metadata associated with this request. Can be used to capture additional monitoring data such as user id, session id, etc. for future analysis.
@@ -794,7 +794,7 @@ class Vellum:
794
794
  Optionally specify a release tag if you want to pin to a specific release of the Workflow Deployment
795
795
 
796
796
  external_id : typing.Optional[str]
797
- Optionally include a unique identifier for tracking purposes. Must be unique for a given workflow deployment.
797
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
798
798
 
799
799
  event_types : typing.Optional[typing.Sequence[WorkflowExecutionEventType]]
800
800
  Optionally specify which events you want to receive. Defaults to only WORKFLOW events. Note that the schema of non-WORKFLOW events is unstable and should be used with caution.
@@ -1717,7 +1717,7 @@ class AsyncVellum:
1717
1717
  Optionally specify a release tag if you want to pin to a specific release of the Prompt Deployment
1718
1718
 
1719
1719
  external_id : typing.Optional[str]
1720
- Optionally include a unique identifier for tracking purposes. Must be unique within a given Prompt Deployment.
1720
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
1721
1721
 
1722
1722
  expand_meta : typing.Optional[PromptDeploymentExpandMetaRequest]
1723
1723
  An optionally specified configuration used to opt in to including additional metadata about this prompt execution in the API response. Corresponding values will be returned under the `meta` key of the API response.
@@ -1873,7 +1873,7 @@ class AsyncVellum:
1873
1873
  Optionally specify a release tag if you want to pin to a specific release of the Prompt Deployment
1874
1874
 
1875
1875
  external_id : typing.Optional[str]
1876
- Optionally include a unique identifier for tracking purposes. Must be unique within a given Prompt Deployment.
1876
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
1877
1877
 
1878
1878
  expand_meta : typing.Optional[PromptDeploymentExpandMetaRequest]
1879
1879
  An optionally specified configuration used to opt in to including additional metadata about this prompt execution in the API response. Corresponding values will be returned under the `meta` key of the API response.
@@ -2040,7 +2040,7 @@ class AsyncVellum:
2040
2040
  Optionally specify a release tag if you want to pin to a specific release of the Workflow Deployment
2041
2041
 
2042
2042
  external_id : typing.Optional[str]
2043
- Optionally include a unique identifier for tracking purposes. Must be unique for a given workflow deployment.
2043
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
2044
2044
 
2045
2045
  metadata : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
2046
2046
  Arbitrary JSON metadata associated with this request. Can be used to capture additional monitoring data such as user id, session id, etc. for future analysis.
@@ -2175,7 +2175,7 @@ class AsyncVellum:
2175
2175
  Optionally specify a release tag if you want to pin to a specific release of the Workflow Deployment
2176
2176
 
2177
2177
  external_id : typing.Optional[str]
2178
- Optionally include a unique identifier for tracking purposes. Must be unique for a given workflow deployment.
2178
+ Optionally include a unique identifier for tracking purposes. Must be unique within a given Workspace.
2179
2179
 
2180
2180
  event_types : typing.Optional[typing.Sequence[WorkflowExecutionEventType]]
2181
2181
  Optionally specify which events you want to receive. Defaults to only WORKFLOW events. Note that the schema of non-WORKFLOW events is unstable and should be used with caution.
@@ -18,7 +18,7 @@ class BaseClientWrapper:
18
18
  headers: typing.Dict[str, str] = {
19
19
  "X-Fern-Language": "Python",
20
20
  "X-Fern-SDK-Name": "vellum-ai",
21
- "X-Fern-SDK-Version": "0.14.5",
21
+ "X-Fern-SDK-Version": "0.14.7",
22
22
  }
23
23
  headers["X_API_KEY"] = self.api_key
24
24
  return headers
@@ -23,6 +23,7 @@ from .deployments import DeploymentsListRequestStatus, ListDeploymentReleaseTags
23
23
  from .document_indexes import DocumentIndexesListRequestStatus
24
24
  from .folder_entities import FolderEntitiesListRequestEntityStatus
25
25
  from .workflow_deployments import ListWorkflowReleaseTagsRequestSource, WorkflowDeploymentsListRequestStatus
26
+ from .workflow_sandboxes import ListWorkflowSandboxExamplesRequestTag
26
27
  from .workflows import WorkflowsPullRequestFormat
27
28
 
28
29
  __all__ = [
@@ -31,6 +32,7 @@ __all__ = [
31
32
  "FolderEntitiesListRequestEntityStatus",
32
33
  "ListDeploymentReleaseTagsRequestSource",
33
34
  "ListWorkflowReleaseTagsRequestSource",
35
+ "ListWorkflowSandboxExamplesRequestTag",
34
36
  "WorkflowDeploymentsListRequestStatus",
35
37
  "WorkflowsPullRequestFormat",
36
38
  "ad_hoc",
@@ -1,2 +1,5 @@
1
1
  # This file was auto-generated by Fern from our API Definition.
2
2
 
3
+ from .types import ListWorkflowSandboxExamplesRequestTag
4
+
5
+ __all__ = ["ListWorkflowSandboxExamplesRequestTag"]
@@ -8,6 +8,8 @@ from ...core.jsonable_encoder import jsonable_encoder
8
8
  from ...core.pydantic_utilities import parse_obj_as
9
9
  from json.decoder import JSONDecodeError
10
10
  from ...core.api_error import ApiError
11
+ from .types.list_workflow_sandbox_examples_request_tag import ListWorkflowSandboxExamplesRequestTag
12
+ from ...types.paginated_workflow_sandbox_example_list import PaginatedWorkflowSandboxExampleList
11
13
  from ...core.client_wrapper import AsyncClientWrapper
12
14
 
13
15
  # this is used as the default value for optional parameters
@@ -97,6 +99,74 @@ class WorkflowSandboxesClient:
97
99
  raise ApiError(status_code=_response.status_code, body=_response.text)
98
100
  raise ApiError(status_code=_response.status_code, body=_response_json)
99
101
 
102
+ def list_workflow_sandbox_examples(
103
+ self,
104
+ *,
105
+ limit: typing.Optional[int] = None,
106
+ offset: typing.Optional[int] = None,
107
+ ordering: typing.Optional[str] = None,
108
+ tag: typing.Optional[ListWorkflowSandboxExamplesRequestTag] = None,
109
+ request_options: typing.Optional[RequestOptions] = None,
110
+ ) -> PaginatedWorkflowSandboxExampleList:
111
+ """
112
+ List Workflow Sandbox examples that were previously cloned into the User's Workspace
113
+
114
+ Parameters
115
+ ----------
116
+ limit : typing.Optional[int]
117
+ Number of results to return per page.
118
+
119
+ offset : typing.Optional[int]
120
+ The initial index from which to return the results.
121
+
122
+ ordering : typing.Optional[str]
123
+ Which field to use when ordering the results.
124
+
125
+ tag : typing.Optional[ListWorkflowSandboxExamplesRequestTag]
126
+
127
+ request_options : typing.Optional[RequestOptions]
128
+ Request-specific configuration.
129
+
130
+ Returns
131
+ -------
132
+ PaginatedWorkflowSandboxExampleList
133
+
134
+
135
+ Examples
136
+ --------
137
+ from vellum import Vellum
138
+
139
+ client = Vellum(
140
+ api_key="YOUR_API_KEY",
141
+ )
142
+ client.workflow_sandboxes.list_workflow_sandbox_examples()
143
+ """
144
+ _response = self._client_wrapper.httpx_client.request(
145
+ "v1/workflow-sandboxes/examples",
146
+ base_url=self._client_wrapper.get_environment().default,
147
+ method="GET",
148
+ params={
149
+ "limit": limit,
150
+ "offset": offset,
151
+ "ordering": ordering,
152
+ "tag": tag,
153
+ },
154
+ request_options=request_options,
155
+ )
156
+ try:
157
+ if 200 <= _response.status_code < 300:
158
+ return typing.cast(
159
+ PaginatedWorkflowSandboxExampleList,
160
+ parse_obj_as(
161
+ type_=PaginatedWorkflowSandboxExampleList, # type: ignore
162
+ object_=_response.json(),
163
+ ),
164
+ )
165
+ _response_json = _response.json()
166
+ except JSONDecodeError:
167
+ raise ApiError(status_code=_response.status_code, body=_response.text)
168
+ raise ApiError(status_code=_response.status_code, body=_response_json)
169
+
100
170
 
101
171
  class AsyncWorkflowSandboxesClient:
102
172
  def __init__(self, *, client_wrapper: AsyncClientWrapper):
@@ -188,3 +258,79 @@ class AsyncWorkflowSandboxesClient:
188
258
  except JSONDecodeError:
189
259
  raise ApiError(status_code=_response.status_code, body=_response.text)
190
260
  raise ApiError(status_code=_response.status_code, body=_response_json)
261
+
262
+ async def list_workflow_sandbox_examples(
263
+ self,
264
+ *,
265
+ limit: typing.Optional[int] = None,
266
+ offset: typing.Optional[int] = None,
267
+ ordering: typing.Optional[str] = None,
268
+ tag: typing.Optional[ListWorkflowSandboxExamplesRequestTag] = None,
269
+ request_options: typing.Optional[RequestOptions] = None,
270
+ ) -> PaginatedWorkflowSandboxExampleList:
271
+ """
272
+ List Workflow Sandbox examples that were previously cloned into the User's Workspace
273
+
274
+ Parameters
275
+ ----------
276
+ limit : typing.Optional[int]
277
+ Number of results to return per page.
278
+
279
+ offset : typing.Optional[int]
280
+ The initial index from which to return the results.
281
+
282
+ ordering : typing.Optional[str]
283
+ Which field to use when ordering the results.
284
+
285
+ tag : typing.Optional[ListWorkflowSandboxExamplesRequestTag]
286
+
287
+ request_options : typing.Optional[RequestOptions]
288
+ Request-specific configuration.
289
+
290
+ Returns
291
+ -------
292
+ PaginatedWorkflowSandboxExampleList
293
+
294
+
295
+ Examples
296
+ --------
297
+ import asyncio
298
+
299
+ from vellum import AsyncVellum
300
+
301
+ client = AsyncVellum(
302
+ api_key="YOUR_API_KEY",
303
+ )
304
+
305
+
306
+ async def main() -> None:
307
+ await client.workflow_sandboxes.list_workflow_sandbox_examples()
308
+
309
+
310
+ asyncio.run(main())
311
+ """
312
+ _response = await self._client_wrapper.httpx_client.request(
313
+ "v1/workflow-sandboxes/examples",
314
+ base_url=self._client_wrapper.get_environment().default,
315
+ method="GET",
316
+ params={
317
+ "limit": limit,
318
+ "offset": offset,
319
+ "ordering": ordering,
320
+ "tag": tag,
321
+ },
322
+ request_options=request_options,
323
+ )
324
+ try:
325
+ if 200 <= _response.status_code < 300:
326
+ return typing.cast(
327
+ PaginatedWorkflowSandboxExampleList,
328
+ parse_obj_as(
329
+ type_=PaginatedWorkflowSandboxExampleList, # type: ignore
330
+ object_=_response.json(),
331
+ ),
332
+ )
333
+ _response_json = _response.json()
334
+ except JSONDecodeError:
335
+ raise ApiError(status_code=_response.status_code, body=_response.text)
336
+ raise ApiError(status_code=_response.status_code, body=_response_json)
@@ -0,0 +1,5 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from .list_workflow_sandbox_examples_request_tag import ListWorkflowSandboxExamplesRequestTag
4
+
5
+ __all__ = ["ListWorkflowSandboxExamplesRequestTag"]
@@ -0,0 +1,5 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ import typing
4
+
5
+ ListWorkflowSandboxExamplesRequestTag = typing.Union[typing.Literal["ONBOARDING", "TEMPLATES"], typing.Any]
@@ -78,6 +78,8 @@ from .deployment_read import DeploymentRead
78
78
  from .deployment_release_tag_deployment_history_item import DeploymentReleaseTagDeploymentHistoryItem
79
79
  from .deployment_release_tag_read import DeploymentReleaseTagRead
80
80
  from .docker_service_token import DockerServiceToken
81
+ from .document_chat_message_content import DocumentChatMessageContent
82
+ from .document_chat_message_content_request import DocumentChatMessageContentRequest
81
83
  from .document_document_to_document_index import DocumentDocumentToDocumentIndex
82
84
  from .document_index_chunking import DocumentIndexChunking
83
85
  from .document_index_chunking_request import DocumentIndexChunkingRequest
@@ -87,6 +89,8 @@ from .document_index_read import DocumentIndexRead
87
89
  from .document_processing_state import DocumentProcessingState
88
90
  from .document_read import DocumentRead
89
91
  from .document_status import DocumentStatus
92
+ from .document_vellum_value import DocumentVellumValue
93
+ from .document_vellum_value_request import DocumentVellumValueRequest
90
94
  from .enriched_normalized_completion import EnrichedNormalizedCompletion
91
95
  from .entity_status import EntityStatus
92
96
  from .entity_visibility import EntityVisibility
@@ -267,6 +271,7 @@ from .paginated_slim_workflow_deployment_list import PaginatedSlimWorkflowDeploy
267
271
  from .paginated_test_suite_run_execution_list import PaginatedTestSuiteRunExecutionList
268
272
  from .paginated_test_suite_test_case_list import PaginatedTestSuiteTestCaseList
269
273
  from .paginated_workflow_release_tag_read_list import PaginatedWorkflowReleaseTagReadList
274
+ from .paginated_workflow_sandbox_example_list import PaginatedWorkflowSandboxExampleList
270
275
  from .pdf_search_result_meta_source import PdfSearchResultMetaSource
271
276
  from .pdf_search_result_meta_source_request import PdfSearchResultMetaSourceRequest
272
277
  from .plain_text_prompt_block import PlainTextPromptBlock
@@ -461,6 +466,8 @@ from .upsert_test_suite_test_case_request import UpsertTestSuiteTestCaseRequest
461
466
  from .variable_prompt_block import VariablePromptBlock
462
467
  from .vellum_audio import VellumAudio
463
468
  from .vellum_audio_request import VellumAudioRequest
469
+ from .vellum_document import VellumDocument
470
+ from .vellum_document_request import VellumDocumentRequest
464
471
  from .vellum_error import VellumError
465
472
  from .vellum_error_code_enum import VellumErrorCodeEnum
466
473
  from .vellum_error_request import VellumErrorRequest
@@ -519,6 +526,7 @@ from .workflow_result_event_output_data_json import WorkflowResultEventOutputDat
519
526
  from .workflow_result_event_output_data_number import WorkflowResultEventOutputDataNumber
520
527
  from .workflow_result_event_output_data_search_results import WorkflowResultEventOutputDataSearchResults
521
528
  from .workflow_result_event_output_data_string import WorkflowResultEventOutputDataString
529
+ from .workflow_sandbox_example import WorkflowSandboxExample
522
530
  from .workflow_stream_event import WorkflowStreamEvent
523
531
  from .workspace_read import WorkspaceRead
524
532
  from .workspace_secret_read import WorkspaceSecretRead
@@ -594,6 +602,8 @@ __all__ = [
594
602
  "DeploymentReleaseTagDeploymentHistoryItem",
595
603
  "DeploymentReleaseTagRead",
596
604
  "DockerServiceToken",
605
+ "DocumentChatMessageContent",
606
+ "DocumentChatMessageContentRequest",
597
607
  "DocumentDocumentToDocumentIndex",
598
608
  "DocumentIndexChunking",
599
609
  "DocumentIndexChunkingRequest",
@@ -603,6 +613,8 @@ __all__ = [
603
613
  "DocumentProcessingState",
604
614
  "DocumentRead",
605
615
  "DocumentStatus",
616
+ "DocumentVellumValue",
617
+ "DocumentVellumValueRequest",
606
618
  "EnrichedNormalizedCompletion",
607
619
  "EntityStatus",
608
620
  "EntityVisibility",
@@ -779,6 +791,7 @@ __all__ = [
779
791
  "PaginatedTestSuiteRunExecutionList",
780
792
  "PaginatedTestSuiteTestCaseList",
781
793
  "PaginatedWorkflowReleaseTagReadList",
794
+ "PaginatedWorkflowSandboxExampleList",
782
795
  "PdfSearchResultMetaSource",
783
796
  "PdfSearchResultMetaSourceRequest",
784
797
  "PlainTextPromptBlock",
@@ -957,6 +970,8 @@ __all__ = [
957
970
  "VariablePromptBlock",
958
971
  "VellumAudio",
959
972
  "VellumAudioRequest",
973
+ "VellumDocument",
974
+ "VellumDocumentRequest",
960
975
  "VellumError",
961
976
  "VellumErrorCodeEnum",
962
977
  "VellumErrorRequest",
@@ -1015,6 +1030,7 @@ __all__ = [
1015
1030
  "WorkflowResultEventOutputDataNumber",
1016
1031
  "WorkflowResultEventOutputDataSearchResults",
1017
1032
  "WorkflowResultEventOutputDataString",
1033
+ "WorkflowSandboxExample",
1018
1034
  "WorkflowStreamEvent",
1019
1035
  "WorkspaceRead",
1020
1036
  "WorkspaceSecretRead",
@@ -5,7 +5,12 @@ from .string_chat_message_content import StringChatMessageContent
5
5
  from .function_call_chat_message_content import FunctionCallChatMessageContent
6
6
  from .image_chat_message_content import ImageChatMessageContent
7
7
  from .audio_chat_message_content import AudioChatMessageContent
8
+ from .document_chat_message_content import DocumentChatMessageContent
8
9
 
9
10
  ArrayChatMessageContentItem = typing.Union[
10
- StringChatMessageContent, FunctionCallChatMessageContent, ImageChatMessageContent, AudioChatMessageContent
11
+ StringChatMessageContent,
12
+ FunctionCallChatMessageContent,
13
+ ImageChatMessageContent,
14
+ AudioChatMessageContent,
15
+ DocumentChatMessageContent,
11
16
  ]
@@ -5,10 +5,12 @@ from .string_chat_message_content_request import StringChatMessageContentRequest
5
5
  from .function_call_chat_message_content_request import FunctionCallChatMessageContentRequest
6
6
  from .image_chat_message_content_request import ImageChatMessageContentRequest
7
7
  from .audio_chat_message_content_request import AudioChatMessageContentRequest
8
+ from .document_chat_message_content_request import DocumentChatMessageContentRequest
8
9
 
9
10
  ArrayChatMessageContentItemRequest = typing.Union[
10
11
  StringChatMessageContentRequest,
11
12
  FunctionCallChatMessageContentRequest,
12
13
  ImageChatMessageContentRequest,
13
14
  AudioChatMessageContentRequest,
15
+ DocumentChatMessageContentRequest,
14
16
  ]
@@ -6,6 +6,7 @@ from .function_call_chat_message_content import FunctionCallChatMessageContent
6
6
  from .array_chat_message_content import ArrayChatMessageContent
7
7
  from .image_chat_message_content import ImageChatMessageContent
8
8
  from .audio_chat_message_content import AudioChatMessageContent
9
+ from .document_chat_message_content import DocumentChatMessageContent
9
10
 
10
11
  ChatMessageContent = typing.Union[
11
12
  StringChatMessageContent,
@@ -13,4 +14,5 @@ ChatMessageContent = typing.Union[
13
14
  ArrayChatMessageContent,
14
15
  ImageChatMessageContent,
15
16
  AudioChatMessageContent,
17
+ DocumentChatMessageContent,
16
18
  ]
@@ -6,6 +6,7 @@ from .function_call_chat_message_content_request import FunctionCallChatMessageC
6
6
  from .array_chat_message_content_request import ArrayChatMessageContentRequest
7
7
  from .image_chat_message_content_request import ImageChatMessageContentRequest
8
8
  from .audio_chat_message_content_request import AudioChatMessageContentRequest
9
+ from .document_chat_message_content_request import DocumentChatMessageContentRequest
9
10
 
10
11
  ChatMessageContentRequest = typing.Union[
11
12
  StringChatMessageContentRequest,
@@ -13,4 +14,5 @@ ChatMessageContentRequest = typing.Union[
13
14
  ArrayChatMessageContentRequest,
14
15
  ImageChatMessageContentRequest,
15
16
  AudioChatMessageContentRequest,
17
+ DocumentChatMessageContentRequest,
16
18
  ]
@@ -0,0 +1,25 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.pydantic_utilities import UniversalBaseModel
4
+ import typing
5
+ from .vellum_document import VellumDocument
6
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
7
+ import pydantic
8
+
9
+
10
+ class DocumentChatMessageContent(UniversalBaseModel):
11
+ """
12
+ A document value that is used in a chat message.
13
+ """
14
+
15
+ type: typing.Literal["DOCUMENT"] = "DOCUMENT"
16
+ value: VellumDocument
17
+
18
+ if IS_PYDANTIC_V2:
19
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
20
+ else:
21
+
22
+ class Config:
23
+ frozen = True
24
+ smart_union = True
25
+ extra = pydantic.Extra.allow
@@ -0,0 +1,25 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.pydantic_utilities import UniversalBaseModel
4
+ import typing
5
+ from .vellum_document_request import VellumDocumentRequest
6
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
7
+ import pydantic
8
+
9
+
10
+ class DocumentChatMessageContentRequest(UniversalBaseModel):
11
+ """
12
+ A document value that is used in a chat message.
13
+ """
14
+
15
+ type: typing.Literal["DOCUMENT"] = "DOCUMENT"
16
+ value: VellumDocumentRequest
17
+
18
+ if IS_PYDANTIC_V2:
19
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
20
+ else:
21
+
22
+ class Config:
23
+ frozen = True
24
+ smart_union = True
25
+ extra = pydantic.Extra.allow
@@ -0,0 +1,25 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.pydantic_utilities import UniversalBaseModel
4
+ import typing
5
+ from .vellum_document import VellumDocument
6
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
7
+ import pydantic
8
+
9
+
10
+ class DocumentVellumValue(UniversalBaseModel):
11
+ """
12
+ A base Vellum primitive value representing a document.
13
+ """
14
+
15
+ type: typing.Literal["DOCUMENT"] = "DOCUMENT"
16
+ value: typing.Optional[VellumDocument] = None
17
+
18
+ if IS_PYDANTIC_V2:
19
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
20
+ else:
21
+
22
+ class Config:
23
+ frozen = True
24
+ smart_union = True
25
+ extra = pydantic.Extra.allow
@@ -0,0 +1,25 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.pydantic_utilities import UniversalBaseModel
4
+ import typing
5
+ from .vellum_document_request import VellumDocumentRequest
6
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
7
+ import pydantic
8
+
9
+
10
+ class DocumentVellumValueRequest(UniversalBaseModel):
11
+ """
12
+ A base Vellum primitive value representing a document.
13
+ """
14
+
15
+ type: typing.Literal["DOCUMENT"] = "DOCUMENT"
16
+ value: typing.Optional[VellumDocumentRequest] = None
17
+
18
+ if IS_PYDANTIC_V2:
19
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
20
+ else:
21
+
22
+ class Config:
23
+ frozen = True
24
+ smart_union = True
25
+ extra = pydantic.Extra.allow
@@ -0,0 +1,23 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.pydantic_utilities import UniversalBaseModel
4
+ import typing
5
+ from .workflow_sandbox_example import WorkflowSandboxExample
6
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
7
+ import pydantic
8
+
9
+
10
+ class PaginatedWorkflowSandboxExampleList(UniversalBaseModel):
11
+ count: typing.Optional[int] = None
12
+ next: typing.Optional[str] = None
13
+ previous: typing.Optional[str] = None
14
+ results: typing.Optional[typing.List[WorkflowSandboxExample]] = None
15
+
16
+ if IS_PYDANTIC_V2:
17
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
18
+ else:
19
+
20
+ class Config:
21
+ frozen = True
22
+ smart_union = True
23
+ extra = pydantic.Extra.allow
@@ -0,0 +1,20 @@
1
+ # This file was auto-generated by Fern from our API Definition.
2
+
3
+ from ..core.pydantic_utilities import UniversalBaseModel
4
+ import typing
5
+ from ..core.pydantic_utilities import IS_PYDANTIC_V2
6
+ import pydantic
7
+
8
+
9
+ class VellumDocument(UniversalBaseModel):
10
+ src: str
11
+ metadata: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
12
+
13
+ if IS_PYDANTIC_V2:
14
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
15
+ else:
16
+
17
+ class Config:
18
+ frozen = True
19
+ smart_union = True
20
+ extra = pydantic.Extra.allow