SDKsMCP ServerAvailable Tools

Available Tools

The ThinkHive MCP Server provides 25+ tools organized by category.

Trace Analysis

trace_explain

Analyze a trace with RAG evaluation and hallucination detection.

{
  "name": "trace_explain",
  "arguments": {
    "traceId": "tr_abc123",
    "tier": "full_llm",
    "includeRagEvaluation": true,
    "includeHallucinationDetection": true
  }
}

Parameters:

ParameterTypeRequiredDescription
traceIdstringYesTrace ID to analyze
tierstringNoAnalysis tier: rule_based, fast_llm, full_llm, deep
includeRagEvaluationbooleanNoInclude RAG quality metrics
includeHallucinationDetectionbooleanNoDetect hallucinations

Search traces using natural language.

{
  "name": "trace_search",
  "arguments": {
    "query": "authentication failures in the last week",
    "agentId": "support-agent",
    "limit": 10
  }
}

trace_get_explanation

Retrieve stored explanation for a trace.

{
  "name": "trace_get_explanation",
  "arguments": {
    "traceId": "tr_abc123"
  }
}

trace_patterns

Get failure patterns for an agent.

{
  "name": "trace_patterns",
  "arguments": {
    "agentId": "support-agent",
    "startDate": "2024-01-01",
    "endDate": "2024-01-31"
  }
}

trace_stats

Get trace statistics for an agent.

{
  "name": "trace_stats",
  "arguments": {
    "agentId": "support-agent"
  }
}

trace_batch_analyze

Analyze multiple traces in batch.

{
  "name": "trace_batch_analyze",
  "arguments": {
    "agentId": "support-agent",
    "limit": 50
  }
}

Quality Metrics

quality_rag_evaluate

Evaluate RAG quality for a trace.

{
  "name": "quality_rag_evaluate",
  "arguments": {
    "traceId": "tr_abc123"
  }
}

Returns:

  • groundedness: Response supported by context (0-1)
  • faithfulness: Response consistent with context (0-1)
  • citationAccuracy: Proper attribution (0-1)
  • contextRelevance: Retrieved docs match query (0-1)

quality_hallucination_detect

Detect hallucinations in a trace.

{
  "name": "quality_hallucination_detect",
  "arguments": {
    "traceId": "tr_abc123"
  }
}

Returns hallucination types:

  • Unsupported claims
  • Factual errors
  • Contradictions
  • Fabricated references
  • And 5 more types

quality_get_scores

Get quality scores for an agent.

{
  "name": "quality_get_scores",
  "arguments": {
    "agentId": "support-agent",
    "startDate": "2024-01-01",
    "endDate": "2024-01-31"
  }
}

ROI Analytics

roi_get_summary

Get revenue impact analysis.

{
  "name": "roi_get_summary",
  "arguments": {
    "agentId": "support-agent"
  }
}

roi_get_correlations

Get performance-to-business correlations.

{
  "name": "roi_get_correlations",
  "arguments": {
    "agentId": "support-agent"
  }
}

roi_calculate_impact

Calculate business impact of improvements.

{
  "name": "roi_calculate_impact",
  "arguments": {
    "agentId": "support-agent",
    "improvement": 0.1
  }
}

Failure Clustering

cluster_list

List failure clusters for an agent.

{
  "name": "cluster_list",
  "arguments": {
    "agentId": "support-agent",
    "minClusterSize": 5
  }
}

cluster_details

Get detailed information about a cluster.

{
  "name": "cluster_details",
  "arguments": {
    "agentId": "support-agent",
    "clusterId": "cluster_abc"
  }
}

Fix Generation

fix_generate

Generate AI-powered fix suggestions.

{
  "name": "fix_generate",
  "arguments": {
    "traceId": "tr_abc123"
  }
}

Or for a cluster:

{
  "name": "fix_generate",
  "arguments": {
    "clusterId": "cluster_abc"
  }
}

fix_list

List generated fixes.

{
  "name": "fix_list",
  "arguments": {
    "agentId": "support-agent",
    "status": "proposed"
  }
}

Silent Failure Detection

silent_failures_detect

Detect silent failures (successful status but actual failure).

{
  "name": "silent_failures_detect",
  "arguments": {
    "agentId": "support-agent",
    "limit": 20
  }
}

silent_failures_summary

Get summary of silent failure patterns.

{
  "name": "silent_failures_summary",
  "arguments": {
    "agentId": "support-agent"
  }
}

Webhook Management

webhook_list

List configured webhooks.

{
  "name": "webhook_list",
  "arguments": {}
}

webhook_create

Create a new webhook.

{
  "name": "webhook_create",
  "arguments": {
    "url": "https://your-app.com/webhook",
    "events": ["trace.failure", "cluster.new"],
    "secret": "your_webhook_secret"
  }
}

webhook_delete

Delete a webhook.

{
  "name": "webhook_delete",
  "arguments": {
    "webhookId": "wh_abc123"
  }
}

webhook_test

Test a webhook.

{
  "name": "webhook_test",
  "arguments": {
    "webhookId": "wh_abc123"
  }
}

Evaluation Tools

eval_run

Run evaluation against a golden dataset.

{
  "name": "eval_run",
  "arguments": {
    "evalSetId": "eval_abc123",
    "agentId": "support-agent"
  }
}

eval_list_sets

List evaluation sets.

{
  "name": "eval_list_sets",
  "arguments": {}
}

eval_get_results

Get evaluation results.

{
  "name": "eval_get_results",
  "arguments": {
    "evalRunId": "run_abc123"
  }
}

Available Prompts

MCP prompts provide structured workflows:

PromptDescription
analyze-traceComprehensive trace analysis with insights
debug-failureDebug failed interactions
explain-clusterExplain failure patterns
quality-reportGenerate quality metrics report
roi-analysisGenerate business impact analysis
hallucination-reviewReview detected hallucinations

Using Prompts

In Claude Code:

> Use the analyze-trace prompt for trace tr_abc123

Tier Restrictions: Some tools require higher API tiers. Check your tier at app.thinkhive.ai/settings.

Next Steps