Skip to main content

vtcode_config/constants/
tools.rs

1// ============================================================
2// UNIFIED TOOLS (Primary Interface)
3// ============================================================
4/// Unified search & discovery tool (aliases: grep_file, list_files, code_intelligence, etc.)
5pub const UNIFIED_SEARCH: &str = "unified_search";
6/// Unified shell execution & code execution tool (aliases: run_pty_cmd, execute_code, etc.)
7pub const UNIFIED_EXEC: &str = "unified_exec";
8/// Unified file operations tool (aliases: read_file, write_file, edit_file, etc.)
9pub const UNIFIED_FILE: &str = "unified_file";
10
11// ============================================================
12// SKILL MANAGEMENT TOOLS (Progressive Disclosure)
13// ============================================================
14/// List all available skills (local and dormant system utilities)
15pub const LIST_SKILLS: &str = "list_skills";
16/// Load a skill's instructions and activate its tools
17pub const LOAD_SKILL: &str = "load_skill";
18/// Load resources from a skill (scripts, templates, docs)
19pub const LOAD_SKILL_RESOURCE: &str = "load_skill_resource";
20
21// ============================================================
22// AGENT CONTROL TOOLS (Delegation)
23// ============================================================
24/// Spawn a subagent for specialized tasks (explore, plan, general, etc.)
25pub const SPAWN_SUBAGENT: &str = "spawn_subagent";
26
27// ============================================================
28// LEGACY SEARCH ALIASES (use unified_search instead)
29// ============================================================
30pub const GREP_FILE: &str = "grep_file";
31pub const LIST_FILES: &str = "list_files";
32pub const CODE_INTELLIGENCE: &str = "code_intelligence";
33pub const SEARCH_TOOLS: &str = "search_tools";
34pub const SKILL: &str = "skill";
35pub const AGENT_INFO: &str = "agent_info";
36pub const WEB_FETCH: &str = "web_fetch";
37pub const SEARCH: &str = "search";
38pub const FIND: &str = "find";
39
40// ============================================================
41// LEGACY EXECUTION ALIASES (use unified_exec instead)
42// ============================================================
43pub const RUN_PTY_CMD: &str = "run_pty_cmd";
44pub const CREATE_PTY_SESSION: &str = "create_pty_session";
45pub const LIST_PTY_SESSIONS: &str = "list_pty_sessions";
46pub const CLOSE_PTY_SESSION: &str = "close_pty_session";
47pub const SEND_PTY_INPUT: &str = "send_pty_input";
48pub const READ_PTY_SESSION: &str = "read_pty_session";
49pub const RESIZE_PTY_SESSION: &str = "resize_pty_session";
50pub const EXECUTE_CODE: &str = "execute_code";
51pub const EXEC_PTY_CMD: &str = "exec_pty_cmd";
52pub const EXEC: &str = "exec";
53pub const SHELL: &str = "shell";
54
55// ============================================================
56// LEGACY FILE OPERATION ALIASES (use unified_file instead)
57// ============================================================
58pub const READ_FILE: &str = "read_file";
59pub const WRITE_FILE: &str = "write_file";
60pub const EDIT_FILE: &str = "edit_file";
61pub const DELETE_FILE: &str = "delete_file";
62pub const CREATE_FILE: &str = "create_file";
63pub const APPLY_PATCH: &str = "apply_patch";
64pub const SEARCH_REPLACE: &str = "search_replace";
65pub const FILE_OP: &str = "file_op";
66pub const MOVE_FILE: &str = "move_file";
67pub const COPY_FILE: &str = "copy_file";
68
69// ============================================================
70// ERROR & DIAGNOSTICS
71// ============================================================
72pub const GET_ERRORS: &str = "get_errors";
73
74// ============================================================
75// HUMAN-IN-THE-LOOP (HITL)
76// ============================================================
77/// Ask the human a question via the interactive UI (TUI) and return the selection.
78pub const ASK_USER_QUESTION: &str = "ask_user_question";
79/// Request structured user input with 1-3 questions and optional multiple-choice options.
80pub const REQUEST_USER_INPUT: &str = "request_user_input";
81
82// ============================================================
83// PLAN MODE
84// ============================================================
85/// Enter plan mode - enables read-only tools and planning workflow.
86pub const ENTER_PLAN_MODE: &str = "enter_plan_mode";
87/// Exit plan mode - triggers confirmation modal before execution.
88pub const EXIT_PLAN_MODE: &str = "exit_plan_mode";
89
90// Special wildcard for full access
91pub const WILDCARD_ALL: &str = "*";