Skip to main content
Glama
TAgents

Planning System MCP Server

by TAgents

get_plan_summary

Retrieve a comprehensive summary with statistics for a specific plan using its ID to understand project status and metrics.

Instructions

Get a comprehensive summary with statistics

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
plan_idYesPlan ID

Implementation Reference

  • src/tools.js:417-427 (registration)
    Registers the get_plan_summary tool in the list of available tools, including its name, description, and input schema.
    {
      name: "get_plan_summary",
      description: "Get a comprehensive summary with statistics",
      inputSchema: {
        type: "object",
        properties: {
          plan_id: { type: "string", description: "Plan ID" }
        },
        required: ["plan_id"]
      }
    }
  • The main execution handler for the get_plan_summary tool. Fetches the plan and its nodes via apiClient, computes statistics using the calculatePlanStatistics helper, calculates progress percentage, and returns a formatted response.
    if (name === "get_plan_summary") {
      const { plan_id } = args;
      
      const plan = await apiClient.plans.getPlan(plan_id);
      const nodes = await apiClient.nodes.getNodes(plan_id);
      
      // Calculate statistics
      const stats = calculatePlanStatistics(nodes);
      
      return formatResponse({
        plan: {
          id: plan.id,
          title: plan.title,
          status: plan.status,
          description: plan.description,
          created_at: plan.created_at,
          updated_at: plan.updated_at
        },
        statistics: stats,
        progress_percentage: stats.total > 0 
          ? ((stats.status_counts.completed / stats.total) * 100).toFixed(1)
          : 0
      });
    }
  • Helper function specifically used by get_plan_summary to recursively traverse the plan's node hierarchy and compute comprehensive statistics including total nodes, counts by type and status, and lists of in-progress and blocked nodes.
    function calculatePlanStatistics(nodes) {
      const stats = {
        total: 0,
        type_counts: {
          root: 0,
          phase: 0,
          task: 0,
          milestone: 0
        },
        status_counts: {
          not_started: 0,
          in_progress: 0,
          completed: 0,
          blocked: 0
        },
        in_progress_nodes: [],
        blocked_nodes: []
      };
      
      const processNode = (node) => {
        stats.total++;
        
        if (node.node_type && stats.type_counts[node.node_type] !== undefined) {
          stats.type_counts[node.node_type]++;
        }
        
        if (node.status && stats.status_counts[node.status] !== undefined) {
          stats.status_counts[node.status]++;
          
          if (node.status === 'in_progress') {
            stats.in_progress_nodes.push({
              id: node.id,
              title: node.title,
              type: node.node_type
            });
          } else if (node.status === 'blocked') {
            stats.blocked_nodes.push({
              id: node.id,
              title: node.title,
              type: node.node_type
            });
          }
        }
        
        if (node.children && node.children.length > 0) {
          node.children.forEach(processNode);
        }
      };
      
      nodes.forEach(processNode);
      
      return stats;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. While 'Get' implies a read operation, the description doesn't specify whether this requires authentication, what format the summary returns, whether there are rate limits, or what happens with invalid plan IDs. The phrase 'comprehensive summary' is vague about scope and completeness.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence without unnecessary words. However, it's arguably too concise - it could benefit from slightly more specificity about what 'comprehensive summary' and 'statistics' mean in this context. The structure is straightforward but lacks front-loading of critical information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no annotations, no output schema, and multiple sibling tools, the description is inadequate. It doesn't explain what the tool returns, how it differs from other plan-related tools, or provide enough context for an agent to understand when and how to use it effectively. The vagueness of 'comprehensive summary with statistics' leaves too much unspecified.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100% (the single parameter 'plan_id' has a description), so the baseline is 3. The tool description adds no additional parameter information beyond what's already in the schema. It doesn't explain what constitutes a valid plan ID, where to find it, or provide examples.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Get a comprehensive summary with statistics' states the basic purpose (retrieving a summary) but is vague about what specifically is summarized. It mentions 'statistics' but doesn't specify what kind of statistics or what resource is being summarized. It doesn't clearly distinguish this from sibling tools like 'get_plan_structure' or 'list_plans'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. With sibling tools like 'get_plan_structure', 'list_plans', and 'get_node_context', there's no indication of when a 'summary with statistics' is appropriate versus when other plan-related tools should be used. No prerequisites or exclusions are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/TAgents/agent-planner-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server