vellum-ai 0.9.16__py3-none-any.whl → 0.9.16rc4__py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (1339) hide show
  1. vellum/client/README.md +242 -0
  2. vellum/client/core/__init__.py +47 -0
  3. vellum/client/core/api_error.py +15 -0
  4. vellum/client/core/client_wrapper.py +59 -0
  5. vellum/client/core/datetime_utils.py +28 -0
  6. vellum/client/core/file.py +62 -0
  7. vellum/client/core/http_client.py +487 -0
  8. vellum/client/core/jsonable_encoder.py +101 -0
  9. vellum/client/core/pydantic_utilities.py +296 -0
  10. vellum/client/core/query_encoder.py +58 -0
  11. vellum/client/core/remove_none_from_dict.py +11 -0
  12. vellum/client/core/request_options.py +32 -0
  13. vellum/client/core/serialization.py +272 -0
  14. vellum/client/environment.py +17 -0
  15. vellum/client/errors/__init__.py +8 -0
  16. vellum/client/errors/bad_request_error.py +9 -0
  17. vellum/client/errors/forbidden_error.py +9 -0
  18. vellum/client/errors/internal_server_error.py +9 -0
  19. vellum/client/errors/not_found_error.py +9 -0
  20. vellum/client/resources/__init__.py +47 -0
  21. vellum/client/resources/ad_hoc/__init__.py +2 -0
  22. vellum/client/resources/ad_hoc/client.py +459 -0
  23. vellum/client/resources/container_images/__init__.py +2 -0
  24. vellum/client/resources/container_images/client.py +502 -0
  25. vellum/client/resources/deployments/__init__.py +5 -0
  26. vellum/client/resources/deployments/client.py +975 -0
  27. vellum/client/resources/deployments/types/__init__.py +6 -0
  28. vellum/client/resources/deployments/types/deployments_list_request_status.py +5 -0
  29. vellum/client/resources/deployments/types/list_deployment_release_tags_request_source.py +5 -0
  30. vellum/client/resources/document_indexes/__init__.py +5 -0
  31. vellum/client/resources/document_indexes/client.py +1154 -0
  32. vellum/client/resources/document_indexes/types/__init__.py +5 -0
  33. vellum/client/resources/document_indexes/types/document_indexes_list_request_status.py +5 -0
  34. vellum/client/resources/documents/__init__.py +2 -0
  35. vellum/client/resources/documents/client.py +781 -0
  36. vellum/client/resources/folder_entities/__init__.py +5 -0
  37. vellum/client/resources/folder_entities/client.py +333 -0
  38. vellum/client/resources/folder_entities/types/__init__.py +5 -0
  39. vellum/client/resources/folder_entities/types/folder_entities_list_request_entity_status.py +5 -0
  40. vellum/client/resources/metric_definitions/__init__.py +2 -0
  41. vellum/client/resources/metric_definitions/client.py +178 -0
  42. vellum/client/resources/sandboxes/__init__.py +2 -0
  43. vellum/client/resources/sandboxes/client.py +481 -0
  44. vellum/client/resources/test_suite_runs/__init__.py +2 -0
  45. vellum/client/resources/test_suite_runs/client.py +445 -0
  46. vellum/client/resources/test_suites/__init__.py +2 -0
  47. vellum/client/resources/test_suites/client.py +688 -0
  48. vellum/client/resources/workflow_deployments/__init__.py +5 -0
  49. vellum/client/resources/workflow_deployments/client.py +693 -0
  50. vellum/client/resources/workflow_deployments/types/__init__.py +6 -0
  51. vellum/client/resources/workflow_deployments/types/list_workflow_release_tags_request_source.py +5 -0
  52. vellum/client/resources/workflow_deployments/types/workflow_deployments_list_request_status.py +5 -0
  53. vellum/client/resources/workflow_sandboxes/__init__.py +2 -0
  54. vellum/client/resources/workflow_sandboxes/client.py +190 -0
  55. vellum/client/resources/workflows/__init__.py +5 -0
  56. vellum/client/resources/workflows/client.py +333 -0
  57. vellum/client/resources/workflows/types/__init__.py +5 -0
  58. vellum/client/resources/workflows/types/workflows_pull_request_format.py +5 -0
  59. vellum/client/resources/workspace_secrets/__init__.py +2 -0
  60. vellum/client/resources/workspace_secrets/client.py +266 -0
  61. vellum/client/types/__init__.py +979 -0
  62. vellum/client/types/ad_hoc_execute_prompt_event.py +14 -0
  63. vellum/client/types/ad_hoc_expand_meta.py +37 -0
  64. vellum/client/types/ad_hoc_fulfilled_prompt_execution_meta.py +27 -0
  65. vellum/client/types/ad_hoc_initiated_prompt_execution_meta.py +24 -0
  66. vellum/client/types/ad_hoc_rejected_prompt_execution_meta.py +25 -0
  67. vellum/client/types/ad_hoc_streaming_prompt_execution_meta.py +23 -0
  68. vellum/client/types/add_openai_api_key_enum.py +3 -0
  69. vellum/client/types/api_node_result.py +25 -0
  70. vellum/client/types/api_node_result_data.py +28 -0
  71. vellum/client/types/array_chat_message_content.py +25 -0
  72. vellum/client/types/array_chat_message_content_item.py +11 -0
  73. vellum/client/types/array_chat_message_content_item_request.py +14 -0
  74. vellum/client/types/array_chat_message_content_request.py +25 -0
  75. vellum/client/types/array_input.py +36 -0
  76. vellum/client/types/array_variable_value.py +27 -0
  77. vellum/client/types/array_variable_value_item.py +29 -0
  78. vellum/client/types/array_vellum_value.py +31 -0
  79. vellum/client/types/array_vellum_value_request.py +31 -0
  80. vellum/client/types/audio_chat_message_content.py +25 -0
  81. vellum/client/types/audio_chat_message_content_request.py +25 -0
  82. vellum/client/types/audio_variable_value.py +25 -0
  83. vellum/client/types/audio_vellum_value.py +25 -0
  84. vellum/client/types/audio_vellum_value_request.py +25 -0
  85. vellum/client/types/basic_vectorizer_intfloat_multilingual_e_5_large.py +24 -0
  86. vellum/client/types/basic_vectorizer_intfloat_multilingual_e_5_large_request.py +24 -0
  87. vellum/client/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_cos_v_1.py +26 -0
  88. vellum/client/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_cos_v_1_request.py +26 -0
  89. vellum/client/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_dot_v_1.py +26 -0
  90. vellum/client/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_dot_v_1_request.py +26 -0
  91. vellum/client/types/chat_history_input.py +30 -0
  92. vellum/client/types/chat_history_input_request.py +30 -0
  93. vellum/client/types/chat_history_variable_value.py +21 -0
  94. vellum/client/types/chat_history_vellum_value.py +25 -0
  95. vellum/client/types/chat_history_vellum_value_request.py +25 -0
  96. vellum/client/types/chat_message.py +27 -0
  97. vellum/client/types/chat_message_content.py +16 -0
  98. vellum/client/types/chat_message_content_request.py +16 -0
  99. vellum/client/types/chat_message_prompt_block.py +39 -0
  100. vellum/client/types/chat_message_request.py +27 -0
  101. vellum/client/types/chat_message_role.py +5 -0
  102. vellum/client/types/code_execution_node_array_result.py +28 -0
  103. vellum/client/types/code_execution_node_chat_history_result.py +22 -0
  104. vellum/client/types/code_execution_node_error_result.py +22 -0
  105. vellum/client/types/code_execution_node_function_call_result.py +22 -0
  106. vellum/client/types/code_execution_node_json_result.py +21 -0
  107. vellum/client/types/code_execution_node_number_result.py +21 -0
  108. vellum/client/types/code_execution_node_result.py +31 -0
  109. vellum/client/types/code_execution_node_result_data.py +27 -0
  110. vellum/client/types/code_execution_node_result_output.py +22 -0
  111. vellum/client/types/code_execution_node_search_results_result.py +22 -0
  112. vellum/client/types/code_execution_node_string_result.py +21 -0
  113. vellum/client/types/code_execution_package.py +20 -0
  114. vellum/client/types/code_execution_runtime.py +5 -0
  115. vellum/client/types/code_executor_input.py +24 -0
  116. vellum/client/types/code_executor_response.py +27 -0
  117. vellum/client/types/code_executor_secret_input.py +29 -0
  118. vellum/client/types/compile_prompt_deployment_expand_meta_request.py +32 -0
  119. vellum/client/types/compile_prompt_meta.py +25 -0
  120. vellum/client/types/components_schemas_pdf_search_result_meta_source.py +5 -0
  121. vellum/client/types/components_schemas_pdf_search_result_meta_source_request.py +5 -0
  122. vellum/client/types/condition_combinator.py +5 -0
  123. vellum/client/types/conditional_node_result.py +25 -0
  124. vellum/client/types/conditional_node_result_data.py +19 -0
  125. vellum/client/types/container_image_read.py +28 -0
  126. vellum/client/types/create_test_suite_test_case_request.py +48 -0
  127. vellum/client/types/deployment_provider_payload_response.py +22 -0
  128. vellum/client/types/deployment_provider_payload_response_payload.py +5 -0
  129. vellum/client/types/deployment_read.py +73 -0
  130. vellum/client/types/deployment_release_tag_deployment_history_item.py +21 -0
  131. vellum/client/types/deployment_release_tag_read.py +37 -0
  132. vellum/client/types/docker_service_token.py +21 -0
  133. vellum/client/types/document_document_to_document_index.py +39 -0
  134. vellum/client/types/document_index_chunking.py +8 -0
  135. vellum/client/types/document_index_chunking_request.py +10 -0
  136. vellum/client/types/document_index_indexing_config.py +22 -0
  137. vellum/client/types/document_index_indexing_config_request.py +22 -0
  138. vellum/client/types/document_index_read.py +52 -0
  139. vellum/client/types/document_processing_state.py +7 -0
  140. vellum/client/types/document_read.py +49 -0
  141. vellum/client/types/document_status.py +5 -0
  142. vellum/client/types/enriched_normalized_completion.py +59 -0
  143. vellum/client/types/entity_status.py +5 -0
  144. vellum/client/types/entity_visibility.py +5 -0
  145. vellum/client/types/environment_enum.py +5 -0
  146. vellum/client/types/ephemeral_prompt_cache_config.py +20 -0
  147. vellum/client/types/ephemeral_prompt_cache_config_type_enum.py +5 -0
  148. vellum/client/types/error_input.py +30 -0
  149. vellum/client/types/error_variable_value.py +21 -0
  150. vellum/client/types/error_vellum_value.py +25 -0
  151. vellum/client/types/error_vellum_value_request.py +25 -0
  152. vellum/client/types/execute_prompt_event.py +11 -0
  153. vellum/client/types/execute_prompt_response.py +7 -0
  154. vellum/client/types/execute_workflow_response.py +29 -0
  155. vellum/client/types/execute_workflow_workflow_result_event.py +9 -0
  156. vellum/client/types/execution_array_vellum_value.py +37 -0
  157. vellum/client/types/execution_chat_history_vellum_value.py +31 -0
  158. vellum/client/types/execution_error_vellum_value.py +31 -0
  159. vellum/client/types/execution_function_call_vellum_value.py +31 -0
  160. vellum/client/types/execution_json_vellum_value.py +30 -0
  161. vellum/client/types/execution_number_vellum_value.py +30 -0
  162. vellum/client/types/execution_search_results_vellum_value.py +31 -0
  163. vellum/client/types/execution_string_vellum_value.py +30 -0
  164. vellum/client/types/execution_vellum_value.py +22 -0
  165. vellum/client/types/external_test_case_execution.py +31 -0
  166. vellum/client/types/external_test_case_execution_request.py +31 -0
  167. vellum/client/types/finish_reason_enum.py +5 -0
  168. vellum/client/types/folder_entity.py +16 -0
  169. vellum/client/types/folder_entity_document_index.py +26 -0
  170. vellum/client/types/folder_entity_document_index_data.py +25 -0
  171. vellum/client/types/folder_entity_folder.py +26 -0
  172. vellum/client/types/folder_entity_folder_data.py +24 -0
  173. vellum/client/types/folder_entity_prompt_sandbox.py +26 -0
  174. vellum/client/types/folder_entity_prompt_sandbox_data.py +26 -0
  175. vellum/client/types/folder_entity_test_suite.py +26 -0
  176. vellum/client/types/folder_entity_test_suite_data.py +25 -0
  177. vellum/client/types/folder_entity_workflow_sandbox.py +26 -0
  178. vellum/client/types/folder_entity_workflow_sandbox_data.py +26 -0
  179. vellum/client/types/fulfilled_ad_hoc_execute_prompt_event.py +28 -0
  180. vellum/client/types/fulfilled_enum.py +5 -0
  181. vellum/client/types/fulfilled_execute_prompt_event.py +28 -0
  182. vellum/client/types/fulfilled_execute_prompt_response.py +37 -0
  183. vellum/client/types/fulfilled_execute_workflow_workflow_result_event.py +36 -0
  184. vellum/client/types/fulfilled_prompt_execution_meta.py +27 -0
  185. vellum/client/types/fulfilled_workflow_node_result_event.py +40 -0
  186. vellum/client/types/function_call.py +27 -0
  187. vellum/client/types/function_call_chat_message_content.py +25 -0
  188. vellum/client/types/function_call_chat_message_content_request.py +25 -0
  189. vellum/client/types/function_call_chat_message_content_value.py +25 -0
  190. vellum/client/types/function_call_chat_message_content_value_request.py +25 -0
  191. vellum/client/types/function_call_input.py +30 -0
  192. vellum/client/types/function_call_request.py +27 -0
  193. vellum/client/types/function_call_variable_value.py +21 -0
  194. vellum/client/types/function_call_vellum_value.py +25 -0
  195. vellum/client/types/function_call_vellum_value_request.py +25 -0
  196. vellum/client/types/function_definition.py +31 -0
  197. vellum/client/types/generate_options_request.py +26 -0
  198. vellum/client/types/generate_request.py +33 -0
  199. vellum/client/types/generate_response.py +38 -0
  200. vellum/client/types/generate_result.py +29 -0
  201. vellum/client/types/generate_result_data.py +23 -0
  202. vellum/client/types/generate_result_error.py +22 -0
  203. vellum/client/types/generate_stream_response.py +20 -0
  204. vellum/client/types/generate_stream_result.py +23 -0
  205. vellum/client/types/generate_stream_result_data.py +21 -0
  206. vellum/client/types/google_vertex_ai_vectorizer_config.py +20 -0
  207. vellum/client/types/google_vertex_ai_vectorizer_config_request.py +20 -0
  208. vellum/client/types/google_vertex_ai_vectorizer_text_embedding_004.py +21 -0
  209. vellum/client/types/google_vertex_ai_vectorizer_text_embedding_004_request.py +21 -0
  210. vellum/client/types/google_vertex_ai_vectorizer_text_multilingual_embedding_002.py +21 -0
  211. vellum/client/types/google_vertex_ai_vectorizer_text_multilingual_embedding_002_request.py +21 -0
  212. vellum/client/types/hkunlp_instructor_xl_vectorizer.py +25 -0
  213. vellum/client/types/hkunlp_instructor_xl_vectorizer_request.py +25 -0
  214. vellum/client/types/image_chat_message_content.py +25 -0
  215. vellum/client/types/image_chat_message_content_request.py +25 -0
  216. vellum/client/types/image_variable_value.py +25 -0
  217. vellum/client/types/image_vellum_value.py +25 -0
  218. vellum/client/types/image_vellum_value_request.py +25 -0
  219. vellum/client/types/indexing_config_vectorizer.py +30 -0
  220. vellum/client/types/indexing_config_vectorizer_request.py +30 -0
  221. vellum/client/types/indexing_state_enum.py +7 -0
  222. vellum/client/types/initiated_ad_hoc_execute_prompt_event.py +26 -0
  223. vellum/client/types/initiated_execute_prompt_event.py +26 -0
  224. vellum/client/types/initiated_prompt_execution_meta.py +26 -0
  225. vellum/client/types/initiated_workflow_node_result_event.py +39 -0
  226. vellum/client/types/instructor_vectorizer_config.py +25 -0
  227. vellum/client/types/instructor_vectorizer_config_request.py +25 -0
  228. vellum/client/types/iteration_state_enum.py +5 -0
  229. vellum/client/types/jinja_prompt_block.py +28 -0
  230. vellum/client/types/json_input.py +29 -0
  231. vellum/client/types/json_input_request.py +29 -0
  232. vellum/client/types/json_variable_value.py +20 -0
  233. vellum/client/types/json_vellum_value.py +24 -0
  234. vellum/client/types/json_vellum_value_request.py +24 -0
  235. vellum/client/types/logical_operator.py +29 -0
  236. vellum/client/types/logprobs_enum.py +5 -0
  237. vellum/client/types/map_node_result.py +25 -0
  238. vellum/client/types/map_node_result_data.py +21 -0
  239. vellum/client/types/merge_node_result.py +25 -0
  240. vellum/client/types/merge_node_result_data.py +19 -0
  241. vellum/client/types/metadata_filter_config_request.py +36 -0
  242. vellum/client/types/metadata_filter_rule_combinator.py +5 -0
  243. vellum/client/types/metadata_filter_rule_request.py +31 -0
  244. vellum/client/types/metadata_filters_request.py +7 -0
  245. vellum/client/types/metric_definition_execution.py +20 -0
  246. vellum/client/types/metric_definition_input.py +9 -0
  247. vellum/client/types/metric_node_result.py +23 -0
  248. vellum/client/types/ml_model_usage.py +25 -0
  249. vellum/client/types/named_scenario_input_chat_history_variable_value_request.py +26 -0
  250. vellum/client/types/named_scenario_input_json_variable_value_request.py +25 -0
  251. vellum/client/types/named_scenario_input_request.py +12 -0
  252. vellum/client/types/named_scenario_input_string_variable_value_request.py +25 -0
  253. vellum/client/types/named_test_case_array_variable_value.py +32 -0
  254. vellum/client/types/named_test_case_array_variable_value_request.py +34 -0
  255. vellum/client/types/named_test_case_chat_history_variable_value.py +26 -0
  256. vellum/client/types/named_test_case_chat_history_variable_value_request.py +26 -0
  257. vellum/client/types/named_test_case_error_variable_value.py +26 -0
  258. vellum/client/types/named_test_case_error_variable_value_request.py +26 -0
  259. vellum/client/types/named_test_case_function_call_variable_value.py +26 -0
  260. vellum/client/types/named_test_case_function_call_variable_value_request.py +26 -0
  261. vellum/client/types/named_test_case_json_variable_value.py +25 -0
  262. vellum/client/types/named_test_case_json_variable_value_request.py +25 -0
  263. vellum/client/types/named_test_case_number_variable_value.py +25 -0
  264. vellum/client/types/named_test_case_number_variable_value_request.py +25 -0
  265. vellum/client/types/named_test_case_search_results_variable_value.py +26 -0
  266. vellum/client/types/named_test_case_search_results_variable_value_request.py +26 -0
  267. vellum/client/types/named_test_case_string_variable_value.py +25 -0
  268. vellum/client/types/named_test_case_string_variable_value_request.py +25 -0
  269. vellum/client/types/named_test_case_variable_value.py +22 -0
  270. vellum/client/types/named_test_case_variable_value_request.py +22 -0
  271. vellum/client/types/node_input_compiled_array_value.py +29 -0
  272. vellum/client/types/node_input_compiled_chat_history_value.py +23 -0
  273. vellum/client/types/node_input_compiled_error_value.py +23 -0
  274. vellum/client/types/node_input_compiled_function_call_value.py +23 -0
  275. vellum/client/types/node_input_compiled_json_value.py +22 -0
  276. vellum/client/types/node_input_compiled_number_value.py +22 -0
  277. vellum/client/types/node_input_compiled_search_results_value.py +23 -0
  278. vellum/client/types/node_input_compiled_string_value.py +22 -0
  279. vellum/client/types/node_input_variable_compiled_value.py +22 -0
  280. vellum/client/types/node_output_compiled_array_value.py +34 -0
  281. vellum/client/types/node_output_compiled_chat_history_value.py +28 -0
  282. vellum/client/types/node_output_compiled_error_value.py +28 -0
  283. vellum/client/types/node_output_compiled_function_call_value.py +28 -0
  284. vellum/client/types/node_output_compiled_json_value.py +27 -0
  285. vellum/client/types/node_output_compiled_number_value.py +27 -0
  286. vellum/client/types/node_output_compiled_search_results_value.py +28 -0
  287. vellum/client/types/node_output_compiled_string_value.py +27 -0
  288. vellum/client/types/node_output_compiled_value.py +22 -0
  289. vellum/client/types/normalized_log_probs.py +21 -0
  290. vellum/client/types/normalized_token_log_probs.py +22 -0
  291. vellum/client/types/number_input.py +29 -0
  292. vellum/client/types/number_variable_value.py +20 -0
  293. vellum/client/types/number_vellum_value.py +24 -0
  294. vellum/client/types/number_vellum_value_request.py +24 -0
  295. vellum/client/types/open_ai_vectorizer_config.py +24 -0
  296. vellum/client/types/open_ai_vectorizer_config_request.py +24 -0
  297. vellum/client/types/open_ai_vectorizer_text_embedding_3_large.py +25 -0
  298. vellum/client/types/open_ai_vectorizer_text_embedding_3_large_request.py +25 -0
  299. vellum/client/types/open_ai_vectorizer_text_embedding_3_small.py +25 -0
  300. vellum/client/types/open_ai_vectorizer_text_embedding_3_small_request.py +25 -0
  301. vellum/client/types/open_ai_vectorizer_text_embedding_ada_002.py +25 -0
  302. vellum/client/types/open_ai_vectorizer_text_embedding_ada_002_request.py +25 -0
  303. vellum/client/types/paginated_container_image_read_list.py +23 -0
  304. vellum/client/types/paginated_deployment_release_tag_read_list.py +23 -0
  305. vellum/client/types/paginated_document_index_read_list.py +23 -0
  306. vellum/client/types/paginated_folder_entity_list.py +23 -0
  307. vellum/client/types/paginated_slim_deployment_read_list.py +29 -0
  308. vellum/client/types/paginated_slim_document_list.py +23 -0
  309. vellum/client/types/paginated_slim_workflow_deployment_list.py +29 -0
  310. vellum/client/types/paginated_test_suite_run_execution_list.py +29 -0
  311. vellum/client/types/paginated_test_suite_test_case_list.py +29 -0
  312. vellum/client/types/paginated_workflow_release_tag_read_list.py +23 -0
  313. vellum/client/types/pdf_search_result_meta_source.py +32 -0
  314. vellum/client/types/pdf_search_result_meta_source_request.py +32 -0
  315. vellum/client/types/plain_text_prompt_block.py +28 -0
  316. vellum/client/types/price.py +21 -0
  317. vellum/client/types/processing_failure_reason_enum.py +5 -0
  318. vellum/client/types/prompt_block.py +12 -0
  319. vellum/client/types/prompt_block_state.py +5 -0
  320. vellum/client/types/prompt_deployment_expand_meta_request.py +52 -0
  321. vellum/client/types/prompt_deployment_input_request.py +8 -0
  322. vellum/client/types/prompt_execution_meta.py +32 -0
  323. vellum/client/types/prompt_node_execution_meta.py +24 -0
  324. vellum/client/types/prompt_node_result.py +25 -0
  325. vellum/client/types/prompt_node_result_data.py +25 -0
  326. vellum/client/types/prompt_output.py +9 -0
  327. vellum/client/types/prompt_parameters.py +27 -0
  328. vellum/client/types/prompt_request_chat_history_input.py +26 -0
  329. vellum/client/types/prompt_request_input.py +8 -0
  330. vellum/client/types/prompt_request_json_input.py +25 -0
  331. vellum/client/types/prompt_request_string_input.py +25 -0
  332. vellum/client/types/prompt_settings.py +19 -0
  333. vellum/client/types/raw_prompt_execution_overrides_request.py +28 -0
  334. vellum/client/types/reducto_chunker_config.py +23 -0
  335. vellum/client/types/reducto_chunker_config_request.py +23 -0
  336. vellum/client/types/reducto_chunking.py +25 -0
  337. vellum/client/types/reducto_chunking_request.py +25 -0
  338. vellum/client/types/rejected_ad_hoc_execute_prompt_event.py +28 -0
  339. vellum/client/types/rejected_execute_prompt_event.py +28 -0
  340. vellum/client/types/rejected_execute_prompt_response.py +37 -0
  341. vellum/client/types/rejected_execute_workflow_workflow_result_event.py +28 -0
  342. vellum/client/types/rejected_prompt_execution_meta.py +25 -0
  343. vellum/client/types/rejected_workflow_node_result_event.py +39 -0
  344. vellum/client/types/release_tag_source.py +5 -0
  345. vellum/client/types/replace_test_suite_test_case_request.py +53 -0
  346. vellum/client/types/rich_text_child_block.py +7 -0
  347. vellum/client/types/rich_text_prompt_block.py +29 -0
  348. vellum/client/types/sandbox_scenario.py +33 -0
  349. vellum/client/types/scenario_input.py +10 -0
  350. vellum/client/types/scenario_input_chat_history_variable_value.py +26 -0
  351. vellum/client/types/scenario_input_json_variable_value.py +25 -0
  352. vellum/client/types/scenario_input_string_variable_value.py +25 -0
  353. vellum/client/types/search_filters_request.py +38 -0
  354. vellum/client/types/search_node_result.py +25 -0
  355. vellum/client/types/search_node_result_data.py +27 -0
  356. vellum/client/types/search_request_options_request.py +50 -0
  357. vellum/client/types/search_response.py +23 -0
  358. vellum/client/types/search_result.py +40 -0
  359. vellum/client/types/search_result_document.py +37 -0
  360. vellum/client/types/search_result_document_request.py +37 -0
  361. vellum/client/types/search_result_merging_request.py +22 -0
  362. vellum/client/types/search_result_meta.py +20 -0
  363. vellum/client/types/search_result_meta_request.py +20 -0
  364. vellum/client/types/search_result_request.py +40 -0
  365. vellum/client/types/search_results_input.py +30 -0
  366. vellum/client/types/search_results_variable_value.py +21 -0
  367. vellum/client/types/search_results_vellum_value.py +25 -0
  368. vellum/client/types/search_results_vellum_value_request.py +25 -0
  369. vellum/client/types/search_weights_request.py +27 -0
  370. vellum/client/types/secret_type_enum.py +5 -0
  371. vellum/client/types/sentence_chunker_config.py +24 -0
  372. vellum/client/types/sentence_chunker_config_request.py +24 -0
  373. vellum/client/types/sentence_chunking.py +25 -0
  374. vellum/client/types/sentence_chunking_request.py +25 -0
  375. vellum/client/types/slim_deployment_read.py +63 -0
  376. vellum/client/types/slim_document.py +70 -0
  377. vellum/client/types/slim_workflow_deployment.py +72 -0
  378. vellum/client/types/streaming_ad_hoc_execute_prompt_event.py +33 -0
  379. vellum/client/types/streaming_execute_prompt_event.py +33 -0
  380. vellum/client/types/streaming_prompt_execution_meta.py +23 -0
  381. vellum/client/types/streaming_workflow_node_result_event.py +40 -0
  382. vellum/client/types/string_chat_message_content.py +24 -0
  383. vellum/client/types/string_chat_message_content_request.py +24 -0
  384. vellum/client/types/string_input.py +29 -0
  385. vellum/client/types/string_input_request.py +29 -0
  386. vellum/client/types/string_variable_value.py +20 -0
  387. vellum/client/types/string_vellum_value.py +24 -0
  388. vellum/client/types/string_vellum_value_request.py +24 -0
  389. vellum/client/types/submit_completion_actual_request.py +48 -0
  390. vellum/client/types/submit_workflow_execution_actual_request.py +10 -0
  391. vellum/client/types/subworkflow_node_result.py +25 -0
  392. vellum/client/types/subworkflow_node_result_data.py +19 -0
  393. vellum/client/types/templating_node_array_result.py +28 -0
  394. vellum/client/types/templating_node_chat_history_result.py +22 -0
  395. vellum/client/types/templating_node_error_result.py +22 -0
  396. vellum/client/types/templating_node_function_call_result.py +22 -0
  397. vellum/client/types/templating_node_json_result.py +21 -0
  398. vellum/client/types/templating_node_number_result.py +21 -0
  399. vellum/client/types/templating_node_result.py +31 -0
  400. vellum/client/types/templating_node_result_data.py +26 -0
  401. vellum/client/types/templating_node_result_output.py +22 -0
  402. vellum/client/types/templating_node_search_results_result.py +22 -0
  403. vellum/client/types/templating_node_string_result.py +21 -0
  404. vellum/client/types/terminal_node_array_result.py +33 -0
  405. vellum/client/types/terminal_node_chat_history_result.py +27 -0
  406. vellum/client/types/terminal_node_error_result.py +27 -0
  407. vellum/client/types/terminal_node_function_call_result.py +27 -0
  408. vellum/client/types/terminal_node_json_result.py +26 -0
  409. vellum/client/types/terminal_node_number_result.py +26 -0
  410. vellum/client/types/terminal_node_result.py +31 -0
  411. vellum/client/types/terminal_node_result_data.py +26 -0
  412. vellum/client/types/terminal_node_result_output.py +22 -0
  413. vellum/client/types/terminal_node_search_results_result.py +27 -0
  414. vellum/client/types/terminal_node_string_result.py +26 -0
  415. vellum/client/types/test_case_array_variable_value.py +33 -0
  416. vellum/client/types/test_case_chat_history_variable_value.py +27 -0
  417. vellum/client/types/test_case_error_variable_value.py +27 -0
  418. vellum/client/types/test_case_function_call_variable_value.py +27 -0
  419. vellum/client/types/test_case_json_variable_value.py +26 -0
  420. vellum/client/types/test_case_number_variable_value.py +26 -0
  421. vellum/client/types/test_case_search_results_variable_value.py +27 -0
  422. vellum/client/types/test_case_string_variable_value.py +26 -0
  423. vellum/client/types/test_case_variable_value.py +22 -0
  424. vellum/client/types/test_suite_run_deployment_release_tag_exec_config.py +29 -0
  425. vellum/client/types/test_suite_run_deployment_release_tag_exec_config_data.py +27 -0
  426. vellum/client/types/test_suite_run_deployment_release_tag_exec_config_data_request.py +27 -0
  427. vellum/client/types/test_suite_run_deployment_release_tag_exec_config_request.py +31 -0
  428. vellum/client/types/test_suite_run_exec_config.py +10 -0
  429. vellum/client/types/test_suite_run_exec_config_request.py +12 -0
  430. vellum/client/types/test_suite_run_execution.py +30 -0
  431. vellum/client/types/test_suite_run_execution_array_output.py +33 -0
  432. vellum/client/types/test_suite_run_execution_chat_history_output.py +27 -0
  433. vellum/client/types/test_suite_run_execution_error_output.py +27 -0
  434. vellum/client/types/test_suite_run_execution_function_call_output.py +27 -0
  435. vellum/client/types/test_suite_run_execution_json_output.py +26 -0
  436. vellum/client/types/test_suite_run_execution_metric_definition.py +21 -0
  437. vellum/client/types/test_suite_run_execution_metric_result.py +24 -0
  438. vellum/client/types/test_suite_run_execution_number_output.py +26 -0
  439. vellum/client/types/test_suite_run_execution_output.py +22 -0
  440. vellum/client/types/test_suite_run_execution_search_results_output.py +27 -0
  441. vellum/client/types/test_suite_run_execution_string_output.py +26 -0
  442. vellum/client/types/test_suite_run_external_exec_config.py +36 -0
  443. vellum/client/types/test_suite_run_external_exec_config_data.py +29 -0
  444. vellum/client/types/test_suite_run_external_exec_config_data_request.py +31 -0
  445. vellum/client/types/test_suite_run_external_exec_config_request.py +38 -0
  446. vellum/client/types/test_suite_run_metric_error_output.py +26 -0
  447. vellum/client/types/test_suite_run_metric_json_output.py +25 -0
  448. vellum/client/types/test_suite_run_metric_number_output.py +25 -0
  449. vellum/client/types/test_suite_run_metric_output.py +14 -0
  450. vellum/client/types/test_suite_run_metric_string_output.py +25 -0
  451. vellum/client/types/test_suite_run_read.py +46 -0
  452. vellum/client/types/test_suite_run_state.py +5 -0
  453. vellum/client/types/test_suite_run_test_suite.py +21 -0
  454. vellum/client/types/test_suite_run_workflow_release_tag_exec_config.py +29 -0
  455. vellum/client/types/test_suite_run_workflow_release_tag_exec_config_data.py +27 -0
  456. vellum/client/types/test_suite_run_workflow_release_tag_exec_config_data_request.py +27 -0
  457. vellum/client/types/test_suite_run_workflow_release_tag_exec_config_request.py +31 -0
  458. vellum/client/types/test_suite_test_case.py +30 -0
  459. vellum/client/types/test_suite_test_case_bulk_operation_request.py +14 -0
  460. vellum/client/types/test_suite_test_case_bulk_result.py +14 -0
  461. vellum/client/types/test_suite_test_case_create_bulk_operation_request.py +38 -0
  462. vellum/client/types/test_suite_test_case_created_bulk_result.py +26 -0
  463. vellum/client/types/test_suite_test_case_created_bulk_result_data.py +23 -0
  464. vellum/client/types/test_suite_test_case_delete_bulk_operation_data_request.py +19 -0
  465. vellum/client/types/test_suite_test_case_delete_bulk_operation_request.py +33 -0
  466. vellum/client/types/test_suite_test_case_deleted_bulk_result.py +30 -0
  467. vellum/client/types/test_suite_test_case_deleted_bulk_result_data.py +23 -0
  468. vellum/client/types/test_suite_test_case_rejected_bulk_result.py +32 -0
  469. vellum/client/types/test_suite_test_case_replace_bulk_operation_request.py +38 -0
  470. vellum/client/types/test_suite_test_case_replaced_bulk_result.py +30 -0
  471. vellum/client/types/test_suite_test_case_replaced_bulk_result_data.py +23 -0
  472. vellum/client/types/test_suite_test_case_upsert_bulk_operation_request.py +38 -0
  473. vellum/client/types/token_overlapping_window_chunker_config.py +24 -0
  474. vellum/client/types/token_overlapping_window_chunker_config_request.py +24 -0
  475. vellum/client/types/token_overlapping_window_chunking.py +25 -0
  476. vellum/client/types/token_overlapping_window_chunking_request.py +25 -0
  477. vellum/client/types/unit_enum.py +5 -0
  478. vellum/client/types/upload_document_response.py +22 -0
  479. vellum/client/types/upsert_test_suite_test_case_request.py +49 -0
  480. vellum/client/types/variable_prompt_block.py +28 -0
  481. vellum/client/types/vellum_audio.py +24 -0
  482. vellum/client/types/vellum_audio_request.py +24 -0
  483. vellum/client/types/vellum_error.py +21 -0
  484. vellum/client/types/vellum_error_code_enum.py +15 -0
  485. vellum/client/types/vellum_error_request.py +21 -0
  486. vellum/client/types/vellum_image.py +20 -0
  487. vellum/client/types/vellum_image_request.py +20 -0
  488. vellum/client/types/vellum_value.py +29 -0
  489. vellum/client/types/vellum_value_logical_condition_group_request.py +38 -0
  490. vellum/client/types/vellum_value_logical_condition_request.py +34 -0
  491. vellum/client/types/vellum_value_logical_expression_request.py +12 -0
  492. vellum/client/types/vellum_value_request.py +29 -0
  493. vellum/client/types/vellum_variable.py +33 -0
  494. vellum/client/types/vellum_variable_extensions.py +23 -0
  495. vellum/client/types/vellum_variable_type.py +20 -0
  496. vellum/client/types/workflow_deployment_read.py +77 -0
  497. vellum/client/types/workflow_event_error.py +21 -0
  498. vellum/client/types/workflow_execution_actual_chat_history_request.py +49 -0
  499. vellum/client/types/workflow_execution_actual_json_request.py +48 -0
  500. vellum/client/types/workflow_execution_actual_string_request.py +48 -0
  501. vellum/client/types/workflow_execution_event_error_code.py +17 -0
  502. vellum/client/types/workflow_execution_event_type.py +5 -0
  503. vellum/client/types/workflow_execution_node_result_event.py +34 -0
  504. vellum/client/types/workflow_execution_workflow_result_event.py +36 -0
  505. vellum/client/types/workflow_expand_meta_request.py +22 -0
  506. vellum/client/types/workflow_node_result_data.py +28 -0
  507. vellum/client/types/workflow_node_result_event.py +14 -0
  508. vellum/client/types/workflow_node_result_event_state.py +7 -0
  509. vellum/client/types/workflow_output.py +24 -0
  510. vellum/client/types/workflow_output_array.py +37 -0
  511. vellum/client/types/workflow_output_chat_history.py +31 -0
  512. vellum/client/types/workflow_output_error.py +31 -0
  513. vellum/client/types/workflow_output_function_call.py +31 -0
  514. vellum/client/types/workflow_output_image.py +31 -0
  515. vellum/client/types/workflow_output_json.py +30 -0
  516. vellum/client/types/workflow_output_number.py +30 -0
  517. vellum/client/types/workflow_output_search_results.py +31 -0
  518. vellum/client/types/workflow_output_string.py +30 -0
  519. vellum/client/types/workflow_push_deployment_config_request.py +22 -0
  520. vellum/client/types/workflow_push_exec_config.py +3 -0
  521. vellum/client/types/workflow_push_response.py +20 -0
  522. vellum/client/types/workflow_release_tag_read.py +37 -0
  523. vellum/client/types/workflow_release_tag_workflow_deployment_history_item.py +28 -0
  524. vellum/client/types/workflow_request_chat_history_input_request.py +30 -0
  525. vellum/client/types/workflow_request_input_request.py +14 -0
  526. vellum/client/types/workflow_request_json_input_request.py +29 -0
  527. vellum/client/types/workflow_request_number_input_request.py +29 -0
  528. vellum/client/types/workflow_request_string_input_request.py +29 -0
  529. vellum/client/types/workflow_result_event.py +39 -0
  530. vellum/client/types/workflow_result_event_output_data.py +22 -0
  531. vellum/client/types/workflow_result_event_output_data_array.py +41 -0
  532. vellum/client/types/workflow_result_event_output_data_chat_history.py +35 -0
  533. vellum/client/types/workflow_result_event_output_data_error.py +35 -0
  534. vellum/client/types/workflow_result_event_output_data_function_call.py +35 -0
  535. vellum/client/types/workflow_result_event_output_data_json.py +34 -0
  536. vellum/client/types/workflow_result_event_output_data_number.py +34 -0
  537. vellum/client/types/workflow_result_event_output_data_search_results.py +35 -0
  538. vellum/client/types/workflow_result_event_output_data_string.py +37 -0
  539. vellum/client/types/workflow_stream_event.py +7 -0
  540. vellum/client/types/workspace_secret_read.py +25 -0
  541. vellum/core/__init__.py +2 -46
  542. vellum/core/api_error.py +2 -14
  543. vellum/core/client_wrapper.py +2 -58
  544. vellum/core/datetime_utils.py +2 -27
  545. vellum/core/file.py +2 -61
  546. vellum/core/http_client.py +2 -486
  547. vellum/core/jsonable_encoder.py +2 -100
  548. vellum/core/pydantic_utilities.py +2 -295
  549. vellum/core/query_encoder.py +2 -57
  550. vellum/core/remove_none_from_dict.py +2 -10
  551. vellum/core/request_options.py +2 -31
  552. vellum/core/serialization.py +2 -271
  553. vellum/environment.py +2 -16
  554. vellum/errors/__init__.py +2 -7
  555. vellum/errors/bad_request_error.py +2 -8
  556. vellum/errors/forbidden_error.py +2 -8
  557. vellum/errors/internal_server_error.py +2 -8
  558. vellum/errors/not_found_error.py +2 -8
  559. vellum/{lib/test_suites → evaluations}/resources.py +20 -51
  560. vellum/plugins/__init__.py +0 -0
  561. vellum/plugins/pydantic.py +74 -0
  562. vellum/plugins/utils.py +19 -0
  563. vellum/plugins/vellum_mypy.py +647 -0
  564. vellum/resources/__init__.py +2 -46
  565. vellum/resources/ad_hoc/__init__.py +2 -1
  566. vellum/resources/ad_hoc/client.py +2 -458
  567. vellum/resources/container_images/__init__.py +2 -1
  568. vellum/resources/container_images/client.py +2 -501
  569. vellum/resources/deployments/__init__.py +2 -4
  570. vellum/resources/deployments/client.py +2 -974
  571. vellum/resources/deployments/types/__init__.py +2 -5
  572. vellum/resources/deployments/types/deployments_list_request_status.py +2 -4
  573. vellum/resources/deployments/types/list_deployment_release_tags_request_source.py +2 -4
  574. vellum/resources/document_indexes/__init__.py +2 -4
  575. vellum/resources/document_indexes/client.py +2 -1153
  576. vellum/resources/document_indexes/types/__init__.py +2 -4
  577. vellum/resources/document_indexes/types/document_indexes_list_request_status.py +2 -4
  578. vellum/resources/documents/__init__.py +2 -1
  579. vellum/resources/documents/client.py +2 -780
  580. vellum/resources/folder_entities/__init__.py +2 -4
  581. vellum/resources/folder_entities/client.py +2 -332
  582. vellum/resources/folder_entities/types/__init__.py +2 -4
  583. vellum/resources/folder_entities/types/folder_entities_list_request_entity_status.py +2 -4
  584. vellum/resources/metric_definitions/__init__.py +2 -1
  585. vellum/resources/metric_definitions/client.py +2 -177
  586. vellum/resources/sandboxes/__init__.py +2 -1
  587. vellum/resources/sandboxes/client.py +2 -480
  588. vellum/resources/test_suite_runs/__init__.py +2 -1
  589. vellum/resources/test_suite_runs/client.py +2 -444
  590. vellum/resources/test_suites/__init__.py +2 -1
  591. vellum/resources/test_suites/client.py +2 -687
  592. vellum/resources/workflow_deployments/__init__.py +2 -4
  593. vellum/resources/workflow_deployments/client.py +2 -692
  594. vellum/resources/workflow_deployments/types/__init__.py +2 -5
  595. vellum/resources/workflow_deployments/types/list_workflow_release_tags_request_source.py +2 -4
  596. vellum/resources/workflow_deployments/types/workflow_deployments_list_request_status.py +2 -4
  597. vellum/resources/workflow_sandboxes/__init__.py +2 -1
  598. vellum/resources/workflow_sandboxes/client.py +2 -189
  599. vellum/resources/workflows/__init__.py +2 -4
  600. vellum/resources/workflows/client.py +2 -332
  601. vellum/resources/workflows/types/__init__.py +2 -4
  602. vellum/resources/workflows/types/workflows_pull_request_format.py +2 -4
  603. vellum/resources/workspace_secrets/__init__.py +2 -1
  604. vellum/resources/workspace_secrets/client.py +2 -265
  605. vellum/types/__init__.py +2 -978
  606. vellum/types/ad_hoc_execute_prompt_event.py +2 -13
  607. vellum/types/ad_hoc_expand_meta.py +2 -36
  608. vellum/types/ad_hoc_fulfilled_prompt_execution_meta.py +2 -26
  609. vellum/types/ad_hoc_initiated_prompt_execution_meta.py +2 -23
  610. vellum/types/ad_hoc_rejected_prompt_execution_meta.py +2 -24
  611. vellum/types/ad_hoc_streaming_prompt_execution_meta.py +2 -22
  612. vellum/types/add_openai_api_key_enum.py +2 -2
  613. vellum/types/api_node_result.py +2 -24
  614. vellum/types/api_node_result_data.py +2 -27
  615. vellum/types/array_chat_message_content.py +2 -24
  616. vellum/types/array_chat_message_content_item.py +2 -10
  617. vellum/types/array_chat_message_content_item_request.py +2 -13
  618. vellum/types/array_chat_message_content_request.py +2 -24
  619. vellum/types/array_input.py +2 -35
  620. vellum/types/array_variable_value.py +2 -26
  621. vellum/types/array_variable_value_item.py +2 -28
  622. vellum/types/array_vellum_value.py +2 -30
  623. vellum/types/array_vellum_value_request.py +2 -30
  624. vellum/types/audio_chat_message_content.py +2 -24
  625. vellum/types/audio_chat_message_content_request.py +2 -24
  626. vellum/types/audio_variable_value.py +2 -24
  627. vellum/types/audio_vellum_value.py +2 -24
  628. vellum/types/audio_vellum_value_request.py +2 -24
  629. vellum/types/basic_vectorizer_intfloat_multilingual_e_5_large.py +2 -23
  630. vellum/types/basic_vectorizer_intfloat_multilingual_e_5_large_request.py +2 -23
  631. vellum/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_cos_v_1.py +2 -25
  632. vellum/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_cos_v_1_request.py +2 -25
  633. vellum/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_dot_v_1.py +2 -25
  634. vellum/types/basic_vectorizer_sentence_transformers_multi_qa_mpnet_base_dot_v_1_request.py +2 -25
  635. vellum/types/chat_history_input.py +2 -29
  636. vellum/types/chat_history_input_request.py +2 -29
  637. vellum/types/chat_history_variable_value.py +2 -20
  638. vellum/types/chat_history_vellum_value.py +2 -24
  639. vellum/types/chat_history_vellum_value_request.py +2 -24
  640. vellum/types/chat_message.py +2 -26
  641. vellum/types/chat_message_content.py +2 -15
  642. vellum/types/chat_message_content_request.py +2 -15
  643. vellum/types/chat_message_prompt_block.py +2 -38
  644. vellum/types/chat_message_request.py +2 -26
  645. vellum/types/chat_message_role.py +2 -4
  646. vellum/types/code_execution_node_array_result.py +2 -27
  647. vellum/types/code_execution_node_chat_history_result.py +2 -21
  648. vellum/types/code_execution_node_error_result.py +2 -21
  649. vellum/types/code_execution_node_function_call_result.py +2 -21
  650. vellum/types/code_execution_node_json_result.py +2 -20
  651. vellum/types/code_execution_node_number_result.py +2 -20
  652. vellum/types/code_execution_node_result.py +2 -30
  653. vellum/types/code_execution_node_result_data.py +2 -26
  654. vellum/types/code_execution_node_result_output.py +2 -21
  655. vellum/types/code_execution_node_search_results_result.py +2 -21
  656. vellum/types/code_execution_node_string_result.py +2 -20
  657. vellum/types/code_execution_package.py +2 -19
  658. vellum/types/code_execution_runtime.py +2 -4
  659. vellum/types/code_executor_input.py +2 -23
  660. vellum/types/code_executor_response.py +2 -26
  661. vellum/types/code_executor_secret_input.py +2 -28
  662. vellum/types/compile_prompt_deployment_expand_meta_request.py +2 -31
  663. vellum/types/compile_prompt_meta.py +2 -24
  664. vellum/types/components_schemas_pdf_search_result_meta_source.py +2 -4
  665. vellum/types/components_schemas_pdf_search_result_meta_source_request.py +2 -4
  666. vellum/types/condition_combinator.py +2 -4
  667. vellum/types/conditional_node_result.py +2 -24
  668. vellum/types/conditional_node_result_data.py +2 -18
  669. vellum/types/container_image_read.py +2 -27
  670. vellum/types/create_test_suite_test_case_request.py +2 -47
  671. vellum/types/deployment_provider_payload_response.py +2 -21
  672. vellum/types/deployment_provider_payload_response_payload.py +2 -4
  673. vellum/types/deployment_read.py +2 -72
  674. vellum/types/deployment_release_tag_deployment_history_item.py +2 -20
  675. vellum/types/deployment_release_tag_read.py +2 -36
  676. vellum/types/docker_service_token.py +2 -20
  677. vellum/types/document_document_to_document_index.py +2 -38
  678. vellum/types/document_index_chunking.py +2 -7
  679. vellum/types/document_index_chunking_request.py +2 -9
  680. vellum/types/document_index_indexing_config.py +2 -21
  681. vellum/types/document_index_indexing_config_request.py +2 -21
  682. vellum/types/document_index_read.py +2 -51
  683. vellum/types/document_processing_state.py +2 -6
  684. vellum/types/document_read.py +2 -48
  685. vellum/types/document_status.py +2 -4
  686. vellum/types/enriched_normalized_completion.py +2 -58
  687. vellum/types/entity_status.py +2 -4
  688. vellum/types/entity_visibility.py +2 -4
  689. vellum/types/environment_enum.py +2 -4
  690. vellum/types/ephemeral_prompt_cache_config.py +2 -19
  691. vellum/types/ephemeral_prompt_cache_config_type_enum.py +2 -4
  692. vellum/types/error_input.py +2 -29
  693. vellum/types/error_variable_value.py +2 -20
  694. vellum/types/error_vellum_value.py +2 -24
  695. vellum/types/error_vellum_value_request.py +2 -24
  696. vellum/types/execute_prompt_event.py +2 -10
  697. vellum/types/execute_prompt_response.py +2 -6
  698. vellum/types/execute_workflow_response.py +2 -28
  699. vellum/types/execute_workflow_workflow_result_event.py +2 -8
  700. vellum/types/execution_array_vellum_value.py +2 -36
  701. vellum/types/execution_chat_history_vellum_value.py +2 -30
  702. vellum/types/execution_error_vellum_value.py +2 -30
  703. vellum/types/execution_function_call_vellum_value.py +2 -30
  704. vellum/types/execution_json_vellum_value.py +2 -29
  705. vellum/types/execution_number_vellum_value.py +2 -29
  706. vellum/types/execution_search_results_vellum_value.py +2 -30
  707. vellum/types/execution_string_vellum_value.py +2 -29
  708. vellum/types/execution_vellum_value.py +2 -21
  709. vellum/types/external_test_case_execution.py +2 -30
  710. vellum/types/external_test_case_execution_request.py +2 -30
  711. vellum/types/finish_reason_enum.py +2 -4
  712. vellum/types/folder_entity.py +2 -15
  713. vellum/types/folder_entity_document_index.py +2 -25
  714. vellum/types/folder_entity_document_index_data.py +2 -24
  715. vellum/types/folder_entity_folder.py +2 -25
  716. vellum/types/folder_entity_folder_data.py +2 -23
  717. vellum/types/folder_entity_prompt_sandbox.py +2 -25
  718. vellum/types/folder_entity_prompt_sandbox_data.py +2 -25
  719. vellum/types/folder_entity_test_suite.py +2 -25
  720. vellum/types/folder_entity_test_suite_data.py +2 -24
  721. vellum/types/folder_entity_workflow_sandbox.py +2 -25
  722. vellum/types/folder_entity_workflow_sandbox_data.py +2 -25
  723. vellum/types/fulfilled_ad_hoc_execute_prompt_event.py +2 -27
  724. vellum/types/fulfilled_enum.py +2 -4
  725. vellum/types/fulfilled_execute_prompt_event.py +2 -27
  726. vellum/types/fulfilled_execute_prompt_response.py +2 -36
  727. vellum/types/fulfilled_execute_workflow_workflow_result_event.py +2 -35
  728. vellum/types/fulfilled_prompt_execution_meta.py +2 -26
  729. vellum/types/fulfilled_workflow_node_result_event.py +2 -39
  730. vellum/types/function_call.py +2 -26
  731. vellum/types/function_call_chat_message_content.py +2 -24
  732. vellum/types/function_call_chat_message_content_request.py +2 -24
  733. vellum/types/function_call_chat_message_content_value.py +2 -24
  734. vellum/types/function_call_chat_message_content_value_request.py +2 -24
  735. vellum/types/function_call_input.py +2 -29
  736. vellum/types/function_call_request.py +2 -26
  737. vellum/types/function_call_variable_value.py +2 -20
  738. vellum/types/function_call_vellum_value.py +2 -24
  739. vellum/types/function_call_vellum_value_request.py +2 -24
  740. vellum/types/function_definition.py +2 -30
  741. vellum/types/generate_options_request.py +2 -25
  742. vellum/types/generate_request.py +2 -32
  743. vellum/types/generate_response.py +2 -24
  744. vellum/types/generate_result.py +2 -28
  745. vellum/types/generate_result_data.py +2 -22
  746. vellum/types/generate_result_error.py +2 -21
  747. vellum/types/generate_stream_response.py +2 -19
  748. vellum/types/generate_stream_result.py +2 -22
  749. vellum/types/generate_stream_result_data.py +2 -20
  750. vellum/types/google_vertex_ai_vectorizer_config.py +2 -19
  751. vellum/types/google_vertex_ai_vectorizer_config_request.py +2 -19
  752. vellum/types/google_vertex_ai_vectorizer_text_embedding_004.py +2 -20
  753. vellum/types/google_vertex_ai_vectorizer_text_embedding_004_request.py +2 -20
  754. vellum/types/google_vertex_ai_vectorizer_text_multilingual_embedding_002.py +2 -20
  755. vellum/types/google_vertex_ai_vectorizer_text_multilingual_embedding_002_request.py +2 -20
  756. vellum/types/hkunlp_instructor_xl_vectorizer.py +2 -24
  757. vellum/types/hkunlp_instructor_xl_vectorizer_request.py +2 -24
  758. vellum/types/image_chat_message_content.py +2 -24
  759. vellum/types/image_chat_message_content_request.py +2 -24
  760. vellum/types/image_variable_value.py +2 -24
  761. vellum/types/image_vellum_value.py +2 -24
  762. vellum/types/image_vellum_value_request.py +2 -24
  763. vellum/types/indexing_config_vectorizer.py +2 -29
  764. vellum/types/indexing_config_vectorizer_request.py +2 -29
  765. vellum/types/indexing_state_enum.py +2 -6
  766. vellum/types/initiated_ad_hoc_execute_prompt_event.py +2 -25
  767. vellum/types/initiated_execute_prompt_event.py +2 -25
  768. vellum/types/initiated_prompt_execution_meta.py +2 -25
  769. vellum/types/initiated_workflow_node_result_event.py +2 -38
  770. vellum/types/instructor_vectorizer_config.py +2 -24
  771. vellum/types/instructor_vectorizer_config_request.py +2 -24
  772. vellum/types/iteration_state_enum.py +2 -4
  773. vellum/types/jinja_prompt_block.py +2 -27
  774. vellum/types/json_input.py +2 -28
  775. vellum/types/json_input_request.py +2 -28
  776. vellum/types/json_variable_value.py +2 -19
  777. vellum/types/json_vellum_value.py +2 -23
  778. vellum/types/json_vellum_value_request.py +2 -23
  779. vellum/types/logical_operator.py +2 -28
  780. vellum/types/logprobs_enum.py +2 -4
  781. vellum/types/map_node_result.py +2 -24
  782. vellum/types/map_node_result_data.py +2 -20
  783. vellum/types/merge_node_result.py +2 -24
  784. vellum/types/merge_node_result_data.py +2 -18
  785. vellum/types/metadata_filter_config_request.py +2 -35
  786. vellum/types/metadata_filter_rule_combinator.py +2 -4
  787. vellum/types/metadata_filter_rule_request.py +2 -30
  788. vellum/types/metadata_filters_request.py +2 -6
  789. vellum/types/metric_definition_execution.py +2 -19
  790. vellum/types/metric_definition_input.py +2 -8
  791. vellum/types/metric_node_result.py +2 -22
  792. vellum/types/ml_model_usage.py +2 -24
  793. vellum/types/named_scenario_input_chat_history_variable_value_request.py +2 -25
  794. vellum/types/named_scenario_input_json_variable_value_request.py +2 -24
  795. vellum/types/named_scenario_input_request.py +2 -11
  796. vellum/types/named_scenario_input_string_variable_value_request.py +2 -24
  797. vellum/types/named_test_case_array_variable_value.py +2 -31
  798. vellum/types/named_test_case_array_variable_value_request.py +2 -33
  799. vellum/types/named_test_case_chat_history_variable_value.py +2 -25
  800. vellum/types/named_test_case_chat_history_variable_value_request.py +2 -25
  801. vellum/types/named_test_case_error_variable_value.py +2 -25
  802. vellum/types/named_test_case_error_variable_value_request.py +2 -25
  803. vellum/types/named_test_case_function_call_variable_value.py +2 -25
  804. vellum/types/named_test_case_function_call_variable_value_request.py +2 -25
  805. vellum/types/named_test_case_json_variable_value.py +2 -24
  806. vellum/types/named_test_case_json_variable_value_request.py +2 -24
  807. vellum/types/named_test_case_number_variable_value.py +2 -24
  808. vellum/types/named_test_case_number_variable_value_request.py +2 -24
  809. vellum/types/named_test_case_search_results_variable_value.py +2 -25
  810. vellum/types/named_test_case_search_results_variable_value_request.py +2 -25
  811. vellum/types/named_test_case_string_variable_value.py +2 -24
  812. vellum/types/named_test_case_string_variable_value_request.py +2 -24
  813. vellum/types/named_test_case_variable_value.py +2 -21
  814. vellum/types/named_test_case_variable_value_request.py +2 -21
  815. vellum/types/node_input_compiled_array_value.py +2 -28
  816. vellum/types/node_input_compiled_chat_history_value.py +2 -22
  817. vellum/types/node_input_compiled_error_value.py +2 -22
  818. vellum/types/node_input_compiled_function_call_value.py +2 -22
  819. vellum/types/node_input_compiled_json_value.py +2 -21
  820. vellum/types/node_input_compiled_number_value.py +2 -21
  821. vellum/types/node_input_compiled_search_results_value.py +2 -22
  822. vellum/types/node_input_compiled_string_value.py +2 -21
  823. vellum/types/node_input_variable_compiled_value.py +2 -21
  824. vellum/types/node_output_compiled_array_value.py +2 -33
  825. vellum/types/node_output_compiled_chat_history_value.py +2 -27
  826. vellum/types/node_output_compiled_error_value.py +2 -27
  827. vellum/types/node_output_compiled_function_call_value.py +2 -27
  828. vellum/types/node_output_compiled_json_value.py +2 -26
  829. vellum/types/node_output_compiled_number_value.py +2 -26
  830. vellum/types/node_output_compiled_search_results_value.py +2 -27
  831. vellum/types/node_output_compiled_string_value.py +2 -26
  832. vellum/types/node_output_compiled_value.py +2 -21
  833. vellum/types/normalized_log_probs.py +2 -20
  834. vellum/types/normalized_token_log_probs.py +2 -21
  835. vellum/types/number_input.py +2 -28
  836. vellum/types/number_variable_value.py +2 -19
  837. vellum/types/number_vellum_value.py +2 -23
  838. vellum/types/number_vellum_value_request.py +2 -23
  839. vellum/types/open_ai_vectorizer_config.py +2 -23
  840. vellum/types/open_ai_vectorizer_config_request.py +2 -23
  841. vellum/types/open_ai_vectorizer_text_embedding_3_large.py +2 -24
  842. vellum/types/open_ai_vectorizer_text_embedding_3_large_request.py +2 -24
  843. vellum/types/open_ai_vectorizer_text_embedding_3_small.py +2 -24
  844. vellum/types/open_ai_vectorizer_text_embedding_3_small_request.py +2 -24
  845. vellum/types/open_ai_vectorizer_text_embedding_ada_002.py +2 -24
  846. vellum/types/open_ai_vectorizer_text_embedding_ada_002_request.py +2 -24
  847. vellum/types/paginated_container_image_read_list.py +2 -22
  848. vellum/types/paginated_deployment_release_tag_read_list.py +2 -22
  849. vellum/types/paginated_document_index_read_list.py +2 -22
  850. vellum/types/paginated_folder_entity_list.py +2 -22
  851. vellum/types/paginated_slim_deployment_read_list.py +2 -28
  852. vellum/types/paginated_slim_document_list.py +2 -22
  853. vellum/types/paginated_slim_workflow_deployment_list.py +2 -28
  854. vellum/types/paginated_test_suite_run_execution_list.py +2 -28
  855. vellum/types/paginated_test_suite_test_case_list.py +2 -28
  856. vellum/types/paginated_workflow_release_tag_read_list.py +2 -22
  857. vellum/types/pdf_search_result_meta_source.py +2 -31
  858. vellum/types/pdf_search_result_meta_source_request.py +2 -31
  859. vellum/types/plain_text_prompt_block.py +2 -27
  860. vellum/types/price.py +2 -20
  861. vellum/types/processing_failure_reason_enum.py +2 -4
  862. vellum/types/prompt_block.py +2 -11
  863. vellum/types/prompt_block_state.py +2 -4
  864. vellum/types/prompt_deployment_expand_meta_request.py +2 -51
  865. vellum/types/prompt_deployment_input_request.py +2 -7
  866. vellum/types/prompt_execution_meta.py +2 -31
  867. vellum/types/prompt_node_execution_meta.py +2 -23
  868. vellum/types/prompt_node_result.py +2 -24
  869. vellum/types/prompt_node_result_data.py +2 -24
  870. vellum/types/prompt_output.py +2 -8
  871. vellum/types/prompt_parameters.py +2 -26
  872. vellum/types/prompt_request_chat_history_input.py +2 -25
  873. vellum/types/prompt_request_input.py +2 -7
  874. vellum/types/prompt_request_json_input.py +2 -24
  875. vellum/types/prompt_request_string_input.py +2 -24
  876. vellum/types/prompt_settings.py +2 -18
  877. vellum/types/raw_prompt_execution_overrides_request.py +2 -27
  878. vellum/types/reducto_chunker_config.py +2 -22
  879. vellum/types/reducto_chunker_config_request.py +2 -22
  880. vellum/types/reducto_chunking.py +2 -24
  881. vellum/types/reducto_chunking_request.py +2 -24
  882. vellum/types/rejected_ad_hoc_execute_prompt_event.py +2 -27
  883. vellum/types/rejected_execute_prompt_event.py +2 -27
  884. vellum/types/rejected_execute_prompt_response.py +2 -36
  885. vellum/types/rejected_execute_workflow_workflow_result_event.py +2 -27
  886. vellum/types/rejected_prompt_execution_meta.py +2 -24
  887. vellum/types/rejected_workflow_node_result_event.py +2 -38
  888. vellum/types/release_tag_source.py +2 -4
  889. vellum/types/replace_test_suite_test_case_request.py +2 -52
  890. vellum/types/rich_text_child_block.py +2 -6
  891. vellum/types/rich_text_prompt_block.py +2 -28
  892. vellum/types/sandbox_scenario.py +2 -32
  893. vellum/types/scenario_input.py +2 -9
  894. vellum/types/scenario_input_chat_history_variable_value.py +2 -25
  895. vellum/types/scenario_input_json_variable_value.py +2 -24
  896. vellum/types/scenario_input_string_variable_value.py +2 -24
  897. vellum/types/search_filters_request.py +2 -37
  898. vellum/types/search_node_result.py +2 -24
  899. vellum/types/search_node_result_data.py +2 -26
  900. vellum/types/search_request_options_request.py +2 -49
  901. vellum/types/search_response.py +2 -22
  902. vellum/types/search_result.py +2 -39
  903. vellum/types/search_result_document.py +2 -36
  904. vellum/types/search_result_document_request.py +2 -36
  905. vellum/types/search_result_merging_request.py +2 -21
  906. vellum/types/search_result_meta.py +2 -19
  907. vellum/types/search_result_meta_request.py +2 -19
  908. vellum/types/search_result_request.py +2 -39
  909. vellum/types/search_results_input.py +2 -29
  910. vellum/types/search_results_variable_value.py +2 -20
  911. vellum/types/search_results_vellum_value.py +2 -24
  912. vellum/types/search_results_vellum_value_request.py +2 -24
  913. vellum/types/search_weights_request.py +2 -26
  914. vellum/types/secret_type_enum.py +2 -4
  915. vellum/types/sentence_chunker_config.py +2 -23
  916. vellum/types/sentence_chunker_config_request.py +2 -23
  917. vellum/types/sentence_chunking.py +2 -24
  918. vellum/types/sentence_chunking_request.py +2 -24
  919. vellum/types/slim_deployment_read.py +2 -62
  920. vellum/types/slim_document.py +2 -69
  921. vellum/types/slim_workflow_deployment.py +2 -71
  922. vellum/types/streaming_ad_hoc_execute_prompt_event.py +2 -32
  923. vellum/types/streaming_execute_prompt_event.py +2 -32
  924. vellum/types/streaming_prompt_execution_meta.py +2 -22
  925. vellum/types/streaming_workflow_node_result_event.py +2 -39
  926. vellum/types/string_chat_message_content.py +2 -23
  927. vellum/types/string_chat_message_content_request.py +2 -23
  928. vellum/types/string_input.py +2 -28
  929. vellum/types/string_input_request.py +2 -28
  930. vellum/types/string_variable_value.py +2 -19
  931. vellum/types/string_vellum_value.py +2 -23
  932. vellum/types/string_vellum_value_request.py +2 -23
  933. vellum/types/submit_completion_actual_request.py +2 -47
  934. vellum/types/submit_workflow_execution_actual_request.py +2 -9
  935. vellum/types/subworkflow_node_result.py +2 -24
  936. vellum/types/subworkflow_node_result_data.py +2 -18
  937. vellum/types/templating_node_array_result.py +2 -27
  938. vellum/types/templating_node_chat_history_result.py +2 -21
  939. vellum/types/templating_node_error_result.py +2 -21
  940. vellum/types/templating_node_function_call_result.py +2 -21
  941. vellum/types/templating_node_json_result.py +2 -20
  942. vellum/types/templating_node_number_result.py +2 -20
  943. vellum/types/templating_node_result.py +2 -30
  944. vellum/types/templating_node_result_data.py +2 -25
  945. vellum/types/templating_node_result_output.py +2 -21
  946. vellum/types/templating_node_search_results_result.py +2 -21
  947. vellum/types/templating_node_string_result.py +2 -20
  948. vellum/types/terminal_node_array_result.py +2 -32
  949. vellum/types/terminal_node_chat_history_result.py +2 -26
  950. vellum/types/terminal_node_error_result.py +2 -26
  951. vellum/types/terminal_node_function_call_result.py +2 -26
  952. vellum/types/terminal_node_json_result.py +2 -25
  953. vellum/types/terminal_node_number_result.py +2 -25
  954. vellum/types/terminal_node_result.py +2 -30
  955. vellum/types/terminal_node_result_data.py +2 -25
  956. vellum/types/terminal_node_result_output.py +2 -21
  957. vellum/types/terminal_node_search_results_result.py +2 -26
  958. vellum/types/terminal_node_string_result.py +2 -25
  959. vellum/types/test_case_array_variable_value.py +2 -32
  960. vellum/types/test_case_chat_history_variable_value.py +2 -26
  961. vellum/types/test_case_error_variable_value.py +2 -26
  962. vellum/types/test_case_function_call_variable_value.py +2 -26
  963. vellum/types/test_case_json_variable_value.py +2 -25
  964. vellum/types/test_case_number_variable_value.py +2 -25
  965. vellum/types/test_case_search_results_variable_value.py +2 -26
  966. vellum/types/test_case_string_variable_value.py +2 -25
  967. vellum/types/test_case_variable_value.py +2 -21
  968. vellum/types/test_suite_run_deployment_release_tag_exec_config.py +2 -28
  969. vellum/types/test_suite_run_deployment_release_tag_exec_config_data.py +2 -26
  970. vellum/types/test_suite_run_deployment_release_tag_exec_config_data_request.py +2 -26
  971. vellum/types/test_suite_run_deployment_release_tag_exec_config_request.py +2 -30
  972. vellum/types/test_suite_run_exec_config.py +2 -9
  973. vellum/types/test_suite_run_exec_config_request.py +2 -11
  974. vellum/types/test_suite_run_execution.py +2 -29
  975. vellum/types/test_suite_run_execution_array_output.py +2 -32
  976. vellum/types/test_suite_run_execution_chat_history_output.py +2 -26
  977. vellum/types/test_suite_run_execution_error_output.py +2 -26
  978. vellum/types/test_suite_run_execution_function_call_output.py +2 -26
  979. vellum/types/test_suite_run_execution_json_output.py +2 -25
  980. vellum/types/test_suite_run_execution_metric_definition.py +2 -20
  981. vellum/types/test_suite_run_execution_metric_result.py +2 -23
  982. vellum/types/test_suite_run_execution_number_output.py +2 -25
  983. vellum/types/test_suite_run_execution_output.py +2 -21
  984. vellum/types/test_suite_run_execution_search_results_output.py +2 -26
  985. vellum/types/test_suite_run_execution_string_output.py +2 -25
  986. vellum/types/test_suite_run_external_exec_config.py +2 -35
  987. vellum/types/test_suite_run_external_exec_config_data.py +2 -28
  988. vellum/types/test_suite_run_external_exec_config_data_request.py +2 -30
  989. vellum/types/test_suite_run_external_exec_config_request.py +2 -37
  990. vellum/types/test_suite_run_metric_error_output.py +2 -25
  991. vellum/types/test_suite_run_metric_json_output.py +2 -24
  992. vellum/types/test_suite_run_metric_number_output.py +2 -24
  993. vellum/types/test_suite_run_metric_output.py +2 -13
  994. vellum/types/test_suite_run_metric_string_output.py +2 -24
  995. vellum/types/test_suite_run_read.py +2 -45
  996. vellum/types/test_suite_run_state.py +2 -4
  997. vellum/types/test_suite_run_test_suite.py +2 -20
  998. vellum/types/test_suite_run_workflow_release_tag_exec_config.py +2 -28
  999. vellum/types/test_suite_run_workflow_release_tag_exec_config_data.py +2 -26
  1000. vellum/types/test_suite_run_workflow_release_tag_exec_config_data_request.py +2 -26
  1001. vellum/types/test_suite_run_workflow_release_tag_exec_config_request.py +2 -30
  1002. vellum/types/test_suite_test_case.py +2 -29
  1003. vellum/types/test_suite_test_case_bulk_operation_request.py +2 -13
  1004. vellum/types/test_suite_test_case_bulk_result.py +2 -13
  1005. vellum/types/test_suite_test_case_create_bulk_operation_request.py +2 -37
  1006. vellum/types/test_suite_test_case_created_bulk_result.py +2 -25
  1007. vellum/types/test_suite_test_case_created_bulk_result_data.py +2 -22
  1008. vellum/types/test_suite_test_case_delete_bulk_operation_data_request.py +2 -18
  1009. vellum/types/test_suite_test_case_delete_bulk_operation_request.py +2 -32
  1010. vellum/types/test_suite_test_case_deleted_bulk_result.py +2 -29
  1011. vellum/types/test_suite_test_case_deleted_bulk_result_data.py +2 -22
  1012. vellum/types/test_suite_test_case_rejected_bulk_result.py +2 -31
  1013. vellum/types/test_suite_test_case_replace_bulk_operation_request.py +2 -37
  1014. vellum/types/test_suite_test_case_replaced_bulk_result.py +2 -29
  1015. vellum/types/test_suite_test_case_replaced_bulk_result_data.py +2 -22
  1016. vellum/types/test_suite_test_case_upsert_bulk_operation_request.py +2 -37
  1017. vellum/types/token_overlapping_window_chunker_config.py +2 -23
  1018. vellum/types/token_overlapping_window_chunker_config_request.py +2 -23
  1019. vellum/types/token_overlapping_window_chunking.py +2 -24
  1020. vellum/types/token_overlapping_window_chunking_request.py +2 -24
  1021. vellum/types/unit_enum.py +2 -4
  1022. vellum/types/upload_document_response.py +2 -21
  1023. vellum/types/upsert_test_suite_test_case_request.py +2 -48
  1024. vellum/types/variable_prompt_block.py +2 -27
  1025. vellum/types/vellum_audio.py +2 -23
  1026. vellum/types/vellum_audio_request.py +2 -23
  1027. vellum/types/vellum_error.py +2 -20
  1028. vellum/types/vellum_error_code_enum.py +2 -14
  1029. vellum/types/vellum_error_request.py +2 -20
  1030. vellum/types/vellum_image.py +2 -19
  1031. vellum/types/vellum_image_request.py +2 -19
  1032. vellum/types/vellum_value.py +2 -28
  1033. vellum/types/vellum_value_logical_condition_group_request.py +2 -37
  1034. vellum/types/vellum_value_logical_condition_request.py +2 -33
  1035. vellum/types/vellum_value_logical_expression_request.py +2 -11
  1036. vellum/types/vellum_value_request.py +2 -28
  1037. vellum/types/vellum_variable.py +2 -32
  1038. vellum/types/vellum_variable_extensions.py +2 -22
  1039. vellum/types/vellum_variable_type.py +2 -19
  1040. vellum/types/workflow_deployment_read.py +2 -76
  1041. vellum/types/workflow_event_error.py +2 -20
  1042. vellum/types/workflow_execution_actual_chat_history_request.py +2 -48
  1043. vellum/types/workflow_execution_actual_json_request.py +2 -47
  1044. vellum/types/workflow_execution_actual_string_request.py +2 -47
  1045. vellum/types/workflow_execution_event_error_code.py +2 -16
  1046. vellum/types/workflow_execution_event_type.py +2 -4
  1047. vellum/types/workflow_execution_node_result_event.py +2 -33
  1048. vellum/types/workflow_execution_workflow_result_event.py +2 -35
  1049. vellum/types/workflow_expand_meta_request.py +2 -21
  1050. vellum/types/workflow_node_result_data.py +2 -27
  1051. vellum/types/workflow_node_result_event.py +2 -13
  1052. vellum/types/workflow_node_result_event_state.py +2 -6
  1053. vellum/types/workflow_output.py +2 -23
  1054. vellum/types/workflow_output_array.py +2 -36
  1055. vellum/types/workflow_output_chat_history.py +2 -30
  1056. vellum/types/workflow_output_error.py +2 -30
  1057. vellum/types/workflow_output_function_call.py +2 -30
  1058. vellum/types/workflow_output_image.py +2 -30
  1059. vellum/types/workflow_output_json.py +2 -29
  1060. vellum/types/workflow_output_number.py +2 -29
  1061. vellum/types/workflow_output_search_results.py +2 -30
  1062. vellum/types/workflow_output_string.py +2 -29
  1063. vellum/types/workflow_push_deployment_config_request.py +2 -21
  1064. vellum/types/workflow_push_exec_config.py +2 -2
  1065. vellum/types/workflow_push_response.py +2 -19
  1066. vellum/types/workflow_release_tag_read.py +2 -36
  1067. vellum/types/workflow_release_tag_workflow_deployment_history_item.py +2 -27
  1068. vellum/types/workflow_request_chat_history_input_request.py +2 -29
  1069. vellum/types/workflow_request_input_request.py +2 -13
  1070. vellum/types/workflow_request_json_input_request.py +2 -28
  1071. vellum/types/workflow_request_number_input_request.py +2 -28
  1072. vellum/types/workflow_request_string_input_request.py +2 -28
  1073. vellum/types/workflow_result_event.py +2 -38
  1074. vellum/types/workflow_result_event_output_data.py +2 -21
  1075. vellum/types/workflow_result_event_output_data_array.py +2 -40
  1076. vellum/types/workflow_result_event_output_data_chat_history.py +2 -34
  1077. vellum/types/workflow_result_event_output_data_error.py +2 -34
  1078. vellum/types/workflow_result_event_output_data_function_call.py +2 -34
  1079. vellum/types/workflow_result_event_output_data_json.py +2 -33
  1080. vellum/types/workflow_result_event_output_data_number.py +2 -33
  1081. vellum/types/workflow_result_event_output_data_search_results.py +2 -34
  1082. vellum/types/workflow_result_event_output_data_string.py +2 -36
  1083. vellum/types/workflow_stream_event.py +2 -6
  1084. vellum/types/workspace_secret_read.py +2 -24
  1085. vellum/workflows/README.md +90 -0
  1086. vellum/workflows/__init__.py +5 -0
  1087. vellum/workflows/constants.py +43 -0
  1088. vellum/workflows/descriptors/__init__.py +0 -0
  1089. vellum/workflows/descriptors/base.py +339 -0
  1090. vellum/workflows/descriptors/tests/test_utils.py +83 -0
  1091. vellum/workflows/descriptors/utils.py +90 -0
  1092. vellum/workflows/edges/__init__.py +5 -0
  1093. vellum/workflows/edges/edge.py +23 -0
  1094. vellum/workflows/emitters/__init__.py +5 -0
  1095. vellum/workflows/emitters/base.py +14 -0
  1096. vellum/workflows/environment/__init__.py +5 -0
  1097. vellum/workflows/environment/environment.py +7 -0
  1098. vellum/workflows/errors/__init__.py +6 -0
  1099. vellum/workflows/errors/types.py +20 -0
  1100. vellum/workflows/events/__init__.py +31 -0
  1101. vellum/workflows/events/node.py +125 -0
  1102. vellum/workflows/events/tests/__init__.py +0 -0
  1103. vellum/workflows/events/tests/test_event.py +216 -0
  1104. vellum/workflows/events/types.py +52 -0
  1105. vellum/workflows/events/utils.py +5 -0
  1106. vellum/workflows/events/workflow.py +139 -0
  1107. vellum/workflows/exceptions.py +15 -0
  1108. vellum/workflows/expressions/__init__.py +0 -0
  1109. vellum/workflows/expressions/accessor.py +52 -0
  1110. vellum/workflows/expressions/and_.py +32 -0
  1111. vellum/workflows/expressions/begins_with.py +31 -0
  1112. vellum/workflows/expressions/between.py +38 -0
  1113. vellum/workflows/expressions/coalesce_expression.py +41 -0
  1114. vellum/workflows/expressions/contains.py +30 -0
  1115. vellum/workflows/expressions/does_not_begin_with.py +31 -0
  1116. vellum/workflows/expressions/does_not_contain.py +30 -0
  1117. vellum/workflows/expressions/does_not_end_with.py +31 -0
  1118. vellum/workflows/expressions/does_not_equal.py +25 -0
  1119. vellum/workflows/expressions/ends_with.py +31 -0
  1120. vellum/workflows/expressions/equals.py +25 -0
  1121. vellum/workflows/expressions/greater_than.py +33 -0
  1122. vellum/workflows/expressions/greater_than_or_equal_to.py +33 -0
  1123. vellum/workflows/expressions/in_.py +31 -0
  1124. vellum/workflows/expressions/is_blank.py +24 -0
  1125. vellum/workflows/expressions/is_not_blank.py +24 -0
  1126. vellum/workflows/expressions/is_not_null.py +21 -0
  1127. vellum/workflows/expressions/is_not_undefined.py +22 -0
  1128. vellum/workflows/expressions/is_null.py +21 -0
  1129. vellum/workflows/expressions/is_undefined.py +22 -0
  1130. vellum/workflows/expressions/less_than.py +33 -0
  1131. vellum/workflows/expressions/less_than_or_equal_to.py +33 -0
  1132. vellum/workflows/expressions/not_between.py +38 -0
  1133. vellum/workflows/expressions/not_in.py +31 -0
  1134. vellum/workflows/expressions/or_.py +32 -0
  1135. vellum/workflows/graph/__init__.py +3 -0
  1136. vellum/workflows/graph/graph.py +131 -0
  1137. vellum/workflows/graph/tests/__init__.py +0 -0
  1138. vellum/workflows/graph/tests/test_graph.py +437 -0
  1139. vellum/workflows/inputs/__init__.py +5 -0
  1140. vellum/workflows/inputs/base.py +55 -0
  1141. vellum/workflows/logging.py +14 -0
  1142. vellum/workflows/nodes/__init__.py +46 -0
  1143. vellum/workflows/nodes/bases/__init__.py +7 -0
  1144. vellum/workflows/nodes/bases/base.py +332 -0
  1145. vellum/workflows/nodes/bases/base_subworkflow_node/__init__.py +5 -0
  1146. vellum/workflows/nodes/bases/base_subworkflow_node/node.py +10 -0
  1147. vellum/workflows/nodes/bases/tests/__init__.py +0 -0
  1148. vellum/workflows/nodes/bases/tests/test_base_node.py +125 -0
  1149. vellum/workflows/nodes/core/__init__.py +16 -0
  1150. vellum/workflows/nodes/core/error_node/__init__.py +5 -0
  1151. vellum/workflows/nodes/core/error_node/node.py +26 -0
  1152. vellum/workflows/nodes/core/inline_subworkflow_node/__init__.py +5 -0
  1153. vellum/workflows/nodes/core/inline_subworkflow_node/node.py +73 -0
  1154. vellum/workflows/nodes/core/map_node/__init__.py +5 -0
  1155. vellum/workflows/nodes/core/map_node/node.py +147 -0
  1156. vellum/workflows/nodes/core/map_node/tests/__init__.py +0 -0
  1157. vellum/workflows/nodes/core/map_node/tests/test_node.py +65 -0
  1158. vellum/workflows/nodes/core/retry_node/__init__.py +5 -0
  1159. vellum/workflows/nodes/core/retry_node/node.py +106 -0
  1160. vellum/workflows/nodes/core/retry_node/tests/__init__.py +0 -0
  1161. vellum/workflows/nodes/core/retry_node/tests/test_node.py +93 -0
  1162. vellum/workflows/nodes/core/templating_node/__init__.py +5 -0
  1163. vellum/workflows/nodes/core/templating_node/custom_filters.py +12 -0
  1164. vellum/workflows/nodes/core/templating_node/exceptions.py +2 -0
  1165. vellum/workflows/nodes/core/templating_node/node.py +123 -0
  1166. vellum/workflows/nodes/core/templating_node/render.py +55 -0
  1167. vellum/workflows/nodes/core/templating_node/tests/test_templating_node.py +21 -0
  1168. vellum/workflows/nodes/core/try_node/__init__.py +5 -0
  1169. vellum/workflows/nodes/core/try_node/node.py +110 -0
  1170. vellum/workflows/nodes/core/try_node/tests/__init__.py +0 -0
  1171. vellum/workflows/nodes/core/try_node/tests/test_node.py +82 -0
  1172. vellum/workflows/nodes/displayable/__init__.py +31 -0
  1173. vellum/workflows/nodes/displayable/api_node/__init__.py +5 -0
  1174. vellum/workflows/nodes/displayable/api_node/node.py +44 -0
  1175. vellum/workflows/nodes/displayable/bases/__init__.py +11 -0
  1176. vellum/workflows/nodes/displayable/bases/api_node/__init__.py +5 -0
  1177. vellum/workflows/nodes/displayable/bases/api_node/node.py +70 -0
  1178. vellum/workflows/nodes/displayable/bases/base_prompt_node/__init__.py +5 -0
  1179. vellum/workflows/nodes/displayable/bases/base_prompt_node/node.py +60 -0
  1180. vellum/workflows/nodes/displayable/bases/inline_prompt_node/__init__.py +5 -0
  1181. vellum/workflows/nodes/displayable/bases/inline_prompt_node/constants.py +13 -0
  1182. vellum/workflows/nodes/displayable/bases/inline_prompt_node/node.py +118 -0
  1183. vellum/workflows/nodes/displayable/bases/prompt_deployment_node.py +98 -0
  1184. vellum/workflows/nodes/displayable/bases/search_node.py +90 -0
  1185. vellum/workflows/nodes/displayable/code_execution_node/__init__.py +5 -0
  1186. vellum/workflows/nodes/displayable/code_execution_node/node.py +197 -0
  1187. vellum/workflows/nodes/displayable/code_execution_node/tests/__init__.py +0 -0
  1188. vellum/workflows/nodes/displayable/code_execution_node/tests/fixtures/__init__.py +0 -0
  1189. vellum/workflows/nodes/displayable/code_execution_node/tests/fixtures/main.py +3 -0
  1190. vellum/workflows/nodes/displayable/code_execution_node/tests/test_code_execution_node.py +111 -0
  1191. vellum/workflows/nodes/displayable/code_execution_node/utils.py +10 -0
  1192. vellum/workflows/nodes/displayable/conditional_node/__init__.py +5 -0
  1193. vellum/workflows/nodes/displayable/conditional_node/node.py +25 -0
  1194. vellum/workflows/nodes/displayable/final_output_node/__init__.py +5 -0
  1195. vellum/workflows/nodes/displayable/final_output_node/node.py +43 -0
  1196. vellum/workflows/nodes/displayable/guardrail_node/__init__.py +5 -0
  1197. vellum/workflows/nodes/displayable/guardrail_node/node.py +97 -0
  1198. vellum/workflows/nodes/displayable/inline_prompt_node/__init__.py +5 -0
  1199. vellum/workflows/nodes/displayable/inline_prompt_node/node.py +41 -0
  1200. vellum/workflows/nodes/displayable/merge_node/__init__.py +5 -0
  1201. vellum/workflows/nodes/displayable/merge_node/node.py +10 -0
  1202. vellum/workflows/nodes/displayable/prompt_deployment_node/__init__.py +5 -0
  1203. vellum/workflows/nodes/displayable/prompt_deployment_node/node.py +45 -0
  1204. vellum/workflows/nodes/displayable/search_node/__init__.py +5 -0
  1205. vellum/workflows/nodes/displayable/search_node/node.py +26 -0
  1206. vellum/workflows/nodes/displayable/subworkflow_deployment_node/__init__.py +5 -0
  1207. vellum/workflows/nodes/displayable/subworkflow_deployment_node/node.py +156 -0
  1208. vellum/workflows/nodes/displayable/tests/__init__.py +0 -0
  1209. vellum/workflows/nodes/displayable/tests/test_inline_text_prompt_node.py +148 -0
  1210. vellum/workflows/nodes/displayable/tests/test_search_node_wth_text_output.py +134 -0
  1211. vellum/workflows/nodes/displayable/tests/test_text_prompt_deployment_node.py +80 -0
  1212. vellum/workflows/nodes/utils.py +27 -0
  1213. vellum/workflows/outputs/__init__.py +6 -0
  1214. vellum/workflows/outputs/base.py +196 -0
  1215. vellum/workflows/ports/__init__.py +7 -0
  1216. vellum/workflows/ports/node_ports.py +75 -0
  1217. vellum/workflows/ports/port.py +75 -0
  1218. vellum/workflows/ports/utils.py +40 -0
  1219. vellum/workflows/references/__init__.py +17 -0
  1220. vellum/workflows/references/environment_variable.py +20 -0
  1221. vellum/workflows/references/execution_count.py +20 -0
  1222. vellum/workflows/references/external_input.py +49 -0
  1223. vellum/workflows/references/input.py +7 -0
  1224. vellum/workflows/references/lazy.py +55 -0
  1225. vellum/workflows/references/node.py +43 -0
  1226. vellum/workflows/references/output.py +78 -0
  1227. vellum/workflows/references/state_value.py +23 -0
  1228. vellum/workflows/references/vellum_secret.py +15 -0
  1229. vellum/workflows/references/workflow_input.py +41 -0
  1230. vellum/workflows/resolvers/__init__.py +5 -0
  1231. vellum/workflows/resolvers/base.py +15 -0
  1232. vellum/workflows/runner/__init__.py +5 -0
  1233. vellum/workflows/runner/runner.py +588 -0
  1234. vellum/workflows/runner/types.py +18 -0
  1235. vellum/workflows/state/__init__.py +5 -0
  1236. vellum/workflows/state/base.py +327 -0
  1237. vellum/workflows/state/context.py +18 -0
  1238. vellum/workflows/state/encoder.py +57 -0
  1239. vellum/workflows/state/store.py +28 -0
  1240. vellum/workflows/state/tests/__init__.py +0 -0
  1241. vellum/workflows/state/tests/test_state.py +113 -0
  1242. vellum/workflows/types/__init__.py +0 -0
  1243. vellum/workflows/types/core.py +91 -0
  1244. vellum/workflows/types/generics.py +14 -0
  1245. vellum/workflows/types/stack.py +39 -0
  1246. vellum/workflows/types/tests/__init__.py +0 -0
  1247. vellum/workflows/types/tests/test_utils.py +76 -0
  1248. vellum/workflows/types/utils.py +164 -0
  1249. vellum/workflows/utils/__init__.py +0 -0
  1250. vellum/workflows/utils/names.py +13 -0
  1251. vellum/workflows/utils/tests/__init__.py +0 -0
  1252. vellum/workflows/utils/tests/test_names.py +15 -0
  1253. vellum/workflows/utils/tests/test_vellum_variables.py +25 -0
  1254. vellum/workflows/utils/vellum_variables.py +81 -0
  1255. vellum/workflows/vellum_client.py +18 -0
  1256. vellum/workflows/workflows/__init__.py +5 -0
  1257. vellum/workflows/workflows/base.py +365 -0
  1258. {vellum_ai-0.9.16.dist-info → vellum_ai-0.9.16rc4.dist-info}/LICENSE +11 -3
  1259. vellum_ai-0.9.16rc4.dist-info/METADATA +120 -0
  1260. vellum_ai-0.9.16rc4.dist-info/RECORD +1339 -0
  1261. vellum_ai-0.9.16rc4.dist-info/entry_points.txt +3 -0
  1262. vellum_cli/__init__.py +72 -0
  1263. vellum_cli/aliased_group.py +103 -0
  1264. vellum_cli/config.py +96 -0
  1265. vellum_cli/image_push.py +112 -0
  1266. vellum_cli/logger.py +36 -0
  1267. vellum_cli/pull.py +73 -0
  1268. vellum_cli/push.py +121 -0
  1269. vellum_cli/tests/test_config.py +100 -0
  1270. vellum_cli/tests/test_pull.py +152 -0
  1271. vellum_ee/__init__.py +0 -0
  1272. vellum_ee/workflows/__init__.py +0 -0
  1273. vellum_ee/workflows/display/__init__.py +0 -0
  1274. vellum_ee/workflows/display/base.py +73 -0
  1275. vellum_ee/workflows/display/nodes/__init__.py +4 -0
  1276. vellum_ee/workflows/display/nodes/base_node_display.py +116 -0
  1277. vellum_ee/workflows/display/nodes/base_node_vellum_display.py +36 -0
  1278. vellum_ee/workflows/display/nodes/get_node_display_class.py +25 -0
  1279. vellum_ee/workflows/display/nodes/tests/__init__.py +0 -0
  1280. vellum_ee/workflows/display/nodes/tests/test_base_node_display.py +47 -0
  1281. vellum_ee/workflows/display/nodes/types.py +18 -0
  1282. vellum_ee/workflows/display/nodes/utils.py +33 -0
  1283. vellum_ee/workflows/display/nodes/vellum/__init__.py +32 -0
  1284. vellum_ee/workflows/display/nodes/vellum/api_node.py +205 -0
  1285. vellum_ee/workflows/display/nodes/vellum/code_execution_node.py +71 -0
  1286. vellum_ee/workflows/display/nodes/vellum/conditional_node.py +217 -0
  1287. vellum_ee/workflows/display/nodes/vellum/final_output_node.py +61 -0
  1288. vellum_ee/workflows/display/nodes/vellum/guardrail_node.py +49 -0
  1289. vellum_ee/workflows/display/nodes/vellum/inline_prompt_node.py +170 -0
  1290. vellum_ee/workflows/display/nodes/vellum/inline_subworkflow_node.py +99 -0
  1291. vellum_ee/workflows/display/nodes/vellum/map_node.py +100 -0
  1292. vellum_ee/workflows/display/nodes/vellum/merge_node.py +48 -0
  1293. vellum_ee/workflows/display/nodes/vellum/prompt_deployment_node.py +68 -0
  1294. vellum_ee/workflows/display/nodes/vellum/search_node.py +193 -0
  1295. vellum_ee/workflows/display/nodes/vellum/subworkflow_deployment_node.py +58 -0
  1296. vellum_ee/workflows/display/nodes/vellum/templating_node.py +67 -0
  1297. vellum_ee/workflows/display/nodes/vellum/tests/__init__.py +0 -0
  1298. vellum_ee/workflows/display/nodes/vellum/tests/test_utils.py +106 -0
  1299. vellum_ee/workflows/display/nodes/vellum/try_node.py +38 -0
  1300. vellum_ee/workflows/display/nodes/vellum/utils.py +76 -0
  1301. vellum_ee/workflows/display/tests/__init__.py +0 -0
  1302. vellum_ee/workflows/display/tests/workflow_serialization/__init__.py +0 -0
  1303. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_api_node_serialization.py +426 -0
  1304. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_code_execution_node_serialization.py +607 -0
  1305. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_conditional_node_serialization.py +1175 -0
  1306. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_guardrail_node_serialization.py +235 -0
  1307. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_inline_subworkflow_serialization.py +511 -0
  1308. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_map_node_serialization.py +372 -0
  1309. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_merge_node_serialization.py +272 -0
  1310. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_prompt_deployment_serialization.py +289 -0
  1311. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_subworkflow_deployment_serialization.py +354 -0
  1312. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_terminal_node_serialization.py +123 -0
  1313. vellum_ee/workflows/display/tests/workflow_serialization/test_basic_try_node_serialization.py +84 -0
  1314. vellum_ee/workflows/display/tests/workflow_serialization/test_complex_terminal_node_serialization.py +233 -0
  1315. vellum_ee/workflows/display/types.py +46 -0
  1316. vellum_ee/workflows/display/utils/__init__.py +0 -0
  1317. vellum_ee/workflows/display/utils/tests/__init__.py +0 -0
  1318. vellum_ee/workflows/display/utils/tests/test_uuids.py +16 -0
  1319. vellum_ee/workflows/display/utils/uuids.py +24 -0
  1320. vellum_ee/workflows/display/utils/vellum.py +121 -0
  1321. vellum_ee/workflows/display/vellum.py +357 -0
  1322. vellum_ee/workflows/display/workflows/__init__.py +5 -0
  1323. vellum_ee/workflows/display/workflows/base_workflow_display.py +302 -0
  1324. vellum_ee/workflows/display/workflows/get_vellum_workflow_display_class.py +32 -0
  1325. vellum_ee/workflows/display/workflows/vellum_workflow_display.py +386 -0
  1326. vellum/lib/__init__.py +0 -5
  1327. vellum_ai-0.9.16.dist-info/METADATA +0 -148
  1328. vellum_ai-0.9.16.dist-info/RECORD +0 -558
  1329. /vellum/{client.py → client/__init__.py} +0 -0
  1330. /vellum/{lib/test_suites → evaluations}/__init__.py +0 -0
  1331. /vellum/{lib/test_suites → evaluations}/constants.py +0 -0
  1332. /vellum/{lib/test_suites → evaluations}/exceptions.py +0 -0
  1333. /vellum/{lib → evaluations}/utils/__init__.py +0 -0
  1334. /vellum/{lib → evaluations}/utils/env.py +0 -0
  1335. /vellum/{lib → evaluations}/utils/exceptions.py +0 -0
  1336. /vellum/{lib → evaluations}/utils/paginator.py +0 -0
  1337. /vellum/{lib → evaluations}/utils/typing.py +0 -0
  1338. /vellum/{lib → evaluations}/utils/uuid.py +0 -0
  1339. {vellum_ai-0.9.16.dist-info → vellum_ai-0.9.16rc4.dist-info}/WHEEL +0 -0
@@ -0,0 +1,327 @@
1
+ from collections import defaultdict
2
+ from copy import deepcopy
3
+ from dataclasses import field
4
+ from datetime import datetime
5
+ from queue import Queue
6
+ from threading import Lock
7
+ from uuid import UUID, uuid4
8
+ from typing import TYPE_CHECKING, Any, Callable, Dict, Iterator, Optional, Sequence, Set, Tuple, Type, cast
9
+ from typing_extensions import dataclass_transform
10
+
11
+ from pydantic import GetCoreSchemaHandler, field_serializer
12
+ from pydantic_core import core_schema
13
+
14
+ from vellum.core.pydantic_utilities import UniversalBaseModel
15
+
16
+ from vellum.workflows.constants import UNDEF
17
+ from vellum.workflows.inputs.base import BaseInputs
18
+ from vellum.workflows.references import ExternalInputReference, OutputReference, StateValueReference
19
+ from vellum.workflows.types.generics import StateType
20
+ from vellum.workflows.types.stack import Stack
21
+ from vellum.workflows.types.utils import datetime_now, deepcopy_with_exclusions, get_class_by_qualname, infer_types
22
+
23
+ if TYPE_CHECKING:
24
+ from vellum.workflows.nodes.bases import BaseNode
25
+
26
+
27
+ class _Snapshottable:
28
+ _snapshot_callback: Callable[[], None]
29
+
30
+ def __deepcopy__(self, memo: Any) -> "_Snapshottable":
31
+ return deepcopy_with_exclusions(
32
+ self,
33
+ memo=memo,
34
+ exclusions={
35
+ "_snapshot_callback": self._snapshot_callback,
36
+ },
37
+ )
38
+
39
+
40
+ @dataclass_transform(kw_only_default=True)
41
+ class _BaseStateMeta(type):
42
+ def __getattribute__(cls, name: str) -> Any:
43
+ if not name.startswith("_"):
44
+ instance = vars(cls).get(name)
45
+ types = infer_types(cls, name)
46
+ return StateValueReference(name=name, types=types, instance=instance)
47
+
48
+ return super().__getattribute__(name)
49
+
50
+
51
+ class _SnapshottableDict(dict, _Snapshottable):
52
+ def __setitem__(self, key: Any, value: Any) -> None:
53
+ super().__setitem__(key, value)
54
+ self._snapshot_callback()
55
+
56
+
57
+ def _make_snapshottable(value: Any, snapshot_callback: Callable[[], None]) -> Any:
58
+ """
59
+ Edits any value to make it snapshottable on edit. Made as a separate function from `BaseState` to
60
+ avoid namespace conflicts with subclasses.
61
+ """
62
+ if isinstance(value, _Snapshottable):
63
+ return value
64
+
65
+ if isinstance(value, dict):
66
+ snapshottable_dict = _SnapshottableDict(value)
67
+ snapshottable_dict._snapshot_callback = snapshot_callback
68
+ return snapshottable_dict
69
+
70
+ return value
71
+
72
+
73
+ class NodeExecutionCache:
74
+ _node_execution_ids: Dict[Type["BaseNode"], Stack[UUID]]
75
+ _node_executions_initiated: Dict[Type["BaseNode"], Set[UUID]]
76
+ _dependencies_invoked: Dict[str, Set[str]]
77
+
78
+ def __init__(
79
+ self,
80
+ dependencies_invoked: Optional[Dict[str, Sequence[str]]] = None,
81
+ node_execution_ids: Optional[Dict[str, Sequence[str]]] = None,
82
+ node_executions_initiated: Optional[Dict[str, Sequence[str]]] = None,
83
+ ) -> None:
84
+ self._dependencies_invoked = defaultdict(set)
85
+ self._node_execution_ids = defaultdict(Stack[UUID])
86
+ self._node_executions_initiated = defaultdict(set)
87
+
88
+ for node, dependencies in (dependencies_invoked or {}).items():
89
+ self._dependencies_invoked[node].update(dependencies)
90
+
91
+ for node, execution_ids in (node_execution_ids or {}).items():
92
+ node_class = get_class_by_qualname(node)
93
+ self._node_execution_ids[node_class].extend(UUID(execution_id) for execution_id in execution_ids)
94
+
95
+ for node, execution_ids in (node_executions_initiated or {}).items():
96
+ node_class = get_class_by_qualname(node)
97
+ self._node_executions_initiated[node_class].update({UUID(execution_id) for execution_id in execution_ids})
98
+
99
+ @property
100
+ def dependencies_invoked(self) -> Dict[str, Set[str]]:
101
+ return self._dependencies_invoked
102
+
103
+ def is_node_initiated(self, node: Type["BaseNode"]) -> bool:
104
+ return node in self._node_executions_initiated and len(self._node_executions_initiated[node]) > 0
105
+
106
+ def initiate_node_execution(self, node: Type["BaseNode"], execution_id: UUID) -> None:
107
+ self._node_executions_initiated[node].add(execution_id)
108
+
109
+ def fulfill_node_execution(self, node: Type["BaseNode"], execution_id: UUID) -> None:
110
+ self._node_executions_initiated[node].remove(execution_id)
111
+ self._node_execution_ids[node].push(execution_id)
112
+
113
+ def get_execution_count(self, node: Type["BaseNode"]) -> int:
114
+ return self._node_execution_ids[node].size()
115
+
116
+ def dump(self) -> Dict[str, Any]:
117
+ return {
118
+ "dependencies_invoked": {
119
+ node: list(dependencies) for node, dependencies in self._dependencies_invoked.items()
120
+ },
121
+ "node_executions_initiated": {
122
+ str(node): list(execution_ids) for node, execution_ids in self._node_executions_initiated.items()
123
+ },
124
+ "node_execution_ids": {
125
+ str(node): execution_ids.dump() for node, execution_ids in self._node_execution_ids.items()
126
+ },
127
+ }
128
+
129
+ @classmethod
130
+ def __get_pydantic_core_schema__(
131
+ cls, source_type: Type[Any], handler: GetCoreSchemaHandler
132
+ ) -> core_schema.CoreSchema:
133
+ return core_schema.is_instance_schema(cls)
134
+
135
+
136
+ def uuid4_default_factory() -> UUID:
137
+ """
138
+ Allows us to mock the uuid4 for testing.
139
+ """
140
+ return uuid4()
141
+
142
+
143
+ def default_datetime_factory() -> datetime:
144
+ """
145
+ Makes it possible to mock the datetime factory for testing.
146
+ """
147
+
148
+ return datetime_now()
149
+
150
+
151
+ class StateMeta(UniversalBaseModel):
152
+ id: UUID = field(default_factory=uuid4_default_factory)
153
+ trace_id: UUID = field(default_factory=uuid4_default_factory)
154
+ span_id: UUID = field(default_factory=uuid4_default_factory)
155
+ updated_ts: datetime = field(default_factory=default_datetime_factory)
156
+ workflow_inputs: BaseInputs = field(default_factory=BaseInputs)
157
+ external_inputs: Dict[ExternalInputReference, Any] = field(default_factory=dict)
158
+ node_outputs: Dict[OutputReference, Any] = field(default_factory=dict)
159
+ node_execution_cache: NodeExecutionCache = field(default_factory=NodeExecutionCache)
160
+ parent: Optional["BaseState"] = None
161
+ is_terminated: Optional[bool] = None
162
+ __snapshot_callback__: Optional[Callable[[], None]] = field(init=False, default=None)
163
+
164
+ def model_post_init(self, context: Any) -> None:
165
+ if self.parent:
166
+ self.trace_id = self.parent.meta.trace_id
167
+ self.__snapshot_callback__ = None
168
+
169
+ def add_snapshot_callback(self, callback: Callable[[], None]) -> None:
170
+ self.node_outputs = _make_snapshottable(self.node_outputs, callback)
171
+ self.__snapshot_callback__ = callback
172
+
173
+ def __setattr__(self, name: str, value: Any) -> None:
174
+ if name.startswith("__") or name == "updated_ts":
175
+ super().__setattr__(name, value)
176
+ return
177
+
178
+ super().__setattr__(name, value)
179
+ if callable(self.__snapshot_callback__):
180
+ self.__snapshot_callback__()
181
+
182
+ @field_serializer("node_outputs")
183
+ def serialize_node_outputs(self, node_outputs: Dict[OutputReference, Any], _info: Any) -> Dict[str, Any]:
184
+ return {str(descriptor): value for descriptor, value in node_outputs.items()}
185
+
186
+ @field_serializer("external_inputs")
187
+ def serialize_external_inputs(
188
+ self, external_inputs: Dict[ExternalInputReference, Any], _info: Any
189
+ ) -> Dict[str, Any]:
190
+ return {str(descriptor): value for descriptor, value in external_inputs.items()}
191
+
192
+ def __deepcopy__(self, memo: Optional[Dict[int, Any]] = None) -> "StateMeta":
193
+ if not memo:
194
+ memo = {}
195
+
196
+ new_node_outputs = {
197
+ descriptor: value if isinstance(value, Queue) else deepcopy(value, memo)
198
+ for descriptor, value in self.node_outputs.items()
199
+ }
200
+
201
+ memo[id(self.node_outputs)] = new_node_outputs
202
+ memo[id(self.__snapshot_callback__)] = None
203
+
204
+ return super().__deepcopy__(memo)
205
+
206
+
207
+ class BaseState(metaclass=_BaseStateMeta):
208
+ meta: StateMeta = field(init=False)
209
+
210
+ __lock__: Lock = field(init=False)
211
+ __is_initializing__: bool = field(init=False)
212
+ __snapshot_callback__: Callable[["BaseState"], None] = field(init=False)
213
+
214
+ def __init__(self, meta: Optional[StateMeta] = None, **kwargs: Any) -> None:
215
+ self.__is_initializing__ = True
216
+ self.__snapshot_callback__ = lambda state: None
217
+ self.__lock__ = Lock()
218
+
219
+ self.meta = meta or StateMeta()
220
+ self.meta.add_snapshot_callback(self.__snapshot__)
221
+
222
+ # Make all class attribute values snapshottable
223
+ for name, value in self.__class__.__dict__.items():
224
+ if not name.startswith("_") and name != "meta":
225
+ # Bypass __is_initializing__ instead of `setattr`
226
+ snapshottable_value = _make_snapshottable(value, self.__snapshot__)
227
+ super().__setattr__(name, snapshottable_value)
228
+
229
+ for name, value in kwargs.items():
230
+ setattr(self, name, value)
231
+
232
+ self.__is_initializing__ = False
233
+
234
+ def __deepcopy__(self, memo: Any) -> "BaseState":
235
+ new_state = deepcopy_with_exclusions(
236
+ self,
237
+ exclusions={
238
+ "__lock__": Lock(),
239
+ },
240
+ memo=memo,
241
+ )
242
+ new_state.meta.add_snapshot_callback(new_state.__snapshot__)
243
+ return new_state
244
+
245
+ def __repr__(self) -> str:
246
+ values = "\n".join(
247
+ [f" {key}={value}" for key, value in vars(self).items() if not key.startswith("_") and key != "meta"]
248
+ )
249
+ node_outputs = "\n".join([f" {key}={value}" for key, value in self.meta.node_outputs.items()])
250
+ return f"""\
251
+ {self.__class__.__name__}:
252
+ {values}
253
+ meta:
254
+ id={self.meta.id}
255
+ is_terminated={self.meta.is_terminated}
256
+ updated_ts={self.meta.updated_ts}
257
+ node_outputs:{' Empty' if not node_outputs else ''}
258
+ {node_outputs}
259
+ """
260
+
261
+ def __iter__(self) -> Iterator[Tuple[Any, Any]]:
262
+ """
263
+ Returns an iterator treating all state keys as (key, value) items, allowing consumers to call `dict()`
264
+ on an instance of this class.
265
+ """
266
+
267
+ # If the user sets a default value on state (e.g. something = "foo"), it's not on `instance_attributes` below.
268
+ # So we need to include class_attributes here just in case
269
+ class_attributes = {key: value for key, value in self.__class__.__dict__.items() if not key.startswith("_")}
270
+ instance_attributes = {key: value for key, value in self.__dict__.items() if not key.startswith("__")}
271
+
272
+ all_attributes = {**class_attributes, **instance_attributes}
273
+ items = [(key, value) for key, value in all_attributes.items() if key not in ["_lock"]]
274
+ return iter(items)
275
+
276
+ def __getitem__(self, key: str) -> Any:
277
+ return self.__dict__[key]
278
+
279
+ def __setattr__(self, name: str, value: Any) -> None:
280
+ if name.startswith("_") or self.__is_initializing__:
281
+ super().__setattr__(name, value)
282
+ return
283
+
284
+ snapshottable_value = _make_snapshottable(value, self.__snapshot__)
285
+ super().__setattr__(name, snapshottable_value)
286
+ self.meta.updated_ts = datetime_now()
287
+ self.__snapshot__()
288
+
289
+ def __add__(self, other: StateType) -> StateType:
290
+ """
291
+ Handles merging two states together, preferring the latest state by updated_ts for any given node output.
292
+ """
293
+
294
+ if not isinstance(other, type(self)):
295
+ raise TypeError(f"Cannot add {type(other).__name__} to {type(self).__name__}]")
296
+
297
+ latest_state = self if self.meta.updated_ts >= other.meta.updated_ts else other
298
+ oldest_state = other if latest_state == self else self
299
+
300
+ for descriptor, value in oldest_state.meta.node_outputs.items():
301
+ if descriptor not in latest_state.meta.node_outputs:
302
+ latest_state.meta.node_outputs[descriptor] = value
303
+
304
+ for key, value in oldest_state:
305
+ if not isinstance(key, str):
306
+ continue
307
+
308
+ if key.startswith("_"):
309
+ continue
310
+
311
+ if getattr(latest_state, key, UNDEF) == UNDEF:
312
+ setattr(latest_state, key, value)
313
+
314
+ return cast(StateType, latest_state)
315
+
316
+ def __snapshot__(self) -> None:
317
+ """
318
+ Snapshots the current state to the workflow emitter. The invoked callback is overridden by the
319
+ workflow runner.
320
+ """
321
+ self.__snapshot_callback__(deepcopy(self))
322
+
323
+ @classmethod
324
+ def __get_pydantic_core_schema__(
325
+ cls, source_type: Type[Any], handler: GetCoreSchemaHandler
326
+ ) -> core_schema.CoreSchema:
327
+ return core_schema.is_instance_schema(cls)
@@ -0,0 +1,18 @@
1
+ from functools import cached_property
2
+ from typing import Optional
3
+
4
+ from vellum import Vellum
5
+
6
+ from vellum.workflows.vellum_client import create_vellum_client
7
+
8
+
9
+ class WorkflowContext:
10
+ def __init__(self, _vellum_client: Optional[Vellum] = None):
11
+ self._vellum_client = _vellum_client
12
+
13
+ @cached_property
14
+ def vellum_client(self) -> Vellum:
15
+ if self._vellum_client:
16
+ return self._vellum_client
17
+
18
+ return create_vellum_client()
@@ -0,0 +1,57 @@
1
+ from dataclasses import asdict, is_dataclass
2
+ from datetime import datetime
3
+ import enum
4
+ from json import JSONEncoder
5
+ from uuid import UUID
6
+ from typing import Any, Callable, Dict, Type
7
+
8
+ from pydantic import BaseModel
9
+
10
+ from vellum.workflows.inputs.base import BaseInputs
11
+ from vellum.workflows.outputs.base import BaseOutput, BaseOutputs
12
+ from vellum.workflows.state.base import BaseState, NodeExecutionCache
13
+
14
+
15
+ class DefaultStateEncoder(JSONEncoder):
16
+ encoders: Dict[Type, Callable] = {}
17
+
18
+ def default(self, obj: Any) -> Any:
19
+ if isinstance(obj, BaseState):
20
+ return dict(obj)
21
+
22
+ if isinstance(obj, (BaseInputs, BaseOutputs)):
23
+ return {descriptor.name: value for descriptor, value in obj}
24
+
25
+ if isinstance(obj, BaseOutput):
26
+ return obj.serialize()
27
+
28
+ if isinstance(obj, NodeExecutionCache):
29
+ return obj.dump()
30
+
31
+ if isinstance(obj, UUID):
32
+ return str(obj)
33
+
34
+ if isinstance(obj, set):
35
+ return list(obj)
36
+
37
+ if isinstance(obj, BaseModel):
38
+ return obj.model_dump()
39
+
40
+ if isinstance(obj, datetime):
41
+ return obj.isoformat()
42
+
43
+ if isinstance(obj, enum.Enum):
44
+ return obj.value
45
+
46
+ if is_dataclass(obj):
47
+ # Technically, obj is DataclassInstance | type[DataclassInstance], but asdict expects a DataclassInstance
48
+ # in practice, we only ever pass the former
49
+ return asdict(obj) # type: ignore[call-overload]
50
+
51
+ if isinstance(obj, type):
52
+ return str(obj)
53
+
54
+ if obj.__class__ in self.encoders:
55
+ return self.encoders[obj.__class__](obj)
56
+
57
+ return super().default(obj)
@@ -0,0 +1,28 @@
1
+ from typing import Iterator, List
2
+
3
+ from vellum.workflows.events.workflow import WorkflowEvent
4
+ from vellum.workflows.state.base import BaseState
5
+
6
+
7
+ class Store:
8
+ def __init__(self) -> None:
9
+ self._events: List[WorkflowEvent] = []
10
+ self._state_snapshots: List[BaseState] = []
11
+
12
+ def append_event(self, event: WorkflowEvent) -> None:
13
+ self._events.append(event)
14
+
15
+ def append_state_snapshot(self, state: BaseState) -> None:
16
+ self._state_snapshots.append(state)
17
+
18
+ def clear(self) -> None:
19
+ self._events = []
20
+ self._state_snapshots = []
21
+
22
+ @property
23
+ def events(self) -> Iterator[WorkflowEvent]:
24
+ return iter(self._events)
25
+
26
+ @property
27
+ def state_snapshots(self) -> Iterator[BaseState]:
28
+ return iter(self._state_snapshots)
File without changes
@@ -0,0 +1,113 @@
1
+ from collections import defaultdict
2
+ from copy import deepcopy
3
+ import json
4
+ from typing import Dict
5
+
6
+ from vellum.workflows.nodes.bases import BaseNode
7
+ from vellum.workflows.outputs.base import BaseOutputs
8
+ from vellum.workflows.state.base import BaseState
9
+ from vellum.workflows.state.encoder import DefaultStateEncoder
10
+
11
+ snapshot_count: Dict[int, int] = defaultdict(int)
12
+
13
+
14
+ class MockState(BaseState):
15
+ foo: str
16
+ nested_dict: Dict[str, int] = {}
17
+
18
+ def __snapshot__(self) -> None:
19
+ global snapshot_count
20
+ snapshot_count[id(self)] += 1
21
+
22
+
23
+ class MockNode(BaseNode):
24
+ class Outputs(BaseOutputs):
25
+ baz: str
26
+
27
+
28
+ def test_state_snapshot__node_attribute_edit():
29
+ # GIVEN an initial state instance
30
+ state = MockState(foo="bar")
31
+ assert snapshot_count[id(state)] == 0
32
+
33
+ # WHEN we edit an attribute
34
+ state.foo = "baz"
35
+
36
+ # THEN the snapshot is emitted
37
+ assert snapshot_count[id(state)] == 1
38
+
39
+
40
+ def test_state_snapshot__node_output_edit():
41
+ # GIVEN an initial state instance
42
+ state = MockState(foo="bar")
43
+ assert snapshot_count[id(state)] == 0
44
+
45
+ # WHEN we add a Node Output to state
46
+ for output in MockNode.Outputs:
47
+ state.meta.node_outputs[output] = "hello"
48
+
49
+ # THEN the snapshot is emitted
50
+ assert snapshot_count[id(state)] == 1
51
+
52
+
53
+ def test_state_snapshot__nested_dictionary_edit():
54
+ # GIVEN an initial state instance
55
+ state = MockState(foo="bar")
56
+ assert snapshot_count[id(state)] == 0
57
+
58
+ # WHEN we edit a nested dictionary
59
+ state.nested_dict["hello"] = 1
60
+
61
+ # THEN the snapshot is emitted
62
+ assert snapshot_count[id(state)] == 1
63
+
64
+
65
+ def test_state_deepcopy():
66
+ # GIVEN an initial state instance
67
+ state = MockState(foo="bar")
68
+
69
+ # AND we add a Node Output to state
70
+ state.meta.node_outputs[MockNode.Outputs.baz] = "hello"
71
+
72
+ # WHEN we deepcopy the state
73
+ deepcopied_state = deepcopy(state)
74
+
75
+ # THEN node outputs are deepcopied
76
+ assert deepcopied_state.meta.node_outputs == state.meta.node_outputs
77
+
78
+
79
+ def test_state_deepcopy__with_node_output_updates():
80
+ # GIVEN an initial state instance
81
+ state = MockState(foo="bar")
82
+
83
+ # AND we add a Node Output to state
84
+ state.meta.node_outputs[MockNode.Outputs.baz] = "hello"
85
+
86
+ # AND we deepcopy the state
87
+ deepcopied_state = deepcopy(state)
88
+
89
+ # AND we update the original state
90
+ state.meta.node_outputs[MockNode.Outputs.baz] = "world"
91
+
92
+ # THEN the copied state is not updated
93
+ assert deepcopied_state.meta.node_outputs[MockNode.Outputs.baz] == "hello"
94
+
95
+ # AND the original state has had the correct number of snapshots
96
+ assert snapshot_count[id(state)] == 2
97
+
98
+ # AND the copied state has had the correct number of snapshots
99
+ assert snapshot_count[id(deepcopied_state)] == 0
100
+
101
+
102
+ def test_state_json_serialization__with_node_output_updates():
103
+ # GIVEN an initial state instance
104
+ state = MockState(foo="bar")
105
+
106
+ # AND we add a Node Output to state
107
+ state.meta.node_outputs[MockNode.Outputs.baz] = "hello"
108
+
109
+ # WHEN we serialize the state
110
+ json_state = json.loads(json.dumps(state, cls=DefaultStateEncoder))
111
+
112
+ # THEN the state is serialized correctly
113
+ assert json_state["meta"]["node_outputs"] == {"MockNode.Outputs.baz": "hello"}
File without changes
@@ -0,0 +1,91 @@
1
+ from enum import Enum
2
+ from typing import ( # type: ignore[attr-defined]
3
+ Dict,
4
+ List,
5
+ Union,
6
+ _GenericAlias,
7
+ _SpecialGenericAlias,
8
+ _UnionGenericAlias,
9
+ )
10
+
11
+ from vellum import (
12
+ ChatMessage,
13
+ FunctionCall,
14
+ FunctionCallRequest,
15
+ SearchResult,
16
+ SearchResultRequest,
17
+ VellumAudio,
18
+ VellumAudioRequest,
19
+ VellumError,
20
+ VellumErrorRequest,
21
+ VellumImage,
22
+ VellumImageRequest,
23
+ VellumValue,
24
+ VellumValueRequest,
25
+ )
26
+
27
+ JsonArray = List["Json"]
28
+ JsonObject = Dict[str, "Json"]
29
+ Json = Union[None, bool, int, float, str, JsonArray, JsonObject]
30
+
31
+ # Unions and Generics inherit from `_GenericAlias` instead of `type`
32
+ # In future versions of python, we'll see `_UnionGenericAlias`
33
+ UnderGenericAlias = _GenericAlias
34
+ SpecialGenericAlias = _SpecialGenericAlias
35
+ UnionGenericAlias = _UnionGenericAlias
36
+
37
+
38
+ class VellumSecret:
39
+ name: str
40
+
41
+ def __init__(self, name: str):
42
+ self.name = name
43
+
44
+
45
+ VellumValuePrimitive = Union[
46
+ # String inputs
47
+ str,
48
+ # Chat history inputs
49
+ List[ChatMessage],
50
+ List[ChatMessage],
51
+ # Search results inputs
52
+ List[SearchResultRequest],
53
+ List[SearchResult],
54
+ # JSON inputs
55
+ Json,
56
+ # Number inputs
57
+ float,
58
+ # Function Call Inputs
59
+ FunctionCall,
60
+ FunctionCallRequest,
61
+ # Error Inputs
62
+ VellumError,
63
+ VellumErrorRequest,
64
+ # Array Inputs
65
+ List[VellumValueRequest],
66
+ List[VellumValue],
67
+ # Image Inputs
68
+ VellumImage,
69
+ VellumImageRequest,
70
+ # Audio Inputs
71
+ VellumAudio,
72
+ VellumAudioRequest,
73
+ # Vellum Secrets
74
+ VellumSecret,
75
+ ]
76
+
77
+ EntityInputsInterface = Dict[
78
+ str,
79
+ VellumValuePrimitive,
80
+ ]
81
+
82
+
83
+ class MergeBehavior(Enum):
84
+ AWAIT_ALL = "AWAIT_ALL"
85
+ AWAIT_ANY = "AWAIT_ANY"
86
+
87
+
88
+ class ConditionType(Enum):
89
+ IF = "IF"
90
+ ELIF = "ELIF"
91
+ ELSE = "ELSE"
@@ -0,0 +1,14 @@
1
+ from typing import TYPE_CHECKING, TypeVar
2
+
3
+ if TYPE_CHECKING:
4
+ from vellum.workflows import BaseWorkflow
5
+ from vellum.workflows.inputs import BaseInputs
6
+ from vellum.workflows.nodes import BaseNode
7
+ from vellum.workflows.outputs import BaseOutputs
8
+ from vellum.workflows.state import BaseState
9
+
10
+ NodeType = TypeVar("NodeType", bound="BaseNode")
11
+ StateType = TypeVar("StateType", bound="BaseState")
12
+ WorkflowType = TypeVar("WorkflowType", bound="BaseWorkflow")
13
+ WorkflowInputsType = TypeVar("WorkflowInputsType", bound="BaseInputs")
14
+ OutputsType = TypeVar("OutputsType", bound="BaseOutputs")
@@ -0,0 +1,39 @@
1
+ from collections import deque
2
+ from typing import Deque, Generic, Iterable, List, TypeVar
3
+
4
+ _T = TypeVar("_T")
5
+
6
+
7
+ class Stack(Generic[_T]):
8
+ def __init__(self) -> None:
9
+ self._items: Deque[_T] = deque()
10
+
11
+ def push(self, item: _T) -> None:
12
+ self._items.append(item)
13
+
14
+ def extend(self, items: Iterable[_T]) -> None:
15
+ item_list = list(items)
16
+ for item in item_list[::-1]:
17
+ self._items.append(item)
18
+
19
+ def pop(self) -> _T:
20
+ if not self.is_empty():
21
+ return self._items.pop()
22
+ raise IndexError("pop from empty stack")
23
+
24
+ def peek(self) -> _T:
25
+ if not self.is_empty():
26
+ return self._items[-1]
27
+ raise IndexError("peek from empty stack")
28
+
29
+ def is_empty(self) -> bool:
30
+ return len(self._items) == 0
31
+
32
+ def size(self) -> int:
33
+ return len(self._items)
34
+
35
+ def __repr__(self) -> str:
36
+ return f"Stack({self.dump()})"
37
+
38
+ def dump(self) -> List[_T]:
39
+ return [item for item in self._items][::-1]
File without changes