Skip to content

Commit 6856236

Browse files
authored
Merge pull request #35 from Jamkris/fix/agent-invalid-tool-names
fix: correct invalid Gemini CLI tool names in agents and docs
2 parents a3b6eab + 440509f commit 6856236

45 files changed

Lines changed: 167 additions & 51 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.coderabbit.yaml

Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
language: "en-US"
2+
3+
tone_instructions: |
4+
Be concise and direct. Focus on bugs and security issues over style.
5+
6+
early_access: true
7+
enable_free_tier: true
8+
9+
reviews:
10+
profile: "assertive"
11+
12+
auto_review:
13+
enabled: true
14+
auto_incremental_review: true
15+
drafts: false
16+
ignore_title_keywords:
17+
- "bump version"
18+
- "release"
19+
- "chore: bump"
20+
21+
high_level_summary: true
22+
poem: false
23+
collapse_walkthrough: false
24+
sequence_diagrams: false
25+
26+
request_changes_workflow: true
27+
suggested_labels: true
28+
suggested_reviewers: false
29+
auto_apply_labels: false
30+
31+
path_filters:
32+
- "!node_modules/**"
33+
- "!package-lock.json"
34+
- "!*.lock"
35+
- "!.DS_Store"
36+
37+
path_instructions:
38+
- path: "agents/**/*.md"
39+
instructions: |
40+
Gemini CLI agent definitions. The YAML frontmatter `tools:` array must
41+
contain either:
42+
(a) a valid Gemini CLI built-in tool: read_file, read_many_files,
43+
write_file, replace, glob, search_file_content, list_directory,
44+
run_shell_command, save_memory, web_fetch, google_web_search; or
45+
(b) an MCP tool in the form `mcp__<server>__<tool_name>`.
46+
Reject Claude-style names like `search_files`, `replace_in_file`, `Read`,
47+
`Edit`. Also flag when the agent body references MCP tools (e.g. Slack,
48+
Context7) that are not declared in the frontmatter `tools:` array — the
49+
agent will be unable to call them at runtime. Each agent must have `name`
50+
and `description` in frontmatter.
51+
- path: "commands/**/*.toml"
52+
instructions: |
53+
Gemini CLI command definitions in TOML format. Verify command metadata
54+
is consistent and shell snippets are safely quoted.
55+
- path: "skills/**/*.md"
56+
instructions: |
57+
Skill definitions. Frontmatter must include `name` and `description`.
58+
The document body (not the frontmatter) should contain a "When to Use"
59+
or "Ideal For" section with specific, actionable trigger conditions.
60+
- path: "hooks/**"
61+
instructions: |
62+
Hook scripts and hooks.json. Hooks run automatically on tool events —
63+
any failure impacts all sessions. Verify error handling, quiet logging,
64+
and that exit codes are intentional.
65+
- path: "scripts/**"
66+
instructions: |
67+
Shell scripts must use `set -euo pipefail`, quote all variables, and
68+
avoid interpolating shell variables into `node -e` strings (use
69+
`process.env` instead). JS scripts target Node.js 20+.
70+
- path: "rules/**/*.md"
71+
instructions: |
72+
Coding rules shipped to end users' ~/.gemini/rules/. Cross-references
73+
between `common/` and language-specific files must use relative paths
74+
(`../common/xxx.md`) and those targets must exist.
75+
- path: "docs/**/*.md"
76+
instructions: |
77+
User-facing documentation. Tool-name mapping tables (Claude Code ↔ Gemini
78+
CLI) must list only valid Gemini CLI tool names — incorrect mappings here
79+
propagate into agent/skill definitions.
80+
- path: "**/*.js"
81+
instructions: |
82+
Node.js 20+ project. Use `node:` prefix for built-in modules. Avoid
83+
mutation — prefer spread/immutable patterns. Handle errors explicitly;
84+
never swallow silently.
85+
86+
labeling_instructions:
87+
- label: "security"
88+
instructions: "Changes to hooks, scripts executing shell commands, or handling of user config/credential paths"
89+
- label: "breaking"
90+
instructions: "Changes to command names, agent tool names, hook event contracts, or public file layout under ~/.gemini/"
91+
- label: "agents"
92+
instructions: "Changes under agents/"
93+
- label: "skills"
94+
instructions: "Changes under skills/"
95+
- label: "commands"
96+
instructions: "Changes under commands/"
97+
- label: "docs"
98+
instructions: "Changes under docs/ or top-level markdown files only"
99+
100+
tools:
101+
shellcheck:
102+
enabled: true
103+
gitleaks:
104+
enabled: true
105+
markdownlint:
106+
enabled: true
107+
eslint:
108+
enabled: true
109+
110+
chat:
111+
auto_reply: true
112+
113+
knowledge_base:
114+
learnings:
115+
scope: "local"

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,9 @@ If you are migrating agents from Claude Code:
108108
|-------------|------------|
109109
| `Read` | `read_file` |
110110
| `Write` | `write_file` |
111-
| `Edit` | `replace_in_file` |
111+
| `Edit` | `replace` |
112112
| `Bash` | `run_shell_command` |
113-
| `Grep` | `search_files` |
113+
| `Grep` | `search_file_content` |
114114
| `Glob` | `list_directory` |
115115
| `WebSearch` | `google_web_search` |
116116

agents/architect.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: architect
33
description: Software architecture specialist for system design, scalability, and technical decision-making. Use PROACTIVELY when planning new features, refactoring large systems, or making architectural decisions.
4-
tools: ["read_file", "search_files", "list_directory"]
4+
tools: ["read_file", "search_file_content", "list_directory"]
55
---
66

77
You are a senior software architect specializing in scalable, maintainable system design.

agents/chief-of-staff.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: chief-of-staff
33
description: Personal communication chief of staff that triages email, Slack, LINE, and Messenger. Classifies messages into 4 tiers (skip/info_only/meeting_info/action_required), generates draft replies, and enforces post-send follow-through via hooks. Use when managing multi-channel communication workflows.
4-
tools: ["read_file", "search_files", "list_directory", "run_shell_command", "replace_in_file", "write_file"]
4+
tools: ["read_file", "search_file_content", "list_directory", "run_shell_command", "replace", "write_file", "mcp__slack__conversations_search_messages", "mcp__slack__channels_list", "mcp__slack__conversations_history", "mcp__slack__conversations_add_message"]
55
---
66

77
You are a personal chief of staff that manages all communication channels — email, Slack, LINE, Messenger, and calendar — through a unified triage pipeline.

agents/code-architect.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: code-architect
33
description: Designs feature architectures by analyzing existing codebase patterns and conventions, then providing implementation blueprints with concrete files, interfaces, data flow, and build order.
4-
tools: [read_file, search_files, list_directory, run_shell_command]
4+
tools: [read_file, search_file_content, list_directory, run_shell_command]
55
---
66

77
# Code Architect Agent

agents/code-explorer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: code-explorer
33
description: Deeply analyzes existing codebase features by tracing execution paths, mapping architecture layers, and documenting dependencies to inform new development.
4-
tools: [read_file, search_files, list_directory, run_shell_command]
4+
tools: [read_file, search_file_content, list_directory, run_shell_command]
55
---
66

77
# Code Explorer Agent

agents/code-reviewer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: code-reviewer
33
description: Expert code review specialist. Proactively reviews code for quality, security, and maintainability. Use immediately after writing or modifying code. MUST BE USED for all code changes.
4-
tools: ["read_file", "search_files", "list_directory", "run_shell_command"]
4+
tools: ["read_file", "search_file_content", "list_directory", "run_shell_command"]
55
---
66

77
You are a senior code reviewer ensuring high standards of code quality and security.

agents/code-simplifier.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: code-simplifier
33
description: Simplifies and refines code for clarity, consistency, and maintainability while preserving behavior. Focus on recently modified code unless instructed otherwise.
4-
tools: [read_file, write_file, replace_in_file, run_shell_command, search_files, list_directory]
4+
tools: [read_file, write_file, replace, run_shell_command, search_file_content, list_directory]
55
---
66

77
# Code Simplifier Agent

agents/comment-analyzer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: comment-analyzer
33
description: Analyze code comments for accuracy, completeness, maintainability, and comment rot risk.
4-
tools: [read_file, search_files, list_directory, run_shell_command]
4+
tools: [read_file, search_file_content, list_directory, run_shell_command]
55
---
66

77
# Comment Analyzer Agent

agents/conversation-analyzer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: conversation-analyzer
33
description: Use this agent when analyzing conversation transcripts to find behaviors worth preventing with hooks. Triggered by /hookify without arguments.
4-
tools: [read_file, search_files]
4+
tools: [read_file, search_file_content]
55
---
66

77
# Conversation Analyzer Agent

0 commit comments

Comments
 (0)