web-shader-extractor

web-shader-extractor is a skill for Claude Code, Codex from ssmurfgg04-gif/context-m. It costs 89 tokens per session (1,783 once invoked), scanned A, original, Apache-2.0.

A tool for extracting WebGL, Canvas, and shader visual effects from a website and moving them into a standalone JavaScript project. WebGL and shaders are browser technologies for rendering interactive graphics.

In plain words
What is it for?
Extracting animated backgrounds and other Canvas or WebGL effects, reversing obfuscated code, and porting the result to an independent project.
Why use it?
It helps recreate a site's visual effect when the original implementation is bundled, difficult to read, or tied to the original page.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: reads .claude/ paths.

Good fit Extracting animated backgrounds and other Canvas or WebGL effects, reversing obfuscated code, and porting the result to an independent project.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ssmurfgg04-gif/context-m/web-shader-extractor
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.

Any agent
npx skills add ssmurfgg04-gif/context-m --skill web-shader-extractor
Clone the repo
git clone --depth 1 https://github.com/ssmurfgg04-gif/context-m

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for web-shader-extractor

README.md
[![agentmods](https://agentmods.dev/badge/skills/ssmurfgg04-gif/context-m/web-shader-extractor/github.svg)](https://agentmods.dev/skills/ssmurfgg04-gif/context-m/web-shader-extractor)
Your own site
<a href="https://agentmods.dev/skills/ssmurfgg04-gif/context-m/web-shader-extractor"><img src="https://agentmods.dev/badge/skills/ssmurfgg04-gif/context-m/web-shader-extractor/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for web-shader-extractor

Your own site · 80×15
<a href="https://agentmods.dev/skills/ssmurfgg04-gif/context-m/web-shader-extractor"><img src="https://agentmods.dev/badge/skills/ssmurfgg04-gif/context-m/web-shader-extractor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 89 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,783 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00089 $0.01783
Opus 5 $0.00044 $0.00892
Sonnet 5 $0.00018 $0.00357
Haiku 4.5 $0.00009 $0.00178

Measured 9d ago against content hash f1982c9a3e36, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

web-shader-extractor scanned grade A with 1 finding 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 9d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/fetch-rendered-dom.mjs, scripts/scan-bundle.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -fsSL https://nodejs.org/dist/v22.15.0/node-v22.15.0-darwin-arm64.tar.gz | tar xz -C /usr/local --strip-components=1
skills/web-shader-extractor/SKILL.md · 146 lines

How it starts

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

Web Shader Extractor

从网页提取 WebGL/Canvas/Shader 特效,反混淆并移植为独立项目。

核心原则:

  • 先 1:1 复刻,确认正确后再考虑简化框架
  • 全程自主执行,不中断用户 — 提取是只读操作,安全性无风险。除 Phase 6 简化提议外,所有步骤自动完成,不询问用户确认。遇到问题自行判断最佳方案继续推进,只在需要用户做产品决策时才询问。

Phase 0: 环境检查(首次自动执行)

在开始提取前,检查并自动安装所需依赖。不要询问用户,直接安装

# 1. 检查 Node.js
node --version 2>/dev/null || {
  echo "Node.js not found, installing..."
  # macOS
  brew install node 2>/dev/null || {
    # fallback: 直接下载 LTS
    curl -fsSL https://nodejs.org/dist/v22.15.0/node-v22.15.0-darwin-arm64.tar.gz | tar xz -C /usr/local --strip-components=1
  }
}

# 2. Playwright 及浏览器(fetch-rendered-dom.mjs 内置自动安装,但这里预检可提前发现问题)
RUNNER_DIR="$HOME/.cache/playwright-runner"
if [ ! -d "$RUNNER_DIR/node_modules/playwright" ]; then
  echo "Installing Playwright (one-time setup)..."
  mkdir -p "$RUNNER_DIR"
  echo '{"type":"module"}' > "$RUNNER_DIR/package.json"
  npm install playwright --prefix "$RUNNER_DIR"
  npx --prefix "$RUNNER_DIR" playwright install chromium
  echo "Playwright + Chromium installed."
fi

如果安装过程中遇到权限或网络问题,尝试以下备选方案:

  • npm 权限问题 → 使用 --prefix 安装到用户目录
  • 网络问题(Chromium 下载慢)→ 设置 PLAYWRIGHT_DOWNLOAD_HOST=https://npmmirror.com/mirrors/playwright 使用国内镜像
  • 实在无法安装 Playwright → 降级为纯 curl 模式(跳过 DOM 渲染,仅分析静态 HTML + JS bundle),在 Phase 2 中标注可能缺失 canvas-info

Phase 1: 获取源码

并行执行:Playwright 获取渲染后 DOM + curl 获取静态 HTML。

# Playwright(获取 canvas 引擎版本、组件树、运行时网络请求)
node ~/.claude/skills/web-shader-extractor/scripts/fetch-rendered-dom.mjs '<URL>'
# → /tmp/rendered/: dom.html, canvas-info.json, network.json, screenshot.png, console.log

# curl(获取原始 HTML,用于提取内嵌配置和密钥)
curl -s -L --compressed '<URL>' > /tmp/page.html

如果 Playwright 脚本失败(未安装/启动异常),先尝试自动修复(重新安装依赖),若仍失败则降级为纯 curl 模式继续工作,不要停下来询问用户。

从 network.json 和 HTML 交叉提取 JS URL,批量下载到 /tmp/。

Phase 2: 技术栈识别

canvas-info.json 的 dataEngine 字段:
├─ "three.js rXXX" → Three.js(r170+ 可能是 TSL → references/tsl-extraction.md)
├─ "Babylon.js vX.X" → Babylon.js
├─ null → 进一步区分:
│   ├─ bundle 含 createShader/shaderSource → Raw WebGL / PixiJS
│   └─ bundle 含 getContext('2d') 且无 WebGL 调用 → 2D Canvas(→ references/porting-strategy.md § 2D Canvas)
└─ 无 canvas → CSS/SVG 动画

URL 或 HTML 特征匹配已知平台 → 直接跳转专用工作流(跳过通用 Phase 3-4):
├─ unicorn.studio → references/unicorn-studio.md(Firestore REST API 直取配置+shader)
└─ shaders.com → references/shaders-com.md(Nuxt payload + XOR 解码 + TSL→GLSL 翻译)

扫描确认:bash scripts/scan-bundle.sh /tmp/*.js
→ 框架特征速查 references/tech-signatures.md

Read the full file on GitHub · 146 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. 9d ago First seen · 146 lines · 89 tokens per session scan A f1982c9a3e36

Subscribe to this mod's changes

web-shader-extractor is a skill published in the GitHub repository ssmurfgg04-gif/context-m (2 stars, last pushed yesterday), licensed Apache-2.0. It adds 89 tokens to every session and 1,783 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

ai-style

A Chinese-language writing guide for producing or revising reader-facing text such as product announcements, public-account articles, emails, and README files. It focuses on reducing patterns that make writing sound machine-generated.

bojieli/ai-agent-book · 25 tokens

data_analysis

A data-analysis guide for doing mathematical calculations and descriptive statistics with confirmed, sourced data. Descriptive statistics summarise data using measures such as totals, averages, or ranges.

bojieli/ai-agent-book · 19 tokens

gsd-sketch

Sketch UI/design ideas with throwaway HTML mockups, or propose what to sketch next (frontier mode).

open-gsd/gsd-core · 27 tokens

impeccable

Create distinctive, production-grade frontend interfaces with high design quality. Generates creative, polished code that avoids generic AI aesthetics. Use when the user asks to build web components, pages, artifacts, posters, or applications, or when any design skill requires project context. Call with 'craft' for…

wrg32786/aigent-os · 90 tokens

motion-design

Restrained, accessible web motion — Framer Motion declarative patterns and CSS-only staggered reveals for high-impact moments, always bundle-aware and reduced-motion-safe. Use when adding animation/transitions to a UI (entrance reveals, list stagger, page/route transitions, micro-interactions) or when motion feels…

nguyenthienthanh/aura-frog · 74 tokens

auv-design

Use this skill to generate well-branded interfaces and assets for AUV (the Moeru AI command-replay / inspect runtime), either for production or throwaway prototypes/mocks. Contains essential design guidelines, colors, type, fonts, assets, and UI kit components for prototyping.

moeru-ai/auv · 60 tokens