Skip to main content
Glama

inspect-logs-mcp

MCP server for exploring inspect_ai evaluation logs from Claude Code.

What it does

This MCP server gives Claude Code, Cursor, and other LLMs direct access to your inspect_ai evaluation logs, allowing you to:

  • List logs: See all your evaluation runs with metadata

  • View summaries: Get detailed evaluation results, scores, and token usage

  • Inspect samples: View full conversation history for any sample

  • Search & filter: Find logs by task, model, date, or status

  • Compare runs: Side-by-side comparison of two evaluation runs

  • Aggregate stats: Get statistics across multiple runs

Related MCP server: reqlog

Installation

Currently only source installation is supported.

git clone https://github.com/PranshuSrivastava/inspect-logs-mcp.git
cd inspect-logs-mcp
pip install -e .

Configuration

To use with Claude code in your current directory, run the following command:

claude mcp add --transport stdio inspect-logs inspect-logs-mcp

To use with Claude code in your global configuration, run the following command:

claude mcp add --scope user --transport stdio inspect-logs inspect-logs-mcp

To use with Cursor, Antigravity or other IDEs, add the following to your mcp config file:

{
    "mcpServers": {
        "inspect-logs": {
            "command": "inspect-logs-mcp",
            "env": {
                "INSPECT_LOG_DIR": "./logs"
            }
        }
    }
}

Environment Variables

Variable

Description

Default

INSPECT_LOG_DIR

Directory containing .eval log files

./logs

INSPECT_LOGS_MCP_DEFAULT_LIMIT

Default number of logs limit

50

INSPECT_LOGS_MCP_MAX_LIMIT

Maximum number of logs limit

500

How it Works

The server reads .eval files (which are ZIP archives containing JSON) using the inspect_ai.log API. All file operations happen in memory - no files are extracted to disk, so your logs directory stays clean.

Requirements

  • Python 3.10+

  • inspect-ai >= 0.3.70

  • mcp >= 1.0.0

Available Tools

6 tools
tool_compare_runsB

Compare metrics between two evaluation runs.

Shows side-by-side comparison of two evaluation runs including task/model info, sample counts, score differences, token usage differences, and duration.

Args: log_file_a: Path to first log file log_file_b: Path to second log file log_dir: Optional log directory for relative paths

Inputs: log_file_a (required), log_file_b (required), log_dir.

tool_get_aggregate_statsA

Get aggregate statistics across multiple evaluation runs.

Provides summary statistics grouped by task and model, including success rates, sample counts, token usage totals, and duration averages.

Args: log_dir: Directory containing log files task: Filter by task name (supports wildcards) model: Filter by model name (supports wildcards) date_from: Filter logs from this date (ISO format) date_to: Filter logs until this date (ISO format)

Inputs: log_dir, task, model, date_from, +1 more.

tool_get_eval_summaryC

Get comprehensive evaluation summary including header, results, and stats.

Returns full metadata about an evaluation run: task info, model configuration, scoring results, token usage, duration, and revision info.

Args: log_file: Path to log file (absolute or relative to log_dir) log_dir: Optional log directory for relative paths

Inputs: log_file (required), log_dir.

tool_get_sampleB

Get detailed sample data including full conversation history.

Returns the complete sample including input, target, all messages exchanged with the model, output, scores, and metadata.

Args: log_file: Path to log file (absolute or relative to log_dir) sample_id: Sample ID to retrieve epoch: Epoch number (default: 1) log_dir: Optional log directory for relative paths include_events: Include event transcript (default: False, can be verbose)

Inputs: log_file (required), sample_id (required), epoch, log_dir, +1 more.

tool_list_logsA

List available evaluation log files with metadata.

Lists all .eval log files in the specified directory, sorted by date (newest first). Returns task name, model, status, sample count, and other metadata for each log.

Args: log_dir: Directory containing log files. Defaults to INSPECT_LOG_DIR env var or ./logs limit: Maximum number of logs to return (default: INSPECT_LOGS_MCP_DEFAULT_LIMIT or 50, max: INSPECT_LOGS_MCP_MAX_LIMIT or 500) offset: Number of logs to skip for pagination (default: 0)

Inputs: log_dir, limit, offset.

tool_search_logsA

Search and filter evaluation logs by various criteria.

Supports filtering by task name, model, status, date range, and minimum sample count. Task and model filters support wildcards (e.g., 'mind2web*', 'google/*').

Args: log_dir: Directory containing log files task: Filter by task name (supports wildcards like 'mind2web*') model: Filter by model name (supports wildcards like 'google/*') status: Filter by status: 'success', 'error', 'cancelled' date_from: Filter logs from this date (ISO format: YYYY-MM-DD) date_to: Filter logs until this date (ISO format: YYYY-MM-DD) min_samples: Minimum sample count limit: Maximum results (default: INSPECT_LOGS_MCP_DEFAULT_LIMIT or 50, max: INSPECT_LOGS_MCP_MAX_LIMIT or 500)

Inputs: log_dir, task, model, status, +4 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.7/5.0

    Scored across 6 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose with no overlap: compare_runs compares two specific runs, get_aggregate_stats provides cross-run statistics, get_eval_summary gives detailed metadata for a single run, get_sample retrieves granular sample data, list_logs enumerates available logs, and search_logs filters logs by criteria. The descriptions clearly differentiate their scopes, making misselection unlikely.

    Naming Consistency5/5

    All tools follow a consistent verb_noun pattern with 'tool_' prefix (e.g., tool_compare_runs, tool_get_aggregate_stats). The verbs are descriptive and appropriate for their functions (compare, get, list, search), and the nouns precisely indicate the target resources (runs, stats, summary, sample, logs). This consistency aids predictability and usability.

    Tool Count5/5

    With 6 tools, this server is well-scoped for inspecting evaluation logs. The count aligns with the domain's needs: listing and searching logs, retrieving summaries and samples, comparing runs, and aggregating statistics. Each tool earns its place without redundancy, covering essential operations without being overwhelming or insufficient.

    Completeness5/5

    The toolset provides complete coverage for log inspection: list_logs and search_logs for discovery, get_eval_summary and get_sample for detailed analysis, compare_runs for comparison, and get_aggregate_stats for cross-run insights. There are no obvious gaps; agents can navigate from discovery to deep analysis seamlessly, supporting typical evaluation workflows.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Enables AI assistants to automatically inspect and analyze application runtime log files for debugging and troubleshooting. Supports monitoring multiple log directories simultaneously with tools for listing, reading, searching, and paginating through log files.
      8
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Provides AI coding agents with tools to query, search, and analyze persisted HTTP request logs, enabling efficient debugging without terminal noise.
      MIT
    • A
      license
      Not graded
      quality
      A
      maintenance
      Enables AI agents to analyze, cluster, compare, and export reports from local log files through seven read-only tools, returning compact evidence packs with line-number citations instead of raw log dumps. All processing happens on the local machine, so log data never leaves the environment.
      1
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables AI agents such as Cursor and Claude Code to inspect local log files through MCP tools for tailing, searching, filtering, statistics, and root-cause diagnosis using local Ollama or a built-in rule engine.
      9
      MIT