auto-consultation
Claude Code自動相談システム。行き詰まった時にSonnet/Opus APIに相談する。2回失敗で自動提案、ハイブリッドエスカレーション。
npx skills add majiayu000/claude-skill-registry --skill auto-consultation --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Auto Consultation ## 📋 実行前チェック(必須) ### このスキルを使うべきか? - [ ] 同じエラーが2回以上発生した? - [ ] 解決策が見つからず行き詰まっている? - [ ] ユーザーから「相談して」「APIに聞いて」と指示された? ### 前提条件 - [ ] `ANTHROPIC_API_KEY` が設定されているか? - [ ] `consult` コマンドが使用可能か? ### 禁止事項の確認 - [ ] 簡単に解決できる問題で無駄にAPIを呼んでいないか? - [ ] 過去の相談履歴を確認したか? --- ## トリガー ### 自動トリガー(Hook) - 同じエラーが2回発生 → 相談を提案 ### 手動トリガー - ユーザーから「相談して」「APIに聞いて」「Opusに相談して」 - 明らかに行き詰まっている時 --- ## 🚨 鉄則 **まず履歴を確認。無駄なAPI呼び出しを避ける。** --- ## 実行方法 ### 基本 ```bash # 直接相談 consult "エラーの原因を教えて: [エラー内容]" # 失敗ログから自動生成 consult --check # 統計確認 consult --stats ``` ### オプション ```bash # コンテキスト収集なし(シンプルな質問) consult --no-context "質問" # 非対話モード consult --no-interactive "質問" ``` --- ## フロー ``` 1. 問題発生 → failure_log に記録 2. 2回失敗 → Hook が検出 → 相談提案 3. consult 実行: a. 過去の類似相談を検索 b. コンテキスト自動収集 c. Sonnet API 呼び出し d. 回答の質を判定 e. 必要ならOpusにエスカレーション 4. 回答を適用 → 解決を試みる 5. 履歴に記録 ``` --- ## 自動エスカレーション条件 以下の場合、Opusに自動エスカレーション: 1. Sonnetの回答が100文字未満 2. 不確実性キーワードを含む: - "確信が持てません" - "より詳細な情報が必要" - "複数の可能性があります" --- ## 履歴の活用 ```bash # 履歴を確認 cat claude_tmp/consultation/index.json # 過去の相談を検索 grep -r "エラーキーワード" claude_tmp/consultation/history/ ``` --- ## コスト目安 | パターン | コスト | |---------|--------| | Sonnetで解決 | ~$0.02 | | Opus必要 | ~$0.06
- 📋 実行前チェック(必須)
- このスキルを使うべきか?
- 前提条件
- 禁止事項の確認
- トリガー
- 自動トリガー(Hook)
- 手動トリガー
- 🚨 鉄則
- 実行方法
- 基本
- オプション
- フロー
- 自動エスカレーション条件
- 履歴の活用
consult "エラーの原因を教えて: [エラー内容]" consult --check consult --stats consult --no-context "質問" consult --no-interactive "質問" cat claude_tmp/consultation/index.json grep -r "エラーキーワード" claude_tmp/consultation/history/
What does the auto-consultation skill do?
Claude Code自動相談システム。行き詰まった時にSonnet/Opus APIに相談する。2回失敗で自動提案、ハイブリッドエスカレーション。
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill auto-consultation --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
