@dpantani/tdmcp 0.1.0

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 (765) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +413 -0
  3. package/dist/cli/agent.d.ts +466 -0
  4. package/dist/cli/agent.js +1902 -0
  5. package/dist/cli/agent.js.map +1 -0
  6. package/dist/index.d.ts +2 -0
  7. package/dist/index.js +4375 -0
  8. package/dist/index.js.map +1 -0
  9. package/dist/knowledge/data/glsl.json +1 -0
  10. package/dist/knowledge/data/meta.json +1 -0
  11. package/dist/knowledge/data/operators/ableton_link_chop.json +1322 -0
  12. package/dist/knowledge/data/operators/accumulate_pop.json +912 -0
  13. package/dist/knowledge/data/operators/actor_comp.json +7477 -0
  14. package/dist/knowledge/data/operators/add_sop.json +946 -0
  15. package/dist/knowledge/data/operators/add_top.json +1653 -0
  16. package/dist/knowledge/data/operators/alembic_sop.json +521 -0
  17. package/dist/knowledge/data/operators/align_sop.json +949 -0
  18. package/dist/knowledge/data/operators/ambient_light_comp.json +1698 -0
  19. package/dist/knowledge/data/operators/analyze_chop.json +710 -0
  20. package/dist/knowledge/data/operators/analyze_pop.json +698 -0
  21. package/dist/knowledge/data/operators/analyze_top.json +1276 -0
  22. package/dist/knowledge/data/operators/angle_chop.json +711 -0
  23. package/dist/knowledge/data/operators/animation_comp.json +2448 -0
  24. package/dist/knowledge/data/operators/annotate_comp.json +2913 -0
  25. package/dist/knowledge/data/operators/anti_alias_top.json +1278 -0
  26. package/dist/knowledge/data/operators/arm_sop.json +1747 -0
  27. package/dist/knowledge/data/operators/art-net_dat.json +472 -0
  28. package/dist/knowledge/data/operators/attribute_chop.json +617 -0
  29. package/dist/knowledge/data/operators/attribute_combine_pop.json +596 -0
  30. package/dist/knowledge/data/operators/attribute_convert_pop.json +462 -0
  31. package/dist/knowledge/data/operators/attribute_create_sop.json +191 -0
  32. package/dist/knowledge/data/operators/attribute_pop.json +1078 -0
  33. package/dist/knowledge/data/operators/attribute_sop.json +429 -0
  34. package/dist/knowledge/data/operators/audio_band_eq_chop.json +1228 -0
  35. package/dist/knowledge/data/operators/audio_binaural_chop.json +711 -0
  36. package/dist/knowledge/data/operators/audio_device_in_chop.json +1793 -0
  37. package/dist/knowledge/data/operators/audio_device_out_chop.json +1840 -0
  38. package/dist/knowledge/data/operators/audio_devices_dat.json +616 -0
  39. package/dist/knowledge/data/operators/audio_dynamics_chop.json +1132 -0
  40. package/dist/knowledge/data/operators/audio_file_in_chop.json +1605 -0
  41. package/dist/knowledge/data/operators/audio_file_out_chop.json +945 -0
  42. package/dist/knowledge/data/operators/audio_filter_chop.json +850 -0
  43. package/dist/knowledge/data/operators/audio_movie_chop.json +851 -0
  44. package/dist/knowledge/data/operators/audio_ndi_chop.json +526 -0
  45. package/dist/knowledge/data/operators/audio_oscillator_chop.json +1087 -0
  46. package/dist/knowledge/data/operators/audio_para_eq_chop.json +1276 -0
  47. package/dist/knowledge/data/operators/audio_play_chop.json +1744 -0
  48. package/dist/knowledge/data/operators/audio_render_chop.json +754 -0
  49. package/dist/knowledge/data/operators/audio_spectrum_chop.json +850 -0
  50. package/dist/knowledge/data/operators/audio_stream_in_chop.json +1039 -0
  51. package/dist/knowledge/data/operators/audio_stream_out_chop.json +806 -0
  52. package/dist/knowledge/data/operators/audio_vst_chop.json +1419 -0
  53. package/dist/knowledge/data/operators/audio_web_render_chop.json +523 -0
  54. package/dist/knowledge/data/operators/base_comp.json +1180 -0
  55. package/dist/knowledge/data/operators/basis_sop.json +805 -0
  56. package/dist/knowledge/data/operators/beat_chop.json +1745 -0
  57. package/dist/knowledge/data/operators/bind_chop.json +613 -0
  58. package/dist/knowledge/data/operators/blacktrax_chop.json +1180 -0
  59. package/dist/knowledge/data/operators/blend_chop.json +616 -0
  60. package/dist/knowledge/data/operators/blend_comp.json +3626 -0
  61. package/dist/knowledge/data/operators/blend_pop.json +618 -0
  62. package/dist/knowledge/data/operators/blend_sop.json +477 -0
  63. package/dist/knowledge/data/operators/blob_track_chop.json +1275 -0
  64. package/dist/knowledge/data/operators/blob_track_top.json +1931 -0
  65. package/dist/knowledge/data/operators/bloom_top.json +1370 -0
  66. package/dist/knowledge/data/operators/blur_top.json +1428 -0
  67. package/dist/knowledge/data/operators/body_track_chop.json +1233 -0
  68. package/dist/knowledge/data/operators/bone_comp.json +3672 -0
  69. package/dist/knowledge/data/operators/bone_group_sop.json +148 -0
  70. package/dist/knowledge/data/operators/boolean_sop.json +336 -0
  71. package/dist/knowledge/data/operators/box_pop.json +827 -0
  72. package/dist/knowledge/data/operators/box_sop.json +994 -0
  73. package/dist/knowledge/data/operators/bridge_sop.json +806 -0
  74. package/dist/knowledge/data/operators/bullet_solver_chop.json +898 -0
  75. package/dist/knowledge/data/operators/bullet_solver_comp.json +3720 -0
  76. package/dist/knowledge/data/operators/button_comp.json +6636 -0
  77. package/dist/knowledge/data/operators/cache_blend_pop.json +292 -0
  78. package/dist/knowledge/data/operators/cache_pop.json +412 -0
  79. package/dist/knowledge/data/operators/cache_select_pop.json +280 -0
  80. package/dist/knowledge/data/operators/cache_select_top.json +946 -0
  81. package/dist/knowledge/data/operators/cache_sop.json +478 -0
  82. package/dist/knowledge/data/operators/cache_top.json +1559 -0
  83. package/dist/knowledge/data/operators/camera_blend_comp.json +4847 -0
  84. package/dist/knowledge/data/operators/camera_comp.json +215 -0
  85. package/dist/knowledge/data/operators/cap_sop.json +527 -0
  86. package/dist/knowledge/data/operators/capture_region_sop.json +568 -0
  87. package/dist/knowledge/data/operators/capture_sop.json +619 -0
  88. package/dist/knowledge/data/operators/carve_sop.json +902 -0
  89. package/dist/knowledge/data/operators/channel_mix_top.json +1088 -0
  90. package/dist/knowledge/data/operators/chop_execute_dat.json +1277 -0
  91. package/dist/knowledge/data/operators/chop_to_dat.json +571 -0
  92. package/dist/knowledge/data/operators/chop_to_pop.json +1236 -0
  93. package/dist/knowledge/data/operators/chop_to_sop.json +714 -0
  94. package/dist/knowledge/data/operators/chop_to_top.json +1231 -0
  95. package/dist/knowledge/data/operators/chroma_key_top.json +1653 -0
  96. package/dist/knowledge/data/operators/circle_pop.json +821 -0
  97. package/dist/knowledge/data/operators/circle_sop.json +991 -0
  98. package/dist/knowledge/data/operators/circle_top.json +2307 -0
  99. package/dist/knowledge/data/operators/clay_sop.json +1231 -0
  100. package/dist/knowledge/data/operators/clip_blender_chop.json +1931 -0
  101. package/dist/knowledge/data/operators/clip_chop.json +1366 -0
  102. package/dist/knowledge/data/operators/clip_dat.json +849 -0
  103. package/dist/knowledge/data/operators/clip_sop.json +475 -0
  104. package/dist/knowledge/data/operators/clock_chop.json +1792 -0
  105. package/dist/knowledge/data/operators/composite_chop.json +1414 -0
  106. package/dist/knowledge/data/operators/composite_top.json +2131 -0
  107. package/dist/knowledge/data/operators/connectivity_pop.json +11 -0
  108. package/dist/knowledge/data/operators/constant_chop.json +1238 -0
  109. package/dist/knowledge/data/operators/constant_mat.json +2727 -0
  110. package/dist/knowledge/data/operators/constant_top.json +1323 -0
  111. package/dist/knowledge/data/operators/constraint_comp.json +2076 -0
  112. package/dist/knowledge/data/operators/container_comp.json +6299 -0
  113. package/dist/knowledge/data/operators/convert_dat.json +569 -0
  114. package/dist/knowledge/data/operators/convert_pop.json +322 -0
  115. package/dist/knowledge/data/operators/convert_sop.json +807 -0
  116. package/dist/knowledge/data/operators/convolve_top.json +1041 -0
  117. package/dist/knowledge/data/operators/copy_chop.json +993 -0
  118. package/dist/knowledge/data/operators/copy_pop.json +1799 -0
  119. package/dist/knowledge/data/operators/copy_sop.json +1887 -0
  120. package/dist/knowledge/data/operators/corner_pin_top.json +1512 -0
  121. package/dist/knowledge/data/operators/count_chop.json +1369 -0
  122. package/dist/knowledge/data/operators/cplusplus_chop.json +569 -0
  123. package/dist/knowledge/data/operators/cplusplus_dat.json +477 -0
  124. package/dist/knowledge/data/operators/cplusplus_pop.json +308 -0
  125. package/dist/knowledge/data/operators/cplusplus_sop.json +195 -0
  126. package/dist/knowledge/data/operators/cplusplus_top.json +1276 -0
  127. package/dist/knowledge/data/operators/creep_sop.json +385 -0
  128. package/dist/knowledge/data/operators/crop_top.json +1323 -0
  129. package/dist/knowledge/data/operators/cross_chop.json +478 -0
  130. package/dist/knowledge/data/operators/cross_top.json +1559 -0
  131. package/dist/knowledge/data/operators/cube_map_top.json +946 -0
  132. package/dist/knowledge/data/operators/curve_pop.json +1525 -0
  133. package/dist/knowledge/data/operators/curveclay_sop.json +618 -0
  134. package/dist/knowledge/data/operators/curvesect_sop.json +665 -0
  135. package/dist/knowledge/data/operators/cycle_chop.json +1040 -0
  136. package/dist/knowledge/data/operators/dat_execute_dat.json +1230 -0
  137. package/dist/knowledge/data/operators/dat_to_chop.json +1510 -0
  138. package/dist/knowledge/data/operators/dat_to_pop.json +756 -0
  139. package/dist/knowledge/data/operators/dat_to_sop.json +902 -0
  140. package/dist/knowledge/data/operators/deform_sop.json +291 -0
  141. package/dist/knowledge/data/operators/delay_chop.json +615 -0
  142. package/dist/knowledge/data/operators/delete_chop.json +1556 -0
  143. package/dist/knowledge/data/operators/delete_pop.json +1422 -0
  144. package/dist/knowledge/data/operators/delete_sop.json +1230 -0
  145. package/dist/knowledge/data/operators/depth_mat.json +1933 -0
  146. package/dist/knowledge/data/operators/depth_top.json +1322 -0
  147. package/dist/knowledge/data/operators/difference_top.json +1647 -0
  148. package/dist/knowledge/data/operators/dimension_pop.json +280 -0
  149. package/dist/knowledge/data/operators/direct_display_out_top.json +997 -0
  150. package/dist/knowledge/data/operators/directx_in_top.json +901 -0
  151. package/dist/knowledge/data/operators/directx_out_top.json +948 -0
  152. package/dist/knowledge/data/operators/displace_top.json +1322 -0
  153. package/dist/knowledge/data/operators/divide_sop.json +713 -0
  154. package/dist/knowledge/data/operators/dmx_fixture_pop.json +772 -0
  155. package/dist/knowledge/data/operators/dmx_in_chop.json +1420 -0
  156. package/dist/knowledge/data/operators/dmx_map_dat.json +11 -0
  157. package/dist/knowledge/data/operators/dmx_out_chop.json +1843 -0
  158. package/dist/knowledge/data/operators/dmx_out_pop.json +668 -0
  159. package/dist/knowledge/data/operators/edge_top.json +1370 -0
  160. package/dist/knowledge/data/operators/emboss_top.json +1275 -0
  161. package/dist/knowledge/data/operators/engine_comp.json +2685 -0
  162. package/dist/knowledge/data/operators/envelope_chop.json +946 -0
  163. package/dist/knowledge/data/operators/environment_light_comp.json +2121 -0
  164. package/dist/knowledge/data/operators/error_dat.json +949 -0
  165. package/dist/knowledge/data/operators/etherdream_dat.json +472 -0
  166. package/dist/knowledge/data/operators/evaluate_dat.json +1650 -0
  167. package/dist/knowledge/data/operators/event_chop.json +1653 -0
  168. package/dist/knowledge/data/operators/examine_dat.json +1182 -0
  169. package/dist/knowledge/data/operators/execute_dat.json +1184 -0
  170. package/dist/knowledge/data/operators/experimental +0 -0
  171. package/dist/knowledge/data/operators/expression_chop.json +617 -0
  172. package/dist/knowledge/data/operators/extend_chop.json +617 -0
  173. package/dist/knowledge/data/operators/extrude_pop.json +316 -0
  174. package/dist/knowledge/data/operators/extrude_sop.json +1081 -0
  175. package/dist/knowledge/data/operators/face_track_chop.json +998 -0
  176. package/dist/knowledge/data/operators/face_track_sop.json +244 -0
  177. package/dist/knowledge/data/operators/facet_pop.json +480 -0
  178. package/dist/knowledge/data/operators/facet_sop.json +619 -0
  179. package/dist/knowledge/data/operators/fan_chop.json +804 -0
  180. package/dist/knowledge/data/operators/fbx_comp.json +4942 -0
  181. package/dist/knowledge/data/operators/feedback_chop.json +664 -0
  182. package/dist/knowledge/data/operators/feedback_pop.json +368 -0
  183. package/dist/knowledge/data/operators/feedback_top.json +191 -0
  184. package/dist/knowledge/data/operators/field_pop.json +2304 -0
  185. package/dist/knowledge/data/operators/fifo_dat.json +711 -0
  186. package/dist/knowledge/data/operators/file_in_chop.json +1181 -0
  187. package/dist/knowledge/data/operators/file_in_dat.json +527 -0
  188. package/dist/knowledge/data/operators/file_in_pop.json +298 -0
  189. package/dist/knowledge/data/operators/file_in_sop.json +289 -0
  190. package/dist/knowledge/data/operators/file_out_chop.json +618 -0
  191. package/dist/knowledge/data/operators/file_out_dat.json +524 -0
  192. package/dist/knowledge/data/operators/fillet_sop.json +949 -0
  193. package/dist/knowledge/data/operators/filter_chop.json +1134 -0
  194. package/dist/knowledge/data/operators/fit_sop.json +1087 -0
  195. package/dist/knowledge/data/operators/fit_top.json +1559 -0
  196. package/dist/knowledge/data/operators/flip_top.json +1040 -0
  197. package/dist/knowledge/data/operators/folder_dat.json +1888 -0
  198. package/dist/knowledge/data/operators/force_comp.json +1701 -0
  199. package/dist/knowledge/data/operators/force_pop.json +878 -0
  200. package/dist/knowledge/data/operators/force_sop.json +429 -0
  201. package/dist/knowledge/data/operators/fractal_sop.json +479 -0
  202. package/dist/knowledge/data/operators/freed_in_chop.json +808 -0
  203. package/dist/knowledge/data/operators/freed_out_chop.json +714 -0
  204. package/dist/knowledge/data/operators/function_chop.json +1086 -0
  205. package/dist/knowledge/data/operators/function_top.json +1558 -0
  206. package/dist/knowledge/data/operators/geo_text_comp.json +7338 -0
  207. package/dist/knowledge/data/operators/geometry_comp.json +199 -0
  208. package/dist/knowledge/data/operators/gesture_chop.json +1133 -0
  209. package/dist/knowledge/data/operators/glsl_advanced_pop.json +3539 -0
  210. package/dist/knowledge/data/operators/glsl_comp.json +6962 -0
  211. package/dist/knowledge/data/operators/glsl_copy_pop.json +2128 -0
  212. package/dist/knowledge/data/operators/glsl_mat.json +3720 -0
  213. package/dist/knowledge/data/operators/glsl_multi_top.json +2922 -0
  214. package/dist/knowledge/data/operators/glsl_pop.json +2317 -0
  215. package/dist/knowledge/data/operators/glsl_select_pop.json +280 -0
  216. package/dist/knowledge/data/operators/glsl_top.json +2922 -0
  217. package/dist/knowledge/data/operators/grid_pop.json +1029 -0
  218. package/dist/knowledge/data/operators/grid_sop.json +1041 -0
  219. package/dist/knowledge/data/operators/group_pop.json +1423 -0
  220. package/dist/knowledge/data/operators/group_sop.json +2075 -0
  221. package/dist/knowledge/data/operators/handle_chop.json +712 -0
  222. package/dist/knowledge/data/operators/handle_comp.json +2171 -0
  223. package/dist/knowledge/data/operators/histogram_pop.json +533 -0
  224. package/dist/knowledge/data/operators/hog_chop.json +620 -0
  225. package/dist/knowledge/data/operators/hokuyo_chop.json +941 -0
  226. package/dist/knowledge/data/operators/hold_chop.json +664 -0
  227. package/dist/knowledge/data/operators/hole_sop.json +291 -0
  228. package/dist/knowledge/data/operators/hsv_adjust_top.json +1370 -0
  229. package/dist/knowledge/data/operators/hsv_to_rgb_top.json +847 -0
  230. package/dist/knowledge/data/operators/import_select_chop.json +1838 -0
  231. package/dist/knowledge/data/operators/import_select_pop.json +808 -0
  232. package/dist/knowledge/data/operators/import_select_sop.json +1463 -0
  233. package/dist/knowledge/data/operators/import_select_top.json +993 -0
  234. package/dist/knowledge/data/operators/impulse_force_comp.json +1415 -0
  235. package/dist/knowledge/data/operators/in_chop.json +572 -0
  236. package/dist/knowledge/data/operators/in_dat.json +386 -0
  237. package/dist/knowledge/data/operators/in_mat.json +1559 -0
  238. package/dist/knowledge/data/operators/in_pop.json +280 -0
  239. package/dist/knowledge/data/operators/in_sop.json +102 -0
  240. package/dist/knowledge/data/operators/in_top.json +903 -0
  241. package/dist/knowledge/data/operators/index.json +1 -0
  242. package/dist/knowledge/data/operators/indices_dat.json +526 -0
  243. package/dist/knowledge/data/operators/info_chop.json +757 -0
  244. package/dist/knowledge/data/operators/info_dat.json +430 -0
  245. package/dist/knowledge/data/operators/insert_dat.json +896 -0
  246. package/dist/knowledge/data/operators/inside_top.json +1652 -0
  247. package/dist/knowledge/data/operators/interpolate_chop.json +711 -0
  248. package/dist/knowledge/data/operators/inverse_curve_chop.json +898 -0
  249. package/dist/knowledge/data/operators/inverse_curve_sop.json +97 -0
  250. package/dist/knowledge/data/operators/inverse_kin_chop.json +850 -0
  251. package/dist/knowledge/data/operators/iso_surface_sop.json +337 -0
  252. package/dist/knowledge/data/operators/join_chop.json +1368 -0
  253. package/dist/knowledge/data/operators/join_sop.json +667 -0
  254. package/dist/knowledge/data/operators/joint_sop.json +573 -0
  255. package/dist/knowledge/data/operators/joystick_chop.json +1558 -0
  256. package/dist/knowledge/data/operators/json_dat.json +619 -0
  257. package/dist/knowledge/data/operators/keyboard_in_chop.json +1041 -0
  258. package/dist/knowledge/data/operators/keyboard_in_dat.json +950 -0
  259. package/dist/knowledge/data/operators/keyframe_chop.json +711 -0
  260. package/dist/knowledge/data/operators/kinect_azure_chop.json +1092 -0
  261. package/dist/knowledge/data/operators/kinect_azure_select_top.json +1187 -0
  262. package/dist/knowledge/data/operators/kinect_azure_top.json +2737 -0
  263. package/dist/knowledge/data/operators/kinect_chop.json +1700 -0
  264. package/dist/knowledge/data/operators/kinect_sop.json +379 -0
  265. package/dist/knowledge/data/operators/kinect_top.json +1700 -0
  266. package/dist/knowledge/data/operators/lag_chop.json +1040 -0
  267. package/dist/knowledge/data/operators/laser_chop.json +1746 -0
  268. package/dist/knowledge/data/operators/laser_device_chop.json +1228 -0
  269. package/dist/knowledge/data/operators/lattice_sop.json +432 -0
  270. package/dist/knowledge/data/operators/layout_top.json +1936 -0
  271. package/dist/knowledge/data/operators/leap_motion_chop.json +1699 -0
  272. package/dist/knowledge/data/operators/leap_motion_top.json +1323 -0
  273. package/dist/knowledge/data/operators/lens_distort_top.json +2262 -0
  274. package/dist/knowledge/data/operators/leuze_rod4_chop.json +1371 -0
  275. package/dist/knowledge/data/operators/level_top.json +2273 -0
  276. package/dist/knowledge/data/operators/lfo_chop.json +1088 -0
  277. package/dist/knowledge/data/operators/light_comp.json +5410 -0
  278. package/dist/knowledge/data/operators/limit_chop.json +1133 -0
  279. package/dist/knowledge/data/operators/limit_pop.json +1243 -0
  280. package/dist/knowledge/data/operators/limit_sop.json +2075 -0
  281. package/dist/knowledge/data/operators/limit_top.json +1557 -0
  282. package/dist/knowledge/data/operators/line_break_pop.json +447 -0
  283. package/dist/knowledge/data/operators/line_divide_pop.json +688 -0
  284. package/dist/knowledge/data/operators/line_mat.json +5551 -0
  285. package/dist/knowledge/data/operators/line_metrics_pop.json +548 -0
  286. package/dist/knowledge/data/operators/line_pop.json +1343 -0
  287. package/dist/knowledge/data/operators/line_smooth_pop.json +1028 -0
  288. package/dist/knowledge/data/operators/line_sop.json +330 -0
  289. package/dist/knowledge/data/operators/line_thick_sop.json +478 -0
  290. package/dist/knowledge/data/operators/list_comp.json +6729 -0
  291. package/dist/knowledge/data/operators/lod_sop.json +431 -0
  292. package/dist/knowledge/data/operators/logic_chop.json +946 -0
  293. package/dist/knowledge/data/operators/lookup_attribute_pop.json +684 -0
  294. package/dist/knowledge/data/operators/lookup_channel_pop.json +1140 -0
  295. package/dist/knowledge/data/operators/lookup_chop.json +992 -0
  296. package/dist/knowledge/data/operators/lookup_dat.json +664 -0
  297. package/dist/knowledge/data/operators/lookup_texture_pop.json +1494 -0
  298. package/dist/knowledge/data/operators/lookup_top.json +1510 -0
  299. package/dist/knowledge/data/operators/lsystem_sop.json +1699 -0
  300. package/dist/knowledge/data/operators/ltc_in_chop.json +760 -0
  301. package/dist/knowledge/data/operators/ltc_out_chop.json +1512 -0
  302. package/dist/knowledge/data/operators/luma_blur_top.json +1316 -0
  303. package/dist/knowledge/data/operators/luma_level_top.json +1746 -0
  304. package/dist/knowledge/data/operators/magnet_sop.json +759 -0
  305. package/dist/knowledge/data/operators/material_sop.json +98 -0
  306. package/dist/knowledge/data/operators/math_chop.json +1193 -0
  307. package/dist/knowledge/data/operators/math_combine_pop.json +4283 -0
  308. package/dist/knowledge/data/operators/math_mix_pop.json +2641 -0
  309. package/dist/knowledge/data/operators/math_pop.json +2163 -0
  310. package/dist/knowledge/data/operators/math_top.json +1885 -0
  311. package/dist/knowledge/data/operators/matte_top.json +994 -0
  312. package/dist/knowledge/data/operators/media_file_info_dat.json +571 -0
  313. package/dist/knowledge/data/operators/merge_chop.json +627 -0
  314. package/dist/knowledge/data/operators/merge_dat.json +620 -0
  315. package/dist/knowledge/data/operators/merge_pop.json +764 -0
  316. package/dist/knowledge/data/operators/merge_sop.json +100 -0
  317. package/dist/knowledge/data/operators/metaball_sop.json +476 -0
  318. package/dist/knowledge/data/operators/midi_event_dat.json +1135 -0
  319. package/dist/knowledge/data/operators/midi_in_chop.json +3297 -0
  320. package/dist/knowledge/data/operators/midi_in_dat.json +1183 -0
  321. package/dist/knowledge/data/operators/midi_in_map_chop.json +946 -0
  322. package/dist/knowledge/data/operators/midi_out_chop.json +1793 -0
  323. package/dist/knowledge/data/operators/mirror_top.json +1271 -0
  324. package/dist/knowledge/data/operators/model_sop.json +52 -0
  325. package/dist/knowledge/data/operators/monitors_dat.json +617 -0
  326. package/dist/knowledge/data/operators/monochrome_top.json +1041 -0
  327. package/dist/knowledge/data/operators/mosys_chop.json +804 -0
  328. package/dist/knowledge/data/operators/mosys_top.json +896 -0
  329. package/dist/knowledge/data/operators/mouse_in_chop.json +1275 -0
  330. package/dist/knowledge/data/operators/mouse_out_chop.json +711 -0
  331. package/dist/knowledge/data/operators/movie_file_in_top.json +3546 -0
  332. package/dist/knowledge/data/operators/movie_file_out_top.json +3390 -0
  333. package/dist/knowledge/data/operators/mpcdi_dat.json +711 -0
  334. package/dist/knowledge/data/operators/mpcdi_top.json +1369 -0
  335. package/dist/knowledge/data/operators/mqtt_client_dat.json +1229 -0
  336. package/dist/knowledge/data/operators/multi_touch_in_dat.json +1185 -0
  337. package/dist/knowledge/data/operators/multiply_top.json +1647 -0
  338. package/dist/knowledge/data/operators/ncam_chop.json +1039 -0
  339. package/dist/knowledge/data/operators/ncam_top.json +1039 -0
  340. package/dist/knowledge/data/operators/ndi_dat.json +478 -0
  341. package/dist/knowledge/data/operators/ndi_in_top.json +1326 -0
  342. package/dist/knowledge/data/operators/ndi_out_top.json +1420 -0
  343. package/dist/knowledge/data/operators/neighbor_pop.json +534 -0
  344. package/dist/knowledge/data/operators/noise_chop.json +2230 -0
  345. package/dist/knowledge/data/operators/noise_pop.json +2107 -0
  346. package/dist/knowledge/data/operators/noise_sop.json +1136 -0
  347. package/dist/knowledge/data/operators/noise_top.json +2356 -0
  348. package/dist/knowledge/data/operators/normal_map_top.json +1182 -0
  349. package/dist/knowledge/data/operators/normal_pop.json +1488 -0
  350. package/dist/knowledge/data/operators/normalize_pop.json +1298 -0
  351. package/dist/knowledge/data/operators/notch_top.json +1511 -0
  352. package/dist/knowledge/data/operators/null_chop.json +673 -0
  353. package/dist/knowledge/data/operators/null_comp.json +2921 -0
  354. package/dist/knowledge/data/operators/null_dat.json +344 -0
  355. package/dist/knowledge/data/operators/null_mat.json +1511 -0
  356. package/dist/knowledge/data/operators/null_pop.json +18 -0
  357. package/dist/knowledge/data/operators/null_sop.json +100 -0
  358. package/dist/knowledge/data/operators/null_top.json +862 -0
  359. package/dist/knowledge/data/operators/nvidia_background_top.json +996 -0
  360. package/dist/knowledge/data/operators/nvidia_denoise_top.json +1089 -0
  361. package/dist/knowledge/data/operators/nvidia_flex_solver_comp.json +5367 -0
  362. package/dist/knowledge/data/operators/nvidia_flex_top.json +995 -0
  363. package/dist/knowledge/data/operators/nvidia_flow_emitter_comp.json +7812 -0
  364. package/dist/knowledge/data/operators/nvidia_flow_top.json +3675 -0
  365. package/dist/knowledge/data/operators/nvidia_upscaler_top.json +1089 -0
  366. package/dist/knowledge/data/operators/oak_device_chop.json +1372 -0
  367. package/dist/knowledge/data/operators/oak_select_chop.json +947 -0
  368. package/dist/knowledge/data/operators/oak_select_top.json +1323 -0
  369. package/dist/knowledge/data/operators/object_chop.json +2356 -0
  370. package/dist/knowledge/data/operators/object_merge_sop.json +194 -0
  371. package/dist/knowledge/data/operators/oculus_audio_chop.json +1371 -0
  372. package/dist/knowledge/data/operators/oculus_rift_chop.json +901 -0
  373. package/dist/knowledge/data/operators/oculus_rift_sop.json +147 -0
  374. package/dist/knowledge/data/operators/oculus_rift_top.json +995 -0
  375. package/dist/knowledge/data/operators/op_execute_dat.json +1463 -0
  376. package/dist/knowledge/data/operators/op_find_dat.json +2827 -0
  377. package/dist/knowledge/data/operators/op_viewer_comp.json +6586 -0
  378. package/dist/knowledge/data/operators/op_viewer_top.json +993 -0
  379. package/dist/knowledge/data/operators/opencolorio_top.json +1980 -0
  380. package/dist/knowledge/data/operators/openvr_chop.json +1135 -0
  381. package/dist/knowledge/data/operators/openvr_sop.json +99 -0
  382. package/dist/knowledge/data/operators/openvr_top.json +900 -0
  383. package/dist/knowledge/data/operators/optical_flow_top.json +1230 -0
  384. package/dist/knowledge/data/operators/optitrack_in_chop.json +854 -0
  385. package/dist/knowledge/data/operators/orbbec_select_top.json +1042 -0
  386. package/dist/knowledge/data/operators/orbbec_top.json +1558 -0
  387. package/dist/knowledge/data/operators/osc_in_chop.json +1371 -0
  388. package/dist/knowledge/data/operators/osc_in_dat.json +1280 -0
  389. package/dist/knowledge/data/operators/osc_out_chop.json +1138 -0
  390. package/dist/knowledge/data/operators/osc_out_dat.json +1280 -0
  391. package/dist/knowledge/data/operators/ouster_select_top.json +1228 -0
  392. package/dist/knowledge/data/operators/ouster_top.json +2404 -0
  393. package/dist/knowledge/data/operators/out_chop.json +476 -0
  394. package/dist/knowledge/data/operators/out_dat.json +386 -0
  395. package/dist/knowledge/data/operators/out_mat.json +1982 -0
  396. package/dist/knowledge/data/operators/out_pop.json +286 -0
  397. package/dist/knowledge/data/operators/out_sop.json +93 -0
  398. package/dist/knowledge/data/operators/out_top.json +903 -0
  399. package/dist/knowledge/data/operators/outside_top.json +1651 -0
  400. package/dist/knowledge/data/operators/over_top.json +1651 -0
  401. package/dist/knowledge/data/operators/override_chop.json +663 -0
  402. package/dist/knowledge/data/operators/pack_top.json +946 -0
  403. package/dist/knowledge/data/operators/pan_tilt_chop.json +11 -0
  404. package/dist/knowledge/data/operators/panel_chop.json +663 -0
  405. package/dist/knowledge/data/operators/panel_execute_dat.json +1182 -0
  406. package/dist/knowledge/data/operators/pangolin_chop.json +1135 -0
  407. package/dist/knowledge/data/operators/parameter_chop.json +803 -0
  408. package/dist/knowledge/data/operators/parameter_comp.json +6962 -0
  409. package/dist/knowledge/data/operators/parameter_dat.json +1698 -0
  410. package/dist/knowledge/data/operators/parameter_execute_dat.json +1371 -0
  411. package/dist/knowledge/data/operators/pargroup_execute_dat.json +1271 -0
  412. package/dist/knowledge/data/operators/particle_pop.json +1130 -0
  413. package/dist/knowledge/data/operators/particle_sop.json +2214 -0
  414. package/dist/knowledge/data/operators/pattern_chop.json +1697 -0
  415. package/dist/knowledge/data/operators/pattern_pop.json +1767 -0
  416. package/dist/knowledge/data/operators/pbr_mat.json +4990 -0
  417. package/dist/knowledge/data/operators/perform_chop.json +1651 -0
  418. package/dist/knowledge/data/operators/perform_dat.json +1184 -0
  419. package/dist/knowledge/data/operators/phaser_chop.json +618 -0
  420. package/dist/knowledge/data/operators/phaser_pop.json +1043 -0
  421. package/dist/knowledge/data/operators/phong_mat.json +5458 -0
  422. package/dist/knowledge/data/operators/photoshop_in_top.json +1418 -0
  423. package/dist/knowledge/data/operators/pipe_in_chop.json +1323 -0
  424. package/dist/knowledge/data/operators/pipe_out_chop.json +1182 -0
  425. package/dist/knowledge/data/operators/point_file_in_pop.json +1246 -0
  426. package/dist/knowledge/data/operators/point_file_in_top.json +3343 -0
  427. package/dist/knowledge/data/operators/point_file_select_top.json +1086 -0
  428. package/dist/knowledge/data/operators/point_generator_pop.json +1407 -0
  429. package/dist/knowledge/data/operators/point_pop.json +752 -0
  430. package/dist/knowledge/data/operators/point_sop.json +2171 -0
  431. package/dist/knowledge/data/operators/point_sprite_mat.json +2920 -0
  432. package/dist/knowledge/data/operators/point_transform_top.json +2779 -0
  433. package/dist/knowledge/data/operators/polygonize_pop.json +386 -0
  434. package/dist/knowledge/data/operators/polyloft_sop.json +759 -0
  435. package/dist/knowledge/data/operators/polypatch_sop.json +761 -0
  436. package/dist/knowledge/data/operators/polyreduce_sop.json +806 -0
  437. package/dist/knowledge/data/operators/polyspline_sop.json +667 -0
  438. package/dist/knowledge/data/operators/polystitch_sop.json +336 -0
  439. package/dist/knowledge/data/operators/pop_to_chop.json +11 -0
  440. package/dist/knowledge/data/operators/pop_to_dat.json +11 -0
  441. package/dist/knowledge/data/operators/pop_to_sop.json +11 -0
  442. package/dist/knowledge/data/operators/pop_to_top.json +11 -0
  443. package/dist/knowledge/data/operators/posistagenet_chop.json +900 -0
  444. package/dist/knowledge/data/operators/prefilter_map_top.json +947 -0
  445. package/dist/knowledge/data/operators/primitive_pop.json +1254 -0
  446. package/dist/knowledge/data/operators/primitive_sop.json +2075 -0
  447. package/dist/knowledge/data/operators/profile_sop.json +756 -0
  448. package/dist/knowledge/data/operators/project_sop.json +1276 -0
  449. package/dist/knowledge/data/operators/projection_pop.json +1060 -0
  450. package/dist/knowledge/data/operators/projection_top.json +1135 -0
  451. package/dist/knowledge/data/operators/proximity_pop.json +505 -0
  452. package/dist/knowledge/data/operators/pulse_chop.json +1744 -0
  453. package/dist/knowledge/data/operators/quantize_pop.json +1052 -0
  454. package/dist/knowledge/data/operators/rails_sop.json +853 -0
  455. package/dist/knowledge/data/operators/ramp_top.json +1899 -0
  456. package/dist/knowledge/data/operators/random_pop.json +1219 -0
  457. package/dist/knowledge/data/operators/raster_sop.json +291 -0
  458. package/dist/knowledge/data/operators/ray_pop.json +497 -0
  459. package/dist/knowledge/data/operators/ray_sop.json +856 -0
  460. package/dist/knowledge/data/operators/realsense_top.json +1608 -0
  461. package/dist/knowledge/data/operators/record_chop.json +1040 -0
  462. package/dist/knowledge/data/operators/rectangle_pop.json +800 -0
  463. package/dist/knowledge/data/operators/rectangle_sop.json +758 -0
  464. package/dist/knowledge/data/operators/rectangle_top.json +2259 -0
  465. package/dist/knowledge/data/operators/refine_sop.json +667 -0
  466. package/dist/knowledge/data/operators/remap_top.json +1182 -0
  467. package/dist/knowledge/data/operators/rename_chop.json +522 -0
  468. package/dist/knowledge/data/operators/render_pass_top.json +3108 -0
  469. package/dist/knowledge/data/operators/render_pick_chop.json +2119 -0
  470. package/dist/knowledge/data/operators/render_pick_dat.json +1840 -0
  471. package/dist/knowledge/data/operators/render_select_top.json +1086 -0
  472. package/dist/knowledge/data/operators/render_top.json +218 -0
  473. package/dist/knowledge/data/operators/renderstream_in_chop.json +617 -0
  474. package/dist/knowledge/data/operators/renderstream_in_top.json +950 -0
  475. package/dist/knowledge/data/operators/renderstream_out_top.json +997 -0
  476. package/dist/knowledge/data/operators/reorder_chop.json +946 -0
  477. package/dist/knowledge/data/operators/reorder_dat.json +711 -0
  478. package/dist/knowledge/data/operators/reorder_top.json +1229 -0
  479. package/dist/knowledge/data/operators/replace_chop.json +568 -0
  480. package/dist/knowledge/data/operators/replicator_comp.json +2208 -0
  481. package/dist/knowledge/data/operators/rerange_pop.json +892 -0
  482. package/dist/knowledge/data/operators/resample_chop.json +1134 -0
  483. package/dist/knowledge/data/operators/resample_sop.json +619 -0
  484. package/dist/knowledge/data/operators/resolution_top.json +892 -0
  485. package/dist/knowledge/data/operators/revolve_pop.json +607 -0
  486. package/dist/knowledge/data/operators/revolve_sop.json +714 -0
  487. package/dist/knowledge/data/operators/rgb_key_top.json +1654 -0
  488. package/dist/knowledge/data/operators/rgb_to_hsv_top.json +853 -0
  489. package/dist/knowledge/data/operators/s_curve_chop.json +1176 -0
  490. package/dist/knowledge/data/operators/scalable_display_top.json +1042 -0
  491. package/dist/knowledge/data/operators/screen_grab_top.json +1465 -0
  492. package/dist/knowledge/data/operators/screen_top.json +1652 -0
  493. package/dist/knowledge/data/operators/script_chop.json +520 -0
  494. package/dist/knowledge/data/operators/script_dat.json +429 -0
  495. package/dist/knowledge/data/operators/script_sop.json +146 -0
  496. package/dist/knowledge/data/operators/script_top.json +947 -0
  497. package/dist/knowledge/data/operators/select_chop.json +899 -0
  498. package/dist/knowledge/data/operators/select_comp.json +5645 -0
  499. package/dist/knowledge/data/operators/select_dat.json +1371 -0
  500. package/dist/knowledge/data/operators/select_mat.json +1977 -0
  501. package/dist/knowledge/data/operators/select_pop.json +347 -0
  502. package/dist/knowledge/data/operators/select_sop.json +100 -0
  503. package/dist/knowledge/data/operators/select_top.json +901 -0
  504. package/dist/knowledge/data/operators/sequence_blend_sop.json +336 -0
  505. package/dist/knowledge/data/operators/serial_chop.json +1182 -0
  506. package/dist/knowledge/data/operators/serial_dat.json +1418 -0
  507. package/dist/knowledge/data/operators/shared_mem_in_chop.json +620 -0
  508. package/dist/knowledge/data/operators/shared_mem_in_comp.json +1323 -0
  509. package/dist/knowledge/data/operators/shared_mem_in_top.json +994 -0
  510. package/dist/knowledge/data/operators/shared_mem_out_chop.json +620 -0
  511. package/dist/knowledge/data/operators/shared_mem_out_comp.json +1372 -0
  512. package/dist/knowledge/data/operators/shared_mem_out_top.json +1137 -0
  513. package/dist/knowledge/data/operators/shift_chop.json +899 -0
  514. package/dist/knowledge/data/operators/shuffle_chop.json +612 -0
  515. package/dist/knowledge/data/operators/sick_top.json +1322 -0
  516. package/dist/knowledge/data/operators/skin_deform_pop.json +972 -0
  517. package/dist/knowledge/data/operators/skin_pop.json +330 -0
  518. package/dist/knowledge/data/operators/skin_sop.json +711 -0
  519. package/dist/knowledge/data/operators/slider_comp.json +6918 -0
  520. package/dist/knowledge/data/operators/slope_chop.json +661 -0
  521. package/dist/knowledge/data/operators/slope_top.json +1370 -0
  522. package/dist/knowledge/data/operators/socketio_dat.json +945 -0
  523. package/dist/knowledge/data/operators/sop_to_chop.json +1137 -0
  524. package/dist/knowledge/data/operators/sop_to_dat.json +622 -0
  525. package/dist/knowledge/data/operators/sop_to_pop.json +409 -0
  526. package/dist/knowledge/data/operators/sort_chop.json +805 -0
  527. package/dist/knowledge/data/operators/sort_dat.json +894 -0
  528. package/dist/knowledge/data/operators/sort_pop.json +1023 -0
  529. package/dist/knowledge/data/operators/sort_sop.json +569 -0
  530. package/dist/knowledge/data/operators/spectrum_top.json +1182 -0
  531. package/dist/knowledge/data/operators/speed_chop.json +1180 -0
  532. package/dist/knowledge/data/operators/sphere_pop.json +1141 -0
  533. package/dist/knowledge/data/operators/sphere_sop.json +1370 -0
  534. package/dist/knowledge/data/operators/splice_chop.json +1226 -0
  535. package/dist/knowledge/data/operators/spring_chop.json +899 -0
  536. package/dist/knowledge/data/operators/spring_sop.json +1463 -0
  537. package/dist/knowledge/data/operators/sprinkle_pop.json +420 -0
  538. package/dist/knowledge/data/operators/sprinkle_sop.json +337 -0
  539. package/dist/knowledge/data/operators/sprite_sop.json +571 -0
  540. package/dist/knowledge/data/operators/ssao_top.json +1510 -0
  541. package/dist/knowledge/data/operators/st2110_device_chop.json +11 -0
  542. package/dist/knowledge/data/operators/stitch_sop.json +807 -0
  543. package/dist/knowledge/data/operators/stretch_chop.json +945 -0
  544. package/dist/knowledge/data/operators/stype_in_chop.json +756 -0
  545. package/dist/knowledge/data/operators/stype_out_chop.json +852 -0
  546. package/dist/knowledge/data/operators/stype_top.json +943 -0
  547. package/dist/knowledge/data/operators/subdivide_pop.json +292 -0
  548. package/dist/knowledge/data/operators/subdivide_sop.json +618 -0
  549. package/dist/knowledge/data/operators/substance_select_top.json +945 -0
  550. package/dist/knowledge/data/operators/substance_top.json +1182 -0
  551. package/dist/knowledge/data/operators/substitute_dat.json +1605 -0
  552. package/dist/knowledge/data/operators/subtract_top.json +1650 -0
  553. package/dist/knowledge/data/operators/superquad_sop.json +1135 -0
  554. package/dist/knowledge/data/operators/surfsect_sop.json +853 -0
  555. package/dist/knowledge/data/operators/sweep_sop.json +947 -0
  556. package/dist/knowledge/data/operators/switch_chop.json +523 -0
  557. package/dist/knowledge/data/operators/switch_dat.json +383 -0
  558. package/dist/knowledge/data/operators/switch_mat.json +1553 -0
  559. package/dist/knowledge/data/operators/switch_pop.json +496 -0
  560. package/dist/knowledge/data/operators/switch_sop.json +101 -0
  561. package/dist/knowledge/data/operators/switch_top.json +959 -0
  562. package/dist/knowledge/data/operators/sync_in_chop.json +617 -0
  563. package/dist/knowledge/data/operators/sync_out_chop.json +993 -0
  564. package/dist/knowledge/data/operators/syphon_spout_in_top.json +946 -0
  565. package/dist/knowledge/data/operators/syphon_spout_out_top.json +948 -0
  566. package/dist/knowledge/data/operators/table_comp.json +7009 -0
  567. package/dist/knowledge/data/operators/table_dat.json +1080 -0
  568. package/dist/knowledge/data/operators/tablet_chop.json +1367 -0
  569. package/dist/knowledge/data/operators/text_comp.json +8981 -0
  570. package/dist/knowledge/data/operators/text_dat.json +675 -0
  571. package/dist/knowledge/data/operators/text_sop.json +1512 -0
  572. package/dist/knowledge/data/operators/text_top.json +4236 -0
  573. package/dist/knowledge/data/operators/texture_3d_top.json +1417 -0
  574. package/dist/knowledge/data/operators/texture_map_pop.json +1744 -0
  575. package/dist/knowledge/data/operators/texture_sop.json +992 -0
  576. package/dist/knowledge/data/operators/threshold_top.json +1227 -0
  577. package/dist/knowledge/data/operators/tile_top.json +1840 -0
  578. package/dist/knowledge/data/operators/time_comp.json +1745 -0
  579. package/dist/knowledge/data/operators/time_machine_top.json +1041 -0
  580. package/dist/knowledge/data/operators/time_slice_chop.json +568 -0
  581. package/dist/knowledge/data/operators/timecode_chop.json +1981 -0
  582. package/dist/knowledge/data/operators/timeline_chop.json +1038 -0
  583. package/dist/knowledge/data/operators/timer_chop.json +4236 -0
  584. package/dist/knowledge/data/operators/top_to_chop.json +2077 -0
  585. package/dist/knowledge/data/operators/top_to_pop.json +2144 -0
  586. package/dist/knowledge/data/operators/topology_pop.json +1526 -0
  587. package/dist/knowledge/data/operators/torus_pop.json +901 -0
  588. package/dist/knowledge/data/operators/torus_sop.json +1368 -0
  589. package/dist/knowledge/data/operators/touch_in_chop.json +1182 -0
  590. package/dist/knowledge/data/operators/touch_in_dat.json +618 -0
  591. package/dist/knowledge/data/operators/touch_in_top.json +1182 -0
  592. package/dist/knowledge/data/operators/touch_out_chop.json +947 -0
  593. package/dist/knowledge/data/operators/touch_out_dat.json +712 -0
  594. package/dist/knowledge/data/operators/touch_out_top.json +1134 -0
  595. package/dist/knowledge/data/operators/trace_sop.json +759 -0
  596. package/dist/knowledge/data/operators/trail_chop.json +901 -0
  597. package/dist/knowledge/data/operators/trail_pop.json +827 -0
  598. package/dist/knowledge/data/operators/trail_sop.json +616 -0
  599. package/dist/knowledge/data/operators/transform_chop.json +2168 -0
  600. package/dist/knowledge/data/operators/transform_pop.json +2659 -0
  601. package/dist/knowledge/data/operators/transform_sop.json +1466 -0
  602. package/dist/knowledge/data/operators/transform_top.json +1803 -0
  603. package/dist/knowledge/data/operators/transform_xyz_chop.json +1369 -0
  604. package/dist/knowledge/data/operators/transpose_dat.json +334 -0
  605. package/dist/knowledge/data/operators/trig_pop.json +1135 -0
  606. package/dist/knowledge/data/operators/trigger_chop.json +2214 -0
  607. package/dist/knowledge/data/operators/trim_chop.json +805 -0
  608. package/dist/knowledge/data/operators/trim_sop.json +336 -0
  609. package/dist/knowledge/data/operators/tristrip_sop.json +194 -0
  610. package/dist/knowledge/data/operators/tube_pop.json +861 -0
  611. package/dist/knowledge/data/operators/tube_sop.json +1323 -0
  612. package/dist/knowledge/data/operators/tuio_in_dat.json +806 -0
  613. package/dist/knowledge/data/operators/twist_pop.json +1127 -0
  614. package/dist/knowledge/data/operators/twist_sop.json +533 -0
  615. package/dist/knowledge/data/operators/udp_in_dat.json +1090 -0
  616. package/dist/knowledge/data/operators/udp_out_dat.json +1280 -0
  617. package/dist/knowledge/data/operators/under_top.json +1652 -0
  618. package/dist/knowledge/data/operators/usd_comp.json +4800 -0
  619. package/dist/knowledge/data/operators/vertex_sop.json +667 -0
  620. package/dist/knowledge/data/operators/video_device_in_top.json +3062 -0
  621. package/dist/knowledge/data/operators/video_device_out_top.json +1936 -0
  622. package/dist/knowledge/data/operators/video_devices_dat.json +616 -0
  623. package/dist/knowledge/data/operators/video_stream_in_top.json +1842 -0
  624. package/dist/knowledge/data/operators/video_stream_out_top.json +2548 -0
  625. package/dist/knowledge/data/operators/vioso_top.json +943 -0
  626. package/dist/knowledge/data/operators/warp_chop.json +570 -0
  627. package/dist/knowledge/data/operators/wave_chop.json +1510 -0
  628. package/dist/knowledge/data/operators/web_client_dat.json +1514 -0
  629. package/dist/knowledge/data/operators/web_render_top.json +1749 -0
  630. package/dist/knowledge/data/operators/web_server_dat.json +714 -0
  631. package/dist/knowledge/data/operators/webrtc_dat.json +851 -0
  632. package/dist/knowledge/data/operators/websocket_dat.json +901 -0
  633. package/dist/knowledge/data/operators/widget_comp.json +6299 -0
  634. package/dist/knowledge/data/operators/window_comp.json +3061 -0
  635. package/dist/knowledge/data/operators/wireframe_mat.json +2165 -0
  636. package/dist/knowledge/data/operators/wireframe_sop.json +338 -0
  637. package/dist/knowledge/data/operators/wrnchai_chop.json +1084 -0
  638. package/dist/knowledge/data/operators/xml_dat.json +1230 -0
  639. package/dist/knowledge/data/operators/zed_chop.json +1840 -0
  640. package/dist/knowledge/data/operators/zed_sop.json +712 -0
  641. package/dist/knowledge/data/operators/zed_top.json +1981 -0
  642. package/dist/knowledge/data/patterns.json +1 -0
  643. package/dist/knowledge/data/python-api/App.json +78 -0
  644. package/dist/knowledge/data/python-api/Attribute.json +43 -0
  645. package/dist/knowledge/data/python-api/Attributes.json +41 -0
  646. package/dist/knowledge/data/python-api/Bounds.json +10 -0
  647. package/dist/knowledge/data/python-api/CHOP.json +683 -0
  648. package/dist/knowledge/data/python-api/COMP.json +1019 -0
  649. package/dist/knowledge/data/python-api/Cell.json +80 -0
  650. package/dist/knowledge/data/python-api/Channel.json +100 -0
  651. package/dist/knowledge/data/python-api/Connector.json +43 -0
  652. package/dist/knowledge/data/python-api/DAT.json +1289 -0
  653. package/dist/knowledge/data/python-api/Dependency.json +10 -0
  654. package/dist/knowledge/data/python-api/Error_DAT.json +9 -0
  655. package/dist/knowledge/data/python-api/Group.json +54 -0
  656. package/dist/knowledge/data/python-api/License.json +25 -0
  657. package/dist/knowledge/data/python-api/MAT.json +621 -0
  658. package/dist/knowledge/data/python-api/MOD.json +83 -0
  659. package/dist/knowledge/data/python-api/Matrix.json +556 -0
  660. package/dist/knowledge/data/python-api/Monitor.json +25 -0
  661. package/dist/knowledge/data/python-api/Network.json +10 -0
  662. package/dist/knowledge/data/python-api/NetworkEditor.json +154 -0
  663. package/dist/knowledge/data/python-api/Node.json +10 -0
  664. package/dist/knowledge/data/python-api/OP.json +621 -0
  665. package/dist/knowledge/data/python-api/OP_Viewer_COMP.json +9 -0
  666. package/dist/knowledge/data/python-api/ObjectCOMP.json +1150 -0
  667. package/dist/knowledge/data/python-api/Page.json +797 -0
  668. package/dist/knowledge/data/python-api/Pane.json +62 -0
  669. package/dist/knowledge/data/python-api/Panel.json +25 -0
  670. package/dist/knowledge/data/python-api/PanelCOMP.json +1167 -0
  671. package/dist/knowledge/data/python-api/PanelValue.json +25 -0
  672. package/dist/knowledge/data/python-api/Par.json +115 -0
  673. package/dist/knowledge/data/python-api/ParGroup.json +101 -0
  674. package/dist/knowledge/data/python-api/Parameter.json +10 -0
  675. package/dist/knowledge/data/python-api/Parent.json +10 -0
  676. package/dist/knowledge/data/python-api/Pattern_CHOP.json +9 -0
  677. package/dist/knowledge/data/python-api/Peer.json +85 -0
  678. package/dist/knowledge/data/python-api/Point.json +32 -0
  679. package/dist/knowledge/data/python-api/Position.json +92 -0
  680. package/dist/knowledge/data/python-api/Prim.json +63 -0
  681. package/dist/knowledge/data/python-api/Project.json +118 -0
  682. package/dist/knowledge/data/python-api/PythonOp.json +140 -0
  683. package/dist/knowledge/data/python-api/Quaternion.json +24 -0
  684. package/dist/knowledge/data/python-api/Replicator_COMP.json +9 -0
  685. package/dist/knowledge/data/python-api/Run.json +32 -0
  686. package/dist/knowledge/data/python-api/Runs.json +10 -0
  687. package/dist/knowledge/data/python-api/SOP.json +642 -0
  688. package/dist/knowledge/data/python-api/ScriptOp.json +119 -0
  689. package/dist/knowledge/data/python-api/Segment.json +25 -0
  690. package/dist/knowledge/data/python-api/Sequence.json +48 -0
  691. package/dist/knowledge/data/python-api/Stype.json +9 -0
  692. package/dist/knowledge/data/python-api/SysInfo.json +25 -0
  693. package/dist/knowledge/data/python-api/TOP.json +724 -0
  694. package/dist/knowledge/data/python-api/Timecode.json +200 -0
  695. package/dist/knowledge/data/python-api/UI.json +73 -0
  696. package/dist/knowledge/data/python-api/Vertex.json +25 -0
  697. package/dist/knowledge/data/python-api/baseCOMP.json +1019 -0
  698. package/dist/knowledge/data/python-api/evaluateDAT.json +1289 -0
  699. package/dist/knowledge/data/python-api/examineDAT.json +1289 -0
  700. package/dist/knowledge/data/python-api/glslTOP.json +724 -0
  701. package/dist/knowledge/data/python-api/index.json +1 -0
  702. package/dist/knowledge/data/python-api/listCOMP.json +1516 -0
  703. package/dist/knowledge/data/python-api/midiinDAT.json +1328 -0
  704. package/dist/knowledge/data/python-api/scriptCHOP.json +24 -0
  705. package/dist/knowledge/data/python-api/scriptDAT.json +1335 -0
  706. package/dist/knowledge/data/python-api/scriptSOP.json +24 -0
  707. package/dist/knowledge/data/python-api/scriptTOP.json +24 -0
  708. package/dist/knowledge/data/python-api/serialDAT.json +1323 -0
  709. package/dist/knowledge/data/python-api/tcpipDAT.json +1357 -0
  710. package/dist/knowledge/data/python-api/td.json +646 -0
  711. package/dist/knowledge/data/python-api/td_Module.json +24 -0
  712. package/dist/knowledge/data/tutorials/anatomy_of_a_chop.json +275 -0
  713. package/dist/knowledge/data/tutorials/build_a_list_comp.json +268 -0
  714. package/dist/knowledge/data/tutorials/index.json +1 -0
  715. package/dist/knowledge/data/tutorials/introduction_to_python_tutorial.json +1598 -0
  716. package/dist/knowledge/data/tutorials/tdbitwig_user_guide.json +1986 -0
  717. package/dist/knowledge/data/tutorials/touchdesigner_video_server_specification_guide.json +555 -0
  718. package/dist/knowledge/data/tutorials/video_streaming_user_guide.json +653 -0
  719. package/dist/knowledge/data/tutorials/write_a_cplusplus_chop.json +139 -0
  720. package/dist/knowledge/data/tutorials/write_a_cplusplus_plugin.json +796 -0
  721. package/dist/knowledge/data/tutorials/write_a_cplusplus_top.json +104 -0
  722. package/dist/knowledge/data/tutorials/write_a_cuda_dll.json +259 -0
  723. package/dist/knowledge/data/tutorials/write_a_glsl_material.json +2353 -0
  724. package/dist/knowledge/data/tutorials/write_a_glsl_top.json +818 -0
  725. package/dist/knowledge/data/tutorials/write_a_shared_memory_chop.json +261 -0
  726. package/dist/knowledge/data/tutorials/write_a_shared_memory_top.json +193 -0
  727. package/dist/recipes/audio_spectrum_bars.json +26 -0
  728. package/dist/recipes/data_sonification.json +37 -0
  729. package/dist/recipes/feedback_tunnel.json +73 -0
  730. package/dist/recipes/kinect_silhouette.json +45 -0
  731. package/dist/recipes/led_strip_mapper.json +32 -0
  732. package/dist/recipes/noise_landscape.json +76 -0
  733. package/dist/recipes/particle_galaxy.json +52 -0
  734. package/dist/recipes/projection_mapping.json +25 -0
  735. package/dist/recipes/reaction_diffusion.json +90 -0
  736. package/dist/recipes/webcam_glitch.json +40 -0
  737. package/package.json +74 -0
  738. package/recipes/audio_spectrum_bars.json +26 -0
  739. package/recipes/data_sonification.json +37 -0
  740. package/recipes/feedback_tunnel.json +73 -0
  741. package/recipes/kinect_silhouette.json +45 -0
  742. package/recipes/led_strip_mapper.json +32 -0
  743. package/recipes/noise_landscape.json +76 -0
  744. package/recipes/particle_galaxy.json +52 -0
  745. package/recipes/projection_mapping.json +25 -0
  746. package/recipes/reaction_diffusion.json +90 -0
  747. package/recipes/webcam_glitch.json +40 -0
  748. package/td/README.md +160 -0
  749. package/td/bootstrap.py +73 -0
  750. package/td/modules/mcp/__init__.py +1 -0
  751. package/td/modules/mcp/controllers/__init__.py +1 -0
  752. package/td/modules/mcp/controllers/api_controller.py +240 -0
  753. package/td/modules/mcp/dev.py +40 -0
  754. package/td/modules/mcp/events.py +25 -0
  755. package/td/modules/mcp/install.py +155 -0
  756. package/td/modules/mcp/services/__init__.py +1 -0
  757. package/td/modules/mcp/services/analysis_service.py +64 -0
  758. package/td/modules/mcp/services/api_service.py +195 -0
  759. package/td/modules/mcp/services/batch_service.py +49 -0
  760. package/td/modules/mcp/services/preview_service.py +40 -0
  761. package/td/modules/utils/__init__.py +1 -0
  762. package/td/modules/utils/version.py +3 -0
  763. package/td/startup.py +34 -0
  764. package/td/templates/webserver_callbacks.py +50 -0
  765. package/td/tests/test_api_controller.py +242 -0
@@ -0,0 +1,195 @@
1
+ """Core node CRUD, Python execution, method calls and server info.
2
+
3
+ All functions assume the TouchDesigner globals (`op`, `app`, `project`) are
4
+ available, which is the case when this package is imported from a running TD.
5
+ """
6
+
7
+ import io
8
+ import re
9
+ import sys
10
+ import traceback
11
+ from contextlib import redirect_stdout
12
+
13
+ import td
14
+
15
+ # TouchDesigner injects globals (op, app, project, operator classes) only into
16
+ # DAT/Textport scope, not into imported modules — so reach them via `td`.
17
+ op = td.op
18
+ app = td.app
19
+ project = td.project
20
+
21
+ _TYPE_RE = re.compile(r"[A-Za-z][A-Za-z0-9_]*$")
22
+
23
+
24
+ def op_type(node):
25
+ """Returns the operator type string, e.g. 'noiseTOP'."""
26
+ return getattr(node, "OPType", None) or getattr(node, "type", "") or ""
27
+
28
+
29
+ def _resolve_type(type_name):
30
+ """Resolves an operator type string to its class via the td module."""
31
+ if not type_name or not _TYPE_RE.match(type_name):
32
+ raise ValueError("Invalid operator type: %r" % (type_name,))
33
+ cls = getattr(td, type_name, None)
34
+ if cls is None:
35
+ raise ValueError("Unknown operator type: %s" % type_name)
36
+ return cls
37
+
38
+
39
+ def node_ref(node):
40
+ return {"path": node.path, "type": op_type(node), "name": node.name}
41
+
42
+
43
+ def _jsonable(value):
44
+ try:
45
+ import json
46
+
47
+ json.dumps(value)
48
+ return value
49
+ except Exception: # noqa: BLE001
50
+ return str(value)
51
+
52
+
53
+ def apply_parameters(node, parameters):
54
+ applied, failed = [], []
55
+ for key, value in (parameters or {}).items():
56
+ try:
57
+ par = getattr(node.par, key, None)
58
+ if par is None:
59
+ failed.append(key)
60
+ continue
61
+ par.val = value
62
+ applied.append(key)
63
+ except Exception: # noqa: BLE001
64
+ failed.append(key)
65
+ return applied, failed
66
+
67
+
68
+ def create_node(parent_path, type_name, name=None, parameters=None):
69
+ parent = op(parent_path) # noqa: F821 - TD global
70
+ if parent is None:
71
+ raise LookupError("Parent not found: %s" % parent_path)
72
+ cls = _resolve_type(type_name)
73
+ node = parent.create(cls, name) if name else parent.create(cls)
74
+ if parameters:
75
+ apply_parameters(node, parameters)
76
+ return node_ref(node)
77
+
78
+
79
+ def delete_node(path):
80
+ node = op(path) # noqa: F821
81
+ if node is None:
82
+ raise LookupError("Node not found: %s" % path)
83
+ node.destroy()
84
+ return {"deleted": path}
85
+
86
+
87
+ def get_nodes(parent_path=None):
88
+ parent = op(parent_path or "/") # noqa: F821
89
+ if parent is None:
90
+ raise LookupError("Parent not found: %s" % parent_path)
91
+ children = parent.findChildren(depth=1) if hasattr(parent, "findChildren") else []
92
+ return {"nodes": [node_ref(c) for c in children]}
93
+
94
+
95
+ def node_detail(node):
96
+ pars = {}
97
+ try:
98
+ for par in node.pars():
99
+ try:
100
+ pars[par.name] = _jsonable(par.eval())
101
+ except Exception: # noqa: BLE001
102
+ pars[par.name] = None
103
+ except Exception: # noqa: BLE001
104
+ pars = {}
105
+ inputs = [c.path for c in getattr(node, "inputs", []) if c]
106
+ outputs = [c.path for c in getattr(node, "outputs", []) if c]
107
+ detail = node_ref(node)
108
+ detail.update({"parameters": pars, "inputs": inputs, "outputs": outputs})
109
+ return detail
110
+
111
+
112
+ def get_node(path):
113
+ node = op(path) # noqa: F821
114
+ if node is None:
115
+ raise LookupError("Node not found: %s" % path)
116
+ return node_detail(node)
117
+
118
+
119
+ def update_parameters(path, parameters):
120
+ node = op(path) # noqa: F821
121
+ if node is None:
122
+ raise LookupError("Node not found: %s" % path)
123
+ apply_parameters(node, parameters)
124
+ return node_detail(node)
125
+
126
+
127
+ def exec_script(script, return_output=True):
128
+ buf = io.StringIO()
129
+ # Seed the exec namespace with the full TD namespace (op, ParMode, operator
130
+ # classes, …) so scripts behave like they would in a DAT/Textport.
131
+ namespace = dict(vars(td))
132
+ namespace["op"] = op
133
+ try:
134
+ with redirect_stdout(buf):
135
+ exec(script, namespace) # noqa: S102 - intentional, runs inside TD
136
+ except Exception: # noqa: BLE001
137
+ raise RuntimeError(traceback.format_exc())
138
+ result = {"stdout": buf.getvalue() if return_output else ""}
139
+ if namespace.get("result") is not None:
140
+ result["result"] = _jsonable(namespace["result"])
141
+ return result
142
+
143
+
144
+ def call_method(path, method, args=None, kwargs=None):
145
+ node = op(path) # noqa: F821
146
+ if node is None:
147
+ raise LookupError("Node not found: %s" % path)
148
+ fn = getattr(node, method, None)
149
+ if not callable(fn):
150
+ raise AttributeError("%s has no callable method %s" % (path, method))
151
+ value = fn(*(args or []), **(kwargs or {}))
152
+ return {"result": _jsonable(value)}
153
+
154
+
155
+ def get_node_errors(path, recursive=False):
156
+ node = op(path) # noqa: F821
157
+ if node is None:
158
+ return {"errors": []}
159
+ targets = [node]
160
+ if recursive and hasattr(node, "findChildren"):
161
+ targets += node.findChildren()
162
+ out = []
163
+ for target in targets:
164
+ for kind in ("errors", "warnings"):
165
+ try:
166
+ fn = getattr(target, kind)
167
+ text = fn(recurse=False) if callable(fn) else fn
168
+ except Exception: # noqa: BLE001
169
+ text = ""
170
+ if text:
171
+ out.append({"path": target.path, "message": text, "type": kind[:-1]})
172
+ return {"errors": out}
173
+
174
+
175
+ def get_info():
176
+ info = {"python_version": sys.version.split()[0]}
177
+ try:
178
+ info["td_version"] = app.version # noqa: F821
179
+ except Exception: # noqa: BLE001
180
+ pass
181
+ try:
182
+ info["build"] = app.build # noqa: F821
183
+ except Exception: # noqa: BLE001
184
+ pass
185
+ try:
186
+ info["project"] = project.name # noqa: F821
187
+ except Exception: # noqa: BLE001
188
+ pass
189
+ try:
190
+ from utils.version import BRIDGE_VERSION
191
+
192
+ info["bridge_version"] = BRIDGE_VERSION
193
+ except Exception: # noqa: BLE001
194
+ info["bridge_version"] = "unknown"
195
+ return info
@@ -0,0 +1,49 @@
1
+ """Atomic-ish batch operations: create / update / delete / connect."""
2
+
3
+ import td
4
+
5
+ from mcp.services import api_service
6
+
7
+ op = td.op # TD globals are not available inside imported modules; reach via td
8
+
9
+
10
+ def connect(source_path, target_path, source_output=0, target_input=0):
11
+ src = op(source_path)
12
+ dst = op(target_path)
13
+ if src is None or dst is None:
14
+ raise LookupError("Source or target not found")
15
+ dst.inputConnectors[target_input].connect(src.outputConnectors[source_output])
16
+
17
+
18
+ def run(operations):
19
+ results = []
20
+ for operation in operations or []:
21
+ action = operation.get("action")
22
+ try:
23
+ if action == "create":
24
+ ref = api_service.create_node(
25
+ operation["parent_path"],
26
+ operation["type"],
27
+ operation.get("name"),
28
+ operation.get("parameters"),
29
+ )
30
+ results.append({"action": action, "ok": True, "data": ref})
31
+ elif action == "update":
32
+ api_service.update_parameters(operation["path"], operation.get("parameters", {}))
33
+ results.append({"action": action, "ok": True, "path": operation["path"]})
34
+ elif action == "delete":
35
+ api_service.delete_node(operation["path"])
36
+ results.append({"action": action, "ok": True, "path": operation["path"]})
37
+ elif action == "connect":
38
+ connect(
39
+ operation["source_path"],
40
+ operation["target_path"],
41
+ operation.get("source_output", 0),
42
+ operation.get("target_input", 0),
43
+ )
44
+ results.append({"action": action, "ok": True})
45
+ else:
46
+ results.append({"action": action, "ok": False, "error": "unknown action"})
47
+ except Exception as exc: # noqa: BLE001
48
+ results.append({"action": action, "ok": False, "error": str(exc)})
49
+ return {"results": results}
@@ -0,0 +1,40 @@
1
+ """Capture a TOP as a base64-encoded PNG."""
2
+
3
+ import base64
4
+
5
+ import td
6
+
7
+ op = td.op # TD globals are not available inside imported modules; reach via td
8
+
9
+
10
+ def capture(path, width=640, height=360):
11
+ node = op(path)
12
+ if node is None:
13
+ raise LookupError("Node not found: %s" % path)
14
+ if getattr(node, "family", None) != "TOP":
15
+ raise ValueError("Preview is only supported for TOPs, got %s" % path)
16
+
17
+ data = None
18
+ try:
19
+ data = node.saveByteArray(".png")
20
+ except Exception: # noqa: BLE001
21
+ data = None
22
+
23
+ if data is None:
24
+ # Fallback: save to a temp file and read it back.
25
+ import os
26
+ import tempfile
27
+
28
+ tmp = os.path.join(tempfile.gettempdir(), "tdmcp_preview.png")
29
+ node.save(tmp)
30
+ with open(tmp, "rb") as handle:
31
+ data = handle.read()
32
+
33
+ encoded = base64.b64encode(bytes(data)).decode("ascii")
34
+ return {
35
+ "path": node.path,
36
+ "width": int(getattr(node, "width", width) or width),
37
+ "height": int(getattr(node, "height", height) or height),
38
+ "format": "png",
39
+ "base64": encoded,
40
+ }
@@ -0,0 +1 @@
1
+ """Utility helpers for the tdmcp bridge."""
@@ -0,0 +1,3 @@
1
+ """Version of the tdmcp TouchDesigner bridge."""
2
+
3
+ BRIDGE_VERSION = "0.2.0"
package/td/startup.py ADDED
@@ -0,0 +1,34 @@
1
+ # tdmcp bridge auto-start (Execute DAT).
2
+ #
3
+ # Easiest path (no DAT at all): once td/modules is on the Preferences module
4
+ # path, just paste this into the Textport once:
5
+ #
6
+ # from mcp import install; install.run()
7
+ #
8
+ # This file is the "run automatically on every project open" version: paste it
9
+ # into an Execute DAT and turn ON its "Start" and "Create" toggles. Put that
10
+ # Execute DAT in your Default Project template to make it global for new projects.
11
+ #
12
+ # If you did NOT add td/modules to the Preferences module path, set MODULES_DIR
13
+ # to its absolute path below.
14
+
15
+ MODULES_DIR = ""
16
+
17
+
18
+ def _install():
19
+ if MODULES_DIR:
20
+ import sys
21
+
22
+ if MODULES_DIR not in sys.path:
23
+ sys.path.insert(0, MODULES_DIR)
24
+ from mcp import install
25
+
26
+ install.run(modules_dir=MODULES_DIR or None)
27
+
28
+
29
+ def onStart():
30
+ _install()
31
+
32
+
33
+ def onCreate():
34
+ _install()
@@ -0,0 +1,50 @@
1
+ # WebServer DAT callbacks for the tdmcp bridge.
2
+ #
3
+ # Setup:
4
+ # 1. Copy the `td/modules` folder into your TD project, e.g. <project>/tdmcp/modules.
5
+ # 2. Add a Web Server DAT, set its port to 9980 (matches TDMCP_TD_PORT).
6
+ # 3. Point the Web Server DAT's callbacks at this file (or paste its contents).
7
+ #
8
+ # The path below assumes <project>/tdmcp/modules — adjust _MODULES if you put it
9
+ # somewhere else.
10
+
11
+ import os
12
+ import sys
13
+
14
+ _MODULES = os.path.join(project.folder, "tdmcp", "modules") # noqa: F821 - TD global
15
+ if _MODULES not in sys.path:
16
+ sys.path.insert(0, _MODULES)
17
+
18
+ from mcp.controllers import api_controller # noqa: E402
19
+
20
+
21
+ def onHTTPRequest(webServerDAT, request, response):
22
+ return api_controller.handle(request, response, webServerDAT)
23
+
24
+
25
+ def onWebSocketOpen(webServerDAT, client, uri):
26
+ return
27
+
28
+
29
+ def onWebSocketReceiveText(webServerDAT, client, data):
30
+ return
31
+
32
+
33
+ def onWebSocketReceiveBinary(webServerDAT, client, data):
34
+ return
35
+
36
+
37
+ def onWebSocketReceivePing(webServerDAT, client, data):
38
+ webServerDAT.webSocketSendPong(client, data=data)
39
+
40
+
41
+ def onWebSocketReceivePong(webServerDAT, client, data):
42
+ return
43
+
44
+
45
+ def onServerStart(webServerDAT):
46
+ return
47
+
48
+
49
+ def onServerStop(webServerDAT):
50
+ return
@@ -0,0 +1,242 @@
1
+ """Unit tests for the tdmcp bridge HTTP router.
2
+
3
+ The bridge normally runs inside TouchDesigner, where `td`, `op`, `app` and the
4
+ operator classes are injected globals. To exercise the router's pure logic —
5
+ auth, the arbitrary-code gate, request parsing, path decoding and route
6
+ dispatch — off-TD, we install a stub `td` module before importing the package
7
+ and replace the service layer with recorders for dispatch assertions.
8
+
9
+ Run from the repo root: `python3 -m unittest discover -s td/tests`
10
+ (or `npm run test:bridge`). No third-party dependencies — stdlib only.
11
+ """
12
+
13
+ import os
14
+ import sys
15
+ import types
16
+ import unittest
17
+ from unittest import mock
18
+
19
+ # --- Make the bridge importable without TouchDesigner --------------------------
20
+ _HERE = os.path.dirname(os.path.abspath(__file__))
21
+ _MODULES = os.path.abspath(os.path.join(_HERE, "..", "modules"))
22
+ if _MODULES not in sys.path:
23
+ sys.path.insert(0, _MODULES)
24
+
25
+ # `mcp.services.*` bind `op/app/project` from `td` at import time; a stub suffices.
26
+ _td_stub = types.ModuleType("td")
27
+ _td_stub.op = mock.MagicMock(name="op")
28
+ _td_stub.app = mock.MagicMock(name="app")
29
+ _td_stub.project = mock.MagicMock(name="project")
30
+ sys.modules.setdefault("td", _td_stub)
31
+
32
+ from mcp.controllers import api_controller as ac # noqa: E402
33
+
34
+
35
+ def _clear_exec_env():
36
+ os.environ.pop("TDMCP_BRIDGE_ALLOW_EXEC", None)
37
+
38
+
39
+ def _clear_token_env():
40
+ os.environ.pop("TDMCP_BRIDGE_TOKEN", None)
41
+
42
+
43
+ class AuthTests(unittest.TestCase):
44
+ def tearDown(self):
45
+ _clear_token_env()
46
+
47
+ def test_no_token_means_auth_off(self):
48
+ _clear_token_env()
49
+ # Should not raise even with no Authorization header.
50
+ ac._check_auth({"method": "GET"})
51
+
52
+ def test_valid_bearer_token_passes(self):
53
+ os.environ["TDMCP_BRIDGE_TOKEN"] = "s3cret"
54
+ ac._check_auth({"Authorization": "Bearer s3cret"})
55
+
56
+ def test_invalid_token_raises(self):
57
+ os.environ["TDMCP_BRIDGE_TOKEN"] = "s3cret"
58
+ with self.assertRaises(PermissionError):
59
+ ac._check_auth({"Authorization": "Bearer wrong"})
60
+
61
+ def test_missing_header_raises_when_token_required(self):
62
+ os.environ["TDMCP_BRIDGE_TOKEN"] = "s3cret"
63
+ with self.assertRaises(PermissionError):
64
+ ac._check_auth({"method": "GET"})
65
+
66
+ def test_header_lookup_is_case_insensitive_and_nested(self):
67
+ os.environ["TDMCP_BRIDGE_TOKEN"] = "s3cret"
68
+ # Header nested under a 'headers' dict with odd casing — must still match.
69
+ ac._check_auth({"headers": {"authorization": "Bearer s3cret"}})
70
+
71
+
72
+ class ExecGateTests(unittest.TestCase):
73
+ def tearDown(self):
74
+ _clear_exec_env()
75
+ _clear_token_env()
76
+
77
+ def test_allowed_by_default(self):
78
+ _clear_exec_env()
79
+ self.assertTrue(ac._exec_allowed())
80
+
81
+ def test_disabled_values(self):
82
+ for value in ("0", "false", "FALSE", "no", "off", " Off "):
83
+ os.environ["TDMCP_BRIDGE_ALLOW_EXEC"] = value
84
+ self.assertFalse(ac._exec_allowed(), value)
85
+
86
+ def test_enabled_values(self):
87
+ for value in ("1", "true", "yes", "on", "", "anything"):
88
+ os.environ["TDMCP_BRIDGE_ALLOW_EXEC"] = value
89
+ self.assertTrue(ac._exec_allowed(), value)
90
+
91
+ def test_route_blocks_exec_when_disabled(self):
92
+ os.environ["TDMCP_BRIDGE_ALLOW_EXEC"] = "0"
93
+ with self.assertRaises(PermissionError):
94
+ ac._route("POST", "/api/exec", {}, {"script": "print(1)"})
95
+
96
+ def test_route_blocks_node_method_when_disabled(self):
97
+ os.environ["TDMCP_BRIDGE_ALLOW_EXEC"] = "0"
98
+ with self.assertRaises(PermissionError):
99
+ ac._route("POST", "/api/nodes/project1/geo1/method", {}, {"method": "cook"})
100
+
101
+
102
+ class RoutingTests(unittest.TestCase):
103
+ """Dispatch logic, with the service layer swapped for recorders."""
104
+
105
+ def setUp(self):
106
+ _clear_exec_env()
107
+ self._saved = {
108
+ "api": ac.api_service,
109
+ "batch": ac.batch_service,
110
+ "analysis": ac.analysis_service,
111
+ "preview": ac.preview_service,
112
+ }
113
+ ac.api_service = mock.MagicMock(name="api_service")
114
+ ac.batch_service = mock.MagicMock(name="batch_service")
115
+ ac.analysis_service = mock.MagicMock(name="analysis_service")
116
+ ac.preview_service = mock.MagicMock(name="preview_service")
117
+
118
+ def tearDown(self):
119
+ ac.api_service = self._saved["api"]
120
+ ac.batch_service = self._saved["batch"]
121
+ ac.analysis_service = self._saved["analysis"]
122
+ ac.preview_service = self._saved["preview"]
123
+
124
+ def test_get_info(self):
125
+ ac._route("GET", "/api/info", {}, {})
126
+ ac.api_service.get_info.assert_called_once_with()
127
+
128
+ def test_create_node(self):
129
+ ac._route("POST", "/api/nodes", {}, {"parent_path": "/project1", "type": "noiseTOP"})
130
+ ac.api_service.create_node.assert_called_once()
131
+ self.assertEqual(ac.api_service.create_node.call_args.args[0], "/project1")
132
+ self.assertEqual(ac.api_service.create_node.call_args.args[1], "noiseTOP")
133
+
134
+ def test_list_nodes_uses_parent_query(self):
135
+ ac._route("GET", "/api/nodes", {"parent": ["/project1"]}, {})
136
+ ac.api_service.get_nodes.assert_called_once_with("/project1")
137
+
138
+ def test_exec_dispatch_when_allowed(self):
139
+ ac._route("POST", "/api/exec", {}, {"script": "x=1", "return_output": False})
140
+ ac.api_service.exec_script.assert_called_once_with("x=1", False)
141
+
142
+ def test_batch_dispatch(self):
143
+ ops = [{"action": "create", "parent_path": "/p", "type": "noiseTOP"}]
144
+ ac._route("POST", "/api/batch", {}, {"operations": ops})
145
+ ac.batch_service.run.assert_called_once_with(ops)
146
+
147
+ def test_node_get_patch_delete(self):
148
+ ac._route("GET", "/api/nodes/project1/noise1", {}, {})
149
+ ac.api_service.get_node.assert_called_once_with("/project1/noise1")
150
+
151
+ ac._route("PATCH", "/api/nodes/project1/noise1", {}, {"parameters": {"period": 4}})
152
+ ac.api_service.update_parameters.assert_called_once_with("/project1/noise1", {"period": 4})
153
+
154
+ ac._route("DELETE", "/api/nodes/project1/noise1", {}, {})
155
+ ac.api_service.delete_node.assert_called_once_with("/project1/noise1")
156
+
157
+ def test_node_method_dispatch(self):
158
+ ac._route(
159
+ "POST",
160
+ "/api/nodes/project1/geo1/method",
161
+ {},
162
+ {"method": "cook", "args": [1], "kwargs": {"force": True}},
163
+ )
164
+ ac.api_service.call_method.assert_called_once_with("/project1/geo1", "cook", [1], {"force": True})
165
+
166
+ def test_node_errors_dispatch(self):
167
+ ac._route("GET", "/api/nodes/project1/geo1/errors", {}, {})
168
+ ac.api_service.get_node_errors.assert_called_once_with("/project1/geo1", recursive=False)
169
+
170
+ def test_preview_dispatch_with_dimensions(self):
171
+ ac._route("GET", "/api/preview/project1/out1", {"width": ["800"], "height": ["600"]}, {})
172
+ ac.preview_service.capture.assert_called_once_with("/project1/out1", 800, 600)
173
+
174
+ def test_network_topology_dispatch(self):
175
+ ac._route("GET", "/api/network/project1/topology", {"recursive": ["true"]}, {})
176
+ ac.analysis_service.topology.assert_called_once_with("/project1", recursive=True)
177
+
178
+ def test_unknown_route_raises(self):
179
+ with self.assertRaises(ValueError):
180
+ ac._route("GET", "/api/does-not-exist", {}, {})
181
+
182
+
183
+ class ParsingTests(unittest.TestCase):
184
+ def test_parse_body_variants(self):
185
+ self.assertEqual(ac._parse_body({"data": ""}), {})
186
+ self.assertEqual(ac._parse_body({"data": None}), {})
187
+ self.assertEqual(ac._parse_body({"data": '{"a": 1}'}), {"a": 1})
188
+ self.assertEqual(ac._parse_body({"data": b'{"b": 2}'}), {"b": 2})
189
+ self.assertEqual(ac._parse_body({"data": {"c": 3}}), {"c": 3})
190
+
191
+ def test_node_path_rejoins_and_restores_leading_slash(self):
192
+ self.assertEqual(ac._node_path(["project1", "noise1"]), "/project1/noise1")
193
+ # Percent-encoded segment decodes back to a slash-bearing path.
194
+ self.assertEqual(ac._node_path(["project1%2Fgeo1"]), "/project1/geo1")
195
+
196
+ def test_qs_returns_first_or_default(self):
197
+ self.assertEqual(ac._qs({"k": ["v1", "v2"]}, "k"), "v1")
198
+ self.assertEqual(ac._qs({}, "missing", "fallback"), "fallback")
199
+
200
+ def test_find_header_top_level_and_default(self):
201
+ self.assertEqual(ac._find_header({"X-Token": "abc"}, "x-token"), "abc")
202
+ self.assertIsNone(ac._find_header({"other": "v"}, "x-token"))
203
+
204
+
205
+ class HandleTests(unittest.TestCase):
206
+ def tearDown(self):
207
+ _clear_exec_env()
208
+ _clear_token_env()
209
+
210
+ def _resp(self):
211
+ return {}
212
+
213
+ def test_ok_envelope(self):
214
+ with mock.patch.object(ac, "_route", return_value={"hello": "world"}):
215
+ resp = ac.handle({"method": "GET", "uri": "/api/info"}, self._resp())
216
+ self.assertEqual(resp["statusCode"], 200)
217
+ self.assertIn('"ok": true', resp["data"])
218
+ self.assertIn("world", resp["data"])
219
+
220
+ def test_auth_failure_is_401(self):
221
+ os.environ["TDMCP_BRIDGE_TOKEN"] = "s3cret"
222
+ resp = ac.handle({"method": "GET", "uri": "/api/info"}, self._resp())
223
+ self.assertEqual(resp["statusCode"], 401)
224
+ self.assertIn('"ok": false', resp["data"])
225
+
226
+ def test_error_is_400(self):
227
+ with mock.patch.object(ac, "_route", side_effect=ValueError("boom")):
228
+ resp = ac.handle({"method": "GET", "uri": "/api/info"}, self._resp())
229
+ self.assertEqual(resp["statusCode"], 400)
230
+ self.assertIn("boom", resp["data"])
231
+
232
+ def test_exec_disabled_surfaces_as_401_with_message(self):
233
+ os.environ["TDMCP_BRIDGE_ALLOW_EXEC"] = "0"
234
+ resp = ac.handle(
235
+ {"method": "POST", "uri": "/api/exec", "data": '{"script": "1"}'}, self._resp()
236
+ )
237
+ self.assertEqual(resp["statusCode"], 401)
238
+ self.assertIn("disabled", resp["data"])
239
+
240
+
241
+ if __name__ == "__main__":
242
+ unittest.main()