river-review-performance
パフォーマンス観点のレビューエージェント。 N+1クエリ、メモリ効率、キャッシュ戦略、可観測性の観点でコード変更を評価する。
- License 许可
- MIT
- 最近更新
- 2026-06-26
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- id
- river-review-performance
- name
- river-review-performance
- tags
- [ "performance", "optimization", "entry", "routing" ]
- phase
- [ "midstream" ]
- applyTo
- [ "src/**/*.{ts,tsx,js,jsx,mjs}", "**/*.sql" ]
- license
- MIT
- version
- 0.1.0
- category
- midstream
- severity
- major
- outputKind
- [ "findings", "actions" ]
- description
- パフォーマンス観点のレビューエージェント。 N+1クエリ、メモリ効率、キャッシュ戦略、可観測性の観点でコード変更を評価する。
- inputContext
- [ "diff", "fullFile" ]
02 资源文件 1
- 参考文档references/ROUTING.md1.8 KB
03 SKILL.md 正文
Performance Review(パフォーマンスレビュー)
パフォーマンスに影響する変更を検出し、適切な個別スキルで検証する。
When to Use / いつ使うか
- データベースクエリの追加・変更時
- ループ処理やバッチ処理の変更時
- キャッシュ戦略の変更時
- 大量データの処理ロジック変更時
Routing / ルーティング
| キーワード | スキルID | 説明 |
|---|---|---|
| キャッシュ, TTL | rr-upstream-cache-strategy-consistency-001 |
キャッシュ戦略の一貫性 |
| 障害, 監視, メトリクス | rr-upstream-failure-modes-observability-001 |
障害モードと可観測性 |
| ログ, トレース | rr-midstream-logging-observability-001 |
ロギング・可観測性 |
| SLO, レイテンシ | rr-upstream-operability-slo-001 |
運用性・SLO |
デフォルト動作
- キーワード指定なし → 以下のヒューリスティクスで判定:
- ループ内I/O → N+1クエリ検出
- 大量データ処理 → メモリ効率チェック
- 外部API呼び出し → タイムアウト・リトライ検証
Execution Flow / 実行フロー
1. 変更内容の分析
├─ ループ内I/O → N+1クエリ検出を優先
├─ 大量データ処理 → メモリ効率チェックを優先
├─ 外部API呼び出し → タイムアウト・リトライ検証を優先
└─ キーワード指定あり → 該当スキルを直接選択
2. スキルの実行
├─ cache-strategy-consistency: キャッシュ戦略の一貫性
├─ failure-modes-observability: 障害モードと可観測性
├─ logging-observability: ロギング・可観測性
└─ operability-slo: 運用性・SLO
3. 統合
├─ 重複する指摘の除去
└─ Checklistに基づくパフォーマンスチェックの補完
Checklist / チェックリスト
パフォーマンスレビューでは以下を確認する:
クエリ効率
- N+1クエリが発生していないか
- 必要なeager loadingが設定されているか
- 不要なカラムを取得していないか(SELECT *)
メモリ効率
- ループ内での不要なオブジェクト生成がないか
- 大量データのストリーム処理が適切か
- メモリリークのパターンがないか
I/O効率
- 外部API呼び出しのタイムアウト設定
- リトライ戦略の妥当性
- 並列化可能なI/Oの逐次実行
キャッシュ
- キャッシュキーの設計が適切か
- TTLが妥当か
- キャッシュの無効化戦略
Output Format / 出力形式
<file>:<line>: <message>
- Finding: 何が問題か(1文)
- Impact: 推定される影響(レイテンシ増加、メモリ消費等)
- Fix: 次の一手(最小の修正案)
他スキルとの関係
| スキル | 関係 | 棲み分け |
|---|---|---|
river-review-architecture |
補完 | performance は「実行時効率」、architecture は「構造的スケーラビリティ」 |
river-review-code |
補完 | performance は「速度・効率」、code は「可読性・保守性」 |
References
- ROUTING.md: 詳細なルーティングルール
04 同仓库更多 Skills
android-emulator-qa
Use when validating Android feature flows in an emulator with adb-driven launch, input, UI-tree inspection, screenshots, and logcat capture.
supabase-postgres-best-practices
Postgres performance optimization and best practices from Supabase. Use this skill when writing, reviewing, or optimizing Postgres queries, schema designs, or database configurations.
sentry
Use when the user asks to inspect Sentry issues or events, summarize recent production errors, or pull basic Sentry health data via the Sentry API; perform read-only queries with the bundled script and require `SENTRY_AUTH_TOKEN`.
render-workflows
Sets up, develops, tests, and deploys Render Workflows. Covers first-time scaffolding (via CLI or manual), SDK installation (Python or TypeScript), task patterns (retries, subtasks, fan-out), local development, Dashboard deployment, and troubleshooting. Use when a user wants to set up Render Workflows for the first time, scaffold a workflow service, add or modify workflow tasks, test workflows locally, or deploy workflows to Render.
render-web-services
Configures Render web services—port binding, TLS, health checks, custom domains, auto-deploy, PR previews, persistent disks, and deploy lifecycle. Use when the user needs to set up a web service, fix health check failures, add a custom domain, configure zero-downtime deploys, or troubleshoot port binding issues.
render-static-sites
Deploys and configures static sites on Render's global CDN—build commands, publish paths, SPA routing, redirects, custom headers, and PR previews. Use when the user needs to deploy a static site, set up a React/Vue/Hugo/Gatsby frontend, configure SPA fallback routing, add redirect rules, customize response headers, or choose between a static site and a web service for their frontend. Trigger terms: static site, CDN, SPA, single-page app, React deploy, Vue deploy, Hugo, Gatsby, Docusaurus, Jekyll, staticPublishPath.