terminator-mcp-agent 0.15.9 → 0.15.17
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.
- package/README.md +32 -1
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -232,7 +232,10 @@ The Terminator MCP agent offers two primary workflows for automating desktop tas
|
|
|
232
232
|
|
|
233
233
|
This is the most powerful and flexible method. You build a workflow step-by-step, using MCP tools to inspect the UI and refine your actions.
|
|
234
234
|
|
|
235
|
-
1. **Inspect the UI**: Start by using `get_focused_window_tree` to understand the structure of your target application. This gives you the roles, names, and IDs of all elements.
|
|
235
|
+
1. **Inspect the UI**: Start by using `get_focused_window_tree` to understand the structure of your target application. This gives you the roles, names, and IDs of all elements. For performance optimization:
|
|
236
|
+
- Use `include_tree: { max_depth: 2 }` to limit tree depth when you only need shallow inspection
|
|
237
|
+
- Use `include_tree: { from_selector: "role:Dialog" }` to get subtree from a specific element
|
|
238
|
+
- Use `include_tree: { from_selector: "true" }` to start from the currently focused element
|
|
236
239
|
2. **Build a Sequence**: Create an `execute_sequence` tool call with a series of actions (`click_element`, `type_into_element`, etc.). Use robust selectors (like `role|name` or stable `properties:AutomationId:value` selectors) whenever possible.
|
|
237
240
|
3. **Capture the Final State**: Ensure the last step in your sequence is an action that returns a UI tree. The `wait_for_element` tool with `include_tree: true` is perfect for this, as it captures the application's state after your automation has run.
|
|
238
241
|
4. **Extract Structured Data with `output_parser`**: Add the `output_parser` argument to your `execute_sequence` call. Write JavaScript code to parse the final UI tree and extract structured data. If successful, the tool result will contain a `parsed_output` field with your clean JSON data.
|
|
@@ -713,6 +716,10 @@ The virtual display manager creates a memory-based display context that satisfie
|
|
|
713
716
|
- Use specific selectors instead of broad element searches
|
|
714
717
|
- Implement delays between rapid operations
|
|
715
718
|
- Consider using `include_tree: false` for intermediate steps
|
|
719
|
+
- For tree extraction tools, optimize with:
|
|
720
|
+
- `include_tree: { max_depth: 2 }` - Limit depth for large trees
|
|
721
|
+
- `include_tree: { from_selector: "role:List" }` - Get subtree from specific element
|
|
722
|
+
- `include_tree: { from_selector: "true" }` - Start from focused element
|
|
716
723
|
|
|
717
724
|
**JavaScript Performance**:
|
|
718
725
|
|
|
@@ -895,6 +902,30 @@ steps:
|
|
|
895
902
|
- tool_name: run_command
|
|
896
903
|
arguments:
|
|
897
904
|
engine: javascript
|
|
905
|
+
|
|
906
|
+
# Tree Parameter Examples - Performance Optimization
|
|
907
|
+
- tool_name: get_window_tree
|
|
908
|
+
arguments:
|
|
909
|
+
pid: 1234
|
|
910
|
+
include_tree:
|
|
911
|
+
max_depth: 2 # Only get 2 levels deep
|
|
912
|
+
|
|
913
|
+
- tool_name: get_focused_window_tree
|
|
914
|
+
arguments:
|
|
915
|
+
include_tree:
|
|
916
|
+
from_selector: "role:Dialog" # Start tree from first dialog
|
|
917
|
+
max_depth: 3 # Limit depth from that point
|
|
918
|
+
|
|
919
|
+
- tool_name: get_focused_window_tree
|
|
920
|
+
arguments:
|
|
921
|
+
include_tree:
|
|
922
|
+
from_selector: "true" # Start from focused element
|
|
923
|
+
|
|
924
|
+
# Backward compatible - still works
|
|
925
|
+
- tool_name: get_window_tree
|
|
926
|
+
arguments:
|
|
927
|
+
pid: 1234
|
|
928
|
+
include_tree: true # Simple boolean form
|
|
898
929
|
run: |
|
|
899
930
|
// Direct variable access - auto-injected!
|
|
900
931
|
const apps = check_apps_result || [];
|
package/package.json
CHANGED
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
],
|
|
16
16
|
"name": "terminator-mcp-agent",
|
|
17
17
|
"optionalDependencies": {
|
|
18
|
-
"terminator-mcp-darwin-arm64": "0.15.
|
|
19
|
-
"terminator-mcp-darwin-x64": "0.15.
|
|
20
|
-
"terminator-mcp-linux-x64-gnu": "0.15.
|
|
21
|
-
"terminator-mcp-win32-x64-msvc": "0.15.
|
|
18
|
+
"terminator-mcp-darwin-arm64": "0.15.17",
|
|
19
|
+
"terminator-mcp-darwin-x64": "0.15.17",
|
|
20
|
+
"terminator-mcp-linux-x64-gnu": "0.15.17",
|
|
21
|
+
"terminator-mcp-win32-x64-msvc": "0.15.17"
|
|
22
22
|
},
|
|
23
23
|
"repository": {
|
|
24
24
|
"type": "git",
|
|
@@ -30,5 +30,5 @@
|
|
|
30
30
|
"sync-version": "node ./utils/sync-version.js",
|
|
31
31
|
"update-badges": "node ./utils/update-badges.js"
|
|
32
32
|
},
|
|
33
|
-
"version": "0.15.
|
|
33
|
+
"version": "0.15.17"
|
|
34
34
|
}
|