📊analyze-ai-topics
- プラグイン
- amplitude
- ソース
- GitHub で見る ↗
説明
ユーザーがAIエージェントに対して何を質問しているか、またそれぞれのトピックにどれだけ適切に対応できているかを分析します。 ユーザーのプロジェクトにAmplitude Agent Analyticsが導入されている場合にのみ使用してください。 次のような場合に使用: ユーザーが「AIに何を聞いている人が多いか」「AIのトップトピック」「AIが苦手にしている部分」「AIのカバレッジギャップ」「AIの改善点」などを尋ねているとき、またはAIの会話パターンからプロダクトに関するインサイトを得たいと思っているとき。
原文を表示
Analyzes what users ask AI agents about and how well each topic is served. Only use when the user has Amplitude Agent Analytics instrumented in their project. Use when the user asks "what are people asking the AI", "top AI topics", "where is the AI struggling", "AI coverage gaps", "what should we improve in our AI", or wants product insights from AI conversation patterns.
ユースケース
- ✓AIへのよくある質問内容を確認するとき
- ✓AIが対応できていないトピックを特定するとき
- ✓AIの会話パターンからインサイトを得たいとき
- ✓AIのカバレッジギャップを分析するとき
- ✓AIの改善点を検討するとき
本文(日本語訳)
AI トピック アナライザー
ユーザーが AI エージェントに何を尋ねているか、また各トピックがどの程度適切に対応されているかを分析します。会話パターンから、対応が不十分な領域・カバレッジのギャップ・プロダクト上の機会を明らかにします。AI セッションデータを「次に何を作るべきか」という意思決定へと転換する、プロダクトインテリジェンス スキルです。
手順
ステップ 1: コンテキストとスキーマの取得
-
コンテキストを取得する。
Amplitude:get_contextを呼び出し、プロジェクトとユーザーロールを確認します。 -
AI スキーマを取得する。
Amplitude:get_agent_analytics_schemaをinclude: ["filter_options", "taxonomy"]で呼び出し、利用可能なトピックモデル・エージェント名・分類値を確認します。 スキーマにより、存在するトピックのディメンション(例:product_area、intent、error_domain)がわかります。これらはプロジェクトごとに異なります。 -
スコープを決定する。 ユーザーがエージェント・時間ウィンドウ・フォーカスエリアを指定した場合は、それに合わせて範囲を絞ります。 デフォルト: 全エージェント、直近 14 日間(期間を長くするほどトピック分布が安定します)。
ステップ 2: トピック全体像のマッピング
以下を並行して実行します:
-
品質スコア付きのトピック内訳。
Amplitude:query_agent_analytics_metricsをmetrics: ["topics"]、limit: 50で呼び出します。 各トピックのセッション数・平均品質スコア・平均センチメント・失敗率が返されます。これがコアデータセットです。 -
エージェント × トピック マトリクス。
Amplitude:query_agent_analytics_sessionsをgroupBy: ["agent_name", "primary_topic"]、limit: 100で呼び出します。 どのエージェントがどのトピックを扱っているか、また同じトピックでもエージェントによって品質がどう異なるかが把握できます。 -
トピック別ボリュームトレンド。
Amplitude:query_agent_analytics_metricsをmetrics: ["volume_timeseries"]、interval: "DAY"で呼び出します。 集計値ではありますが、トピック内訳と組み合わせることで、全体的なボリューム増加が特定のトピックによって牽引されているかどうかを把握できます。 -
トピック別の失敗セッション。
Amplitude:query_agent_analytics_sessionsをhasTaskFailure: true、groupBy: ["primary_topic"]、limit: 50で呼び出します。 失敗が最も多いトピックを把握できます。低品質(ソフトな劣化)とは異なるシグナルで、失敗はハードストップを意味します。
ステップ 3: 対応不足トピックの特定
各トピックを「ボリューム × 品質」の 2×2 マトリクスでスコアリングします:
| 高品質(> 0.7) | 低品質(< 0.7) | |
|---|---|---|
| 高ボリューム | 十分に対応済み(維持) | 対応不足(今すぐ対処) |
| 低ボリューム | ニッチだが機能中(監視) | ギャップまたは新興(調査) |
各象限で上位 3〜5 トピックを特定します。 優先度が最も高いのは 「高ボリューム + 低品質」 の象限です。ユーザーが頻繁に質問しているにもかかわらず、エージェントがうまく対応できていない領域です。
また、以下にもフラグを立てます:
- 急成長トピック: 対象期間内でボリュームが増加しているトピック。現時点で品質が許容範囲内でも、近いうちにカバレッジ強化が必要になる可能性があります。
- センチメント外れ値: 品質スコアより著しくセンチメントが低いトピック。エージェントは技術的にタスクを完了しているものの、ユーザー体験に不満があることを意味します。
- エージェントルーティングの問題: 同じトピックでも、あるエージェントは上手く対応できているのに別のエージェントは対応が悪い場合。ルーティングの改善を示唆しています。
ステップ 4: 上位の対応不足トピックの詳細調査(予算: 3〜6 回の呼び出し)
最もインパクトの大きい対応不足トピック 2〜3 件について:
-
会話のサンプリング。
Amplitude:search_agent_analytics_conversationsをトピックのキーワードで呼び出し、代表的な会話を探します。3〜5 件の例を読み、以下を把握します:- ユーザーは具体的に何を尋ねているか?
- エージェントはどこで詰まっているか(誤回答・無回答・ツール誤用・応答遅延)?
- トピック内にサブパターンはあるか?
-
失敗セッションの詳細。
Amplitude:query_agent_analytics_sessionsをトピックで絞り込み、hasTaskFailure: trueまたはmaxQualityScore: 0.5、responseFormat: "detailed"、limit: 5で呼び出します。 失敗理由とルーブリックスコアのエンリッチメントデータを確認します。 -
トピックのツール使用状況。
Amplitude:query_agent_analytics_metricsをmetrics: ["tool_stats"]で呼び出します(そのトピックのセッションに絞り込めれば理想的です)。 絞り込みができない場合は、Amplitude:query_agent_analytics_spansで失敗セッションのスパンデータを数件取得し、関与するツールを確認します。
ステップ 5: プロダクトインサイトへの統合
分析結果を、実行可能なプロダクト意思決定へと変換します。
必須セクション:
-
トピック全体像のサマリー(3〜4 文): 個別トピックの数・セッションの総ボリューム・品質の全体的な分布を記述します。 「AI エージェントは X トピックにわたり Y セッションを処理しています。うまくいっていること・いないことをご説明します」という形で表現します。
-
トピックヒートマップ表(コアの成果物):
| トピック | セッション数 | 品質 | センチメント | 失敗率 | トレンド | 優先度 |
|----------|------------|------|------------|--------|--------|--------|
| [トピック] | [N] | [スコア] | [スコア] | [%] | [↑/↓/→] | [要対処/要監視/良好] |
優先度順(要対処 → 要監視 → 良好)でソートし、上位 15〜20 トピックに絞ります。
-
対応不足トピック(2〜4 件の発見事項): 各項目を段落形式で記述します:
- [トピックの見出し — ユーザーが尋ねていること] — ボリューム(N セッション)・品質スコア・何がうまくいっていないか(会話サンプルより)・担当エージェント・改善策。具体性を持たせるため、会話の抜粋を含めます。
-
カバレッジギャップ(1〜2 件の発見事項): エージェントがまったく回答できない質問をユーザーがしているトピック。 根拠: 高い失敗率・非常に低い品質スコア・「対応できません」とエージェントが明示しているセッション。
-
新興トピック(1〜2 件の発見事項): ボリュームが増加しており、近いうちに対応が必要になる可能性があるトピック。 成長率と現在の品質スコアを含めます。
-
エージェントルーティングのインサイト(該当する場合): 別のエージェントがより適切に対応できるトピック、または専門エージェントを追加することで品質が向上するトピック。
-
推奨アクション(優先度順に 3〜5 件): インパクト(ボリューム × 品質ギャップ)の大きさ順に並べます。例:
- 「Chart Agent のリテンションクエリへの対応を改善する — 週 340 セッション、品質スコア 0.42。ユーザーはコホートリテンションを求めているが、イベントトレンドが返ってくる。エージェントのルーティングにリテンションチャートタイプの検出を追加する。」
- 「専用オンボーディングエージェントを作成する — 「はじめに」系トピックが 3 つのエージェントに分散しており、品質にばらつきがある(0.38〜0.72)。オンボーディングのコンテキストを持つ単一エージェントに統一することで体験を向上させる。」
- 「未対応クエリタイプに対してより適切なエラーメッセージを追加する — 週 89 セッションが「対応できません」という行き止まりに到達している。最低限、代替手段を提案するようにする。」
-
フォローアップのプロンプト: 「特定のトピックをより詳しく調査する、[最も対応不足なトピック] の失敗セッションを調べる、または AI トピック品質の監視ダッシュボードを構築しますか?」
ライティング基準:
- データではなく、ユーザーへのインパクトを起点に記述する
- 会話の抜粋を使って抽象的なトピックを具体化する
- すべてを数値化する(「多くのセッション」ではなく「週 340 セッション」)
- すべての発見事項にアクションを付ける
- レポート全体は 800 語以内に収める(トピック分析は運用レポートよりも内容が充実する傾向があります)
使用例
例 1: トピックの全体分析
次のような場合に使用: ユーザーが「AI に何を聞いているか教えて」と言う。
アクション:
- コンテキストと AI スキーマを取得する
- トピック内訳・エージェント × トピック マトリクス・ボリュームトレンド・トピック別失敗を並行してクエリする(4 並行呼び出し)
- ボリューム × 品質マトリクスでトピックをスコアリングする
- 上位 2〜3 件の対応不足トピックを、会話検索と詳細セッションで深掘りする
- トピックヒートマップと対応不足の発見事項・推奨事項を提示する
例 2: ギャップのフォーカス分析
次のような場合に使用: ユーザーが「AI はどこで失敗しているか?」と言う。
アクション:
- コンテキストとスキーマを取得する
- トピックと失敗をクエリし、品質が低く失敗率が高いトピックにフォーカスする
- 各対応不足トピックについて会話を検索し、失敗のパターンを把握する
- 深刻度別に整理し、具体的な改善提案を含めて発見事項を提示する
例 3: エージェント固有のトピックレビュー
次のような場合に使用: ユーザーが「Chart Agent はどんなトピックを扱っていて、どの程度うまく対応しているか?」と言う。
アクション:
- コンテキストを取得し、そのエージェント限定でトピック別にグループ化したセッションをクエリする
- そのエージェントのトピック品質スコアをフリート全体の平均と比較する
- そのエージェントの最も品質が低いトピックを深掘りする
- そのエージェントのトピックカバレッジに関するフォーカスレポートを提示する
トラブルシューティング
トピックエンリッチメントデータがない場合
トピックはセッションエンリッチメントが有効になっている必要があります。
トピックが空の場合は、search_agent_analytics_conversations を幅広いキーワードで呼び出し、共通のテーマを手動で分類するフォールバックを行います。
制限事項を明記し、エンリッチメントの有効化を提案してください。
トピックが多すぎる場合(50 件超)
類似トピックをグループ化し、ボリューム上位 20 件を提示します。 リクエストに応じて特定クラスターへのドリルダウンを提案してください。
トピックが汎用的すぎる場合
トピックラベルが
原文(English)を表示
AI Topic Analyzer
You analyze what users ask AI agents about and how well each topic is served — surfacing underserved areas, coverage gaps, and product opportunities from conversation patterns. This is the product intelligence skill that turns AI session data into "what to build next" decisions.
Instructions
Step 1: Get Context and Schema
- Get context. Call
Amplitude:get_contextto identify projects and user role. - Get AI schema. Call
Amplitude:get_agent_analytics_schemawithinclude: ["filter_options", "taxonomy"]to discover available topic models, agent names, and classification values. The schema tells you what topic dimensions exist (e.g., product_area, intent, error_domain) — these vary by project. - Determine scope. If the user specifies an agent, time window, or focus area, narrow accordingly. Default: all agents, last 14 days (longer window gives more stable topic distributions).
Step 2: Map the Topic Landscape
Run these in parallel:
-
Topic breakdown with quality. Call
Amplitude:query_agent_analytics_metricswithmetrics: ["topics"],limit: 50. This returns each topic with session count, average quality score, average sentiment, and failure rate. This is the core dataset. -
Agent-by-topic matrix. Call
Amplitude:query_agent_analytics_sessionswithgroupBy: ["agent_name", "primary_topic"],limit: 100. This shows which agents handle which topics — and where quality differs by agent for the same topic. -
Volume trend by topic. Call
Amplitude:query_agent_analytics_metricswithmetrics: ["volume_timeseries"],interval: "DAY". While this is aggregate, combine it with the topic breakdown to understand whether total volume growth is driven by specific topics. -
Failure sessions by topic. Call
Amplitude:query_agent_analytics_sessionswithhasTaskFailure: true,groupBy: ["primary_topic"],limit: 50. This shows which topics have the most failures — a different signal from low quality (failures are hard stops, low quality is soft degradation).
Step 3: Identify Underserved Topics
Score each topic on a 2x2 of volume x quality:
| High Quality (>0.7) | Low Quality (<0.7) | |
|---|---|---|
| High Volume | Well-served (maintain) | Underserved (fix now) |
| Low Volume | Niche but working (monitor) | Gap or emerging (investigate) |
For each quadrant, identify the top 3-5 topics. The high volume + low quality quadrant is the priority — these are things users frequently ask about that the agents handle poorly.
Also flag:
- Growing topics: Topics with increasing volume over the time window. These may need better coverage soon even if quality is currently acceptable.
- Sentiment outliers: Topics where sentiment is notably lower than quality score. This means the agent technically completes the task but users aren't happy with the experience.
- Agent routing issues: Topics where one agent handles them well but another handles them poorly — suggesting a routing improvement.
Step 4: Deep-Dive into Top Underserved Topics (Budget: 3-6 calls)
For the 2-3 most impactful underserved topics:
-
Sample conversations. Call
Amplitude:search_agent_analytics_conversationswith keywords from the topic to find representative conversations. Read 3-5 examples to understand:- What specifically are users asking?
- Where does the agent struggle — wrong answer, no answer, wrong tool, slow response?
- Are there sub-patterns within the topic?
-
Detailed failing sessions. Call
Amplitude:query_agent_analytics_sessionsfiltered to the topic withhasTaskFailure: trueormaxQualityScore: 0.5,responseFormat: "detailed",limit: 5. Read the enrichment data for failure reasons and rubric scores. -
Tool usage for the topic. Call
Amplitude:query_agent_analytics_metricswithmetrics: ["tool_stats"]— if you can filter to sessions for this topic. Otherwise, pull span data for a few failing sessions withAmplitude:query_agent_analytics_spansto see which tools are involved.
Step 5: Synthesize into Product Insights
Transform the analysis into actionable product decisions.
Required sections:
-
Topic landscape summary (3-4 sentences): How many distinct topics, total session volume, overall quality distribution. Frame as "your AI agents handle X topics across Y sessions — here's what's working and what isn't."
-
Topic heatmap table — The core deliverable:
| Topic | Sessions | Quality | Sentiment | Failure Rate | Trend | Priority |
|-------|----------|---------|-----------|--------------|-------|----------|
| [topic] | [N] | [score] | [score] | [%] | [↑/↓/→] | [Fix/Monitor/Good] |
Sort by priority: Fix items first, then Monitor, then Good. Limit to top 15-20 topics.
-
Underserved topics (2-4 findings): Each as a narrative paragraph:
- [Topic headline — what users are asking] — Volume (N sessions), quality score, what goes wrong (from conversation samples), which agent handles it, and what would fix it. Include example conversation excerpts to make it concrete.
-
Coverage gaps (1-2 findings): Topics where users are asking questions the agents can't answer at all. Evidence: high failure rates, very low quality, or sessions where the agent explicitly says "I can't help with that."
-
Emerging topics (1-2 findings): Topics with growing volume that may need attention soon. Include the growth rate and current quality.
-
Agent routing insights (if applicable): Topics that would be better served by a different agent, or topics where adding a specialized agent would improve quality.
-
Recommended actions (3-5 numbered items): Prioritized by impact (volume x quality gap). Examples:
- "Improve the Chart Agent's handling of retention queries — 340 sessions/week at 0.42 quality. Users ask for cohort retention but get event trends. Add retention chart type detection to the agent's routing."
- "Create a dedicated onboarding agent — 'getting started' topics span 3 agents with inconsistent quality (0.38-0.72). A single agent with onboarding context would unify the experience."
- "Add better error messages for unsupported query types — 89 sessions/week hit 'I can't do that' dead ends. At minimum, suggest what the user should try instead."
-
Follow-on prompt: "Want me to deep-dive into a specific topic, investigate the failing sessions for [top underserved topic], or build a monitoring dashboard for AI topic quality?"
Writing standards:
- Lead with the user impact, not the data
- Use conversation excerpts to make abstract topics concrete
- Quantify everything — "340 sessions/week" not "many sessions"
- Every finding needs an action
- Keep the full report under 800 words (topic analysis tends to be richer than operational reports)
Examples
Example 1: Full Topic Analysis
User says: "What are people asking our AI about?"
Actions:
- Get context and AI schema
- Query topic breakdown, agent-by-topic matrix, volume trends, and failures by topic (4 parallel calls)
- Score topics on the volume x quality matrix
- Deep-dive into top 2-3 underserved topics with conversation search and detailed sessions
- Present the topic heatmap with underserved findings and recommendations
Example 2: Focused Gap Analysis
User says: "Where is our AI falling short?"
Actions:
- Get context and schema
- Query topics and failures — focus on low quality and high failure rate topics
- For each underserved topic, search conversations to understand the failure mode
- Present findings organized by severity with concrete fix recommendations
Example 3: Agent-Specific Topic Review
User says: "What topics does the Chart Agent handle, and how well?"
Actions:
- Get context, then query sessions grouped by topic for that agent specifically
- Compare the agent's topic quality scores against the fleet average
- Deep-dive into the agent's worst topics
- Present a focused report on that agent's topic coverage
Troubleshooting
No topic enrichment data
Topics require session enrichment to be enabled. If topics are empty, fall back to search_agent_analytics_conversations with broad keyword searches to manually categorize common themes. Note the limitation and suggest enabling enrichment.
Too many topics (>50)
Group similar topics and present the top 20 by volume. Offer to drill into specific clusters on request.
Topics are too generic
If topic labels are broad (e.g., "data question", "help request"), the enrichment model may need tuning. Note this and use conversation search to identify more specific sub-topics manually.
原文・著作権は Anthropic および各プラグイン作者に帰属します。日本語訳は Claude API による自動翻訳です。