Skip to main content
Glama
claude-subagent-mcp

claude-subagent-mcp

by chrisliebaer

claude-subagent-mcp

MCP server that gives an agent structured and complete views into a Claude Code agent's .jsonl log without reading the raw file. It speaks MCP 2026-07-28 over stdio through mcp==2.0.0.

Tools

  • get_last_status(path, count, after_line=0) returns the last count assistant lines carrying visible text blocks and includes all text blocks of each returned line.

  • get_last_tools(path, count, after_line=0) returns the last count assistant lines carrying tool calls with name and input but without results and includes all tool calls of each returned line.

count is applied after filtering, so exactly count qualifying lines are returned whenever that many exist. after_line is a lower bound on raw line numbers and only lines strictly greater than it are considered. Pass the highest line already seen as after_line to suppress repeats. Returned line values are raw file line numbers and therefore contain gaps. An incomplete trailing line is ignored. Any other line that does not parse makes the tool report a format error.

Related MCP server: mcp-session-insight

Install into Claude Code

claude mcp add --scope user claude-subagent-log -- uvx --from git+https://github.com/chrisliebaer/claude-subagent-mcp claude-subagent-mcp

Pin a tag or commit with @<ref> behind the repository URL to keep the server from changing under an agent. For a local checkout use uv --directory <checkout> run claude-subagent-mcp as the command instead.

Development

uv run pytest
uv run ruff check . && uv run ruff format --check .
uv run mypy src tests

Available Tools

2 tools
get_last_statusA

Return the last count status messages the agent emitted.

Status messages are the visible text blocks of assistant lines. Every assistant line carrying at least one text block counts as one entry and all of its text blocks are returned. Entries are ordered oldest first and tagged with their raw line number.

Inputs: path (required), count (required), after_line. Returns: Result of `get_last_status`, oldest entry first.

get_last_toolsA

Return the last count tool-calling lines the agent emitted.

Every assistant line carrying at least one tool call counts as one entry and all of its tool calls (name and input, without results) are returned. Entries are ordered oldest first and tagged with their raw line number.

Inputs: path (required), count (required), after_line. Returns: Result of `get_last_tools`, oldest entry first.

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A3.9/5.0

    Scored across 2 tools

    Disambiguation5/5

    The two tools are clearly distinct: one retrieves text/status messages, the other retrieves tool call details. There is no overlap in purpose or output.

    Naming Consistency5/5

    Both tool names follow a consistent `get_last_<entity>` pattern, making it easy for an agent to predict the naming convention.

    Tool Count3/5

    With only 2 tools, the server feels thin for a general subagent monitoring use case. However, it may be appropriately minimal if the server's scope is intentionally limited to just observing agent output.

    Completeness3/5

    The tools cover reading status and tool calls, which are core observation needs. However, there are no tools for filtering by type, searching, or managing the agent's state, leaving notable gaps for a monitoring server.

    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
      A
      quality
      C
      maintenance
      Enables AI assistants to query and analyze past Claude Code sessions, providing structured insights like file changes, decisions, errors, and git history across projects.
      11
      1
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Indexes and searches agent conversation logs from Antigravity and Cursor workspaces, enabling semantic search, token analysis, and benchmarking over local SQLite storage.
      MIT