Skip to content
Back to skills

Figures Gallery

ASecurity

Generates an HTML gallery of all project figures with captions and source notebooks. Use when reviewing figures.

  • 5,142 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 3, 2026
researchbashgit

Security analysis

A100/100

Scanned September 3, 2026

npx -y skills add brycewang-stanford/Auto-Empirical-Research-Skills --skill figures-gallery --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Figures Gallery?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Figures Gallery
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/brycewang-stanford-figures-gallery/badge)](https://www.skillsdirectory.com/skills/brycewang-stanford-figures-gallery)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: figures-gallery
description: Generates an HTML gallery of all project figures with captions and source notebooks. Use when reviewing figures.
allowed-tools: Bash, Read, Write, Glob, Grep
---

# Generate Figures Gallery

Create an HTML gallery page displaying all project figures with their captions and source notebooks.

## Steps

1. Scan `images/` for all image files:
   - Supported formats: `.png`, `.jpg`, `.jpeg`, `.svg`, `.pdf`
   - Record each file's name, path, and modification date

2. Scan all registered notebooks (from `_quarto.yml`) for cells with `fig-` labels:
   - Extract the cell label (e.g., `fig-sample`, `fig-event-study`)
   - Extract the caption from `#| fig-cap:` or `*| fig-cap:` directives
   - Record the source notebook path

3. Generate an HTML gallery page with:
   - A title and generation timestamp
   - For each figure from `images/`:
     - Image thumbnail (or placeholder for PDFs)
     - Filename as caption
     - File size and dimensions (if determinable)
   - For each figure from notebooks:
     - The cell label
     - The caption (from cell directive)
     - The source notebook name
     - The embed shortcode: `{{< embed notebooks/<name>.ipynb#<label> >}}`
   - Simple CSS styling for a grid layout

4. Save the gallery to `_manuscript/figures-gallery.html` (the `_manuscript/` directory is gitignored, so this output won't be committed).

5. Report:
   - File path to the gallery
   - Count of figures from `images/`
   - Count of figure cells from notebooks
   - Command to open: `open _manuscript/figures-gallery.html`

## Error handling

- If `images/` does not exist or is empty, note it and continue with notebook figures.
- If no notebooks have `fig-` labeled cells, note it and continue with `images/` files.
- If both sources are empty, report "No figures found in the project."

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in research →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.