create-thumbnail
Skill294 starsChanged 9 days agoApache-2.0View on GitHub
Create, replace, audit, and publish Papers With Code paper thumbnails for one paper or every paper on a benchmark page. Use this whenever a user asks to add a thumbnail, fix an "Untitled resource" card, use artwork from a source/project/GitHub README, regenerate a paper preview, or find papers on a benchmark with missing, generic, stale, or broken thumbnails. This is the repo-specific end-to-end workflow for source selection, portrait composition, cache-safe publication, and live visual verification.
- Reads credentials
We split this skill into the rules it gives an agent
12 rules. About 0 are common, 8 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈8
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Create recognizable paper-card thumbnails from authoritative source material.
- Very specific: line 16
Read docs/database.md before database access.
- Distinctive: line 17
Treat thumbnail publication as a data operation.
- Distinctive: line 20
Keep the audit read-only until the user has requested creation or replacement.
- Distinctive: line 21
Use immutable or content-addressed filenames.
- Distinctive: line 29
Run the bundled read-only audit:
- Very specific: line 48
Do not infer visual quality from HTTP status alone.
- Distinctive: line 58
Verify that the PDF version matches the title displayed in the catalog.
- Distinctive: line 62
Only for papers without an arXiv ID, use this priority order:
- Distinctive: line 70
Prefer a recognizable overview over a dense benchmark chart.
- Very specific: line 110
Do not run the raster compositor for an arXiv paper.
- Very specific: line 112
If pwc thumbnail or the automatic path yields the blank "Untitled resource" card for a non-arXiv PDF (seen with a 32 MB PDF), download the …
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Create paper thumbnails
Create recognizable paper-card thumbnails from authoritative source material. A thumbnail is not complete merely because a URL exists: blank captures and generic “Untitled resource” cards count as missing.
Guardrails
Skill scripts live under .agents/skills/create-thumbnail/ (the canonical, tracked path). .claude/skills/ is a gitignored symlink layer that may be missing in worktrees.
- Work from the repository root and run repository Python with
uv run --env-file backend/keys.env .... - Read
docs/database.mdbefore database access. - Treat thumbnail publication as a data operation. Do not restart services or deploy application code.
- Branch on paper source before choosing an image: arXiv papers use a rendered first page; source/project visuals are only for non-arXiv papers.
- Preserve source artwork faithfully. Do not redraw logos, alter plots, or use generated imagery when an official image or paper page is available.
- Keep the audit read-only until the user has requested creation or replacement.
- Use immutable or content-addressed filenames. A query-string cache marker alone may not bypass the public image proxy.
1. Resolve the scope
For a paper URL, resolve the numeric paper ID and inspect its title, source, source URL, arXiv ID/version, repositories, project pages, Hugging Face artifacts, and current thumbnail_url.
For a benchmark URL, resolve datasets.slug, then collect distinct papers through evaluations.dataset_id. Audit every linked paper, not only external rows.
Run the bundled read-only audit:
uv run --env-file backend/keys.env python \
.agents/skills/create-thumbnail/scripts/audit_thumbnails.py \
--paper 109261
uv run --env-file backend/keys.env python \
.agents/skills/create-thumbnail/scripts/audit_thumbnails.py \
--benchmark tabarena-v0-1The audit distinguishes:
missing_url: the public paper API has no thumbnail URL.broken: the URL does not return an image successfully.review_default_external: an external paper uses the defaultexternal_<id>.jpgfilename. Visually inspect it because it may be a useful PDF render or a generic browser capture.healthy: reachable image; still inspect when the user reports poor content.
Do not infer visual quality from HTTP status alone. Download candidates and use view_image or a montage.
2. Choose the thumbnail source
Choose the source from the paper record before inspecting visual candidates.
ArXiv papers: always render the first page
When the paper has an arXiv ID or source = 'arxiv', use a screenshot/render of the first page of the matching arXiv PDF. Do not substitute a project hero, README image, logo, architecture diagram, model-card image, or generated title card, even when one appears more visually distinctive. The paper page represents the publication, and the first-page convention keeps arXiv-backed cards consistent and verifiable.
Verify that the PDF version matches the title displayed in the catalog. Older arXiv versions can have a different title; use the latest matching version and persist its explicit thumbnail URL when necessary.
Non-arXiv papers: choose authoritative artwork
Only for papers without an arXiv ID, use this priority order:
- A clear hero, architecture diagram, logo, or overview image visibly used by the canonical source page.
- Artwork used in the official project page or official GitHub README.
- Artwork in an explicit Hugging Face model card for the release.
- The first page of an official direct PDF.
- A title card using the real title only when no meaningful artwork or PDF exists.
Prefer a recognizable overview over a dense benchmark chart. Skip artwork wider than about 2:1 (wide pipeline diagrams become unreadable on the portrait card) and use the first page of the PDF instead. Ignore badges, CI shields, unrelated dependencies, citation images, and images from unofficial forks.
For GitHub, inspect both README references and the image assets in the repository tree:
gh api repos/OWNER/REPO/readme -H 'Accept: application/vnd.github.raw' > /tmp/REPO-README.md
rg -n '<img|!\[' /tmp/REPO-README.md
gh api 'repos/OWNER/REPO/git/trees/HEAD?recursive=1' \
--jq '.tree[] | select(.type=="blob") | .path' \
| rg -i '\.(png|jpe?g|webp|svg)$'3. Render the portrait thumbnail
Paper cards expect a 400 px wide portrait JPEG. Source images should remain legible rather than being cropped to fill the frame.
For an official raster image, use the bundled deterministic compositor:
uv run python .agents/skills/create-thumbnail/scripts/compose_thumbnail.py \
--input /tmp/source-art.png \
--output /tmp/paper-thumbnail.jpg \
--title 'OPTIONAL TITLE' \
--background '#f7f5ff,#fff4ef'The compositor:
- produces a 400×550 RGB JPEG;
- contains the full source image without cropping;
- respects alpha transparency;
- uses a restrained background derived from explicit colors;
- adds text only when requested, usually when a logo lacks the paper/model name.
For every arXiv paper, use the existing repository command to render and publish the first page:
uv run --env-file backend/keys.env pwc thumbnail PAPER_REFERENCE --jsonDo not run the raster compositor for an arXiv paper. For a non-arXiv direct PDF, use ThumbnailService._convert_pdf_to_thumbnail on the downloaded PDF, then publish the resulting image through the helper below. Inspect the render before publication.
If pwc thumbnail or the automatic path yields the blank "Untitled resource" card for a non-arXiv PDF (seen with a 32 MB PDF), download the PDF to a local file, render page 1 with ThumbnailService._convert_pdf_to_thumbnail from that local copy, and publish the result with the helper below.
4. Publish without stale-cache collisions
Publish a prepared JPEG with the bundled helper:
uv run --env-file backend/keys.env python \
.agents/skills/create-thumbnail/scripts/publish_thumbnail.py \
--paper-id 109261 \
--image /tmp/paper-thumbnail.jpgThe helper validates the image, names it with a content digest, uploads it through ThumbnailService, updates only the target paper row, and prints JSON. Content-addressed filenames make a changed image a genuinely new URL, avoiding the stale-image behavior seen when only &v= changes.
For the required arXiv first page generated by pwc thumbnail, the command already uploads the image and persists a cache-busted URL. If a newer arXiv version is required than the database row currently names, render that version explicitly and publish it under its matching versioned filename or through the custom helper; do not show a first page whose title contradicts the paper page.
5. Verify live
Verification has three layers:
- Fetch
https://paperswithcode.co/api/v1/papers/<id>and confirm the expectedthumbnail_url. - Fetch the exact public thumbnail URL and confirm HTTP 200,
image/*, JPEG/RGB, width 400, and portrait height. - Download and visually inspect the public response. Inspecting only the local preview can miss stale CDN content.
For benchmark work, rerun the audit and require every linked paper to have a healthy public image. Create a montage of changed thumbnails for a final visual scan.
Reporting
Report:
- the paper or benchmark URL;
- every paper changed;
- the source used for each image (arXiv PDF/version, or README/project/model-card artwork for a non-arXiv paper);
- the final full-benchmark healthy count when applicable;
- any candidate deliberately left unchanged and why.
Include a rendered image or montage when useful. Data-only thumbnail work does not require a git commit or application deployment.
In this repository32 other files it gives its agents.
- AGENTS.mdAGENTS.md
- frontend/public/llms.txtllms.txt
- add-benchmarkSkill
- add-conferenceSkill
- add-evalsSkill
- add-external-paperSkill
- add-methodSkill
- add-taskSkill
- complete-task-based-on-hfSkill
- complete-taskSkill
- complete-task-v2Skill
- create-trendsSkill
- curate-daily-papersSkill
- enrich-paperSkill
- grill-meSkill
- handoffSkill
- hf-cliSkill
- implementSkill
- lean-code-cleanupSkill
- process-x-bookmarksSkill
- pwc-brandSkill
- pwc-cliSkill
- pwc-cron-healthSkill
- pwc-deploySkill
- remote-paper-curationSkill
- reply-github-issueSkill
- resolve-model-paperSkill
- s2-cliSkill
- skill-creatorSkill
- to-ticketsSkill
- verify-evalsSkill
- s2-cliSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

