code0-hercules 1.3.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (258) hide show
  1. code0_hercules-1.3.0.dist-info/METADATA +79 -0
  2. code0_hercules-1.3.0.dist-info/RECORD +258 -0
  3. code0_hercules-1.3.0.dist-info/WHEEL +5 -0
  4. code0_hercules-1.3.0.dist-info/entry_points.txt +2 -0
  5. code0_hercules-1.3.0.dist-info/top_level.txt +1 -0
  6. hercules/__init__.py +81 -0
  7. hercules/_metadata.py +38 -0
  8. hercules/_tsgen/convert.mjs +96 -0
  9. hercules/_tsgen/package-lock.json +366 -0
  10. hercules/_tsgen/package.json +11 -0
  11. hercules/_tucana/__init__.py +29 -0
  12. hercules/_tucana/helpers.py +73 -0
  13. hercules/action.py +345 -0
  14. hercules/actions/__init__.py +21 -0
  15. hercules/actions/execution.py +121 -0
  16. hercules/actions/flow_execution.py +11 -0
  17. hercules/actions/flow_update.py +18 -0
  18. hercules/actions/module_configurations.py +14 -0
  19. hercules/actions/sub_flow_execution.py +14 -0
  20. hercules/cli.py +137 -0
  21. hercules/decorators/__init__.py +0 -0
  22. hercules/decorators/datatype.py +39 -0
  23. hercules/decorators/event.py +35 -0
  24. hercules/decorators/function.py +59 -0
  25. hercules/decorators/meta.py +82 -0
  26. hercules/decorators/runtime_event.py +15 -0
  27. hercules/decorators/runtime_function.py +18 -0
  28. hercules/definitions/__init__.py +162 -0
  29. hercules/definitions/cron_action/__init__.py +0 -0
  30. hercules/definitions/cron_action/data_types/__init__.py +0 -0
  31. hercules/definitions/cron_action/data_types/cron_day_of_month.py +11 -0
  32. hercules/definitions/cron_action/data_types/cron_day_of_week.py +11 -0
  33. hercules/definitions/cron_action/data_types/cron_hour.py +11 -0
  34. hercules/definitions/cron_action/data_types/cron_minute.py +11 -0
  35. hercules/definitions/cron_action/data_types/cron_month.py +11 -0
  36. hercules/definitions/cron_action/runtime_flow_types/__init__.py +0 -0
  37. hercules/definitions/cron_action/runtime_flow_types/cron.py +19 -0
  38. hercules/definitions/rest_action/__init__.py +0 -0
  39. hercules/definitions/rest_action/data_types/__init__.py +0 -0
  40. hercules/definitions/rest_action/data_types/rest_adapter_input.py +19 -0
  41. hercules/definitions/rest_action/data_types/rest_auth_type.py +19 -0
  42. hercules/definitions/rest_action/data_types/rest_auth_value.py +11 -0
  43. hercules/definitions/rest_action/runtime_flow_types/__init__.py +0 -0
  44. hercules/definitions/rest_action/runtime_flow_types/rest.py +20 -0
  45. hercules/definitions/rest_action/runtime_functions/__init__.py +0 -0
  46. hercules/definitions/rest_action/runtime_functions/rest_control_respond.py +21 -0
  47. hercules/definitions/taurus_boolean/__init__.py +0 -0
  48. hercules/definitions/taurus_boolean/data_types/__init__.py +0 -0
  49. hercules/definitions/taurus_boolean/data_types/boolean.py +11 -0
  50. hercules/definitions/taurus_boolean/runtime_functions/__init__.py +0 -0
  51. hercules/definitions/taurus_boolean/runtime_functions/std_boolean_as_number.py +18 -0
  52. hercules/definitions/taurus_boolean/runtime_functions/std_boolean_as_text.py +18 -0
  53. hercules/definitions/taurus_boolean/runtime_functions/std_boolean_from_number.py +18 -0
  54. hercules/definitions/taurus_boolean/runtime_functions/std_boolean_from_text.py +18 -0
  55. hercules/definitions/taurus_boolean/runtime_functions/std_boolean_is_equal.py +19 -0
  56. hercules/definitions/taurus_boolean/runtime_functions/std_boolean_negate.py +18 -0
  57. hercules/definitions/taurus_color/__init__.py +0 -0
  58. hercules/definitions/taurus_color/data_types/__init__.py +0 -0
  59. hercules/definitions/taurus_color/data_types/color.py +17 -0
  60. hercules/definitions/taurus_color/runtime_functions/__init__.py +0 -0
  61. hercules/definitions/taurus_color/runtime_functions/std_color_as_hex.py +18 -0
  62. hercules/definitions/taurus_color/runtime_functions/std_color_as_hsl.py +18 -0
  63. hercules/definitions/taurus_color/runtime_functions/std_color_as_rgb.py +18 -0
  64. hercules/definitions/taurus_color/runtime_functions/std_color_from_hex.py +18 -0
  65. hercules/definitions/taurus_color/runtime_functions/std_color_from_hsl.py +21 -0
  66. hercules/definitions/taurus_color/runtime_functions/std_color_from_rgb.py +21 -0
  67. hercules/definitions/taurus_control/__init__.py +0 -0
  68. hercules/definitions/taurus_control/data_types/__init__.py +0 -0
  69. hercules/definitions/taurus_control/data_types/comparator.py +21 -0
  70. hercules/definitions/taurus_control/data_types/consumer.py +20 -0
  71. hercules/definitions/taurus_control/data_types/predicate.py +20 -0
  72. hercules/definitions/taurus_control/data_types/runnable.py +13 -0
  73. hercules/definitions/taurus_control/data_types/transform.py +20 -0
  74. hercules/definitions/taurus_control/runtime_functions/__init__.py +0 -0
  75. hercules/definitions/taurus_control/runtime_functions/std_control_if.py +19 -0
  76. hercules/definitions/taurus_control/runtime_functions/std_control_if_else.py +21 -0
  77. hercules/definitions/taurus_control/runtime_functions/std_control_return.py +18 -0
  78. hercules/definitions/taurus_control/runtime_functions/std_control_stop.py +16 -0
  79. hercules/definitions/taurus_control/runtime_functions/std_control_value.py +18 -0
  80. hercules/definitions/taurus_date/__init__.py +0 -0
  81. hercules/definitions/taurus_date/data_types/__init__.py +0 -0
  82. hercules/definitions/taurus_date/data_types/date.py +11 -0
  83. hercules/definitions/taurus_date/data_types/hour.py +11 -0
  84. hercules/definitions/taurus_date/data_types/minute.py +11 -0
  85. hercules/definitions/taurus_date/data_types/month.py +22 -0
  86. hercules/definitions/taurus_date/runtime_functions/__init__.py +0 -0
  87. hercules/definitions/taurus_date/runtime_functions/std_date_format.py +20 -0
  88. hercules/definitions/taurus_date/runtime_functions/std_date_from.py +24 -0
  89. hercules/definitions/taurus_date/runtime_functions/std_date_from_text.py +19 -0
  90. hercules/definitions/taurus_date/runtime_functions/std_date_from_unix.py +18 -0
  91. hercules/definitions/taurus_date/runtime_functions/std_date_now.py +16 -0
  92. hercules/definitions/taurus_file/__init__.py +0 -0
  93. hercules/definitions/taurus_file/data_types/__init__.py +0 -0
  94. hercules/definitions/taurus_file/data_types/file.py +19 -0
  95. hercules/definitions/taurus_file/runtime_functions/__init__.py +0 -0
  96. hercules/definitions/taurus_file/runtime_functions/std_file_size.py +18 -0
  97. hercules/definitions/taurus_http/__init__.py +0 -0
  98. hercules/definitions/taurus_http/data_types/__init__.py +0 -0
  99. hercules/definitions/taurus_http/data_types/http_auth_place.py +12 -0
  100. hercules/definitions/taurus_http/data_types/http_auth_type.py +17 -0
  101. hercules/definitions/taurus_http/data_types/http_auth_value.py +11 -0
  102. hercules/definitions/taurus_http/data_types/http_method.py +16 -0
  103. hercules/definitions/taurus_http/data_types/http_payload.py +11 -0
  104. hercules/definitions/taurus_http/data_types/http_request.py +19 -0
  105. hercules/definitions/taurus_http/data_types/http_response.py +18 -0
  106. hercules/definitions/taurus_http/data_types/http_schema.py +31 -0
  107. hercules/definitions/taurus_http/data_types/http_status_code.py +13 -0
  108. hercules/definitions/taurus_http/data_types/http_url.py +13 -0
  109. hercules/definitions/taurus_http/runtime_functions/__init__.py +0 -0
  110. hercules/definitions/taurus_http/runtime_functions/http_request_send.py +26 -0
  111. hercules/definitions/taurus_list/__init__.py +0 -0
  112. hercules/definitions/taurus_list/data_types/__init__.py +0 -0
  113. hercules/definitions/taurus_list/data_types/list.py +13 -0
  114. hercules/definitions/taurus_list/runtime_functions/__init__.py +0 -0
  115. hercules/definitions/taurus_list/runtime_functions/std_list_at.py +20 -0
  116. hercules/definitions/taurus_list/runtime_functions/std_list_concat.py +20 -0
  117. hercules/definitions/taurus_list/runtime_functions/std_list_filter.py +19 -0
  118. hercules/definitions/taurus_list/runtime_functions/std_list_find.py +20 -0
  119. hercules/definitions/taurus_list/runtime_functions/std_list_find_index.py +19 -0
  120. hercules/definitions/taurus_list/runtime_functions/std_list_find_last.py +20 -0
  121. hercules/definitions/taurus_list/runtime_functions/std_list_first.py +18 -0
  122. hercules/definitions/taurus_list/runtime_functions/std_list_flat.py +18 -0
  123. hercules/definitions/taurus_list/runtime_functions/std_list_for_each.py +19 -0
  124. hercules/definitions/taurus_list/runtime_functions/std_list_index_of.py +19 -0
  125. hercules/definitions/taurus_list/runtime_functions/std_list_is_empty.py +18 -0
  126. hercules/definitions/taurus_list/runtime_functions/std_list_join.py +19 -0
  127. hercules/definitions/taurus_list/runtime_functions/std_list_last.py +18 -0
  128. hercules/definitions/taurus_list/runtime_functions/std_list_map.py +19 -0
  129. hercules/definitions/taurus_list/runtime_functions/std_list_max.py +18 -0
  130. hercules/definitions/taurus_list/runtime_functions/std_list_min.py +18 -0
  131. hercules/definitions/taurus_list/runtime_functions/std_list_pop.py +18 -0
  132. hercules/definitions/taurus_list/runtime_functions/std_list_push.py +19 -0
  133. hercules/definitions/taurus_list/runtime_functions/std_list_remove.py +19 -0
  134. hercules/definitions/taurus_list/runtime_functions/std_list_reverse.py +18 -0
  135. hercules/definitions/taurus_list/runtime_functions/std_list_size.py +18 -0
  136. hercules/definitions/taurus_list/runtime_functions/std_list_sort.py +19 -0
  137. hercules/definitions/taurus_list/runtime_functions/std_list_sort_reverse.py +19 -0
  138. hercules/definitions/taurus_list/runtime_functions/std_list_sum.py +18 -0
  139. hercules/definitions/taurus_list/runtime_functions/std_list_to_unique.py +18 -0
  140. hercules/definitions/taurus_number/__init__.py +0 -0
  141. hercules/definitions/taurus_number/data_types/__init__.py +0 -0
  142. hercules/definitions/taurus_number/data_types/number.py +11 -0
  143. hercules/definitions/taurus_number/runtime_functions/__init__.py +0 -0
  144. hercules/definitions/taurus_number/runtime_functions/std_number_abs.py +18 -0
  145. hercules/definitions/taurus_number/runtime_functions/std_number_add.py +19 -0
  146. hercules/definitions/taurus_number/runtime_functions/std_number_arccos.py +18 -0
  147. hercules/definitions/taurus_number/runtime_functions/std_number_arcsin.py +18 -0
  148. hercules/definitions/taurus_number/runtime_functions/std_number_arctan.py +18 -0
  149. hercules/definitions/taurus_number/runtime_functions/std_number_as_text.py +18 -0
  150. hercules/definitions/taurus_number/runtime_functions/std_number_clamp.py +20 -0
  151. hercules/definitions/taurus_number/runtime_functions/std_number_cos.py +18 -0
  152. hercules/definitions/taurus_number/runtime_functions/std_number_cosh.py +18 -0
  153. hercules/definitions/taurus_number/runtime_functions/std_number_divide.py +20 -0
  154. hercules/definitions/taurus_number/runtime_functions/std_number_euler.py +16 -0
  155. hercules/definitions/taurus_number/runtime_functions/std_number_exponential.py +19 -0
  156. hercules/definitions/taurus_number/runtime_functions/std_number_from_text.py +18 -0
  157. hercules/definitions/taurus_number/runtime_functions/std_number_has_digits.py +18 -0
  158. hercules/definitions/taurus_number/runtime_functions/std_number_is_equal.py +19 -0
  159. hercules/definitions/taurus_number/runtime_functions/std_number_is_greater.py +19 -0
  160. hercules/definitions/taurus_number/runtime_functions/std_number_is_less.py +19 -0
  161. hercules/definitions/taurus_number/runtime_functions/std_number_is_positive.py +18 -0
  162. hercules/definitions/taurus_number/runtime_functions/std_number_is_zero.py +18 -0
  163. hercules/definitions/taurus_number/runtime_functions/std_number_ln.py +18 -0
  164. hercules/definitions/taurus_number/runtime_functions/std_number_log.py +19 -0
  165. hercules/definitions/taurus_number/runtime_functions/std_number_max.py +19 -0
  166. hercules/definitions/taurus_number/runtime_functions/std_number_min.py +19 -0
  167. hercules/definitions/taurus_number/runtime_functions/std_number_modulo.py +19 -0
  168. hercules/definitions/taurus_number/runtime_functions/std_number_multiply.py +19 -0
  169. hercules/definitions/taurus_number/runtime_functions/std_number_negate.py +18 -0
  170. hercules/definitions/taurus_number/runtime_functions/std_number_pi.py +16 -0
  171. hercules/definitions/taurus_number/runtime_functions/std_number_random_number.py +19 -0
  172. hercules/definitions/taurus_number/runtime_functions/std_number_remove_digits.py +18 -0
  173. hercules/definitions/taurus_number/runtime_functions/std_number_root.py +19 -0
  174. hercules/definitions/taurus_number/runtime_functions/std_number_round.py +19 -0
  175. hercules/definitions/taurus_number/runtime_functions/std_number_round_down.py +19 -0
  176. hercules/definitions/taurus_number/runtime_functions/std_number_round_up.py +19 -0
  177. hercules/definitions/taurus_number/runtime_functions/std_number_sin.py +18 -0
  178. hercules/definitions/taurus_number/runtime_functions/std_number_sinh.py +18 -0
  179. hercules/definitions/taurus_number/runtime_functions/std_number_square.py +18 -0
  180. hercules/definitions/taurus_number/runtime_functions/std_number_square_root.py +18 -0
  181. hercules/definitions/taurus_number/runtime_functions/std_number_subtract.py +19 -0
  182. hercules/definitions/taurus_number/runtime_functions/std_number_tan.py +18 -0
  183. hercules/definitions/taurus_object/__init__.py +0 -0
  184. hercules/definitions/taurus_object/data_types/__init__.py +0 -0
  185. hercules/definitions/taurus_object/data_types/object.py +13 -0
  186. hercules/definitions/taurus_object/data_types/type.py +13 -0
  187. hercules/definitions/taurus_object/runtime_functions/__init__.py +0 -0
  188. hercules/definitions/taurus_object/runtime_functions/std_object_contains_key.py +19 -0
  189. hercules/definitions/taurus_object/runtime_functions/std_object_get.py +19 -0
  190. hercules/definitions/taurus_object/runtime_functions/std_object_keys.py +18 -0
  191. hercules/definitions/taurus_object/runtime_functions/std_object_set.py +20 -0
  192. hercules/definitions/taurus_object/runtime_functions/std_object_size.py +18 -0
  193. hercules/definitions/taurus_text/__init__.py +0 -0
  194. hercules/definitions/taurus_text/data_types/__init__.py +0 -0
  195. hercules/definitions/taurus_text/data_types/text.py +11 -0
  196. hercules/definitions/taurus_text/data_types/text_encoding.py +13 -0
  197. hercules/definitions/taurus_text/runtime_functions/__init__.py +0 -0
  198. hercules/definitions/taurus_text/runtime_functions/std_text_append.py +19 -0
  199. hercules/definitions/taurus_text/runtime_functions/std_text_as_bytes.py +18 -0
  200. hercules/definitions/taurus_text/runtime_functions/std_text_at.py +19 -0
  201. hercules/definitions/taurus_text/runtime_functions/std_text_byte_size.py +18 -0
  202. hercules/definitions/taurus_text/runtime_functions/std_text_capitalize.py +18 -0
  203. hercules/definitions/taurus_text/runtime_functions/std_text_chars.py +18 -0
  204. hercules/definitions/taurus_text/runtime_functions/std_text_contains.py +19 -0
  205. hercules/definitions/taurus_text/runtime_functions/std_text_decode.py +19 -0
  206. hercules/definitions/taurus_text/runtime_functions/std_text_encode.py +19 -0
  207. hercules/definitions/taurus_text/runtime_functions/std_text_ends_with.py +19 -0
  208. hercules/definitions/taurus_text/runtime_functions/std_text_from_ascii.py +18 -0
  209. hercules/definitions/taurus_text/runtime_functions/std_text_hex.py +18 -0
  210. hercules/definitions/taurus_text/runtime_functions/std_text_index_of.py +19 -0
  211. hercules/definitions/taurus_text/runtime_functions/std_text_insert.py +20 -0
  212. hercules/definitions/taurus_text/runtime_functions/std_text_is_equal.py +19 -0
  213. hercules/definitions/taurus_text/runtime_functions/std_text_length.py +18 -0
  214. hercules/definitions/taurus_text/runtime_functions/std_text_lowercase.py +18 -0
  215. hercules/definitions/taurus_text/runtime_functions/std_text_octal.py +18 -0
  216. hercules/definitions/taurus_text/runtime_functions/std_text_prepend.py +19 -0
  217. hercules/definitions/taurus_text/runtime_functions/std_text_remove.py +20 -0
  218. hercules/definitions/taurus_text/runtime_functions/std_text_replace.py +20 -0
  219. hercules/definitions/taurus_text/runtime_functions/std_text_replace_first.py +21 -0
  220. hercules/definitions/taurus_text/runtime_functions/std_text_replace_last.py +20 -0
  221. hercules/definitions/taurus_text/runtime_functions/std_text_reverse.py +18 -0
  222. hercules/definitions/taurus_text/runtime_functions/std_text_split.py +19 -0
  223. hercules/definitions/taurus_text/runtime_functions/std_text_starts_with.py +19 -0
  224. hercules/definitions/taurus_text/runtime_functions/std_text_swapcase.py +18 -0
  225. hercules/definitions/taurus_text/runtime_functions/std_text_to_ascii.py +18 -0
  226. hercules/definitions/taurus_text/runtime_functions/std_text_trim.py +18 -0
  227. hercules/definitions/taurus_text/runtime_functions/std_text_uppercase.py +18 -0
  228. hercules/events.py +23 -0
  229. hercules/internal/__init__.py +0 -0
  230. hercules/internal/connection.py +37 -0
  231. hercules/internal/literal.py +113 -0
  232. hercules/internal/module_builder.py +261 -0
  233. hercules/internal/pydantic_codegen.py +82 -0
  234. hercules/internal/schema.py +158 -0
  235. hercules/internal/tsgen.py +93 -0
  236. hercules/manager/__init__.py +0 -0
  237. hercules/manager/base.py +73 -0
  238. hercules/manager/config.py +45 -0
  239. hercules/manager/datatype.py +8 -0
  240. hercules/manager/event.py +8 -0
  241. hercules/manager/flow.py +12 -0
  242. hercules/manager/function.py +8 -0
  243. hercules/manager/runtime_event.py +8 -0
  244. hercules/manager/runtime_function.py +8 -0
  245. hercules/map/__init__.py +0 -0
  246. hercules/map/datatype.py +41 -0
  247. hercules/map/event.py +74 -0
  248. hercules/map/function.py +76 -0
  249. hercules/map/runtime_event.py +43 -0
  250. hercules/map/runtime_function.py +64 -0
  251. hercules/models/__init__.py +0 -0
  252. hercules/models/datatype.py +49 -0
  253. hercules/models/event.py +35 -0
  254. hercules/models/function.py +37 -0
  255. hercules/models/runtime_event.py +29 -0
  256. hercules/models/runtime_function.py +33 -0
  257. hercules/schema.py +38 -0
  258. hercules/types.py +88 -0
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::boolean::as_number")
9
+ @Signature("(value: BOOLEAN): NUMBER")
10
+ @Name({"code": "en-US", "content": "Boolean as Number"})
11
+ @Description({"code": "en-US", "content": "Will convert the boolean to a number."})
12
+ @DisplayMessage({"code": "en-US", "content": "Convert ${value} to number"})
13
+ @Alias({"code": "en-US", "content": "to number;numeric;boolean;logic;std;as;number"})
14
+ @DisplayIcon("tabler:toggle-left")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "Converts a boolean to a number."}]})
16
+ class StdBooleanAsNumber(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdBooleanAsNumber.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::boolean::as_text")
9
+ @Signature("(value: BOOLEAN): TEXT")
10
+ @Name({"code": "en-US", "content": "Boolean as Text"})
11
+ @Description({"code": "en-US", "content": "Will convert the boolean to text."})
12
+ @DisplayMessage({"code": "en-US", "content": "Convert ${value} to text"})
13
+ @Alias({"code": "en-US", "content": "to text;string;format number;boolean;logic;std;as;text"})
14
+ @DisplayIcon("tabler:toggle-left")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "Converts a boolean to a text."}]})
16
+ class StdBooleanAsText(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdBooleanAsText.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::boolean::from_number")
9
+ @Signature("(value: NUMBER): BOOLEAN")
10
+ @Name({"code": "en-US", "content": "Boolean from Number"})
11
+ @Description({"code": "en-US", "content": "Will convert the number to a boolean."})
12
+ @DisplayMessage({"code": "en-US", "content": "Convert ${value} to boolean"})
13
+ @Alias({"code": "en-US", "content": "from number;to boolean;convert;boolean;logic;std;from;number"})
14
+ @DisplayIcon("tabler:toggle-left")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "Converts a number to a boolean."}]})
16
+ class StdBooleanFromNumber(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdBooleanFromNumber.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::boolean::from_text")
9
+ @Signature("(value: TEXT): BOOLEAN")
10
+ @Name({"code": "en-US", "content": "Boolean from Text"})
11
+ @Description({"code": "en-US", "content": "Will convert the string to a boolean."})
12
+ @DisplayMessage({"code": "en-US", "content": "Convert ${value} to boolean"})
13
+ @Alias({"code": "en-US", "content": "from text;parse;convert;boolean;logic;std;from;text"})
14
+ @DisplayIcon("tabler:toggle-left")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "Converts a text to a boolean."}]})
16
+ class StdBooleanFromText(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdBooleanFromText.run() is not implemented")
@@ -0,0 +1,19 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::boolean::is_equal")
9
+ @Signature("(first: BOOLEAN, second: BOOLEAN): BOOLEAN")
10
+ @Name({"code": "en-US", "content": "Is Equal"})
11
+ @Description({"code": "en-US", "content": "Compares two boolean values for equality. Returns true if they are the same, false otherwise."})
12
+ @DisplayMessage({"code": "en-US", "content": "${first} Equals ${second}"})
13
+ @Alias({"code": "en-US", "content": "equal;equals;same;boolean;logic;std;is"})
14
+ @DisplayIcon("tabler:toggle-left")
15
+ @Parameter({"runtime_name": "first", "name": [{"code": "en-US", "content": "First"}], "description": [{"code": "en-US", "content": "The first boolean value to compare."}]})
16
+ @Parameter({"runtime_name": "second", "name": [{"code": "en-US", "content": "Second"}], "description": [{"code": "en-US", "content": "The second boolean value to compare."}]})
17
+ class StdBooleanIsEqual(RuntimeFunctionRunnable):
18
+ def run(self, *args):
19
+ raise NotImplementedError("StdBooleanIsEqual.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::boolean::negate")
9
+ @Signature("(value: BOOLEAN): BOOLEAN")
10
+ @Name({"code": "en-US", "content": "Negate Boolean"})
11
+ @Description({"code": "en-US", "content": "Negates a boolean value."})
12
+ @DisplayMessage({"code": "en-US", "content": "Negate ${value}"})
13
+ @Alias({"code": "en-US", "content": "negate;negative;invert;opposite;boolean;logic;std"})
14
+ @DisplayIcon("tabler:toggle-left")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The boolean value to negate."}]})
16
+ class StdBooleanNegate(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdBooleanNegate.run() is not implemented")
File without changes
@@ -0,0 +1,17 @@
1
+ from __future__ import annotations
2
+
3
+ from pydantic import BaseModel, ConfigDict
4
+
5
+
6
+ class Color(BaseModel):
7
+ model_config = ConfigDict(
8
+ extra='forbid',
9
+ )
10
+ hue: float
11
+ saturation: float
12
+ lightness: float
13
+ alpha: float | None = None
14
+
15
+
16
+ from hercules.internal.schema import register_schema
17
+ register_schema(Color, "COLOR")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::color::as_hex")
9
+ @Signature("(value: COLOR): TEXT")
10
+ @Name({"code": "en-US", "content": "Color as Hex"})
11
+ @Description({"code": "en-US", "content": "Formats a color as a `#RRGGBB` hex string, or `#RRGGBBAA` when alpha is not fully opaque."})
12
+ @DisplayMessage({"code": "en-US", "content": "Hex of ${value}"})
13
+ @Alias({"code": "en-US", "content": "to hex;format;convert;color;colour;std;as"})
14
+ @DisplayIcon("tabler:palette")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The color to format as hex."}]})
16
+ class StdColorAsHex(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdColorAsHex.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::color::as_hsl")
9
+ @Signature("(value: COLOR): { hue: number; saturation: number; lightness: number; alpha: number }")
10
+ @Name({"code": "en-US", "content": "Color as HSL"})
11
+ @Description({"code": "en-US", "content": "Converts a color to its hue (0-360), saturation and lightness (0-100) and alpha (0-1) channels."})
12
+ @DisplayMessage({"code": "en-US", "content": "HSL of ${value}"})
13
+ @Alias({"code": "en-US", "content": "to hsl;convert;color;colour;std;as"})
14
+ @DisplayIcon("tabler:palette")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The color to convert to HSL."}]})
16
+ class StdColorAsHsl(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdColorAsHsl.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::color::as_rgb")
9
+ @Signature("(value: COLOR): { red: number; green: number; blue: number; alpha: number }")
10
+ @Name({"code": "en-US", "content": "Color as RGB"})
11
+ @Description({"code": "en-US", "content": "Converts a color to its red, green, blue (0-255) and alpha (0-1) channels."})
12
+ @DisplayMessage({"code": "en-US", "content": "RGB of ${value}"})
13
+ @Alias({"code": "en-US", "content": "to rgb;convert;color;colour;std;as"})
14
+ @DisplayIcon("tabler:palette")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The color to convert to RGB."}]})
16
+ class StdColorAsRgb(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdColorAsRgb.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::color::from_hex")
9
+ @Signature("(value: TEXT): COLOR")
10
+ @Name({"code": "en-US", "content": "Color from Hex"})
11
+ @Description({"code": "en-US", "content": "Parses a `#RRGGBB` or `#RRGGBBAA` hex string into a color."})
12
+ @DisplayMessage({"code": "en-US", "content": "Color from ${value}"})
13
+ @Alias({"code": "en-US", "content": "from hex;parse;convert;color;colour;std;from"})
14
+ @DisplayIcon("tabler:palette")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The hex text to parse, e.g. `#FF00FF` or `#FF00FFAA`."}]})
16
+ class StdColorFromHex(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdColorFromHex.run() is not implemented")
@@ -0,0 +1,21 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::color::from_hsl")
9
+ @Signature("(hue: NUMBER, saturation: NUMBER, lightness: NUMBER, alpha?: NUMBER): COLOR")
10
+ @Name({"code": "en-US", "content": "Color from HSL"})
11
+ @Description({"code": "en-US", "content": "Builds a color from hue (0-360), saturation and lightness (0-100) and an alpha channel (0-1)."})
12
+ @DisplayMessage({"code": "en-US", "content": "Color from ${hue}, ${saturation}, ${lightness}, ${alpha}"})
13
+ @Alias({"code": "en-US", "content": "from hsl;build;convert;color;colour;std;from"})
14
+ @DisplayIcon("tabler:palette")
15
+ @Parameter({"runtime_name": "hue", "name": [{"code": "en-US", "content": "Hue"}], "description": [{"code": "en-US", "content": "The hue, from 0 to 360."}]})
16
+ @Parameter({"runtime_name": "saturation", "name": [{"code": "en-US", "content": "Saturation"}], "description": [{"code": "en-US", "content": "The saturation, from 0 to 100."}]})
17
+ @Parameter({"runtime_name": "lightness", "name": [{"code": "en-US", "content": "Lightness"}], "description": [{"code": "en-US", "content": "The lightness, from 0 to 100."}]})
18
+ @Parameter({"runtime_name": "alpha", "name": [{"code": "en-US", "content": "Alpha"}], "description": [{"code": "en-US", "content": "The opacity, from 0 to 1. Defaults to 1 (fully opaque) when omitted."}]})
19
+ class StdColorFromHsl(RuntimeFunctionRunnable):
20
+ def run(self, *args):
21
+ raise NotImplementedError("StdColorFromHsl.run() is not implemented")
@@ -0,0 +1,21 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::color::from_rgb")
9
+ @Signature("(red: NUMBER, green: NUMBER, blue: NUMBER, alpha?: NUMBER): COLOR")
10
+ @Name({"code": "en-US", "content": "Color from RGB"})
11
+ @Description({"code": "en-US", "content": "Builds a color from red, green and blue channels (0-255) and an alpha channel (0-1)."})
12
+ @DisplayMessage({"code": "en-US", "content": "Color from ${red}, ${green}, ${blue}, ${alpha}"})
13
+ @Alias({"code": "en-US", "content": "from rgb;build;convert;color;colour;std;from"})
14
+ @DisplayIcon("tabler:palette")
15
+ @Parameter({"runtime_name": "red", "name": [{"code": "en-US", "content": "Red"}], "description": [{"code": "en-US", "content": "The red channel, from 0 to 255."}]})
16
+ @Parameter({"runtime_name": "green", "name": [{"code": "en-US", "content": "Green"}], "description": [{"code": "en-US", "content": "The green channel, from 0 to 255."}]})
17
+ @Parameter({"runtime_name": "blue", "name": [{"code": "en-US", "content": "Blue"}], "description": [{"code": "en-US", "content": "The blue channel, from 0 to 255."}]})
18
+ @Parameter({"runtime_name": "alpha", "name": [{"code": "en-US", "content": "Alpha"}], "description": [{"code": "en-US", "content": "The opacity, from 0 to 1. Defaults to 1 (fully opaque) when omitted."}]})
19
+ class StdColorFromRgb(RuntimeFunctionRunnable):
20
+ def run(self, *args):
21
+ raise NotImplementedError("StdColorFromRgb.run() is not implemented")
File without changes
@@ -0,0 +1,21 @@
1
+ from __future__ import annotations
2
+
3
+ from typing import Any
4
+
5
+ from pydantic import BaseModel, ConfigDict
6
+
7
+
8
+ class NamedArgs(BaseModel):
9
+ model_config = ConfigDict(
10
+ extra='forbid',
11
+ )
12
+ left: Any
13
+ right: Any
14
+
15
+
16
+ class Comparator(BaseModel):
17
+ namedArgs: NamedArgs | None = None
18
+
19
+
20
+ from hercules.internal.schema import register_schema
21
+ register_schema(Comparator, "COMPARATOR")
@@ -0,0 +1,20 @@
1
+ from __future__ import annotations
2
+
3
+ from typing import Any
4
+
5
+ from pydantic import BaseModel, ConfigDict
6
+
7
+
8
+ class NamedArgs(BaseModel):
9
+ model_config = ConfigDict(
10
+ extra='forbid',
11
+ )
12
+ item: Any
13
+
14
+
15
+ class Consumer(BaseModel):
16
+ namedArgs: NamedArgs | None = None
17
+
18
+
19
+ from hercules.internal.schema import register_schema
20
+ register_schema(Consumer, "CONSUMER")
@@ -0,0 +1,20 @@
1
+ from __future__ import annotations
2
+
3
+ from typing import Any
4
+
5
+ from pydantic import BaseModel, ConfigDict
6
+
7
+
8
+ class NamedArgs(BaseModel):
9
+ model_config = ConfigDict(
10
+ extra='forbid',
11
+ )
12
+ item: Any
13
+
14
+
15
+ class Predicate(BaseModel):
16
+ namedArgs: NamedArgs | None = None
17
+
18
+
19
+ from hercules.internal.schema import register_schema
20
+ register_schema(Predicate, "PREDICATE")
@@ -0,0 +1,13 @@
1
+ from __future__ import annotations
2
+
3
+ from typing import Any
4
+
5
+ from pydantic import RootModel
6
+
7
+
8
+ class Runnable(RootModel[Any]):
9
+ root: Any
10
+
11
+
12
+ from hercules.internal.schema import register_schema
13
+ register_schema(Runnable, "RUNNABLE")
@@ -0,0 +1,20 @@
1
+ from __future__ import annotations
2
+
3
+ from typing import Any
4
+
5
+ from pydantic import BaseModel, ConfigDict
6
+
7
+
8
+ class NamedArgs(BaseModel):
9
+ model_config = ConfigDict(
10
+ extra='forbid',
11
+ )
12
+ item: Any
13
+
14
+
15
+ class Transform(BaseModel):
16
+ namedArgs: NamedArgs | None = None
17
+
18
+
19
+ from hercules.internal.schema import register_schema
20
+ register_schema(Transform, "TRANSFORM")
@@ -0,0 +1,19 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::control::if")
9
+ @Signature("(condition: BOOLEAN, runnable: RUNNABLE): void")
10
+ @Name({"code": "en-US", "content": "If"})
11
+ @Description({"code": "en-US", "content": "The 'If' runnable evaluates a boolean condition and, if it is true, executes the provided runnable. If the condition is false, execution continues without running the runnable."})
12
+ @DisplayMessage({"code": "en-US", "content": "If ${condition} is True do ${runnable}"})
13
+ @Alias({"code": "en-US", "content": "if;control;std"})
14
+ @DisplayIcon("tabler:arrow-ramp-right-2")
15
+ @Parameter({"runtime_name": "condition", "name": [{"code": "en-US", "content": "Condition"}], "description": [{"code": "en-US", "content": "Specifies the condition that determines whether the provided runnable should be executed. If this condition evaluates to true, the execution proceeds with the runnable defined in the second parameter."}]})
16
+ @Parameter({"runtime_name": "runnable", "name": [{"code": "en-US", "content": "Runnable"}], "description": [{"code": "en-US", "content": "Defines the runnable that runs if the condition evaluates to true."}]})
17
+ class StdControlIf(RuntimeFunctionRunnable):
18
+ def run(self, *args):
19
+ raise NotImplementedError("StdControlIf.run() is not implemented")
@@ -0,0 +1,21 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Documentation, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::control::if_else")
9
+ @Signature("(condition: BOOLEAN, runnable: RUNNABLE, else_runnable: RUNNABLE): void")
10
+ @Name({"code": "en-US", "content": "If-Else"})
11
+ @Description({"code": "en-US", "content": "Evaluates a condition and executes either the Then Runnable or the Else Runnable."})
12
+ @Documentation({"code": "en-US", "content": "Evaluates a boolean condition. If true, executes the Runnable. Otherwise executes the Else Runnable."})
13
+ @DisplayMessage({"code": "en-US", "content": "If ${condition} is True do ${then_runnable} else ${else_runnable}"})
14
+ @Alias({"code": "en-US", "content": "if_else;control;std;if;else"})
15
+ @DisplayIcon("tabler:arrow-ramp-right")
16
+ @Parameter({"runtime_name": "condition", "name": [{"code": "en-US", "content": "Condition"}], "description": [{"code": "en-US", "content": "Boolean that determines which branch to execute. If true the Runnable runs otherwise the Else Runnable runs."}]})
17
+ @Parameter({"runtime_name": "runnable", "name": [{"code": "en-US", "content": "Runnable"}], "description": [{"code": "en-US", "content": "Defines the runnable that runs if the condition evaluates to true."}]})
18
+ @Parameter({"runtime_name": "else_runnable", "name": [{"code": "en-US", "content": "Else Runnable"}], "description": [{"code": "en-US", "content": "Defines the runnable that runs if the condition evaluates to false."}]})
19
+ class StdControlIfElse(RuntimeFunctionRunnable):
20
+ def run(self, *args):
21
+ raise NotImplementedError("StdControlIfElse.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::control::return")
9
+ @Signature("<T>(value: T): T")
10
+ @Name({"code": "en-US", "content": "Return"})
11
+ @Description({"code": "en-US", "content": "Ends the current context and returns the specified value to the upper scope."})
12
+ @DisplayMessage({"code": "en-US", "content": "Return ${value}"})
13
+ @Alias({"code": "en-US", "content": "return;control;std"})
14
+ @DisplayIcon("tabler:arrow-back")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Return Value"}], "description": [{"code": "en-US", "content": "The value to be returned to the upper context."}]})
16
+ class StdControlReturn(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdControlReturn.run() is not implemented")
@@ -0,0 +1,16 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+
5
+
6
+ @OmitRuntimeFunction()
7
+ @Identifier("std::control::stop")
8
+ @Signature("(): void")
9
+ @Name({"code": "en-US", "content": "Stop"})
10
+ @Description({"code": "en-US", "content": "Terminates the current execution context entirely, halting all ongoing and future iterations. Once invoked, no additional steps or loops within this context will be executed. This node behaves like a global stop or termination signal within the flow."})
11
+ @DisplayMessage({"code": "en-US", "content": "Stop"})
12
+ @Alias({"code": "en-US", "content": "stop;control;std"})
13
+ @DisplayIcon("tabler:xbox-x")
14
+ class StdControlStop(RuntimeFunctionRunnable):
15
+ def run(self, *args):
16
+ raise NotImplementedError("StdControlStop.run() is not implemented")
@@ -0,0 +1,18 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::control::value")
9
+ @Signature("<T>(value: T): T")
10
+ @Name({"code": "en-US", "content": "Set Value"})
11
+ @Description({"code": "en-US", "content": "Saves the given value."})
12
+ @DisplayMessage({"code": "en-US", "content": "Save ${value}"})
13
+ @Alias({"code": "en-US", "content": "value;save;create;control;std"})
14
+ @DisplayIcon("tabler:new-section")
15
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The value to save."}]})
16
+ class StdControlValue(RuntimeFunctionRunnable):
17
+ def run(self, *args):
18
+ raise NotImplementedError("StdControlValue.run() is not implemented")
File without changes
@@ -0,0 +1,11 @@
1
+ from __future__ import annotations
2
+
3
+ from pydantic import RootModel
4
+
5
+
6
+ class Date(RootModel[float]):
7
+ root: float
8
+
9
+
10
+ from hercules.internal.schema import register_schema
11
+ register_schema(Date, "DATE")
@@ -0,0 +1,11 @@
1
+ from __future__ import annotations
2
+
3
+ from pydantic import RootModel
4
+
5
+
6
+ class Hour(RootModel[float]):
7
+ root: float
8
+
9
+
10
+ from hercules.internal.schema import register_schema
11
+ register_schema(Hour, "HOUR")
@@ -0,0 +1,11 @@
1
+ from __future__ import annotations
2
+
3
+ from pydantic import RootModel
4
+
5
+
6
+ class Minute(RootModel[float]):
7
+ root: float
8
+
9
+
10
+ from hercules.internal.schema import register_schema
11
+ register_schema(Minute, "MINUTE")
@@ -0,0 +1,22 @@
1
+ from __future__ import annotations
2
+
3
+ from enum import Enum
4
+
5
+
6
+ class Month(Enum):
7
+ JAN = 'JAN'
8
+ FEB = 'FEB'
9
+ MAR = 'MAR'
10
+ APR = 'APR'
11
+ MAY = 'MAY'
12
+ JUN = 'JUN'
13
+ JUL = 'JUL'
14
+ AUG = 'AUG'
15
+ SEP = 'SEP'
16
+ OCT = 'OCT'
17
+ NOV = 'NOV'
18
+ DEC = 'DEC'
19
+
20
+
21
+ from hercules.internal.schema import register_schema
22
+ register_schema(Month, "MONTH")
@@ -0,0 +1,20 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import ThrowsError, Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::date::format")
9
+ @Signature("(date: DATE, pattern: TEXT): TEXT")
10
+ @Name({"code": "en-US", "content": "Format Date"})
11
+ @Description({"code": "en-US", "content": "Converts a date into a formatted text using the given pattern. Throws an error if the pattern is invalid."})
12
+ @DisplayMessage({"code": "en-US", "content": "Format ${date} as ${pattern}"})
13
+ @Alias({"code": "en-US", "content": "format;pattern;stringify;to text;display;date;time;std"})
14
+ @DisplayIcon("tabler:calendar-cog")
15
+ @ThrowsError()
16
+ @Parameter({"runtime_name": "date", "name": [{"code": "en-US", "content": "Date"}], "description": [{"code": "en-US", "content": "The date that will be formatted."}]})
17
+ @Parameter({"runtime_name": "pattern", "name": [{"code": "en-US", "content": "Pattern"}], "description": [{"code": "en-US", "content": "The pattern used to format the date, for example DD:MM:YYYY or YY:MM:DD."}]})
18
+ class StdDateFormat(RuntimeFunctionRunnable):
19
+ def run(self, *args):
20
+ raise NotImplementedError("StdDateFormat.run() is not implemented")
@@ -0,0 +1,24 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import ThrowsError, Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::date::from")
9
+ @Signature("(year: NUMBER, month: MONTH, day: NUMBER, hour: HOUR, minute: MINUTE, second: NUMBER): DATE")
10
+ @Name({"code": "en-US", "content": "Date from Components"})
11
+ @Description({"code": "en-US", "content": "Creates a date from the given year, month, day, hour, minute and second. Throws an error if the combination does not represent a valid date."})
12
+ @DisplayMessage({"code": "en-US", "content": "Date ${day} ${month} ${year} at ${hour}:${minute}:${second}"})
13
+ @Alias({"code": "en-US", "content": "from;create;build;construct;date;year;month;day;time;std"})
14
+ @DisplayIcon("tabler:calendar-plus")
15
+ @ThrowsError()
16
+ @Parameter({"runtime_name": "year", "name": [{"code": "en-US", "content": "Year"}], "description": [{"code": "en-US", "content": "The year of the date, for example 2026."}]})
17
+ @Parameter({"runtime_name": "month", "name": [{"code": "en-US", "content": "Month"}], "description": [{"code": "en-US", "content": "The month of the date."}]})
18
+ @Parameter({"runtime_name": "day", "name": [{"code": "en-US", "content": "Day"}], "description": [{"code": "en-US", "content": "The day of the month, ranging from 1 to 31."}]})
19
+ @Parameter({"runtime_name": "hour", "name": [{"code": "en-US", "content": "Hour"}], "description": [{"code": "en-US", "content": "The hour of the day, ranging from 0 to 23."}]})
20
+ @Parameter({"runtime_name": "minute", "name": [{"code": "en-US", "content": "Minute"}], "description": [{"code": "en-US", "content": "The minute of the hour, ranging from 0 to 59."}]})
21
+ @Parameter({"runtime_name": "second", "name": [{"code": "en-US", "content": "Second"}], "description": [{"code": "en-US", "content": "The second of the minute, ranging from 0 to 59."}]})
22
+ class StdDateFrom(RuntimeFunctionRunnable):
23
+ def run(self, *args):
24
+ raise NotImplementedError("StdDateFrom.run() is not implemented")
@@ -0,0 +1,19 @@
1
+ from hercules.models.runtime_function import RuntimeFunctionRunnable
2
+ from hercules.decorators.meta import Alias, Description, DisplayIcon, DisplayMessage, Identifier, Name, Signature
3
+ from hercules.decorators.runtime_function import OmitRuntimeFunction
4
+ from hercules.decorators.function import ThrowsError, Parameter
5
+
6
+
7
+ @OmitRuntimeFunction()
8
+ @Identifier("std::date::from_text")
9
+ @Signature("(value: TEXT): DATE")
10
+ @Name({"code": "en-US", "content": "Date from Text"})
11
+ @Description({"code": "en-US", "content": "Parses a date from its textual representation. Throws an error if the text cannot be parsed into a valid date."})
12
+ @DisplayMessage({"code": "en-US", "content": "Date from text ${value}"})
13
+ @Alias({"code": "en-US", "content": "from text;parse;string;iso;from;date;time;std"})
14
+ @DisplayIcon("tabler:calendar-plus")
15
+ @ThrowsError()
16
+ @Parameter({"runtime_name": "value", "name": [{"code": "en-US", "content": "Value"}], "description": [{"code": "en-US", "content": "The textual representation of the date, for example an ISO 8601 string like 2026-07-28T10:15:30Z."}]})
17
+ class StdDateFromText(RuntimeFunctionRunnable):
18
+ def run(self, *args):
19
+ raise NotImplementedError("StdDateFromText.run() is not implemented")