Install
$ agentstack add skill-kama34-kama-skills-slidegen ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ● Filesystem access Used
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Slidegen — AI Image Presentation Generator
You generate complete presentations as AI-generated images from slide outlines. Every generation produces a set of PNG slides and an assembled PDF, with consistent visual style across all slides.
References
Before generating, internalize these references:
references/providers.md— CRITICAL: Provider API configs (endpoints, request formats, auth, async handling)references/image-prompt-guide.md— CRITICAL: How to compose effective prompts for image generation modelsreferences/scoring-subroutine.md— Slide scoring (1-10 on 6 axes), used by --polish, --learn, --comparereferences/content-review-subroutine.md— Content quality checks (3-second test, narrative flow, redundancy, CTA clarity, hierarchy)references/polish-procedure.md—--polish=Niterative improvement cyclereferences/ab-testing.md— A/B variant generation for weak slides (used by --polish)references/design-memory.md— Design pattern memory (read/write protocol)references/compare-procedure.md—--compareside-by-side scoringreferences/notes-procedure.md—--notesspeaker notes generationreferences/preset-format.md— Prompt-template preset specification
Input Parsing
Parse the user's input to determine the subcommand or mode.
Global Flags (can combine with any mode)
--provider— API provider:polza(default),openai,custom--model— Model ID (default:google/gemini-3.1-flash-image-previewfor Polza)--no-ref— Disable reference-based style consistency (generate each slide independently)--base-url— Custom provider endpoint URL--api-key-env— Environment variable name for the API key--resolution— Image resolution (Polza only, default:1K). Higher = better quality but slower and more expensive (1K≈4.8₽, 2K≈7.2₽, 4K≈10.8₽ per slide)--quality— Image quality (OpenAI only, default:high)--format— Output image format (Polza only, default:jpeg)--size— Output image dimensions (OpenAI only, default:1792x1024). Supported:1024x1024,1536x1024,1024x1536,1792x1024,1024x1792
Subcommands (handle before anything else)
--help: Display usage help and stop. Show:
Slidegen — AI Image Presentation Generator
Usage:
/slidegen Generate with unique design
/slidegen --preset Generate with preset style
/slidegen style: Generate with custom style
/slidegen --edit [dir] Edit existing presentation
/slidegen --polish=N [dir] Iterative quality improvement (N cycles)
/slidegen --compare Compare two presentations
/slidegen --notes [dir] Generate speaker notes
/slidegen --learn=N Self-improving loop (N cycles)
/slidegen --create-preset Create a new preset
/slidegen --export pdf [dir] Reassemble PDF from PNGs
/slidegen --help Show this help
Provider flags (combinable with any mode):
--provider polza (default), openai, custom
--model Model ID for the provider
--no-ref Generate without style references
--base-url Custom provider endpoint
--api-key-env API key env variable name
Image quality flags:
--resolution Image resolution (Polza, default: 1K)
--quality Image quality (OpenAI, default: high)
--format Output format (Polza, default: jpeg)
--size Image dimensions (OpenAI, default: 1792x1024)
--create-preset : Interactive preset creation wizard.
- Extract preset name from arguments. If missing, ask for one (kebab-case).
- Ask 7 questions ONE AT A TIME, waiting for each answer:
- Mood: "What mood? (professional, playful, dramatic, calm, futuristic, elegant, bold)"
- Color scheme: "Light or dark? (dark, light, deep navy, warm cream...)"
- Accent color: "Accent color? (#ff6b35, electric blue, warm coral...)"
- Typography: "Font personality? (geometric & modern, classic & refined, rounded & friendly, sharp & technical)"
- Density: "Content density? (minimal with whitespace, balanced, information-dense)"
- Textures: "Background textures? (gradient mesh, geometric patterns, clean flat, frosted glass, subtle noise)"
- Save location: "Save preset globally or locally? (global: ~/.claude/slidegen-presets/, local: ./.slidegen-presets/)"
- Synthesize answers into a prompt template with concrete visual parameters: specific colors (hex values), typography mood, background treatment, decoration style. The template MUST include
{{SLIDE_CONTENT}}and{{SLIDE_ROLE}}placeholders. - Based on save location answer:
- Global: Create
~/.claude/slidegen-presets/if needed, write.preset.mdthere - Local: Create
./.slidegen-presets/in the current working directory if needed, write.preset.mdthere
Write per references/preset-format.md.
- Generate demo presentation using
assets/demo-outline.mdwith that preset. - QA — Run the QA procedure. Print score report. If overall average score `).
Stop here — do not proceed to generation.
--learn=N: Self-improving learning loop. Parse N from the argument (e.g., --learn=5). Default N=3, max N=10.
- Generate a presentation from
assets/demo-outline.mdusing current design approach. - Run Scoring Subroutine → score-report.md.
- Analyze: which axes scored lowest? What prompt patterns produced weak results?
- Adjust approach: modify prompt construction strategy based on analysis.
- Regenerate with adjusted approach.
- Write Design Memory entry using the write protocol in
references/design-memory.md. - Print iteration summary: score delta, what changed, what improved.
- Repeat from step 2 until N iterations complete or overall avg >= 9.
Stop here — do not proceed to generation.
--polish=N [dir]: Iterative design improvement cycle. Follow the Polish Procedure in references/polish-procedure.md. Stop here — do not proceed to generation.
--compare : Compare two presentations side-by-side with scoring. Follow the Compare Procedure in references/compare-procedure.md. Stop here — do not proceed to generation.
--notes [dir]: Generate speaker notes for the presentation. Follow the Notes Procedure in references/notes-procedure.md. Stop here — do not proceed to generation.
--edit [dir] : Edit an existing presentation based on a free-text comment.
- Resolve project directory (see Directory Auto-Detection below).
- Load state: read
prompts.jsonandmeta.jsonfrom the project directory. - List slides: print a numbered list of all slides with their roles and prompt summaries (first 50 chars of each prompt).
- Identify affected slides: Claude analyzes the comment to determine which slides need changes. If ambiguous (e.g., "make it more modern"), ask user to confirm slide numbers.
- Modify prompts: update the affected prompts in
prompts.jsonbased on the comment. Preserve the style suffix and unaffected parts of the prompt. - Regenerate: regenerate only the affected slides using the API. Use the style anchor from
meta.jsonas reference (unless--no-refor the anchor itself is being regenerated). - QA: run scoring on regenerated slides only. If any score ` to create one."
Generation Modes
After subcommands are handled, determine the generation mode:
- Preset mode —
--preset: Load preset fromreferences/preset-format.mdlookup order. Use the preset's prompt template for all slides. - Custom Style mode —
style:: User provides a free-text style description. Convert to a style suffix appended to every prompt. - Unique mode (default) — No style specified: Claude designs a unique visual direction for this presentation. Consult Design Memory (
references/design-memory.md) for inspiration and avoidance patterns.
Generation Procedure
Step 1: Resolve Provider, API Key, and Image Settings
Follow references/providers.md to resolve the provider, model, endpoint, and API key based on flags or defaults.
Resolve image quality settings based on provider:
- Polza:
image_resolutionfrom--resolution(default1K),output_formatfrom--format(defaultjpeg) - OpenAI:
qualityfrom--quality(defaulthigh),sizefrom--size(default1792x1024) - Custom: same as Polza (Polza-compatible format)
If the API key environment variable is not set, print error and stop:
Error: API key not found.
For Polza (default provider):
1. Register at https://polza.ai?referral=dA0vnQPKuQ
2. Generate an API key in your dashboard
3. Set the environment variable:
export POLZA_API_KEY=your-key
For other providers:
OpenAI: export OPENAI_API_KEY=your-key
Custom: export CUSTOM_API_KEY=your-key (or use --api-key-env=YOUR_VAR)
Step 2: Read Design Memory
If generating in Unique or Custom Style mode, read Design Memory (references/design-memory.md read protocol):
- Draw inspiration from "success" entries (don't copy — extract principles)
- Avoid patterns from "failure" entries
- Skip silently if memory file doesn't exist
Step 3: Design Thinking
Determine the visual direction for the presentation. This is where Claude makes creative decisions.
In Preset mode: Use the preset's frontmatter parameters (mood, palette, typography, decoration) as the style direction. Skip creative decisions.
In Custom Style mode: Parse the user's style description into concrete visual parameters.
In Unique mode: Design a bold, distinctive visual direction:
- Palette: Choose 3-5 colors with a dominant + accent hierarchy. Use specific hex values.
- Typography mood: Describe the feeling (geometric modern, classic refined, etc.)
- Background treatment: Gradients, textures, patterns, solid — be specific.
- Decorative elements: Lines, shapes, icons, overlays, borders.
- Composition approach: How content is arranged (centered, asymmetric, grid, etc.)
Document the visual direction as a style suffix — a paragraph of English text that will be appended to every slide prompt for baseline consistency. Example:
> "Style: Dark navy background (#1a1a2e) with subtle gradient to deep purple. Clean geometric sans-serif typography, white headings (48pt equivalent), light gray body text (24pt equivalent). Electric blue (#0066ff) accent for highlights. Thin horizontal line separators. Rounded rectangle cards with subtle shadow. 16:9 aspect ratio."
Step 4: Plan Slides (Phase 1 — Planning)
For each slide in the outline, generate:
- Role — one of:
cover,section,content,stat,quote,comparison,end - Text content — the actual text that will appear on the slide:
- Heading (required)
- Subheading (optional)
- Body text / bullets / key points (optional)
- Figures / metrics (optional)
- Visual description — slide-specific visual notes beyond the style suffix:
- Layout composition (centered, left-aligned, split, etc.)
- Special elements (charts, diagrams, icons)
- Emphasis / focal point
- Final prompt — combine all of the above into a single English prompt for the image API. Follow
references/image-prompt-guide.mdfor prompt composition best practices.
CRITICAL: The prompt MUST include:
- Explicit text content (every word that should appear on the slide)
- Typography instructions (font sizes, weights, alignment)
- The style suffix (appended at the end)
- Aspect ratio instruction: "16:9 aspect ratio presentation slide"
- Slide role description (see rule 11 in Slide Prompt Authoring Rules below)
Before proceeding to Step 5: run prompt review (Step 6a) — verify each prompt is detailed enough, contains the style suffix, has the role description, and has no contradictions. Fix any issues before generating images.
Save all prompts to prompts.json:
{
"slides": [
{
"index": 1,
"role": "cover",
"heading": "Title Text",
"subheading": "Subtitle",
"body": null,
"prompt": "Full prompt text...",
"style_suffix": "Style: Dark navy..."
}
],
"style_suffix": "Style: Dark navy...",
"generation_mode": "unique"
}
Step 5: Generate Images (Phase 2 — Generation)
Output directory naming: derive from the outline topic. Slugify the topic to kebab-case, e.g., "AI in Healthcare" → ai-in-healthcare/. If the directory already exists, append a timestamp: ai-in-healthcare-1710400000/.
Create the output directory: mkdir -p /slides
Determine the generation mode:
- If slide count /slides/slide-01.png`. Print: "Generated slide 1/"
- Generate slide 2 — call the provider API with the slide 2 prompt, no reference images. Save to
/slides/slide-02.png. Print: "Generated slide 2/" - Select style anchor — read both PNGs. Score each on the anchor selection rubric:
| Criterion (1-5) | Description | |---|---| | Layout density | Multiple content elements vs single centered title | | Background complexity | Represents intended visual style | | Decorative elements | Contains representative decorative details | | Typography variety | Shows heading + body text styles |
Higher total score wins. Tie → slide 2 wins. Record anchor index in meta.json.
- Regenerate the non-anchor slide — the slide that lost anchor selection was generated without a style reference and is likely stylistically inconsistent. CRITICAL: regenerate the losing slide using the winning anchor as reference image. Replace the old PNG. This ensures ALL slides in the deck share the same visual foundation.
- Generate slides 3..N — for each remaining slide:
- Read the style anchor PNG as base64
- Call the provider API with the slide prompt + anchor image as reference
- Save to
/slides/slide-NN.png - Print: "Generated slide N/"
- Handle async responses per
references/providers.md
No-reference mode:
Generate all slides sequentially without reference images. Print progress after each.
Error handling during generation:
- Per-slide timeout (120 seconds): print warning, skip slide, continue
- Rate limit (429): exponential backoff — 5s, 10s, 20s (max 3 retries)
- At the end: report any skipped slides, suggest
--editto regenerate them
Save meta.json:
{
"provider": "polza",
"model": "google/gemini-3.1-flash-image-preview",
"mode": "reference",
"style_anchor": 2,
"aspect_ratio": "16:9",
"resolution": "1K",
"format": "jpeg",
"created": "2026-03-14T12:00:00Z",
"slide_count": 10
}
Step 6: Quality Assurance (Phase 3 — QA)
6a. Prompt Review (IMPORTANT: this check runs during Step 4, before generation begins):
- Is each prompt detailed enough? (minimum: text content + layout + style suffix)
- Does every prompt contain the style suffix?
- Are there contradictions between the prompt and style suffix?
- Fix any issues before sending to the API.
6b. Visual Review (after generation): Read EVERY generated PNG. For each slide, run these concrete checks:
- Language & Script Verification — CRITICAL gate, check FIRST:
- Detect the expected language from the outline (e.g., Russian → Cyrillic, Chinese → CJK, etc.)
- For each slide, verify that ALL visible text is rendered in the correct script
- FAIL criteria (any one triggers mandatory regeneration):
- Latin characters where Cyrillic/CJK/Arabic should be (transliteration)
- Garbled/nonsensical characters (model failed to render the script)
- Mixed scripts where outline sp
…
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: kama34
- Source: kama34/kama-skills
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.