跳到主要内容

metrics 精选

Expertise in analyzing time-series repository health metrics, investigating root causes, and proposing proactive workflow improvements.

在 GitHub 打开

安装方式

cp -r tools/gemini-cli-bot/.gemini/skills/metrics ~/.claude/skills/metrics

把该 skill 目录放进客户端 skills 目录。不同客户端的目录可能不同,Claude Code 默认是 ~/.claude/skills/

整仓一次性获取:git clone --depth 1 https://github.com/google-gemini/gemini-cli.git

依赖与权限

  • 无需 API Key
  • 无需联网
  • 依赖外部命令:git gh
  • 以上为按正文与 frontmatter 自动推断的信号,仅供参考;安装前建议先阅读原文。

SKILL.md 正文

来源 google-gemini/gemini-cli@9b6e026 · 许可 Apache-2.0 · 内容未修改

Phase: The Brain (Metrics & Root-Cause Analysis)

Goal

Analyze time-series repository metrics and current repository state to identify

trends, anomalies, and opportunities for proactive improvement. You are

empowered to formulate hypotheses, rigorously investigate root causes, and

propose changes that safely improve repository health, productivity, and

maintainability.

Context

  • Time-series repository metrics are stored in

tools/gemini-cli-bot/history/metrics-timeseries.csv.

  • Recent point-in-time metrics are in

tools/gemini-cli-bot/history/metrics-before-prev.csv and the current run's

metrics.

  • Preservation Status: The orchestrator will provide a System Directive telling you whether PR creation is enabled for this run. If enabled, your proposed changes may be automatically promoted to a Pull Request. In this case, you MUST activate the 'prs' skill to generate a PR description and stage your changes. If PR creation is NOT enabled, you MUST NOT stage file changes or attempt to create a patch. Instead, simply report your findings.

Repo Policy Priorities

When analyzing data and proposing solutions, prioritize the following in order:

  1. Security & Quality: Security fixes, product quality, and release

blockers.

  1. Maintainer Workload: Keeping a manageable and focused workload for core

maintainers.

  1. Community Collaboration: Working effectively with the external

contributor community, maintaining a close collaborative relationship, and

treating them with respect.

  1. Productivity & Maintainability: Proactively recommending changes that

improve the developer experience or simplify repository maintenance, even if

no immediate "anomaly" is detected.

LLM-Powered Classification

You are explicitly authorized to use the Gemini CLI (bundle/gemini.js) within

your proposed scripts to perform classification tasks (e.g., sentiment analysis,

advanced triage, or semantic labeling).

  • Preference for Determinism: Always prefer deterministic TypeScript/Git

logic (System 1) when it can achieve equivalent quality and reliability. Use

the LLM only when heuristic or semantic understanding is required.

  • Strict Role Separation: Use Gemini CLI ONLY for classification (data

labeling). Do not use it for execution or decision-making.

  • Default Policy Enforcement: When generating scripts that invoke Gemini

CLI, they MUST NOT use the specialized tools/gemini-cli-bot/ci-policy.toml.

They should rely on the default repository policies.

Instructions

1. Read & Identify Trends (Time-Series Analysis)

  • Load and analyze tools/gemini-cli-bot/history/metrics-timeseries.csv.
  • Identify significant anomalies or deteriorating trends over time (e.g.,

latency_pr_overall_hours steadily increasing, open_issues growing faster

than closure rates).

  • Proactive Opportunities: Even if metrics are stable, identify areas where

maintainability or productivity could be improved.

  • Cost Savings (Lowest Priority): Monitor actions_spend_minutes and Gemini

usage for significant anomalies. You may proactively recommend cost savings

for both Actions and Gemini usage, provided that other repository health and

latency priorities are satisfied first.

2. Hypothesis Testing & Deep Dive

For the single most significant identified trend or opportunity (or a small

set of highly related ones):

  • Develop Competing Hypotheses: Brainstorm multiple potential root causes or

improvement strategies.

  • Gather Evidence: Use your tools (e.g., gh CLI, GraphQL) to collect data

that supports or refutes EACH hypothesis. You may write temporary local

scripts to slice the data.

  • Select Root Cause: Identify the hypothesis or strategy most strongly

supported by the data.

3. Maintainer Workload Assessment

Before blaming or proposing reflexes that rely on maintainer action:

  • Quantify Capacity: Assess the volume of open, unactioned work (untriaged

issues, review requests) against the number of active maintainers.

  • If the ratio indicates overload, **do not propose solutions that simply

generate more pings**. Instead, prioritize systemic triage, automated routing,

or auto-closure reflexes.

4. Actor-Aware Bottleneck Identification

Before proposing an intervention, accurately identify the blocker:

  • Waiting on Author: Needs a polite nudge or closure grace period.
  • Waiting on Maintainer: Needs routing, aggregated reports, or escalation.
  • Waiting on System (CI/Infra): Needs tooling fixes or reporting.

5. Policy Critique & Evaluation

  • Review Existing Policies: Examine the existing automation in

.github/workflows/ and scripts in tools/gemini-cli-bot/reflexes/scripts/.

  • Analyze Effectiveness: Determine if current policies are achieving their

goals.

6. Investigation Conclusion

  • Summarize your findings for the Orchestrator. When modifying scripts in

tools/gemini-cli-bot/metrics/scripts/, you MUST NEVER change the output

format (comma-separated values to stdout).

质量与来源

所属仓库
google-gemini/gemini-cli
仓库星标
11 万
最近更新
今天
采集时间
今天
commit
9b6e0265d16b
内容指纹
sha256:9858f3459c0b8b5
文件路径
tools/gemini-cli-bot/.gemini/skills/metrics/SKILL.md

同仓库其它 Skill

查看全部 25 个
agent-tui
Main Agents: Do NOT use this skill directly. If you need to test the TUI, invoke the `tui_tester` subagent. Drive terminal UI (TUI) applications programmatically for testing, automation, and inspection. Use when: automating CLI/TUI interactions, regression testing terminal apps, or verifying interactive behavior. Also use when: user asks "what is agent-tui", "what does agent-tui do", "demo agent-tui", "show me agent-tui", "how does agent-tui work", or wants to see it in action.
精选 google-gemini/gemini-cli 11 万 原文
Codex CLIGemini CLIMCP 客户端
async-pr-review
Trigger this skill when the user wants to start an asynchronous PR review, run background checks on a PR, or check the status of a previously started async PR review.
精选 google-gemini/gemini-cli 11 万 原文
Codex CLIGemini CLIMCP 客户端
behavioral-evals
Guidance for creating, running, fixing, and promoting behavioral evaluations. Use when verifying agent decision logic, debugging failures, debugging prompt steering, or adding workspace regression tests.
精选 google-gemini/gemini-cli 11 万 原文
Codex CLIGemini CLIMCP 客户端
ci
A specialized skill for Gemini CLI that provides high-performance, fail-fast monitoring of GitHub Actions workflows and automated local verification of CI failures. It handles run discovery automatically—simply provide the branch name.
精选 google-gemini/gemini-cli 11 万 原文
Codex CLIGemini CLIMCP 客户端
code-reviewer
Use this skill to review code. It supports both local changes (staged or working tree) and remote Pull Requests (by ID or URL). It focuses on correctness, maintainability, and adherence to project standards.
精选 google-gemini/gemini-cli 11 万 原文
Codex CLIGemini CLIMCP 客户端
docs-changelog
Generates and formats changelog files for a new release based on provided version and raw changelog data.
精选 google-gemini/gemini-cli 11 万 原文
Codex CLIGemini CLIMCP 客户端

相似 Skill

更多「编码」
access
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed, or change policy for the Discord channel.
精选 anthropics/claude-plugins-official 3.8 万 原文
Claude CodeMCP 客户端
configure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how do I set this up" or "who can reach me," or wants to check channel status.
精选 anthropics/claude-plugins-official 3.8 万 原文
Claude CodeMCP 客户端
access
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed, or change policy for the iMessage channel.
精选 anthropics/claude-plugins-official 3.8 万 原文
Claude CodeMCP 客户端
configure
Check iMessage channel setup and review access policy. Use when the user asks to configure iMessage, asks "how do I set this up" or "who can reach me," or wants to know why texts aren't reaching the assistant.
精选 anthropics/claude-plugins-official 3.8 万 原文
Claude CodeMCP 客户端
access
Manage Telegram channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed, or change policy for the Telegram channel.
精选 anthropics/claude-plugins-official 3.8 万 原文
Claude CodeMCP 客户端
configure
Set up the Telegram channel — save the bot token and review access policy. Use when the user pastes a Telegram bot token, asks to configure Telegram, asks "how do I set this up" or "who can reach me," or wants to check channel status.
精选 anthropics/claude-plugins-official 3.8 万 原文
Claude CodeMCP 客户端