Skip to main content
Glama

update_session_summary

Append current session information to the summary file without closing the session, enabling ongoing documentation of work progress.

Instructions

Update the session summary file with current session info without doing a full session close.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
summaryYesSession summary text to append to session-summary.md

Implementation Reference

  • Main tool handler for 'update_session_summary' that constructs a SessionSummary object (ignoring input args) and delegates to SessionCloser.updateSessionSummary()
    case 'update_session_summary': {
      const summary = {
        timestamp: new Date().toISOString(),
        accomplishments: [],
        decisions: [],
        blockers: [],
        nextSteps: [],
        filesChanged: [],
      };
      
      await (this.sessionCloser as any).updateSessionSummary(summary);
    
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify({
              success: true,
              message: 'Session summary updated!',
            }),
          },
        ],
      };
    }
  • Core implementation of session summary update: appends formatted session entry to .agent-os/session-summary.md file
    private async updateSessionSummary(summary: SessionSummary): Promise<void> {
      const summaryPath = path.join(this.projectRoot, '.agent-os', 'session-summary.md');
      
      // Ensure directory exists
      await fs.mkdir(path.dirname(summaryPath), { recursive: true });
    
      let existingContent = '';
      try {
        existingContent = await fs.readFile(summaryPath, 'utf-8');
      } catch {
        // File doesn't exist, create it
        existingContent = '# Session Summary\n\n';
      }
    
      const sessionEntry = this.formatSessionEntry(summary);
      const updatedContent = existingContent + '\n' + sessionEntry;
    
      await fs.writeFile(summaryPath, updatedContent, 'utf-8');
    }
  • src/index.ts:85-98 (registration)
    Tool registration in ListToolsRequest handler, including name, description, and JSON input schema
    {
      name: 'update_session_summary',
      description: 'Update the session summary file with current session info without doing a full session close.',
      inputSchema: {
        type: 'object',
        properties: {
          summary: {
            type: 'string',
            description: 'Session summary text to append to session-summary.md',
          },
        },
        required: ['summary'],
      },
    },
  • TypeScript interface defining the SessionSummary structure used by the updateSessionSummary method
    export interface SessionSummary {
      timestamp: string;
      accomplishments: string[];
      decisions: Decision[];
      blockers: string[];
      nextSteps: string[];
      filesChanged: string[];
    }
Behavior2/5

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

With no annotations provided, the description carries full burden. It states the tool updates a file, implying mutation, but doesn't disclose important behavioral traits like whether this requires specific permissions, how conflicts are handled, if changes are reversible, or what happens to existing content. The 'append' behavior is only hinted at in the parameter description, not in the main description.

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 that front-loads the core purpose. It could be slightly more structured by explicitly mentioning the append behavior, but it avoids unnecessary elaboration.

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 mutation tool with no annotations and no output schema, the description is insufficient. It doesn't explain what 'update' entails (e.g., append vs. replace), what the session-summary.md file is, or what the tool returns. The context of 'current session info' is vague without elaboration.

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?

Schema description coverage is 100%, with the single parameter 'summary' well-documented in the schema. The description doesn't add any parameter semantics beyond what the schema provides, maintaining the baseline score of 3 for high schema coverage.

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

Purpose4/5

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

The description clearly states the action ('update') and resource ('session summary file') with specific context ('without doing a full session close'). It distinguishes from 'end_session' by specifying partial vs. full closure, but doesn't explicitly differentiate from 'sync_context_files'.

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

Usage Guidelines3/5

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

The description implies usage context ('without doing a full session close'), suggesting this is for incremental updates during an active session rather than final closure. However, it doesn't provide explicit guidance on when to choose this over 'sync_context_files' or what triggers its use.

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/Tylarcam/mcp-session-closer'

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