generate-slides

A command for creating slide decks as standalone HTML pages, with vertical or magazine-style horizontal layouts.

In plain words
What is it for?
Use it to generate visual presentations from slide-deck content and export them as HTML files.
Why use it?
It turns slide content into a viewable HTML presentation while keeping an editable MDX or TSX source for revisions.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/theclaymethod/artifacture/generate-slides
Clone the repo
git clone --depth 1 https://github.com/theclaymethod/artifacture
Per session 23 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,534 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00023 $0.01534
Opus 5 $0.00012 $0.00767
Sonnet 5 $0.00005 $0.00307
Haiku 4.5 $0.00002 $0.00153

Measured 2d ago against content hash ddb80a98d0a4, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

generate-slides scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/visual-explainer/commands/generate-slides.md · 58 lines

How it starts

The opening of the file, as written. The whole thing — 58 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Read cards/slide-deck.md.

Load the visual-explainer skill, then generate a slide deck for: $@

Authoring contract. Prefer the MDX/React pipeline. Write the editable source as .mdx by default, or .tsx when the deck needs heavier state, custom generated SVG, or bespoke interaction. Use shared components from visual-explainer-mdx/components.tsx, especially SlideDeck and Slide, and export the generated standalone HTML with:

npm run ve:export -- <source.mdx> --out ~/.agent/diagrams/<slug>.html

The generated HTML is the artifact, not the source of truth. If a revision is needed, edit the MDX/TSX source and re-export. The legacy HTML templates below are reference material for layout, pacing, and aesthetic conventions; do not hand-write final HTML unless the MDX/React path is blocked and you explicitly report that fallback.

Follow the visual-explainer skill workflow and the card. Escalate to ./references/slide-patterns.md only for custom deck mechanics, magazine-specific pacing, or poster/PDF export details; use ./references/legacy-html.md only if the MDX/React deck path is blocked.

Slide output is always opt-in. Only generate slides when this command is invoked or the user explicitly asks for a slide deck or magazine.

Orientation — vertical vs horizontal (magazine). Slides can be authored in two orientations:

  • Vertical (default) — scroll-snap-type: y mandatory. Each slide is 100dvh. Deck feels like a presentation. Good for plans, reviews, recaps, any sequence where the user progresses one slide at a time.
  • Horizontal (--magazine) — scroll-snap-type: x mandatory. Each page is 100vw × 100vh. Deck feels like a print zine. Good for editorial narratives, brand pieces, year-in-review content, longer 12–30 page arcs. Nav dots at bottom, arrow-key + swipe support, dark cover + dark back cover + ≥ 1 interior dark panel, different tint per interior page (tint ramp adapts to active aesthetic — see ./references/diagram-tokens.md), at least one full-bleed stat page with 100px+ anchor.

If the user hasn't specified and the content is ambiguous (could work as either), ask via AskUserQuestion: "Vertical slide deck, horizontal magazine, or video (MP4)?" See ./references/clarify.md for the tiered ask policy — slides are a high-cost command and benefit from confirmation.

Aesthetic. Pick from the 4 slide presets in slide-patterns.md (Midnight Editorial, Warm Signal, Terminal Mono, Swiss Clean) or use the default OA Design. Read references/oa-design.md, then commit to one direction and carry it through every slide.

Narrative structure. Slides have a temporal dimension — compose a story arc, not a list of sections. Start with impact (title/cover), build context, deep dive (content, diagrams, data), resolve (summary/next steps/back cover). Plan the sequence and assign a layout per slide before writing HTML.

Visual richness. Proactively reach for visuals. If surf CLI is available (which surf), generate images for title/cover backgrounds and full-bleed pages via surf gemini --generate-image. Add SVG decorative accents, inline sparklines, mini-charts, and small diagrams (use inline SVG per ./references/diagrams-svg.md, or Mermaid as fallback). Visual-first, text-second.

Compositional variety. Consecutive slides must vary their spatial approach — centered, left-heavy, right-heavy, split, edge-aligned, full-bleed, quadrant, grid. Three centered slides in a row means push one off-axis. For magazine mode specifically: dark panels interrupt tint rotation; full-bleed stat pages land roughly every 4–6 pages, never back-to-back.

Magazine-specific rules (when --magazine is passed).

  • Use the MDX/React deck primitive with <SlideDeck orientation="horizontal"> unless a blocker forces a reported fallback.
  • Cover page is dark. Back cover is dark. At least one interior dark panel (≥ 3 dark pages total).
  • Every interior page uses a different tint from the active aesthetic's tint ramp; never repeat consecutively.
  • At least one full-bleed stat page with the primary number rendered at 100px+ (clamp(160px, 22vw, 360px)).
  • Layouts available: title cover, content, split (left/right color-block), quadrant (2×2), full-bleed stat, dark panel, color block, viewport-filling grid (3×2 or 4×3).
  • Nav chrome: dot strip at bottom, arrow-key support, page counter top-right.
  • The horizontal-snap engine replaces the vertical engine — don't mix.

Read the full file on GitHub · 58 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 58 lines · 23 tokens per session scan A ddb80a98d0a4

Subscribe to this mod's changes

generate-slides is a command published in the GitHub repository theclaymethod/artifacture (2 stars, last pushed 9d ago), licensed MIT. It adds 23 tokens to every session and 1,534 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.