Skills

Shader Gen

AI shader generator for WebGL video effects, transitions, masks, and color grading (LUT...

Install

npx skills add 0xsline/OpenChatCut --skill shader-gen -g -a claude-code -y
Repository
0xsline/OpenChatCut2.8k
Category
Media
Updated
14d ago
License
AGPL-3.0
Context cost
Mediumabout 3,000 tokens
Runs scripts
No, instructions only

What it does

AI shader generator for WebGL video effects, transitions, masks, and color grading (LUT / 调色 / 电影感 / film look). Use when the user wants a video effect (滤镜 / 特效), a transition (转场 / crossfade / wipe / cube / 3d), a mask (蒙版 / 遮罩 / reveal), a zoom / push-in (推近 / 推镜头), or a color grade, try the built-in effects (zoom, builtin LUTs) before generating a new shader.

Shader Generator

Submit-only: creates a backend generation job, returns jobId. Use the track_progress tool for job lifecycle after submission.

Always use generate.ts for new shaders. Manual authoring is only for editing existing asset code, never as a fallback when generation fails.

Catalog-first rule, try existing assets before generation

Before generating a shader, call browse_library unless the user names an exact asset id that is already visible in read_project.

browse_library is the source of truth for built-in effects, built-in transitions, and project effect/transition assets. Built-ins are stable global asset ids, not per-project DB assets, so they may not appear in read_project asset lists.

Apply catalog entries with edit_item, do not call submit_shader.

Good catalog searches:

browse_library(query: "zoom")
browse_library(category: "transitions", query: "dissolve")
browse_library(category: "audio-fx")

Generate only when no catalog entry matches the user's intent closely enough.

builtin:zoom is track-bound only, DO NOT use item-bound

The default effect mode is "item-bound" (attach to a single item via targetItemId). builtin:zoom does NOT render in item-bound mode, the renderer reads zoom data exclusively from track-bound effect items. An item-bound zoom inserts into the DB silently but shows nothing in preview.

Use mode: "track-bound" with trackId + trackBoundFrom + trackBoundDurationInFrames. These three fields are required.

# Zoom on the entire video clip
edit_item(json: '{"adds":[{"type":"effect","assetId":"builtin:zoom","mode":"track-bound","trackId":"<clip-trackId>","trackBoundFrom":<clip-fromFrame>,"trackBoundDurationInFrames":<clip-durationInFrames>,"propertyOverrides":{"magnification":1.5,"shape":"hold"}}]}')
Read the whole SKILL.md on GitHub

More in Media