Skip to main content
Glama

set_theme

Changes the theme of a Slidev presentation by updating global frontmatter and optionally installing the theme package. Use a dry run to preview slides.md and package.json diffs before applying.

Instructions

Change the theme of the current Slidev presentation. Updates the global frontmatter and optionally installs the theme package. Supports all built-in Slidev themes (default, seriph, apple-basic, etc.) and community themes. Set dry_run=true to preview slides.md/package.json diffs without writing or running pnpm install.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "set_theme"
  }
}

Input Schema

NameRequiredDescriptionDefault
themeNoTheme name to apply. Can be a built-in Slidev theme (e.g. 'default', 'seriph', 'apple-basic') or any published package name (e.g. 'slidev-theme-eloc'). Built-in themes are prefixed automatically: 'seriph' → '@slidev/theme-seriph'. Pass a full package name (starting with '@' or 'slidev-theme-') to use community themes. If omitted, defaults to 'seriph'.seriph
dry_runNoPreview the theme change without writing slides.md or package.json and without running pnpm install. Returns dryRun, wouldWrite, diffs, and install metadata.
installNoWhether to run pnpm install to install the theme package. Defaults to true. Set to false if you know the theme is already installed.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations supplied, the description carries the full burden and does well: it discloses that the tool writes to slides.md frontmatter and package.json and may run pnpm install, plus that dry_run avoids both writes and install. It does not mention reversibility, failure modes, or validation of unknown theme names, which keeps it from a 5.

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?

Four short sentences, front-loaded with the action and side effects before the options. Slightly redundant with the schema on theme names and dry_run, but every sentence carries relevant information with no filler.

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

Completeness4/5

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

For a mutating tool with no annotations and no output schema, the description covers the essential behavior: what is modified, that a package install may run, and how to preview safely. What remains unstated (reversibility, error handling for invalid themes, effect on existing theme config) is minor for this operation.

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 fully documents theme naming rules, dry_run behavior, and install defaults. The description only echoes that built-in and community themes are supported and that dry_run previews diffs, adding little beyond the structured fields; baseline 3 applies.

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

Purpose5/5

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

States a specific verb and resource ('Change the theme of the current Slidev presentation') and immediately clarifies the mechanism (global frontmatter update plus optional package install). This is clearly distinguishable from sibling settings tools such as set_style or set_slide_transition without opening any schema.

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

Usage Guidelines4/5

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

Gives concrete conditional guidance: use dry_run=true to preview diffs, and install=false when the package is already present. It stops short of explicit routing against siblings (e.g. set_style vs set_theme) or stating when not to use it, so it is clear context rather than full when/when-not guidance.

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