slides-generator
Create Hummingbot-branded PDF slides from markdown with Mermaid diagram support. Use for presentations, decks, and technical documentation with professional diagrams.
By hummingbot · 358 installs
npx skills add hummingbot/skills --skill slides-generator
Source repository · Upstream listing
slides generator
Create Hummingbot branded presentation slides in PDF format from markdown content. Features two column layouts and Mermaid diagram rendering for technical architecture and flowcharts.
Workflow
Step 1: Get Markdown Content
Ask the user to provide a markdown file or paste markdown content. The content should follow this format:
Format Rules:
Title = Presentation title (optional, becomes title slide)
N. Slide Title = New slide (N is slide number)
Content under each heading becomes slide content
Supports markdown formatting: lists, bold, italic, code blocks, links
Step 2: Parse and Confirm
Before generating the PDF, parse the markdown and show the user a summary:
Wait for user confirmation before proceeding.
Step 3: Generate PDF
Run the generation script:
Or if the user provided inline content, save it to a temp file first:
Step 4: Deliver Result
After generation, tell the user:
The PDF file location
How many slides were generated
Offer to open/view the PDF if desired
Editing Existing Slides
If the user wants to edit slides from a previously generated PDF:
1. Read the original markdown (if available) or view the PDF to understand current content
2. Ask the user what changes they want:
Edit specific slide content
Add new slides
Remove slides
Reorder slides
3. Apply changes to the markdown
4. Regenerate the PDF
Use the edit flag to update specific slides without regenerating all:
Diagrams
Users can describe diagrams in natural language using mermaid: syntax. You must translate these descriptions to Mermaid code before generating the PDF.
User Input Format
Users write descriptions like:
Translation to Mermaid
Convert the description to proper Mermaid syntax:
Diagram Types
flowchart TD Top down flowchart
flowchart LR Left right flowchart
sequenceDiagram API and interaction flows
classDiagram Object oriented design
erDiagram Database schemas
Highlighting
Use style NodeName fill: 00D084,color: fff for Hummingbot green highlighting.
Requirements
Mermaid diagrams require the Mermaid CLI:
Code Blocks
Use regular \ \ \ code blocks for ASCII art, code snippets, or preformatted text:
Code blocks render with monospace font on a gray background.
Two Column Layout
When a slide has both bullet points AND a diagram, it automatically renders in two columns:
Left column: Text content
Right column: Diagram
After translation:
Example Markdown
After translating mermaid: descriptions:
Dependencies
The script will check for and install if needed:
Python 3
fpdf2 Python package (for PDF generation)
Troubleshooting
Issue Solution
"Python not found" Install Python 3: brew install python3 (macOS) or apt install python3 (Linux)
"fpdf2 not installed" Run: pip3 install fpdf2
"Permission denied" Check write permissions for output directory
"Empty PDF" Verify markdown format follows the N. Title pattern
Scripts
Script Purpose
generate slides.sh Main PDF generation script