vivekmind 0.15.6

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.
@@ -0,0 +1,304 @@
1
+ ---
2
+ name: batch
3
+ description: Execute batch operations on multiple files in parallel. Automatically discovers files, splits into chunks, and processes with parallel worker agents. Use `/batch` followed by operation and file pattern.
4
+ argument-hint: '<operation> <file-pattern>'
5
+ allowedTools:
6
+ - task
7
+ - glob
8
+ - grep_search
9
+ - read_file
10
+ - edit
11
+ - write_file
12
+ - run_shell_command
13
+ - ask_user_question
14
+ ---
15
+
16
+ # /batch - Parallel Batch Operations
17
+
18
+ You are orchestrating a batch operation across multiple files. Your job is to:
19
+
20
+ 1. Parse the user's request to understand the target files and operation
21
+ 2. Discover matching files using glob
22
+ 3. Split files into chunks for parallel processing
23
+ 4. Launch multiple worker agents to process files concurrently
24
+ 5. Aggregate results and present a summary
25
+
26
+ ## Step 1: Parse Intent and Discover Files
27
+
28
+ First, parse the user's request to identify:
29
+
30
+ - **Target pattern**: glob pattern for files (e.g., `src/**/*.ts`, `**/*.js`)
31
+ - **Operation**: what to do with each file (e.g., "add JSDoc comments", "convert to TypeScript")
32
+
33
+ If the user didn't specify a pattern, infer it from context or ask for clarification.
34
+
35
+ Use the `glob` tool to discover matching files.
36
+
37
+ **If no files match the pattern**:
38
+
39
+ - Inform the user that no files were found for the given pattern
40
+ - Suggest checking the pattern or broadening the search scope
41
+ - Do not proceed with an empty batch
42
+
43
+ Apply these common exclusions automatically:
44
+
45
+ - `node_modules/**`
46
+ - `dist/**`
47
+ - `build/**`
48
+ - `.git/**`
49
+ - `**/*.test.ts`, `**/*.test.js`
50
+ - `**/*.spec.ts`, `**/*.spec.js`
51
+ - `**/__tests__/**`
52
+ - `**/test/**`, `**/tests/**`
53
+ - `**/package-lock.json`
54
+ - `**/yarn.lock`
55
+ - `**/*.min.js`
56
+ - Binary files (images, fonts, etc.)
57
+ - Files larger than 500KB (check size if needed)
58
+
59
+ **Important**: If more than 50 files match, inform the user with the exact count and the file list, then proceed. The user can cancel (Ctrl+C) if needed. If the count exceeds 100 files, warn the user and suggest a more specific pattern instead of proceeding.
60
+
61
+ ## Step 2: Chunk Files for Parallel Processing
62
+
63
+ Split the discovered files into chunks based on these rules:
64
+
65
+ | Total Files | Chunk Count | Files Per Chunk |
66
+ | ----------- | ----------- | --------------- |
67
+ | 1-5 | 1 | All files |
68
+ | 6-15 | 2 | 3-8 each |
69
+ | 16-30 | 3 | ~10 each |
70
+ | 31-50 | 4 | ~10-12 each |
71
+ | 51-75 | 5 | ~10-15 each |
72
+ | 76-100 | 5 | ~15-20 each |
73
+
74
+ **Chunking algorithm**:
75
+
76
+ - Minimum chunk size: 3 files (avoid over-parallelization for small batches)
77
+ - Maximum chunk size: 15 files (ensure reasonable work per agent)
78
+ - Maximum parallel agents: 5 (API rate limit consideration)
79
+
80
+ Example: 24 files → 3 chunks of ~8 files each
81
+
82
+ ## Step 3: Launch Parallel Worker Agents
83
+
84
+ Launch worker agents **in parallel** by invoking the `task` tool (the Agent tool) multiple times in a **SINGLE message**.
85
+
86
+ **Note**: The `task` tool in allowedTools is the Agent tool used to spawn worker agents.
87
+
88
+ Each worker agent should receive:
89
+
90
+ - The list of files to process (full paths)
91
+ - The operation to perform
92
+ - Clear instructions to report success/failure per file
93
+
94
+ Use the `general-purpose` subagent type for workers.
95
+
96
+ **CRITICAL**: All Agent tool calls MUST be in a single response to enable parallel execution. The system automatically runs multiple Agent calls concurrently.
97
+
98
+ ### Agent Prompt Template
99
+
100
+ For each chunk, use this prompt format:
101
+
102
+ ```
103
+ You are a worker agent processing a batch of files.
104
+
105
+ **Operation**: [describe the operation, e.g., "Add JSDoc comments to all exported functions"]
106
+
107
+ **Files to process**:
108
+ - [file1.ts]
109
+ - [file2.ts]
110
+ - ...
111
+
112
+ **Instructions**:
113
+ 1. Process each file independently
114
+ 2. For each file, report one of:
115
+ - SUCCESS: [file path] - [brief description of change]
116
+ - FAILED: [file path] - [reason for failure]
117
+ - SKIPPED: [file path] - [reason for skipping]
118
+ 3. If a file fails or is skipped, continue with the next file - do not abort
119
+ 4. At the end, provide a summary of what was done
120
+
121
+ **Constraints**:
122
+ - Do not modify test files unless explicitly requested
123
+ - Preserve existing code style and formatting
124
+ - Make minimal necessary changes to accomplish the operation
125
+ ```
126
+
127
+ ### Example Invocation Pattern
128
+
129
+ ```
130
+ <Agent tool call 1>
131
+ description: "Process batch chunk 1/3"
132
+ prompt: "You are a worker agent... [full prompt as above]"
133
+ subagent_type: "general-purpose"
134
+ </Agent tool call 1>
135
+
136
+ <Agent tool call 2>
137
+ description: "Process batch chunk 2/3"
138
+ prompt: "You are a worker agent... [full prompt as above]"
139
+ subagent_type: "general-purpose"
140
+ </Agent tool call 2>
141
+
142
+ <Agent tool call 3>
143
+ description: "Process batch chunk 3/3"
144
+ prompt: "You are a worker agent... [full prompt as above]"
145
+ subagent_type: "general-purpose"
146
+ </Agent tool call 3>
147
+ ```
148
+
149
+ ## Step 4: Aggregate Results
150
+
151
+ After all worker agents complete, aggregate their results into a clear summary.
152
+
153
+ ### Output Format
154
+
155
+ ```markdown
156
+ ### Batch Operation Complete
157
+
158
+ **Operation**: [description of what was done]
159
+ **Files discovered**: [total count]
160
+ **Chunks processed**: [number of parallel agents]
161
+ **Total time**: [duration if tracked]
162
+
163
+ | Status | Count |
164
+ | ------- | ----- |
165
+ | Success | [N] |
166
+ | Failed | [N] |
167
+ | Skipped | [N] |
168
+
169
+ **Successful files**:
170
+
171
+ - [file1.ts] - [brief description]
172
+ - [file2.ts] - [brief description]
173
+ ...
174
+
175
+ **Failed files** (if any):
176
+
177
+ - [file.ts]: [reason for failure]
178
+
179
+ **Skipped files** (if any):
180
+
181
+ - [file.ts]: [reason for skipping]
182
+ ```
183
+
184
+ ### Handling Partial Failures
185
+
186
+ If some files failed but others succeeded:
187
+
188
+ - Clearly report which files succeeded
189
+ - List failures with specific reasons
190
+ - Suggest follow-up actions if appropriate
191
+
192
+ If all files failed:
193
+
194
+ - Report the common failure pattern
195
+ - Suggest potential fixes
196
+
197
+ ## Step 5: Error Handling
198
+
199
+ ### During Batch Processing
200
+
201
+ 1. **Single file failure**: Don't abort the batch. The worker agent records the error and continues.
202
+ 2. **Agent failure**: If a worker agent fails completely (timeout, crash), note the chunk as failed with reason.
203
+ 3. **User cancellation**: If the user sends Ctrl+C, the system will cancel all pending agents gracefully.
204
+
205
+ ### Error Reporting
206
+
207
+ For each failed file, include:
208
+
209
+ - File path
210
+ - Specific error message or reason
211
+ - Suggested fix if obvious
212
+
213
+ ## Usage Examples
214
+
215
+ ### Example 1: Add License Headers
216
+
217
+ ```
218
+ /batch Add Apache 2.0 license header to all .ts files in src/
219
+ ```
220
+
221
+ **Flow**:
222
+
223
+ 1. glob `src/**/*.ts` → find 45 files
224
+ 2. Split into 4 chunks
225
+ 3. Launch 4 parallel agents
226
+ 4. Each agent adds the license header to its assigned files
227
+ 5. Summary: 45 files processed, 45 succeeded, 0 failed
228
+
229
+ ### Example 2: Convert JavaScript to TypeScript
230
+
231
+ ```
232
+ /batch Convert all .js files in utils/ to TypeScript
233
+ ```
234
+
235
+ **Flow**:
236
+
237
+ 1. glob `utils/**/*.js` → find 12 files
238
+ 2. Split into 2 chunks
239
+ 3. Launch 2 parallel agents
240
+ 4. Each agent converts files and renames to .ts
241
+ 5. Summary: 12 files processed, 10 succeeded, 2 failed (complex dynamic patterns)
242
+
243
+ ### Example 3: Fix Lint Errors
244
+
245
+ ```
246
+ /batch Fix all @typescript-eslint/no-explicit-any errors in src/
247
+ ```
248
+
249
+ **Flow**:
250
+
251
+ 1. Use `grep_search` to find files containing `: any` pattern in `src/`
252
+ 2. Filter to relevant files
253
+ 3. Split into chunks and launch parallel agents
254
+ 4. Each agent fixes the specific lint issue (replace `any` with proper types)
255
+ 5. Summary: 8 files fixed
256
+
257
+ ## Constraints and Limits
258
+
259
+ | Constraint | Value | Reason |
260
+ | ------------------- | ----- | ---------------------------- |
261
+ | Max files per batch | 100 | Prevent resource exhaustion |
262
+ | Max parallel agents | 5 | API rate limit consideration |
263
+ | Min files per agent | 3 | Avoid over-parallelization |
264
+ | Max files per agent | 15 | Ensure meaningful work |
265
+ | File size limit | 500KB | Avoid context overflow |
266
+
267
+ ## Dry-Run Mode
268
+
269
+ If the user wants to preview what will be changed without actually modifying files (e.g., "preview", "show me what would change", "dry run"):
270
+
271
+ 1. Discover and list all matching files with counts
272
+ 2. Show the planned operation for each file
273
+ 3. Display the chunking strategy
274
+ 4. Ask the user if they want to proceed with the actual changes
275
+ 5. If user confirms, execute the batch operation
276
+
277
+ **Example**:
278
+
279
+ ```
280
+ /batch preview adding JSDoc comments to src/**/*.ts
281
+ ```
282
+
283
+ **Expected output**:
284
+
285
+ ```
286
+ ### Dry-Run Preview
287
+
288
+ **Operation**: Add JSDoc comments to all .ts files in src/
289
+
290
+ **Files discovered**: 24 files
291
+
292
+ **Chunking plan**:
293
+ | Chunk | Files |
294
+ |-------|-------|
295
+ | 1 | src/utils/a.ts, b.ts, c.ts, ... (8 files) |
296
+ | 2 | src/components/x.ts, y.ts, ... (8 files) |
297
+ | 3 | src/services/m.ts, n.ts, ... (8 files) |
298
+
299
+ **Planned operation per file**:
300
+ - Add JSDoc comments to all exported functions
301
+ - Preserve existing code style
302
+
303
+ Proceed? (y/n)
304
+ ```
@@ -0,0 +1,62 @@
1
+ ---
2
+ name: loop
3
+ description: Create a recurring loop that runs a prompt on a schedule. Usage - /loop 5m check the build, /loop check the PR every 30m, /loop run tests (defaults to 10m). /loop list to show jobs, /loop clear to cancel all.
4
+ argument-hint: '[interval] <prompt> | list | clear'
5
+ allowedTools:
6
+ - cron_create
7
+ - cron_list
8
+ - cron_delete
9
+ ---
10
+
11
+ # /loop — schedule a recurring prompt
12
+
13
+ ## Subcommands
14
+
15
+ If the input (after stripping the `/loop` prefix) is exactly one of these keywords, run the subcommand instead of scheduling:
16
+
17
+ - **`list`** — call CronList and display the results. Done.
18
+ - **`clear`** — call CronList, then call CronDelete for every job returned. Confirm how many were cancelled. Done.
19
+
20
+ Otherwise, parse the input below into `[interval] <prompt…>` and schedule it with CronCreate.
21
+
22
+ ## Parsing (in priority order)
23
+
24
+ 1. **Leading token**: if the first whitespace-delimited token matches `^\d+[smhd]$` (e.g. `5m`, `2h`), that's the interval; the rest is the prompt.
25
+ 2. **Trailing "every" clause**: otherwise, if the input ends with `every <N><unit>` or `every <N> <unit-word>` (e.g. `every 20m`, `every 5 minutes`, `every 2 hours`), extract that as the interval and strip it from the prompt. Only match when what follows "every" is a time expression — `check every PR` has no interval.
26
+ 3. **Default**: otherwise, interval is `10m` and the entire input is the prompt.
27
+
28
+ If the resulting prompt is empty, show usage `/loop [interval] <prompt>` and stop — do not call CronCreate.
29
+
30
+ Examples:
31
+
32
+ - `5m /babysit-prs` → interval `5m`, prompt `/babysit-prs` (rule 1)
33
+ - `check the deploy every 20m` → interval `20m`, prompt `check the deploy` (rule 2)
34
+ - `run tests every 5 minutes` → interval `5m`, prompt `run tests` (rule 2)
35
+ - `check the deploy` → interval `10m`, prompt `check the deploy` (rule 3)
36
+ - `check every PR` → interval `10m`, prompt `check every PR` (rule 3 — "every" not followed by time)
37
+ - `5m` → empty prompt → show usage
38
+
39
+ ## Interval → cron
40
+
41
+ Supported suffixes: `s` (seconds, rounded up to nearest minute, min 1), `m` (minutes), `h` (hours), `d` (days). Convert:
42
+
43
+ | Interval pattern | Cron expression | Notes |
44
+ | ----------------- | ---------------------- | ----------------------------------------- |
45
+ | `Nm` where N ≤ 59 | `*/N * * * *` | every N minutes |
46
+ | `Nm` where N ≥ 60 | `0 */H * * *` | round to hours (H = N/60, must divide 24) |
47
+ | `Nh` where N ≤ 23 | `0 */N * * *` | every N hours |
48
+ | `Nd` | `0 0 */N * *` | every N days at midnight local |
49
+ | `Ns` | treat as `ceil(N/60)m` | cron minimum granularity is 1 minute |
50
+
51
+ **If the interval doesn't cleanly divide its unit** (e.g. `7m` → `*/7 * * * *` gives uneven gaps at :56→:00; `90m` → 1.5h which cron can't express), pick the nearest clean interval and tell the user what you rounded to before scheduling.
52
+
53
+ ## Action
54
+
55
+ 1. Call CronCreate with:
56
+ - `cron`: the expression from the table above
57
+ - `prompt`: the parsed prompt from above, verbatim (slash commands are passed through unchanged)
58
+ - `recurring`: `true`
59
+ 2. Briefly confirm: what's scheduled, the cron expression, the human-readable cadence, that recurring tasks auto-expire after 3 days, and that they can cancel sooner with CronDelete (include the job ID).
60
+ 3. **Then immediately execute the parsed prompt now** — don't wait for the first cron fire. If it's a slash command, invoke it via the Skill tool; otherwise act on it directly.
61
+
62
+ ## Input
@@ -0,0 +1,152 @@
1
+ ---
2
+ name: qc-helper
3
+ description: Answer any question about VivekMind usage, features, configuration, and troubleshooting by referencing the official user documentation. Also helps users view or modify their settings.json. Invoke with `/qc-helper` followed by a question, e.g. `/qc-helper how do I configure MCP servers?` or `/qc-helper change approval mode to yolo`.
4
+ argument-hint: '<question>'
5
+ allowedTools:
6
+ - read_file
7
+ - edit_file
8
+ - grep_search
9
+ - glob
10
+ - read_many_files
11
+ ---
12
+
13
+ # VivekMind Helper
14
+
15
+ You are a helpful assistant for **VivekMind** — an AI coding agent for the terminal. Your job is to answer user questions about VivekMind's usage, features, configuration, and troubleshooting by referencing the official documentation, and to help users modify their configuration when requested.
16
+
17
+ ## How to Find Documentation
18
+
19
+ The official user documentation is available in the `docs/` subdirectory **relative to this skill's directory**. Use the `read_file` tool to load the relevant document on demand by concatenating this skill's base directory path with the relative doc path listed below.
20
+
21
+ > **Example**: If the user asks about MCP servers, read `docs/features/mcp.md` (relative to this skill's directory).
22
+
23
+ ---
24
+
25
+ ## Documentation Index
26
+
27
+ Use this index to locate the right document for the user's question. Load only the docs that are relevant — do not read everything at once.
28
+
29
+ ### Getting Started
30
+
31
+ | Topic | Doc Path |
32
+ | ----------------- | ------------------------- |
33
+ | Product overview | `docs/overview.md` |
34
+ | Quick start guide | `docs/quickstart.md` |
35
+ | Common workflows | `docs/common-workflow.md` |
36
+
37
+ ### Configuration
38
+
39
+ | Topic | Doc Path |
40
+ | ----------------------------------------- | --------------------------------------- |
41
+ | Settings reference (all config keys) | `docs/configuration/settings.md` |
42
+ | Authentication setup | `docs/configuration/auth.md` |
43
+ | Model providers (OpenAI-compatible, etc.) | `docs/configuration/model-providers.md` |
44
+ | .vivekmindignore file | `docs/configuration/qwen-ignore.md` |
45
+ | Themes | `docs/configuration/themes.md` |
46
+ | Memory | `docs/configuration/memory.md` |
47
+ | Trusted folders | `docs/configuration/trusted-folders.md` |
48
+
49
+ ### Features
50
+
51
+ | Topic | Doc Path |
52
+ | ------------------------------------------- | -------------------------------- |
53
+ | Approval mode (plan/default/auto_edit/yolo) | `docs/features/approval-mode.md` |
54
+ | MCP (Model Context Protocol) | `docs/features/mcp.md` |
55
+ | Skills system | `docs/features/skills.md` |
56
+ | Sub-agents | `docs/features/sub-agents.md` |
57
+ | Sandbox / security | `docs/features/sandbox.md` |
58
+ | Slash commands | `docs/features/commands.md` |
59
+ | Headless / non-interactive mode | `docs/features/headless.md` |
60
+ | LSP integration | `docs/features/lsp.md` |
61
+ | Checkpointing | `docs/features/checkpointing.md` |
62
+ | Token caching | `docs/features/token-caching.md` |
63
+ | Language / i18n | `docs/features/language.md` |
64
+ | Arena mode | `docs/features/arena.md` |
65
+
66
+ ### IDE Integration
67
+
68
+ | Topic | Doc Path |
69
+ | ----------------------- | -------------------------------------------- |
70
+ | VS Code integration | `docs/integration-vscode.md` |
71
+ | Zed IDE integration | `docs/integration-zed.md` |
72
+ | JetBrains integration | `docs/integration-jetbrains.md` |
73
+ | GitHub Actions | `docs/integration-github-action.md` |
74
+ | IDE companion spec | `docs/ide-integration/ide-companion-spec.md` |
75
+ | IDE integration details | `docs/ide-integration/ide-integration.md` |
76
+
77
+ ### Extensions
78
+
79
+ | Topic | Doc Path |
80
+ | ------------------------------- | ---------------------------------------------- |
81
+ | Extension introduction | `docs/extension/introduction.md` |
82
+ | Getting started with extensions | `docs/extension/getting-started-extensions.md` |
83
+ | Releasing extensions | `docs/extension/extension-releasing.md` |
84
+
85
+ ### Reference & Support
86
+
87
+ | Topic | Doc Path |
88
+ | -------------------------- | -------------------------------------- |
89
+ | Keyboard shortcuts | `docs/reference/keyboard-shortcuts.md` |
90
+ | Troubleshooting | `docs/support/troubleshooting.md` |
91
+ | Uninstall guide | `docs/support/Uninstall.md` |
92
+ | Terms of service & privacy | `docs/support/tos-privacy.md` |
93
+
94
+ ---
95
+
96
+ ## Configuration Quick Reference
97
+
98
+ When the user asks about configuration, the primary reference is `docs/configuration/settings.md`. Here is a quick orientation:
99
+
100
+ ### Config File Locations & Priority
101
+
102
+ | Level | Path | Description |
103
+ | ------- | ------------------------------------------------------------ | -------------------------------------- |
104
+ | User | `~/.vivekmind/settings.json` | Personal global config |
105
+ | Project | `<project>/.vivekmind/settings.json` | Project-specific, overrides user level |
106
+ | System | macOS: `/Library/Application Support/QwenCode/settings.json` | Admin-level config |
107
+
108
+ **Priority** (highest to lowest): CLI args > env vars > system settings > project settings > user settings > defaults
109
+
110
+ **Format**: JSON with Comments (supports `//` and `/* */`), with environment variable interpolation (`$VAR` or `${VAR}`)
111
+
112
+ ### Common Config Categories
113
+
114
+ | Category | Key Config Keys | Reference |
115
+ | ------------- | ----------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
116
+ | Permissions | `permissions.allow/ask/deny` | `docs/configuration/settings.md`, `docs/features/approval-mode.md` |
117
+ | MCP Servers | `mcpServers.*`, `mcp.*` | `docs/configuration/settings.md`, `docs/features/mcp.md` |
118
+ | Tool Approval | `tools.approvalMode` | `docs/configuration/settings.md`, `docs/features/approval-mode.md` |
119
+ | Model | `model.name`, `modelProviders` | `docs/configuration/settings.md`, `docs/configuration/model-providers.md` |
120
+ | General/UI | `general.*`, `ui.*`, `ide.*`, `output.*` | `docs/configuration/settings.md` |
121
+ | Context | `context.*` | `docs/configuration/settings.md` |
122
+ | Advanced | `hooks`, `env`, `webSearch`, `security`, `privacy`, `telemetry`, `advanced.*` | `docs/configuration/settings.md` |
123
+
124
+ ---
125
+
126
+ ## Workflow
127
+
128
+ ### Answering Questions
129
+
130
+ 1. **Identify the topic** from the user's question using the Documentation Index above
131
+ 2. **Use `read_file`** to load the relevant doc(s) — only load what you need
132
+ 3. **Provide a clear, concise answer** grounded in the documentation content
133
+ 4. If the docs don't cover the question, say so honestly and suggest where to look
134
+
135
+ ### Helping with Configuration Changes
136
+
137
+ When the user wants to modify their configuration:
138
+
139
+ 1. **Read the relevant doc** to understand the config key, its type, allowed values, and defaults
140
+ 2. **Ask which config level** to modify if not specified: user (`~/.vivekmind/settings.json`) or project (`.vivekmind/settings.json`)
141
+ 3. **Use `read_file`** to check the current content of the target settings file
142
+ 4. **Use `edit_file`** to apply the change with correct JSON syntax
143
+ 5. **After every configuration change**, you MUST remind the user:
144
+
145
+ > **Note: Most configuration changes require restarting VivekMind (`/exit` then re-launch) to take effect.** Only a few settings (like `permissions`) are picked up dynamically.
146
+
147
+ ### Important Notes
148
+
149
+ - Always ground your answers in the actual documentation content — do not guess or fabricate config keys
150
+ - When showing config examples, use JSONC format with comments for clarity
151
+ - If a question spans multiple topics (e.g., "How do I set up MCP with sandbox?"), read both relevant docs
152
+ - For migration questions from other tools (Claude Code, Gemini CLI, etc.), check `docs/configuration/settings.md` for equivalent config keys