Claudecode-Codex-Gemini: Command for Claude Code

.claude/commands/kim-review.md

kim-review is a command for Claude Code from KimYx0207/Claudecode-Codex-Gemini. It costs 25 tokens per session (1,418 once invoked), scanned A, original, MIT.

A code-review command that coordinates Claude and Gemini, two AI assistants, to inspect existing code.

In plain words
What is it for?
Use it for reviewing selected files or directories, checking code quality and security, and producing a review report without generating new code.
Why use it?
It separates code understanding from deeper quality and security review, making review findings easier to organize.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: reads .claude/ paths; mentions Claude Code; mentions Codex.

This is KimYx0207/Claudecode-Codex-Gemini's own configuration. It tells Claude Code how to work on Claudecode-Codex-Gemini itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything Claudecode-Codex-Gemini configures →

Reuse

Borrowing it

Nothing to install: this file belongs to KimYx0207/Claudecode-Codex-Gemini. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/KimYx0207/Claudecode-Codex-Gemini/main/.claude/commands/kim-review.md
Clone the repo
git clone --depth 1 https://github.com/KimYx0207/Claudecode-Codex-Gemini

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for kim-review

README.md
[![agentmods](https://agentmods.dev/badge/commands/kimyx0207/claudecode-codex-gemini/kim-review/github.svg)](https://agentmods.dev/commands/kimyx0207/claudecode-codex-gemini/kim-review)
Your own site
<a href="https://agentmods.dev/commands/kimyx0207/claudecode-codex-gemini/kim-review"><img src="https://agentmods.dev/badge/commands/kimyx0207/claudecode-codex-gemini/kim-review/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for kim-review

Your own site · 80×15
<a href="https://agentmods.dev/commands/kimyx0207/claudecode-codex-gemini/kim-review"><img src="https://agentmods.dev/badge/commands/kimyx0207/claudecode-codex-gemini/kim-review.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 25 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,418 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00025 $0.01418
Opus 5 $0.00013 $0.00709
Sonnet 5 $0.00005 $0.00284
Haiku 4.5 $0.00003 $0.00142

Measured 10d ago against content hash e0fb7b334480, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

kim-review scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/kim-review.md · 189 lines

How it starts

The opening of the file, as written. The whole thing — 189 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Kim代码审查命令(Claude + Gemini)

代码审查模式:理解代码 → 深度审查,专注于代码质量和安全

你现在要协调2个AI工具完成代码审查:$ARGUMENTS

模式说明:这是专业审查模式,适合审查现有代码、代码质量检查、安全审计。

⚠️ 文件写入规则(必须遵守)

Claude Code的Write工具要求:写入文件前必须先读取它。对于新文件:

# 创建新文件的标准流程:
1. 用 Bash 创建目录和空文件:mkdir -p 目录 && echo "" > 文件路径
2. 用 Read 读取该文件
3. 用 Write 写入实际内容

执行流程

阶段0.1:健康检查

参考 .claude/skills/kim-orchestrator/prompts/health-check.md 执行MCP健康检查。

在开始前检测 mcp__gemini__gemini 工具是否可用:

  • ✅ 可用 → 继续执行
  • ❌ 不可用 → 显示修复指南,询问是否用Claude降级执行

阶段0.2:初始化工作目录

mkdir -p .kim-orchestrator && echo "" > .kim-orchestrator/phase1_analysis.json && echo "" > .kim-orchestrator/phase2_review.md && echo "" > .kim-orchestrator/result.md

然后读取这些文件:

  • Read .kim-orchestrator/phase1_analysis.json
  • Read .kim-orchestrator/phase2_review.md
  • Read .kim-orchestrator/result.md

阶段1:代码理解与分析(你自己完成)

首先读取用户指定的代码文件,然后分析:

  1. 识别审查目标:用户可能提供文件路径、目录、或描述
  2. 读取代码:使用Read/Glob/Grep工具获取代码内容
  3. 初步分析:理解代码结构、功能、潜在问题点

输出JSON格式的分析报告:

{
  "review_target": "审查目标描述",
  "files_analyzed": [
    {"path": "文件路径", "lines": 行数, "purpose": "用途"}
  ],
  "code_summary": "代码功能概述",
  "initial_concerns": [
    "初步发现的问题1",
    "初步发现的问题2"
  ],
  "review_focus": [
    "重点审查方向1:安全性",
    "重点审查方向2:性能",
    "重点审查方向3:可维护性"
  ]
}

保存到 .kim-orchestrator/phase1_analysis.json

阶段2:深度代码审查(调用Gemini MCP Server)

检查工具:确认 mcp__gemini__gemini 可用。如果不可用,提示用户配置MCP Server。

调用Gemini进行深度审查:

  • prompt: 包含代码内容和phase1_analysis.json的审查要点
  • reviewMode: true(启用专业审查模式)
  • conversationId: "kim_review_" + 当前时间戳

审查维度

  1. 代码质量:可读性、命名规范、代码复杂度
  2. 安全性:SQL注入、XSS、认证漏洞、敏感信息泄露
  3. 性能:N+1查询、内存泄漏、算法效率
  4. 可维护性:模块化、依赖关系、测试覆盖
  5. 最佳实践:设计模式、SOLID原则、错误处理

将响应保存到 .kim-orchestrator/phase2_review.md

阶段3:生成审查报告

# Kim代码审查报告(Claude + Gemini)

**审查目标**: $ARGUMENTS
**审查时间**: [当前时间]
**模式**: 深度代码审查

---

## 阶段1: 代码分析(Claude Sonnet 4.5)

\`\`\`json
[phase1_analysis.json的内容]
\`\`\`

---

## 阶段2: 深度审查(Gemini 3 Pro)

[phase2_review.md的内容]

---

## 审查总结

### 🔴 严重问题(必须修复)
[列出严重问题]

### 🟡 一般问题(建议修复)
[列出一般问题]

### 🟢 优化建议(可选改进)
[列出优化建议]

---

## 下一步建议

1. 优先修复严重问题
2. 使用 `/kim-code` 生成修复代码
3. 修复后再次运行 `/kim-review` 验证

Read the full file on GitHub · 189 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 189 lines · 25 tokens per session scan A e0fb7b334480

Subscribe to this mod's changes

kim-review is a command published in the GitHub repository KimYx0207/Claudecode-Codex-Gemini (120 stars, last pushed 28d ago), licensed MIT. It adds 25 tokens to every session and 1,418 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.