@autotest/agent 0.0.1 → 0.0.3

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 (248) hide show
  1. package/README.md +43 -27
  2. package/dist/api/agent_api.d.ts +1 -1
  3. package/dist/api/agent_api.js +555 -0
  4. package/dist/api/autotest_agent.d.ts +0 -1
  5. package/dist/api/autotest_agent.js +205 -0
  6. package/dist/api/types.d.ts +0 -1
  7. package/dist/api/types.js +11 -0
  8. package/dist/autotest-cli.d.ts +1 -1
  9. package/dist/autotest-cli.js +391 -0
  10. package/dist/common/case_manager.d.ts +0 -1
  11. package/dist/common/case_manager.js +91 -0
  12. package/dist/common/collect_case.d.ts +0 -1
  13. package/dist/common/collect_case.js +128 -0
  14. package/dist/common/common_errors.d.ts +0 -1
  15. package/dist/common/common_errors.js +66 -0
  16. package/dist/common/config/config_validator.d.ts +0 -1
  17. package/dist/common/config/config_validator.js +28 -0
  18. package/dist/common/config/manager.d.ts +0 -1
  19. package/dist/common/config/manager.js +257 -0
  20. package/dist/common/config/output.d.ts +0 -1
  21. package/dist/common/config/output.js +59 -0
  22. package/dist/common/config/types.d.ts +2243 -2244
  23. package/dist/common/config/types.js +184 -0
  24. package/dist/common/dfx/client_factory.d.ts +0 -1
  25. package/dist/common/dfx/client_factory.js +62 -0
  26. package/dist/common/dfx/context.d.ts +0 -1
  27. package/dist/common/dfx/context.js +23 -0
  28. package/dist/common/dfx/index.d.ts +0 -1
  29. package/dist/common/dfx/index.js +15 -0
  30. package/dist/common/dfx/recorder.d.ts +0 -1
  31. package/dist/common/dfx/recorder.js +191 -0
  32. package/dist/common/dfx/recording_fetch.d.ts +0 -1
  33. package/dist/common/dfx/recording_fetch.js +228 -0
  34. package/dist/common/dfx/source.d.ts +0 -1
  35. package/dist/common/dfx/source.js +13 -0
  36. package/dist/common/image_cacher.d.ts +0 -1
  37. package/dist/common/image_cacher.js +36 -0
  38. package/dist/common/image_helper.d.ts +0 -1
  39. package/dist/common/image_helper.js +128 -0
  40. package/dist/common/image_similarity.d.ts +0 -1
  41. package/dist/common/image_similarity.js +171 -0
  42. package/dist/common/llm_cache/cache_transport.d.ts +2 -1
  43. package/dist/common/llm_cache/cache_transport.js +102 -0
  44. package/dist/common/llm_cache/prompt_cache.d.ts +53 -0
  45. package/dist/common/llm_cache/prompt_cache.js +113 -0
  46. package/dist/common/logger.d.ts +0 -1
  47. package/dist/common/logger.js +158 -0
  48. package/dist/common/model/custom_model.d.ts +0 -1
  49. package/dist/common/model/custom_model.js +467 -0
  50. package/dist/common/model/index.d.ts +0 -1
  51. package/dist/common/model/index.js +5 -0
  52. package/dist/common/path_utils.d.ts +0 -1
  53. package/dist/common/path_utils.js +81 -0
  54. package/dist/common/result_parser.d.ts +0 -1
  55. package/dist/common/result_parser.js +49 -0
  56. package/dist/common/usage/token_usage.d.ts +0 -1
  57. package/dist/common/usage/token_usage.js +117 -0
  58. package/dist/common/utils.d.ts +0 -1
  59. package/dist/common/utils.js +125 -0
  60. package/dist/core/agent/layered_agent/ability_helper.d.ts +0 -1
  61. package/dist/core/agent/layered_agent/ability_helper.js +125 -0
  62. package/dist/core/agent/layered_agent/agent.d.ts +0 -1
  63. package/dist/core/agent/layered_agent/agent.js +37 -0
  64. package/dist/core/agent/layered_agent/agent_registry.d.ts +0 -1
  65. package/dist/core/agent/layered_agent/agent_registry.js +75 -0
  66. package/dist/core/agent/layered_agent/decision.d.ts +0 -1
  67. package/dist/core/agent/layered_agent/decision.js +478 -0
  68. package/dist/core/agent/layered_agent/execute_agent/action_handler.d.ts +0 -1
  69. package/dist/core/agent/layered_agent/execute_agent/action_handler.js +155 -0
  70. package/dist/core/agent/layered_agent/execute_agent/agent_factory.d.ts +1 -2
  71. package/dist/core/agent/layered_agent/execute_agent/agent_factory.js +41 -0
  72. package/dist/core/agent/layered_agent/execute_agent/base_agent.d.ts +0 -1
  73. package/dist/core/agent/layered_agent/execute_agent/base_agent.js +112 -0
  74. package/dist/core/agent/layered_agent/execute_agent/general_agent.d.ts +0 -1
  75. package/dist/core/agent/layered_agent/execute_agent/general_agent.js +207 -0
  76. package/dist/core/agent/layered_agent/execute_agent/glm_agent.d.ts +0 -1
  77. package/dist/core/agent/layered_agent/execute_agent/glm_agent.js +241 -0
  78. package/dist/core/agent/layered_agent/execute_agent/i18n.d.ts +0 -1
  79. package/dist/core/agent/layered_agent/execute_agent/i18n.js +34 -0
  80. package/dist/core/agent/layered_agent/execute_agent/index.d.ts +0 -1
  81. package/dist/core/agent/layered_agent/execute_agent/index.js +67 -0
  82. package/dist/core/agent/layered_agent/execute_agent/mai_ui_agent.d.ts +0 -1
  83. package/dist/core/agent/layered_agent/execute_agent/mai_ui_agent.js +316 -0
  84. package/dist/core/agent/layered_agent/execute_agent/mcp_prompts.d.ts +0 -1
  85. package/dist/core/agent/layered_agent/execute_agent/mcp_prompts.js +154 -0
  86. package/dist/core/agent/layered_agent/execute_agent/parser/general_parser.d.ts +0 -1
  87. package/dist/core/agent/layered_agent/execute_agent/parser/general_parser.js +243 -0
  88. package/dist/core/agent/layered_agent/execute_agent/parser/glm_parser.d.ts +0 -1
  89. package/dist/core/agent/layered_agent/execute_agent/parser/glm_parser.js +139 -0
  90. package/dist/core/agent/layered_agent/execute_agent/parser/index.d.ts +0 -1
  91. package/dist/core/agent/layered_agent/execute_agent/parser/index.js +9 -0
  92. package/dist/core/agent/layered_agent/execute_agent/parser/mai_ui_parser.d.ts +0 -1
  93. package/dist/core/agent/layered_agent/execute_agent/parser/mai_ui_parser.js +94 -0
  94. package/dist/core/agent/layered_agent/execute_agent/prompts.d.ts +0 -1
  95. package/dist/core/agent/layered_agent/execute_agent/prompts.js +109 -0
  96. package/dist/core/agent/layered_agent/execute_agent/simple_reporter.d.ts +0 -1
  97. package/dist/core/agent/layered_agent/execute_agent/simple_reporter.js +33 -0
  98. package/dist/core/agent/layered_agent/execute_agent/utils.d.ts +0 -1
  99. package/dist/core/agent/layered_agent/execute_agent/utils.js +52 -0
  100. package/dist/core/agent/report_analyzer_agent/agent.d.ts +0 -1
  101. package/dist/core/agent/report_analyzer_agent/agent.js +565 -0
  102. package/dist/core/agent/report_analyzer_agent/config.d.ts +0 -1
  103. package/dist/core/agent/report_analyzer_agent/config.js +22 -0
  104. package/dist/core/agent/report_analyzer_agent/data_loader.d.ts +0 -1
  105. package/dist/core/agent/report_analyzer_agent/data_loader.js +255 -0
  106. package/dist/core/agent/report_analyzer_agent/guardrails.d.ts +0 -1
  107. package/dist/core/agent/report_analyzer_agent/guardrails.js +99 -0
  108. package/dist/core/agent/report_analyzer_agent/hooks.d.ts +0 -1
  109. package/dist/core/agent/report_analyzer_agent/hooks.js +31 -0
  110. package/dist/core/agent/report_analyzer_agent/index.d.ts +0 -1
  111. package/dist/core/agent/report_analyzer_agent/index.js +52 -0
  112. package/dist/core/agent/report_analyzer_agent/key_steps_builder.d.ts +0 -1
  113. package/dist/core/agent/report_analyzer_agent/key_steps_builder.js +42 -0
  114. package/dist/core/agent/report_analyzer_agent/mapping.d.ts +0 -1
  115. package/dist/core/agent/report_analyzer_agent/mapping.js +133 -0
  116. package/dist/core/agent/report_analyzer_agent/parse.d.ts +0 -1
  117. package/dist/core/agent/report_analyzer_agent/parse.js +375 -0
  118. package/dist/core/agent/report_analyzer_agent/prompt.d.ts +0 -1
  119. package/dist/core/agent/report_analyzer_agent/prompt.js +300 -0
  120. package/dist/core/agent/report_analyzer_agent/report_writer.d.ts +0 -1
  121. package/dist/core/agent/report_analyzer_agent/report_writer.js +558 -0
  122. package/dist/core/agent/report_analyzer_agent/tools.d.ts +0 -1
  123. package/dist/core/agent/report_analyzer_agent/tools.js +150 -0
  124. package/dist/core/agent/report_analyzer_agent/types.d.ts +0 -1
  125. package/dist/core/agent/report_analyzer_agent/types.js +274 -0
  126. package/dist/core/agent/rewrite_agent/agent.d.ts +0 -1
  127. package/dist/core/agent/rewrite_agent/agent.js +209 -0
  128. package/dist/core/agent/rewrite_agent/guardrails.d.ts +0 -1
  129. package/dist/core/agent/rewrite_agent/guardrails.js +95 -0
  130. package/dist/core/agent/rewrite_agent/mapping.d.ts +0 -1
  131. package/dist/core/agent/rewrite_agent/mapping.js +56 -0
  132. package/dist/core/agent/rewrite_agent/parse.d.ts +0 -1
  133. package/dist/core/agent/rewrite_agent/parse.js +121 -0
  134. package/dist/core/agent/rewrite_agent/types.d.ts +0 -1
  135. package/dist/core/agent/rewrite_agent/types.js +37 -0
  136. package/dist/core/agent/single_agent/agent.d.ts +0 -1
  137. package/dist/core/agent/single_agent/agent.js +798 -0
  138. package/dist/core/agent/single_agent/hook_manager.d.ts +0 -1
  139. package/dist/core/agent/single_agent/hook_manager.js +60 -0
  140. package/dist/core/agent/single_agent/hooks.d.ts +0 -1
  141. package/dist/core/agent/single_agent/hooks.js +288 -0
  142. package/dist/core/agent/single_agent/image_utils.d.ts +0 -1
  143. package/dist/core/agent/single_agent/image_utils.js +159 -0
  144. package/dist/core/agent/single_agent/scroll_search_agent.d.ts +0 -1
  145. package/dist/core/agent/single_agent/scroll_search_agent.js +376 -0
  146. package/dist/core/agent/single_agent/subagent_manager.d.ts +0 -1
  147. package/dist/core/agent/single_agent/subagent_manager.js +73 -0
  148. package/dist/core/agent/single_agent/tool_recorder_hook.d.ts +0 -1
  149. package/dist/core/agent/single_agent/tool_recorder_hook.js +42 -0
  150. package/dist/core/agent/types.d.ts +0 -1
  151. package/dist/core/agent/types.js +2 -0
  152. package/dist/core/agent/utils/message_builder.d.ts +0 -1
  153. package/dist/core/agent/utils/message_builder.js +138 -0
  154. package/dist/core/device/device_protocol.d.ts +0 -1
  155. package/dist/core/device/device_protocol.js +2 -0
  156. package/dist/core/device/hdc/apps.d.ts +0 -1
  157. package/dist/core/device/hdc/apps.js +437 -0
  158. package/dist/core/device/hdc/device.d.ts +0 -1
  159. package/dist/core/device/hdc/device.js +219 -0
  160. package/dist/core/device/hdc/index.d.ts +0 -1
  161. package/dist/core/device/hdc/index.js +31 -0
  162. package/dist/core/device/hdc/input.d.ts +0 -1
  163. package/dist/core/device/hdc/input.js +74 -0
  164. package/dist/core/device/hdc/screenshot.d.ts +0 -1
  165. package/dist/core/device/hdc/screenshot.js +171 -0
  166. package/dist/core/device/index.d.ts +0 -1
  167. package/dist/core/device/index.js +70 -0
  168. package/dist/core/device/types.d.ts +0 -1
  169. package/dist/core/device/types.js +2 -0
  170. package/dist/core/knowledge/knowledge_manager.d.ts +0 -1
  171. package/dist/core/knowledge/knowledge_manager.js +70 -0
  172. package/dist/core/knowledge/vectordb.d.ts +0 -1
  173. package/dist/core/knowledge/vectordb.js +283 -0
  174. package/dist/core/mcp/adapter_factory.d.ts +0 -1
  175. package/dist/core/mcp/adapter_factory.js +99 -0
  176. package/dist/core/mcp/android_adapter.d.ts +1 -2
  177. package/dist/core/mcp/android_adapter.js +286 -0
  178. package/dist/core/mcp/base_adapter.d.ts +0 -1
  179. package/dist/core/mcp/base_adapter.js +86 -0
  180. package/dist/core/mcp/harmony_hdc_adapter.d.ts +9 -1
  181. package/dist/core/mcp/harmony_hdc_adapter.js +782 -0
  182. package/dist/core/mcp/ios_adapter.d.ts +1 -2
  183. package/dist/core/mcp/ios_adapter.js +286 -0
  184. package/dist/core/mcp/local_tools.d.ts +0 -1
  185. package/dist/core/mcp/local_tools.js +41 -0
  186. package/dist/core/mcp/mcp_tools.d.ts +0 -1
  187. package/dist/core/mcp/mcp_tools.js +382 -0
  188. package/dist/core/mcp/types.d.ts +0 -1
  189. package/dist/core/mcp/types.js +6 -0
  190. package/dist/core/memory/compressed_session.d.ts +0 -1
  191. package/dist/core/memory/compressed_session.js +182 -0
  192. package/dist/core/memory/context_compressor.d.ts +0 -1
  193. package/dist/core/memory/context_compressor.js +176 -0
  194. package/dist/core/memory/index.d.ts +0 -1
  195. package/dist/core/memory/index.js +22 -0
  196. package/dist/core/memory/memory_manager.d.ts +0 -1
  197. package/dist/core/memory/memory_manager.js +28 -0
  198. package/dist/core/memory/reflector.d.ts +0 -1
  199. package/dist/core/memory/reflector.js +95 -0
  200. package/dist/core/memory/session_factory.d.ts +0 -1
  201. package/dist/core/memory/session_factory.js +29 -0
  202. package/dist/core/memory/tool_player.d.ts +0 -1
  203. package/dist/core/memory/tool_player.js +225 -0
  204. package/dist/core/memory/tool_recorder.d.ts +0 -1
  205. package/dist/core/memory/tool_recorder.js +126 -0
  206. package/dist/core/preprocessor/task_splitter.d.ts +0 -1
  207. package/dist/core/preprocessor/task_splitter.js +112 -0
  208. package/dist/core/prompt/prompt_loader.d.ts +0 -1
  209. package/dist/core/prompt/prompt_loader.js +313 -0
  210. package/dist/core/skill/skill_manager.d.ts +0 -1
  211. package/dist/core/skill/skill_manager.js +299 -0
  212. package/dist/data_types/action.d.ts +0 -1
  213. package/dist/data_types/action.js +2 -0
  214. package/dist/data_types/agent.d.ts +0 -1
  215. package/dist/data_types/agent.js +2 -0
  216. package/dist/data_types/device.d.ts +0 -1
  217. package/dist/data_types/device.js +2 -0
  218. package/dist/data_types/index.d.ts +0 -1
  219. package/dist/data_types/index.js +6 -0
  220. package/dist/data_types/report.d.ts +0 -1
  221. package/dist/data_types/report.js +6 -0
  222. package/dist/data_types/task.d.ts +0 -1
  223. package/dist/data_types/task.js +2 -0
  224. package/dist/index.d.ts +1 -2
  225. package/dist/index.js +164 -1
  226. package/dist/loop/cli.d.ts +0 -1
  227. package/dist/loop/cli.js +127 -0
  228. package/dist/loop/orchestrator.d.ts +0 -1
  229. package/dist/loop/orchestrator.js +314 -0
  230. package/dist/loop/result_writer.d.ts +0 -1
  231. package/dist/loop/result_writer.js +260 -0
  232. package/dist/loop/types.d.ts +0 -1
  233. package/dist/loop/types.js +82 -0
  234. package/dist/mcp-server/server.d.ts +0 -1
  235. package/dist/mcp-server/server.js +341 -0
  236. package/dist/mcp-server/types.d.ts +283 -118
  237. package/dist/mcp-server/types.js +202 -0
  238. package/dist/reporter/batch_summary.d.ts +0 -1
  239. package/dist/reporter/batch_summary.js +197 -0
  240. package/dist/reporter/generator.d.ts +0 -1
  241. package/dist/reporter/generator.js +772 -0
  242. package/dist/reporter/types.d.ts +14 -15
  243. package/dist/reporter/types.js +44 -0
  244. package/dist/tools/batch_runner.d.ts +1 -1
  245. package/dist/tools/batch_runner.js +731 -0
  246. package/package.json +5 -3
  247. package/dist/common/config/config.yaml +0 -113
  248. package/dist/hypium_generator/generator.d.ts +0 -38
@@ -6,14 +6,41 @@ export interface McpServerConfig {
6
6
  autoStart: boolean;
7
7
  }
8
8
  export declare enum McpServerToolName {
9
- TAP = "tap",
10
- DOUBLE_TAP = "double_tap",
9
+ CLICK = "click",
10
+ DOUBLE_CLICK = "double_click",
11
+ LONG_CLICK = "long_click",
11
12
  SWIPE = "swipe",
12
- TYPE_TEXT = "type_text",
13
- BACK = "back",
14
- HOME = "home",
15
- LAUNCH_APP = "launch_app",
16
- GET_SCREENSHOT = "get_screenshot",
13
+ DRAG = "drag",
14
+ INPUT_TEXT = "input_text",
15
+ CLEAR_TEXT = "clear_text",
16
+ GO_BACK = "go_back",
17
+ GO_HOME = "go_home",
18
+ START_APP = "start_app",
19
+ STOP_APP = "stop_app",
20
+ CLEAR_APP_DATA = "clear_app_data",
21
+ WAIT = "wait",
22
+ PRESS_KEY = "press_key",
23
+ SCREEN_ON = "screen_on",
24
+ SCREEN_OFF = "screen_off",
25
+ UNLOCK_SCREEN = "unlock_screen",
26
+ CLEAR_RECENT_TASK = "clear_recent_task",
27
+ ENTER_RECENT_TASK = "enter_recent_task",
28
+ GET_CURRENT_APP = "get_current_app",
29
+ SCREENSHOT = "screenshot",
30
+ LAYOUT = "layout",
31
+ MCP_CLEAN_UP = "mcp_clean_up",
32
+ OPEN_CONTROL_CENTER = "open_control_center",
33
+ OPEN_NOTIFICATION_CENTER = "open_notification_center",
34
+ PINCH_IN = "pinch_in",
35
+ PINCH_OUT = "pinch_out",
36
+ ROTATE_GESTURE = "rotate_gesture",
37
+ ROTATE_SCREEN = "rotate_screen",
38
+ STOP_ALL_APP = "stop_all_app",
39
+ START_LISTEN_TOAST = "start_listen_toast",
40
+ GET_TOAST = "get_toast",
41
+ START_DATA_COLLECT = "start_data_collect",
42
+ STOP_DATA_COLLECT = "stop_data_collect",
43
+ GENERATE_REPORT = "generate_report",
17
44
  LIST_DEVICES = "list_devices",
18
45
  RUN_TASK = "run_task",
19
46
  GET_TASK_RESULT = "get_task_result",
@@ -22,96 +49,240 @@ export declare enum McpServerToolName {
22
49
  GET_CONFIG = "get_config",
23
50
  UPDATE_CONFIG = "update_config"
24
51
  }
25
- export declare const TapInputSchema: z.ZodObject<{
26
- x: z.ZodNumber;
27
- y: z.ZodNumber;
28
- delay: z.ZodDefault<z.ZodNumber>;
29
- }, "strip", z.ZodTypeAny, {
30
- x: number;
31
- y: number;
32
- delay: number;
33
- }, {
34
- x: number;
35
- y: number;
36
- delay?: number | undefined;
37
- }>;
38
- export type TapInput = z.infer<typeof TapInputSchema>;
39
- export declare const DoubleTapInputSchema: z.ZodObject<{
40
- x: z.ZodNumber;
41
- y: z.ZodNumber;
42
- delay: z.ZodDefault<z.ZodNumber>;
43
- }, "strip", z.ZodTypeAny, {
44
- x: number;
45
- y: number;
46
- delay: number;
47
- }, {
48
- x: number;
49
- y: number;
50
- delay?: number | undefined;
51
- }>;
52
- export type DoubleTapInput = z.infer<typeof DoubleTapInputSchema>;
52
+ export declare const ClickInputSchema: z.ZodObject<{
53
+ pos: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
54
+ x: z.ZodOptional<z.ZodNumber>;
55
+ y: z.ZodOptional<z.ZodNumber>;
56
+ }, "strip", z.ZodTypeAny, {
57
+ pos?: number[];
58
+ x?: number;
59
+ y?: number;
60
+ }, {
61
+ pos?: number[];
62
+ x?: number;
63
+ y?: number;
64
+ }>;
65
+ export declare const DoubleClickInputSchema: z.ZodObject<{
66
+ pos: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
67
+ x: z.ZodOptional<z.ZodNumber>;
68
+ y: z.ZodOptional<z.ZodNumber>;
69
+ }, "strip", z.ZodTypeAny, {
70
+ pos?: number[];
71
+ x?: number;
72
+ y?: number;
73
+ }, {
74
+ pos?: number[];
75
+ x?: number;
76
+ y?: number;
77
+ }>;
78
+ export declare const LongClickInputSchema: z.ZodObject<{
79
+ pos: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
80
+ x: z.ZodOptional<z.ZodNumber>;
81
+ y: z.ZodOptional<z.ZodNumber>;
82
+ duration: z.ZodDefault<z.ZodNumber>;
83
+ }, "strip", z.ZodTypeAny, {
84
+ pos?: number[];
85
+ x?: number;
86
+ y?: number;
87
+ duration?: number;
88
+ }, {
89
+ pos?: number[];
90
+ x?: number;
91
+ y?: number;
92
+ duration?: number;
93
+ }>;
53
94
  export declare const SwipeInputSchema: z.ZodObject<{
54
- startX: z.ZodNumber;
55
- startY: z.ZodNumber;
56
- endX: z.ZodNumber;
57
- endY: z.ZodNumber;
58
- }, "strip", z.ZodTypeAny, {
59
- startX: number;
60
- startY: number;
61
- endX: number;
62
- endY: number;
63
- }, {
64
- startX: number;
65
- startY: number;
66
- endX: number;
67
- endY: number;
68
- }>;
69
- export type SwipeInput = z.infer<typeof SwipeInputSchema>;
70
- export declare const TypeTextInputSchema: z.ZodObject<{
95
+ start: z.ZodArray<z.ZodNumber, "many">;
96
+ end: z.ZodArray<z.ZodNumber, "many">;
97
+ direction: z.ZodOptional<z.ZodString>;
98
+ }, "strip", z.ZodTypeAny, {
99
+ start?: number[];
100
+ end?: number[];
101
+ direction?: string;
102
+ }, {
103
+ start?: number[];
104
+ end?: number[];
105
+ direction?: string;
106
+ }>;
107
+ export declare const DragInputSchema: z.ZodObject<{
108
+ start: z.ZodArray<z.ZodNumber, "many">;
109
+ end: z.ZodArray<z.ZodNumber, "many">;
110
+ }, "strip", z.ZodTypeAny, {
111
+ start?: number[];
112
+ end?: number[];
113
+ }, {
114
+ start?: number[];
115
+ end?: number[];
116
+ }>;
117
+ export declare const InputTextInputSchema: z.ZodObject<{
71
118
  text: z.ZodString;
72
119
  }, "strip", z.ZodTypeAny, {
73
- text: string;
120
+ text?: string;
121
+ }, {
122
+ text?: string;
123
+ }>;
124
+ export declare const ClearTextInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
125
+ export declare const GoBackInputSchema: z.ZodObject<{
126
+ times: z.ZodDefault<z.ZodNumber>;
127
+ }, "strip", z.ZodTypeAny, {
128
+ times?: number;
129
+ }, {
130
+ times?: number;
131
+ }>;
132
+ export declare const GoHomeInputSchema: z.ZodObject<{
133
+ times: z.ZodDefault<z.ZodNumber>;
134
+ }, "strip", z.ZodTypeAny, {
135
+ times?: number;
136
+ }, {
137
+ times?: number;
138
+ }>;
139
+ export declare const StartAppInputSchema: z.ZodObject<{
140
+ app_name: z.ZodString;
141
+ cold_start: z.ZodDefault<z.ZodBoolean>;
142
+ }, "strip", z.ZodTypeAny, {
143
+ app_name?: string;
144
+ cold_start?: boolean;
145
+ }, {
146
+ app_name?: string;
147
+ cold_start?: boolean;
148
+ }>;
149
+ export declare const StopAppInputSchema: z.ZodObject<{
150
+ app_name: z.ZodString;
151
+ }, "strip", z.ZodTypeAny, {
152
+ app_name?: string;
74
153
  }, {
75
- text: string;
154
+ app_name?: string;
76
155
  }>;
77
- export type TypeTextInput = z.infer<typeof TypeTextInputSchema>;
78
- export declare const BackInputSchema: z.ZodObject<{
79
- delay: z.ZodDefault<z.ZodNumber>;
156
+ export declare const ClearAppDataInputSchema: z.ZodObject<{
157
+ app_name: z.ZodString;
80
158
  }, "strip", z.ZodTypeAny, {
81
- delay: number;
159
+ app_name?: string;
82
160
  }, {
83
- delay?: number | undefined;
161
+ app_name?: string;
84
162
  }>;
85
- export type BackInput = z.infer<typeof BackInputSchema>;
86
- export declare const HomeInputSchema: z.ZodObject<{
87
- delay: z.ZodDefault<z.ZodNumber>;
163
+ export declare const WaitInputSchema: z.ZodObject<{
164
+ duration: z.ZodDefault<z.ZodNumber>;
88
165
  }, "strip", z.ZodTypeAny, {
89
- delay: number;
166
+ duration?: number;
90
167
  }, {
91
- delay?: number | undefined;
168
+ duration?: number;
92
169
  }>;
93
- export type HomeInput = z.infer<typeof HomeInputSchema>;
94
- export declare const LaunchAppInputSchema: z.ZodObject<{
95
- appName: z.ZodString;
96
- delay: z.ZodDefault<z.ZodNumber>;
170
+ export declare const PressKeyInputSchema: z.ZodObject<{
171
+ key_name: z.ZodEnum<["home", "power", "volume_up", "volume_down"]>;
97
172
  }, "strip", z.ZodTypeAny, {
98
- appName: string;
99
- delay: number;
173
+ key_name?: "home" | "power" | "volume_up" | "volume_down";
100
174
  }, {
101
- appName: string;
102
- delay?: number | undefined;
175
+ key_name?: "home" | "power" | "volume_up" | "volume_down";
103
176
  }>;
104
- export type LaunchAppInput = z.infer<typeof LaunchAppInputSchema>;
105
- export declare const GetScreenshotInputSchema: z.ZodObject<{
106
- saveToReport: z.ZodDefault<z.ZodBoolean>;
177
+ export declare const ScreenOnInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
178
+ export declare const ScreenOffInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
179
+ export declare const UnlockScreenInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
180
+ export declare const ClearRecentTaskInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
181
+ export declare const EnterRecentTaskInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
182
+ export declare const GetCurrentAppInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
183
+ export declare const ScreenshotInputSchema: z.ZodObject<{
184
+ save_path: z.ZodOptional<z.ZodString>;
107
185
  }, "strip", z.ZodTypeAny, {
108
- saveToReport: boolean;
186
+ save_path?: string;
109
187
  }, {
110
- saveToReport?: boolean | undefined;
188
+ save_path?: string;
111
189
  }>;
112
- export type GetScreenshotInput = z.infer<typeof GetScreenshotInputSchema>;
190
+ export declare const LayoutInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
191
+ export declare const McpCleanUpInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
192
+ export declare const OpenControlCenterInputSchema: z.ZodObject<{
193
+ full_screen: z.ZodDefault<z.ZodBoolean>;
194
+ }, "strip", z.ZodTypeAny, {
195
+ full_screen?: boolean;
196
+ }, {
197
+ full_screen?: boolean;
198
+ }>;
199
+ export declare const OpenNotificationCenterInputSchema: z.ZodObject<{
200
+ full_screen: z.ZodDefault<z.ZodBoolean>;
201
+ }, "strip", z.ZodTypeAny, {
202
+ full_screen?: boolean;
203
+ }, {
204
+ full_screen?: boolean;
205
+ }>;
206
+ export declare const PinchInInputSchema: z.ZodObject<{
207
+ pos: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
208
+ x: z.ZodOptional<z.ZodNumber>;
209
+ y: z.ZodOptional<z.ZodNumber>;
210
+ radius: z.ZodDefault<z.ZodNumber>;
211
+ scale: z.ZodDefault<z.ZodNumber>;
212
+ }, "strip", z.ZodTypeAny, {
213
+ pos?: number[];
214
+ x?: number;
215
+ y?: number;
216
+ radius?: number;
217
+ scale?: number;
218
+ }, {
219
+ pos?: number[];
220
+ x?: number;
221
+ y?: number;
222
+ radius?: number;
223
+ scale?: number;
224
+ }>;
225
+ export declare const PinchOutInputSchema: z.ZodObject<{
226
+ pos: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
227
+ x: z.ZodOptional<z.ZodNumber>;
228
+ y: z.ZodOptional<z.ZodNumber>;
229
+ radius: z.ZodDefault<z.ZodNumber>;
230
+ scale: z.ZodDefault<z.ZodNumber>;
231
+ }, "strip", z.ZodTypeAny, {
232
+ pos?: number[];
233
+ x?: number;
234
+ y?: number;
235
+ radius?: number;
236
+ scale?: number;
237
+ }, {
238
+ pos?: number[];
239
+ x?: number;
240
+ y?: number;
241
+ radius?: number;
242
+ scale?: number;
243
+ }>;
244
+ export declare const RotateGestureInputSchema: z.ZodObject<{
245
+ pos: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
246
+ x: z.ZodOptional<z.ZodNumber>;
247
+ y: z.ZodOptional<z.ZodNumber>;
248
+ angle: z.ZodDefault<z.ZodNumber>;
249
+ clockwise: z.ZodDefault<z.ZodBoolean>;
250
+ radius: z.ZodDefault<z.ZodNumber>;
251
+ }, "strip", z.ZodTypeAny, {
252
+ pos?: number[];
253
+ x?: number;
254
+ y?: number;
255
+ radius?: number;
256
+ angle?: number;
257
+ clockwise?: boolean;
258
+ }, {
259
+ pos?: number[];
260
+ x?: number;
261
+ y?: number;
262
+ radius?: number;
263
+ angle?: number;
264
+ clockwise?: boolean;
265
+ }>;
266
+ export declare const RotateScreenInputSchema: z.ZodObject<{
267
+ direction: z.ZodEnum<["portrait", "landscape"]>;
268
+ }, "strip", z.ZodTypeAny, {
269
+ direction?: "portrait" | "landscape";
270
+ }, {
271
+ direction?: "portrait" | "landscape";
272
+ }>;
273
+ export declare const StopAllAppInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
274
+ export declare const StartListenToastInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
275
+ export declare const GetToastInputSchema: z.ZodObject<{
276
+ timeout: z.ZodDefault<z.ZodNumber>;
277
+ }, "strip", z.ZodTypeAny, {
278
+ timeout?: number;
279
+ }, {
280
+ timeout?: number;
281
+ }>;
282
+ export declare const StartDataCollectInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
283
+ export declare const StopDataCollectInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
284
+ export declare const GenerateReportInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
113
285
  export declare const ListDevicesInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
114
- export type ListDevicesInput = z.infer<typeof ListDevicesInputSchema>;
115
286
  export declare const RunTaskInputSchema: z.ZodObject<{
116
287
  task: z.ZodString;
117
288
  agentMode: z.ZodDefault<z.ZodEnum<["single", "hypium", "layered"]>>;
@@ -123,67 +294,62 @@ export declare const RunTaskInputSchema: z.ZodObject<{
123
294
  feedbackMode: z.ZodDefault<z.ZodEnum<["poll", "stream", "callback"]>>;
124
295
  callbackUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
125
296
  }, "strip", z.ZodTypeAny, {
126
- task: string;
127
- platform: "harmony" | "android" | "ios";
128
- agentMode: "single" | "hypium" | "layered";
129
- deviceId: string;
130
- feedbackMode: "poll" | "stream" | "callback";
131
- promptVersion?: string | null | undefined;
132
- reportDir?: string | null | undefined;
133
- configOverrides?: Record<string, unknown> | null | undefined;
134
- callbackUrl?: string | null | undefined;
135
- }, {
136
- task: string;
137
- deviceId: string;
138
- promptVersion?: string | null | undefined;
139
- reportDir?: string | null | undefined;
140
- platform?: "harmony" | "android" | "ios" | undefined;
141
- configOverrides?: Record<string, unknown> | null | undefined;
142
- agentMode?: "single" | "hypium" | "layered" | undefined;
143
- feedbackMode?: "poll" | "stream" | "callback" | undefined;
144
- callbackUrl?: string | null | undefined;
145
- }>;
146
- export type RunTaskInput = z.infer<typeof RunTaskInputSchema>;
297
+ promptVersion?: string;
298
+ reportDir?: string;
299
+ task?: string;
300
+ agentMode?: "single" | "hypium" | "layered";
301
+ deviceId?: string;
302
+ platform?: "harmony" | "android" | "ios";
303
+ configOverrides?: Record<string, unknown>;
304
+ feedbackMode?: "poll" | "stream" | "callback";
305
+ callbackUrl?: string;
306
+ }, {
307
+ promptVersion?: string;
308
+ reportDir?: string;
309
+ task?: string;
310
+ agentMode?: "single" | "hypium" | "layered";
311
+ deviceId?: string;
312
+ platform?: "harmony" | "android" | "ios";
313
+ configOverrides?: Record<string, unknown>;
314
+ feedbackMode?: "poll" | "stream" | "callback";
315
+ callbackUrl?: string;
316
+ }>;
147
317
  export declare const GetTaskResultInputSchema: z.ZodObject<{
148
318
  taskId: z.ZodString;
149
319
  }, "strip", z.ZodTypeAny, {
150
- taskId: string;
320
+ taskId?: string;
151
321
  }, {
152
- taskId: string;
322
+ taskId?: string;
153
323
  }>;
154
- export type GetTaskResultInput = z.infer<typeof GetTaskResultInputSchema>;
155
324
  export declare const ResumeTaskInputSchema: z.ZodObject<{
156
325
  taskId: z.ZodString;
157
326
  startIndex: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
158
327
  }, "strip", z.ZodTypeAny, {
159
- taskId: string;
160
- startIndex?: number | null | undefined;
328
+ taskId?: string;
329
+ startIndex?: number;
161
330
  }, {
162
- taskId: string;
163
- startIndex?: number | null | undefined;
331
+ taskId?: string;
332
+ startIndex?: number;
164
333
  }>;
165
- export type ResumeTaskInput = z.infer<typeof ResumeTaskInputSchema>;
166
334
  export declare const AnalyzeFailureInputSchema: z.ZodObject<{
167
335
  taskId: z.ZodString;
168
336
  caseIdx: z.ZodNumber;
169
337
  }, "strip", z.ZodTypeAny, {
170
- taskId: string;
171
- caseIdx: number;
338
+ taskId?: string;
339
+ caseIdx?: number;
172
340
  }, {
173
- taskId: string;
174
- caseIdx: number;
341
+ taskId?: string;
342
+ caseIdx?: number;
175
343
  }>;
176
- export type AnalyzeFailureInput = z.infer<typeof AnalyzeFailureInputSchema>;
177
344
  export declare const GetConfigInputSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
178
- export type GetConfigInput = z.infer<typeof GetConfigInputSchema>;
179
345
  export declare const UpdateConfigInputSchema: z.ZodObject<{
180
346
  partial: z.ZodRecord<z.ZodString, z.ZodUnknown>;
181
347
  }, "strip", z.ZodTypeAny, {
182
- partial: Record<string, unknown>;
348
+ partial?: Record<string, unknown>;
183
349
  }, {
184
- partial: Record<string, unknown>;
350
+ partial?: Record<string, unknown>;
185
351
  }>;
186
- export type UpdateConfigInput = z.infer<typeof UpdateConfigInputSchema>;
352
+ export declare const TOOL_DESCRIPTIONS: Record<string, string>;
187
353
  export interface McpServerCapabilities {
188
354
  tools: {
189
355
  listChanged: boolean;
@@ -193,4 +359,3 @@ export interface McpServerCapabilities {
193
359
  listChanged: boolean;
194
360
  };
195
361
  }
196
- //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1,202 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TOOL_DESCRIPTIONS = exports.UpdateConfigInputSchema = exports.GetConfigInputSchema = exports.AnalyzeFailureInputSchema = exports.ResumeTaskInputSchema = exports.GetTaskResultInputSchema = exports.RunTaskInputSchema = exports.ListDevicesInputSchema = exports.GenerateReportInputSchema = exports.StopDataCollectInputSchema = exports.StartDataCollectInputSchema = exports.GetToastInputSchema = exports.StartListenToastInputSchema = exports.StopAllAppInputSchema = exports.RotateScreenInputSchema = exports.RotateGestureInputSchema = exports.PinchOutInputSchema = exports.PinchInInputSchema = exports.OpenNotificationCenterInputSchema = exports.OpenControlCenterInputSchema = exports.McpCleanUpInputSchema = exports.LayoutInputSchema = exports.ScreenshotInputSchema = exports.GetCurrentAppInputSchema = exports.EnterRecentTaskInputSchema = exports.ClearRecentTaskInputSchema = exports.UnlockScreenInputSchema = exports.ScreenOffInputSchema = exports.ScreenOnInputSchema = exports.PressKeyInputSchema = exports.WaitInputSchema = exports.ClearAppDataInputSchema = exports.StopAppInputSchema = exports.StartAppInputSchema = exports.GoHomeInputSchema = exports.GoBackInputSchema = exports.ClearTextInputSchema = exports.InputTextInputSchema = exports.DragInputSchema = exports.SwipeInputSchema = exports.LongClickInputSchema = exports.DoubleClickInputSchema = exports.ClickInputSchema = exports.McpServerToolName = void 0;
4
+ const zod_1 = require("zod");
5
+ var McpServerToolName;
6
+ (function (McpServerToolName) {
7
+ McpServerToolName["CLICK"] = "click";
8
+ McpServerToolName["DOUBLE_CLICK"] = "double_click";
9
+ McpServerToolName["LONG_CLICK"] = "long_click";
10
+ McpServerToolName["SWIPE"] = "swipe";
11
+ McpServerToolName["DRAG"] = "drag";
12
+ McpServerToolName["INPUT_TEXT"] = "input_text";
13
+ McpServerToolName["CLEAR_TEXT"] = "clear_text";
14
+ McpServerToolName["GO_BACK"] = "go_back";
15
+ McpServerToolName["GO_HOME"] = "go_home";
16
+ McpServerToolName["START_APP"] = "start_app";
17
+ McpServerToolName["STOP_APP"] = "stop_app";
18
+ McpServerToolName["CLEAR_APP_DATA"] = "clear_app_data";
19
+ McpServerToolName["WAIT"] = "wait";
20
+ McpServerToolName["PRESS_KEY"] = "press_key";
21
+ McpServerToolName["SCREEN_ON"] = "screen_on";
22
+ McpServerToolName["SCREEN_OFF"] = "screen_off";
23
+ McpServerToolName["UNLOCK_SCREEN"] = "unlock_screen";
24
+ McpServerToolName["CLEAR_RECENT_TASK"] = "clear_recent_task";
25
+ McpServerToolName["ENTER_RECENT_TASK"] = "enter_recent_task";
26
+ McpServerToolName["GET_CURRENT_APP"] = "get_current_app";
27
+ McpServerToolName["SCREENSHOT"] = "screenshot";
28
+ McpServerToolName["LAYOUT"] = "layout";
29
+ McpServerToolName["MCP_CLEAN_UP"] = "mcp_clean_up";
30
+ McpServerToolName["OPEN_CONTROL_CENTER"] = "open_control_center";
31
+ McpServerToolName["OPEN_NOTIFICATION_CENTER"] = "open_notification_center";
32
+ McpServerToolName["PINCH_IN"] = "pinch_in";
33
+ McpServerToolName["PINCH_OUT"] = "pinch_out";
34
+ McpServerToolName["ROTATE_GESTURE"] = "rotate_gesture";
35
+ McpServerToolName["ROTATE_SCREEN"] = "rotate_screen";
36
+ McpServerToolName["STOP_ALL_APP"] = "stop_all_app";
37
+ McpServerToolName["START_LISTEN_TOAST"] = "start_listen_toast";
38
+ McpServerToolName["GET_TOAST"] = "get_toast";
39
+ McpServerToolName["START_DATA_COLLECT"] = "start_data_collect";
40
+ McpServerToolName["STOP_DATA_COLLECT"] = "stop_data_collect";
41
+ McpServerToolName["GENERATE_REPORT"] = "generate_report";
42
+ McpServerToolName["LIST_DEVICES"] = "list_devices";
43
+ McpServerToolName["RUN_TASK"] = "run_task";
44
+ McpServerToolName["GET_TASK_RESULT"] = "get_task_result";
45
+ McpServerToolName["RESUME_TASK"] = "resume_task";
46
+ McpServerToolName["ANALYZE_FAILURE"] = "analyze_failure";
47
+ McpServerToolName["GET_CONFIG"] = "get_config";
48
+ McpServerToolName["UPDATE_CONFIG"] = "update_config";
49
+ })(McpServerToolName || (exports.McpServerToolName = McpServerToolName = {}));
50
+ const PointSchema = zod_1.z.object({
51
+ pos: zod_1.z.array(zod_1.z.number()).length(2).optional(),
52
+ x: zod_1.z.number().optional(),
53
+ y: zod_1.z.number().optional(),
54
+ });
55
+ exports.ClickInputSchema = PointSchema;
56
+ exports.DoubleClickInputSchema = PointSchema;
57
+ exports.LongClickInputSchema = zod_1.z.object({
58
+ pos: zod_1.z.array(zod_1.z.number()).length(2).optional(),
59
+ x: zod_1.z.number().optional(),
60
+ y: zod_1.z.number().optional(),
61
+ duration: zod_1.z.number().default(2),
62
+ });
63
+ exports.SwipeInputSchema = zod_1.z.object({
64
+ start: zod_1.z.array(zod_1.z.number()).length(2),
65
+ end: zod_1.z.array(zod_1.z.number()).length(2),
66
+ direction: zod_1.z.string().optional(),
67
+ });
68
+ exports.DragInputSchema = zod_1.z.object({
69
+ start: zod_1.z.array(zod_1.z.number()).length(2),
70
+ end: zod_1.z.array(zod_1.z.number()).length(2),
71
+ });
72
+ exports.InputTextInputSchema = zod_1.z.object({ text: zod_1.z.string() });
73
+ exports.ClearTextInputSchema = zod_1.z.object({});
74
+ exports.GoBackInputSchema = zod_1.z.object({ times: zod_1.z.number().int().default(1) });
75
+ exports.GoHomeInputSchema = zod_1.z.object({ times: zod_1.z.number().int().default(1) });
76
+ exports.StartAppInputSchema = zod_1.z.object({
77
+ app_name: zod_1.z.string(),
78
+ cold_start: zod_1.z.boolean().default(false),
79
+ });
80
+ exports.StopAppInputSchema = zod_1.z.object({ app_name: zod_1.z.string() });
81
+ exports.ClearAppDataInputSchema = zod_1.z.object({ app_name: zod_1.z.string() });
82
+ exports.WaitInputSchema = zod_1.z.object({ duration: zod_1.z.number().default(3) });
83
+ exports.PressKeyInputSchema = zod_1.z.object({
84
+ key_name: zod_1.z.enum(['home', 'power', 'volume_up', 'volume_down']),
85
+ });
86
+ exports.ScreenOnInputSchema = zod_1.z.object({});
87
+ exports.ScreenOffInputSchema = zod_1.z.object({});
88
+ exports.UnlockScreenInputSchema = zod_1.z.object({});
89
+ exports.ClearRecentTaskInputSchema = zod_1.z.object({});
90
+ exports.EnterRecentTaskInputSchema = zod_1.z.object({});
91
+ exports.GetCurrentAppInputSchema = zod_1.z.object({});
92
+ exports.ScreenshotInputSchema = zod_1.z.object({
93
+ save_path: zod_1.z.string().optional(),
94
+ });
95
+ exports.LayoutInputSchema = zod_1.z.object({});
96
+ exports.McpCleanUpInputSchema = zod_1.z.object({});
97
+ exports.OpenControlCenterInputSchema = zod_1.z.object({
98
+ full_screen: zod_1.z.boolean().default(false),
99
+ });
100
+ exports.OpenNotificationCenterInputSchema = zod_1.z.object({
101
+ full_screen: zod_1.z.boolean().default(false),
102
+ });
103
+ exports.PinchInInputSchema = zod_1.z.object({
104
+ pos: zod_1.z.array(zod_1.z.number()).length(2).optional(),
105
+ x: zod_1.z.number().optional(),
106
+ y: zod_1.z.number().optional(),
107
+ radius: zod_1.z.number().default(300),
108
+ scale: zod_1.z.number().default(0.2),
109
+ });
110
+ exports.PinchOutInputSchema = zod_1.z.object({
111
+ pos: zod_1.z.array(zod_1.z.number()).length(2).optional(),
112
+ x: zod_1.z.number().optional(),
113
+ y: zod_1.z.number().optional(),
114
+ radius: zod_1.z.number().default(300),
115
+ scale: zod_1.z.number().default(1.6),
116
+ });
117
+ exports.RotateGestureInputSchema = zod_1.z.object({
118
+ pos: zod_1.z.array(zod_1.z.number()).length(2).optional(),
119
+ x: zod_1.z.number().optional(),
120
+ y: zod_1.z.number().optional(),
121
+ angle: zod_1.z.number().default(90),
122
+ clockwise: zod_1.z.boolean().default(true),
123
+ radius: zod_1.z.number().default(300),
124
+ });
125
+ exports.RotateScreenInputSchema = zod_1.z.object({
126
+ direction: zod_1.z.enum(['portrait', 'landscape']),
127
+ });
128
+ exports.StopAllAppInputSchema = zod_1.z.object({});
129
+ exports.StartListenToastInputSchema = zod_1.z.object({});
130
+ exports.GetToastInputSchema = zod_1.z.object({
131
+ timeout: zod_1.z.number().default(3),
132
+ });
133
+ exports.StartDataCollectInputSchema = zod_1.z.object({});
134
+ exports.StopDataCollectInputSchema = zod_1.z.object({});
135
+ exports.GenerateReportInputSchema = zod_1.z.object({});
136
+ exports.ListDevicesInputSchema = zod_1.z.object({});
137
+ exports.RunTaskInputSchema = zod_1.z.object({
138
+ task: zod_1.z.string(),
139
+ agentMode: zod_1.z.enum(['single', 'hypium', 'layered']).default('single'),
140
+ deviceId: zod_1.z.string(),
141
+ platform: zod_1.z.enum(['harmony', 'android', 'ios']).default('harmony'),
142
+ promptVersion: zod_1.z.string().nullable().optional(),
143
+ configOverrides: zod_1.z.record(zod_1.z.string(), zod_1.z.unknown()).nullable().optional(),
144
+ reportDir: zod_1.z.string().nullable().optional(),
145
+ feedbackMode: zod_1.z.enum(['poll', 'stream', 'callback']).default('poll'),
146
+ callbackUrl: zod_1.z.string().nullable().optional(),
147
+ });
148
+ exports.GetTaskResultInputSchema = zod_1.z.object({ taskId: zod_1.z.string() });
149
+ exports.ResumeTaskInputSchema = zod_1.z.object({
150
+ taskId: zod_1.z.string(),
151
+ startIndex: zod_1.z.number().int().nullable().optional(),
152
+ });
153
+ exports.AnalyzeFailureInputSchema = zod_1.z.object({
154
+ taskId: zod_1.z.string(),
155
+ caseIdx: zod_1.z.number().int(),
156
+ });
157
+ exports.GetConfigInputSchema = zod_1.z.object({});
158
+ exports.UpdateConfigInputSchema = zod_1.z.object({ partial: zod_1.z.record(zod_1.z.string(), zod_1.z.unknown()) });
159
+ exports.TOOL_DESCRIPTIONS = {
160
+ click: 'Click at the given coordinates',
161
+ double_click: 'Double-click at the given coordinates',
162
+ long_click: 'Long-press at the given coordinates',
163
+ swipe: 'Swipe from start point to end point',
164
+ drag: 'Drag from start point to end point',
165
+ input_text: 'Input text at the current cursor position',
166
+ clear_text: 'Clear text at the current cursor position',
167
+ go_back: 'Go back to the previous screen',
168
+ go_home: 'Go to the home screen',
169
+ start_app: 'Launch an application on the device',
170
+ stop_app: 'Stop an application on the device',
171
+ clear_app_data: 'Clear application data',
172
+ wait: 'Wait for the specified duration (max 200s)',
173
+ press_key: 'Press a key (home/power/volume_up/volume_down)',
174
+ screen_on: 'Turn on the device screen',
175
+ screen_off: 'Turn off the device screen',
176
+ unlock_screen: 'Unlock the device screen',
177
+ clear_recent_task: 'Clear all recent tasks',
178
+ enter_recent_task: 'Enter the recent tasks page',
179
+ get_current_app: 'Get the current foreground app bundle name',
180
+ screenshot: 'Capture a screenshot',
181
+ layout: 'Get the current UI layout',
182
+ mcp_clean_up: 'Release all cached device connections',
183
+ open_control_center: 'Open the system control center',
184
+ open_notification_center: 'Open the system notification center',
185
+ pinch_in: 'Pinch in (two-finger zoom out)',
186
+ pinch_out: 'Pinch out (two-finger zoom in)',
187
+ rotate_gesture: 'Perform a two-finger rotation gesture',
188
+ rotate_screen: 'Rotate the screen orientation',
189
+ stop_all_app: 'Stop all running applications',
190
+ start_listen_toast: 'Start listening for Toast messages',
191
+ get_toast: 'Get the latest Toast message',
192
+ start_data_collect: 'Start data collection',
193
+ stop_data_collect: 'Stop data collection',
194
+ generate_report: 'Generate a test report',
195
+ list_devices: 'List all connected devices',
196
+ run_task: 'Run a test task',
197
+ get_task_result: 'Get the result of a task',
198
+ resume_task: 'Resume a task from a given step',
199
+ analyze_failure: 'Analyze the failure of a task',
200
+ get_config: 'Get the current configuration',
201
+ update_config: 'Update the configuration',
202
+ };