omni-context-cli 0.0.32 → 0.0.34

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.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: craft
3
- description: Execute bash commands. Automatically fixes errors and retries if the command fails. Returns the result you expect.
3
+ description: Execute bash commands when no suitable specialized tool exists. Automatically fixes errors and retries if the command fails.
4
4
  allowedTools: [Bash, BashOutput, Read, Write]
5
5
  parameters:
6
6
  properties:
@@ -9,42 +9,44 @@ parameters:
9
9
  description: Bash command to run. Pipes, redirects, and chains all work.
10
10
  expectedResult:
11
11
  type: string
12
- description: What result you expect from this commandlike "list of JavaScript files", "successful installation message", or "version number".
12
+ description: What result you expect from this command, like "list of JavaScript files", "successful installation message", or "version number".
13
13
  timeout:
14
14
  type: number
15
15
  description: Max runtime in milliseconds. Defaults to 120000 (2 minutes).
16
16
  workdir:
17
17
  type: string
18
- description: Where to run the commandrelative or absolute path. Defaults to current directory.
18
+ description: Where to run the command, relative or absolute path. Defaults to current directory.
19
19
  required: [command, expectedResult]
20
20
  ---
21
21
 
22
- Command: {{command}}
23
- Expected result: {{expectedResult}}
24
- {{#if timeout}}Timeout: {{timeout}}ms{{/if}}
25
- {{#if workdir}}Working directory: {{workdir}}{{/if}}
22
+ Use the bash tool to run this command: {{command}}
26
23
 
27
- First, attempt to execute the command using the bash tool.
24
+ Working directory: {{#if workdir}}{{workdir}}{{else}}current directory{{/if}}.
25
+
26
+ Timeout: {{#if timeout}}{{timeout}}ms{{else}}120000ms (2 minutes){{/if}}.
27
+
28
+ Expected result: {{expectedResult}}.
29
+
30
+ If it works, extract what was asked for and return:
28
31
 
29
- If the command succeeds, extract and return the result according to the expected result description in this exact format:
30
32
  ```
31
- Success: [extracted result matching the expected result description]
33
+ Done: [the result matching what was expected]
32
34
  ```
33
35
 
34
- If the command fails, analyze the error and attempt to fix it.
36
+ If something goes wrong, figure out why and fix it. Then try again.
35
37
 
36
- After fixing, retry the command.
38
+ If the fix worked, return:
37
39
 
38
- If it succeeds after fix, return:
39
40
  ```
40
- Success after fix: [extracted result matching the expected result description]
41
- Fixed issue: [brief description of what was fixed]
41
+ Done: [the result matching what was expected]
42
+ What I fixed: [quick note on what went wrong and how you fixed it]
42
43
  ```
43
44
 
44
- If all attempts fail, return:
45
+ If nothing worked after a few tries, return:
46
+
45
47
  ```
46
- Failed: [error description]
47
- Attempted fixes: [what was tried]
48
+ Couldn't complete this: [what went wrong]
49
+ What I tried: [the fixes you attempted]
48
50
  ```
49
51
 
50
52
  Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -1,23 +1,31 @@
1
1
  ---
2
2
  name: explore
3
- description: Survey project structure and architecture. Shows directory layout, where features live, and how the codebase is organized. For high-level mapping, not detailed code analysis.
3
+ description: Survey project structure and architecture. Shows directory layout, where features live, and how the codebase is organized. For structural overview, not detailed analysis.
4
4
  allowedTools: [Read, Glob, Grep, Bash, BashOutput]
5
5
  parameters:
6
6
  properties:
7
7
  query:
8
8
  type: string
9
9
  description: What aspect of the project structure to explore
10
+ directory:
11
+ type: string
12
+ description: Limit the search to this directory. If not provided, searches the entire project.
10
13
  required: [query]
11
14
  ---
12
15
 
13
- Explore: {{query}}
16
+ Survey the project structure and find out: {{query}}
17
+
18
+ {{#if directory}}Limit the search to this directory: {{directory}}.{{/if}}
19
+
20
+ Use glob to survey the file structure and identify relevant areas. Use grep to scan for where functionality lives.
14
21
 
15
- Use glob to survey the file structure and identify relevant areas. Use grep to scan for where functionality lives. Focus on the big picturewhat directories exist, how the project is organized, where different concerns are separated.
22
+ Focus on the big picture: what directories exist, how the project is organized, where different concerns are separated.
16
23
 
17
24
  Return a report covering:
25
+ - A brief overview of what you found
18
26
  - Relevant directories and their purposes
19
27
  - Key files and their roles
20
28
  - How the codebase is organized (features, layers, modules)
21
29
  - Where the queried functionality lives
22
30
 
23
- Keep code excerpts minimal—just enough to identify locations and responsibilities.
31
+ Keep the report concise and to the point. Focus on what matters, skip the fluff.
@@ -0,0 +1,52 @@
1
+ ---
2
+ name: morph
3
+ description: Refactor code across multiple files. Performs mechanical transformations like renaming or updating references.
4
+ allowedTools: [Read, Edit, Grep, Glob, Bash]
5
+ parameters:
6
+ properties:
7
+ task:
8
+ type: string
9
+ description: What refactor to perform. Be specific about what to change and where.
10
+ directory:
11
+ type: string
12
+ description: Limit the refactor to this directory. If not provided, searches the entire project.
13
+ required: [task]
14
+ ---
15
+
16
+ Perform this refactor: {{task}}
17
+
18
+ {{#if directory}}Limit the scope to this directory: {{directory}}.{{/if}}
19
+
20
+ Use grep to find all relevant occurrences. Read files to verify matches are real references. Edit each file to apply the change.
21
+
22
+ This is mechanical work. Don't make judgment calls, just execute precisely.
23
+
24
+ If everything works, return:
25
+
26
+ ```
27
+ Done: [summary of what changed]
28
+
29
+ Files updated:
30
+ - path/to/file1.ts
31
+ - path/to/file2.ts
32
+ ```
33
+
34
+ If you ran into something and fixed it along the way:
35
+
36
+ ```
37
+ Done: [summary of what changed]
38
+ What I fixed: [what went wrong and how you handled it]
39
+
40
+ Files updated:
41
+ - path/to/file1.ts
42
+ - path/to/file2.ts
43
+ ```
44
+
45
+ If it didn't work out:
46
+
47
+ ```
48
+ Couldn't complete this: [what went wrong]
49
+ What I tried: [the approaches you attempted]
50
+ ```
51
+
52
+ Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -1,49 +1,48 @@
1
1
  ---
2
2
  name: pluck
3
- description: Find and extract specific code segments. Searches project-wide or in a single file. Returns matching code with line numbers only.
4
- allowedTools: [Read, Grep, Glob]
3
+ description: Find and extract specific code segments from a file. Returns matching code with line numbers only.
4
+ allowedTools: [Read]
5
5
  parameters:
6
6
  properties:
7
- filePath:
8
- type: string
9
- description: Path to search within. If not provided, searches across the entire project.
10
7
  query:
11
8
  type: string
12
- description: What code segment to find
13
- required: [query]
9
+ description: What code segment to find, e.g. "the registerTool function implementation", "UserService class definition", "where formatOutput is called", "error handling in the login flow"
10
+ filePath:
11
+ type: string
12
+ description: Exact path to the file to search within.
13
+ required: [query, filePath]
14
14
  ---
15
15
 
16
- {{#if filePath}}
17
- File: {{filePath}}
18
- {{else}}
19
- Search across entire project
20
- {{/if}}
21
- Query: {{query}}
16
+ Find and extract this code segment: {{query}}
17
+
18
+ Search within this file: {{filePath}}.
22
19
 
23
- {{#if filePath}}
24
- Read the specified file and locate the code segment that matches the query.
25
- {{else}}
26
- First use glob and grep to search across the project and identify which file contains the code segment that matches the query. Then read that file to extract the exact code.
27
- {{/if}}
20
+ Read the file and locate the code segment that matches the query.
28
21
 
29
- Return ONLY the matching code segments with their file paths and line numbers in this exact format. If multiple matches are found, list all of them separated by "---":
22
+ Return what you find in this format:
30
23
 
31
24
  ```
32
25
  File: path/to/file.ts
33
26
  Lines X-Y:
34
- <code>
27
+ <the matching code>
35
28
  ```
36
29
 
37
- If there are multiple matches:
30
+ If there are multiple matches, separate them like this:
38
31
 
39
32
  ```
40
33
  File: path/to/file1.ts
41
34
  Lines X-Y:
42
- <code>
35
+ <the matching code>
43
36
  ---
44
37
  File: path/to/file2.ts
45
38
  Lines A-B:
46
- <code>
39
+ <the matching code>
40
+ ```
41
+
42
+ If you can't find what was asked for:
43
+
44
+ ```
45
+ Couldn't find it: [brief explanation of what you searched and why nothing matched]
47
46
  ```
48
47
 
49
48
  Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -9,29 +9,38 @@ parameters:
9
9
  description: What to research.
10
10
  expectedResult:
11
11
  type: string
12
- description: What result you expectlike "latest version number", "list of best practices", "comparison of approaches", or "code examples".
12
+ description: What result you expect, like "latest version number", "list of best practices", "comparison of approaches", or "code examples".
13
13
  required: [query, expectedResult]
14
14
  ---
15
15
 
16
- Query: {{query}}
17
- Expected result: {{expectedResult}}
16
+ Research this topic: {{query}}
18
17
 
19
- Use available web search tools and external knowledge bases to research the query. Gather information from multiple sources if needed for a comprehensive answer.
18
+ Expected result: {{expectedResult}}.
19
+
20
+ Use available web search tools and external knowledge bases to find the answer.
21
+
22
+ Gather information from multiple sources if needed for a comprehensive result.
23
+
24
+ Return what you find in this format:
20
25
 
21
- Extract and return the result according to the expected result description in this exact format:
22
26
  ```
23
- Result: [extracted result matching the expected result description]
27
+ Here's what I found: [the result matching what was expected]
24
28
  ```
25
29
 
26
- If sources are relevant, you may include them in a brief format:
30
+ If sources are worth mentioning:
31
+
27
32
  ```
28
- Result: [extracted result matching the expected result description]
29
- Sources: [brief list of sources if relevant]
33
+ Here's what I found: [the result matching what was expected]
34
+
35
+ Sources:
36
+ - [source 1]
37
+ - [source 2]
30
38
  ```
31
39
 
32
- If the research cannot find relevant information, return:
40
+ If you couldn't find relevant information:
41
+
33
42
  ```
34
- Not found: [brief explanation of what was searched]
43
+ Couldn't find this: [brief explanation of what you searched and why nothing turned up]
35
44
  ```
36
45
 
37
46
  Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -12,36 +12,46 @@ parameters:
12
12
  description: Name of the symbol to find references for
13
13
  symbolType:
14
14
  type: string
15
- description: Type of symbolfunction, class, interface, variable, etc. Helps narrow the search.
16
- contextLines:
17
- type: number
18
- description: Lines to include before and after each reference. Defaults to 5.
15
+ description: Type of symbol (function, class, interface, variable, etc.). Helps narrow the search.
19
16
  required: [filePath, symbolName]
20
17
  ---
21
18
 
22
- File: {{filePath}}
23
- Symbol: {{symbolName}}{{#if symbolType}} ({{symbolType}}){{/if}}
19
+ Find all references to a symbol in the codebase.
24
20
 
25
- Use grep and glob to search for all places where the symbol is referenced. For each reference found, read the file and extract the code snippet with {{#if contextLines}}{{contextLines}}{{else}}5{{/if}} lines of context before and after.
21
+ Symbol name: {{symbolName}}.
26
22
 
27
- Return the reference sites in this exact format. For each location found, include:
23
+ {{#if symbolType}}Symbol type: {{symbolType}}.{{/if}}
24
+
25
+ Defined in: {{filePath}}.
26
+
27
+ Use grep and glob to search for all places where this symbol is referenced.
28
+
29
+ For each reference found, read the file and extract the code snippet with 5 lines of context before and after.
30
+
31
+ Return the references in this format:
28
32
 
29
33
  ```
30
34
  File: path/to/file.ts
31
35
  Lines X-Y:
32
- <code>
36
+ <the code with context>
33
37
  ```
34
38
 
35
- If multiple reference sites are found, separate each with "---":
39
+ If there are multiple references, separate them like this:
36
40
 
37
41
  ```
38
42
  File: path/to/file1.ts
39
43
  Lines X-Y:
40
- <code>
44
+ <the code with context>
41
45
  ---
42
46
  File: path/to/file2.ts
43
47
  Lines A-B:
44
- <code>
48
+ <the code with context>
49
+ ```
50
+
51
+ If you can't find any references:
52
+
53
+ ```
54
+ No references found: [brief explanation of what you searched]
45
55
  ```
46
56
 
47
57
  Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -6,7 +6,7 @@ parameters:
6
6
  properties:
7
7
  filePath:
8
8
  type: string
9
- description: File to editrelative or absolute path.
9
+ description: File to edit, relative or absolute path.
10
10
  oldString:
11
11
  type: string
12
12
  description: Exact text to replace. Must match perfectly, including whitespace and indentation.
@@ -19,44 +19,44 @@ parameters:
19
19
  required: [filePath, oldString, newString]
20
20
  ---
21
21
 
22
- Target file: {{filePath}}
23
- {{#if replaceAll}}
24
- Replace all occurrences.
25
- {{else}}
26
- Replace single occurrence only.
27
- {{/if}}
22
+ Edit this file by replacing text: {{filePath}}
28
23
 
29
- Old text to replace:
30
- <oldString>
24
+ {{#if replaceAll}}Replace all occurrences of the old text.{{else}}Replace only the first occurrence.{{/if}}
25
+
26
+ Old text to find and replace:
27
+
28
+ <old_text>
31
29
  {{oldString}}
32
- </oldString>
30
+ </old_text>
31
+
32
+ New text to insert:
33
33
 
34
- New text:
35
- <newString>
34
+ <new_text>
36
35
  {{newString}}
37
- </newString>
36
+ </new_text>
38
37
 
39
- First, attempt to edit the file using the edit tool.
38
+ Try to make the edit using the edit tool.
39
+
40
+ If it works, return:
40
41
 
41
- If the edit succeeds, return the result immediately in this exact format:
42
42
  ```
43
- Success: Edited /path/to/file
43
+ Done: Edited {{filePath}}
44
44
  ```
45
45
 
46
- If the edit fails, analyze the error and attempt to fix it.
46
+ If it fails, figure out why. Maybe the text doesn't match exactly, or there's a whitespace issue. Fix it and try again.
47
47
 
48
- After fixing, retry the edit operation.
48
+ If the fix worked:
49
49
 
50
- If it succeeds, return:
51
50
  ```
52
- Success after fix: Edited /path/to/file
53
- Fixed issue: [brief description of what was fixed]
51
+ Done: Edited {{filePath}}
52
+ What I fixed: [quick note on what was off and how you corrected it]
54
53
  ```
55
54
 
56
- If all attempts fail, return:
55
+ If nothing worked after a few tries:
56
+
57
57
  ```
58
- Failed: [error description]
59
- Attempted fixes: [what was tried]
58
+ Couldn't complete this: [what went wrong]
59
+ What I tried: [the fixes you attempted]
60
60
  ```
61
61
 
62
62
  Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -0,0 +1,41 @@
1
+ ---
2
+ name: slice
3
+ description: Extract code snippets relevant to answering a specific question. Returns targeted code segments from across the codebase that address the query.
4
+ allowedTools: [Read, Grep, Glob, Bash, BashOutput]
5
+ parameters:
6
+ properties:
7
+ question:
8
+ type: string
9
+ description: What you want to understand. Be specific, like "How does session persistence work?" or "Where are tool calls dispatched?"
10
+ directory:
11
+ type: string
12
+ description: Limit the search to this directory. If not provided, searches the entire project.
13
+ required: [question]
14
+ ---
15
+
16
+ Find and extract code that answers this question: {{question}}
17
+
18
+ {{#if directory}}Limit the search to this directory: {{directory}}.{{/if}}
19
+
20
+ Use grep to search for keywords related to the question. Trace function calls, imports, and references.
21
+
22
+ Use glob to identify relevant files based on your grep findings.
23
+
24
+ Read the files that contain the answer to the question. Focus on the specific code sections that address what's being asked.
25
+
26
+ For complex flows, read multiple files to understand the complete picture.
27
+
28
+ Return the code in this format. Use line ranges when only a section is relevant, complete contents for small files:
29
+
30
+ ```
31
+ File: path/to/file.ts
32
+ Lines X-Y:
33
+ <relevant code segment>
34
+ ---
35
+ File: path/to/another.ts
36
+ <complete file contents>
37
+ ```
38
+
39
+ If the code references other parts that explain the answer, include those too.
40
+
41
+ Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -6,19 +6,25 @@ parameters:
6
6
  properties:
7
7
  query:
8
8
  type: string
9
- description: What files to findlike "configuration files", "React components", or "test files for user authentication".
9
+ description: What files to find, like "configuration files", "React components", or "test files for user authentication".
10
+ directory:
11
+ type: string
12
+ description: Limit the search to this directory. If not provided, searches the entire project.
10
13
  maxFiles:
11
14
  type: number
12
15
  description: Maximum number of files to return. Defaults to 50.
13
16
  required: [query]
14
17
  ---
15
18
 
16
- Query: {{query}}
17
- Max files to return: {{#if maxFiles}}{{maxFiles}}{{else}}50{{/if}}
19
+ Find files in the project that match this criteria: {{query}}
20
+
21
+ {{#if directory}}Limit the search to this directory: {{directory}}.{{/if}}
18
22
 
19
- Use glob and grep to search across the project for files matching the criteria.
23
+ Maximum files to return: {{#if maxFiles}}{{maxFiles}}{{else}}50 (default){{/if}}.
20
24
 
21
- Return ONLY the list of matching file paths in this exact format:
25
+ Use glob and grep to search for matching files. Only return file paths, don't read the contents.
26
+
27
+ Return just the list of matching file paths:
22
28
 
23
29
  ```
24
30
  path/to/file1.ts
@@ -26,6 +32,12 @@ path/to/file2.tsx
26
32
  path/to/file3.json
27
33
  ```
28
34
 
29
- If more files match than the maximum limit, return the most relevant ones.
35
+ If more files match than the limit allows, return the most relevant ones.
36
+
37
+ If you can't find any matching files:
38
+
39
+ ```
40
+ Couldn't find any matches: [brief explanation of what you searched]
41
+ ```
30
42
 
31
43
  Do not include explanations beyond the result format. Keep responses concise and structured.
@@ -6,7 +6,7 @@ parameters:
6
6
  properties:
7
7
  filePath:
8
8
  type: string
9
- description: Destination pathrelative or absolute. Parent directories created automatically.
9
+ description: Destination path, relative or absolute. Parent directories created automatically.
10
10
  content:
11
11
  type: string
12
12
  description: Complete file content. Replaces everything in the file.
@@ -16,39 +16,38 @@ parameters:
16
16
  required: [filePath, content]
17
17
  ---
18
18
 
19
- Target file: {{filePath}}
20
- {{#if createOnly}}
21
- Only create new file, do not overwrite if exists.
22
- {{else}}
23
- Overwrite file if it exists.
24
- {{/if}}
19
+ Write content to this file: {{filePath}}
20
+
21
+ {{#if createOnly}}Only create the file if it doesn't exist. Do not overwrite existing files.{{else}}Overwrite the file if it already exists.{{/if}}
25
22
 
26
23
  Content to write:
27
- <content>
24
+
25
+ <file_content>
28
26
  {{content}}
29
- </content>
27
+ </file_content>
30
28
 
31
- First, attempt to write the content using the write tool.
29
+ Try to write the content using the write tool.
30
+
31
+ If it works, return:
32
32
 
33
- If the write succeeds, return the result immediately in this exact format:
34
33
  ```
35
- Success: Wrote N lines to /path/to/file
34
+ Done: Wrote N lines to {{filePath}}
36
35
  ```
37
36
 
38
- If the write fails, analyze the error and attempt to fix it.
37
+ If it fails, figure out why and fix it. Then try again.
39
38
 
40
- After fixing, retry the write operation.
39
+ If the fix worked:
41
40
 
42
- If it succeeds, return:
43
41
  ```
44
- Success after fix: Wrote N lines to /path/to/file
45
- Fixed issue: [brief description of what was fixed]
42
+ Done: Wrote N lines to {{filePath}}
43
+ What I fixed: [quick note on what went wrong and how you fixed it]
46
44
  ```
47
45
 
48
- If all attempts fail, return:
46
+ If nothing worked after a few tries:
47
+
49
48
  ```
50
- Failed: [error description]
51
- Attempted fixes: [what was tried]
49
+ Couldn't complete this: [what went wrong]
50
+ What I tried: [the fixes you attempted]
52
51
  ```
53
52
 
54
53
  Do not include explanations beyond the result format. Keep responses concise and structured.