Skip to main content
Glama
supercurses

Powerpoint MCP Server

by supercurses

add-slide-section-header

Add a section header slide to organize PowerPoint presentations into clear segments with titles and optional subtitles.

Instructions

This tool adds a section header (a.k.a segue) slide to the presentation you are working on. The tool doesn't return anything. It requires the presentation_name to work on.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
presentation_nameYesName of the presentation to add the slide to
headerYesSection header title
subtitleNoSection header subtitle

Implementation Reference

  • The core handler function that adds a section header slide to the presentation. It retrieves the presentation, uses slide layout 2 (SLIDE_LAYOUT_SECTION_HEADER), sets the header as title, and optional subtitle.
    def add_section_header_slide(self, presentation_name: str, header: str, subtitle: str):
        """
        Create a section header slide for the given presentation
    
        Args:
            presentation_name: The presentation to add the slide to
            header: The section header to use
            subtitle: The subtitle of the section header to use
        """
        try:
            prs = self.presentations[presentation_name]
        except KeyError as e:
            raise ValueError(f"Presentation '{presentation_name}' not found")
        slide_master = prs.slide_master
    
        # Add a new slide with layout
        slide_layout = prs.slide_layouts[self.SLIDE_LAYOUT_SECTION_HEADER]
        slide = prs.slides.add_slide(slide_layout)
    
        # Set the subtitle
        if subtitle:
            subtitle_shape = slide.placeholders[1]
            text_frame = subtitle_shape.text_frame
            text_frame.text = subtitle
    
        # Set the section header
        if header:
            header_shape = slide.shapes.title
            header_shape.text = header
    
        return slide
  • Tool registration in the list_tools handler, including name, description, and input schema.
    types.Tool(
        name="add-slide-section-header",
        description="This tool adds a section header (a.k.a segue) slide to the presentation you are working on. The tool doesn't "
                    "return anything. It requires the presentation_name to work on.",
        inputSchema={
            "type": "object",
            "properties": {
                "presentation_name": {
                    "type": "string",
                    "description": "Name of the presentation to add the slide to",
                },
                "header": {
                    "type": "string",
                    "description": "Section header title",
                },
                "subtitle": {
                    "type": "string",
                    "description": "Section header subtitle",
                }
    
            },
            "required": ["presentation_name", "header"],
        },
    ),
  • Dispatch handler in call_tool that validates arguments and delegates to PresentationManager.add_section_header_slide.
    elif name == "add-slide-section-header":
        presentation_name = arguments.get("presentation_name")
        header = arguments.get("header")
        subtitle = arguments.get("subtitle")
    
        if not all([presentation_name, header]):
            raise ValueError("Missing required arguments")
    
        if presentation_name not in presentation_manager.presentations:
            raise ValueError(f"Presentation not found: {presentation_name}")
    
        try:
            slide = presentation_manager.add_section_header_slide(presentation_name, header, subtitle)
        except Exception as e:
            raise ValueError(f"Unable to add slide '{header}' to presentation: {presentation_name}")
    
        return [
            types.TextContent(
                type="text",
                text=f"Added slide '{header}' to presentation: {presentation_name}"
            )
        ]

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

C2.9/5.0
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. It states 'The tool doesn't return anything,' which is useful for setting expectations, and implies a mutation ('adds'). However, it lacks critical details like whether this requires specific permissions, if changes are reversible, or potential side effects (e.g., affecting other slides). For a mutation tool with zero annotation coverage, this is inadequate.

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 appropriately sized with two sentences that are front-loaded: the first states the purpose, and the second covers behavioral and prerequisite info. There's minimal waste, though the phrase 'a.k.a segue' could be slightly redundant. Overall, it's efficient and well-structured.

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?

Given the tool's complexity (a mutation with 3 parameters), lack of annotations, and no output schema, the description is incomplete. It covers the basic action and non-return behavior but misses critical context like error handling, what 'adds' entails (e.g., insertion position), or how it interacts with sibling tools. This leaves significant gaps for an AI agent.

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%, so the schema already documents all parameters (header, presentation_name, subtitle) with clear descriptions. The description adds no additional meaning beyond what the schema provides, such as formatting examples or constraints. Baseline 3 is appropriate when the schema does the heavy lifting.

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 verb ('adds') and resource ('section header slide to the presentation'), making the purpose specific and understandable. However, it doesn't explicitly differentiate this tool from its siblings (e.g., 'add-slide-title-content'), which would require a 5. The mention of 'section header (a.k.a segue)' adds helpful context but not sibling differentiation.

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 minimal guidance by stating 'requires the presentation_name to work on,' which is a prerequisite but not usage context. It lacks explicit when-to-use instructions, alternatives (e.g., vs. other add-slide-* tools), or exclusions, leaving the agent with no clear direction on when this tool is appropriate versus others.

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