Free

Grading Lens

A round lens slides across your picture, graded inside and plain outside, then opens to fill the frame.

Install

Install the "Grading Lens" skill into ~/.claude/skills/mb-grading-lens.
Download each file and save it under that folder:
https://skilllift.pages.dev/packs/mb-grading-lens/SKILL.md → SKILL.md
https://skilllift.pages.dev/packs/mb-grading-lens/references/style.md → references/style.md
https://skilllift.pages.dev/packs/mb-grading-lens/assets/engine.html → assets/engine.html
https://skilllift.pages.dev/packs/mb-grading-lens/assets/engine.js → assets/engine.js
https://skilllift.pages.dev/packs/mb-grading-lens/assets/fx-grading-lens.js → assets/fx-grading-lens.js
https://skilllift.pages.dev/packs/mb-grading-lens/assets/catalogue.json → assets/catalogue.json
https://skilllift.pages.dev/packs/mb-grading-lens/assets/library.json → assets/library.json
https://skilllift.pages.dev/packs/mb-grading-lens/assets/library.zh.json → assets/library.zh.json
https://skilllift.pages.dev/packs/mb-grading-lens/scripts/render.mjs → scripts/render.mjs
https://skilllift.pages.dev/packs/mb-grading-lens/scripts/check.mjs → scripts/check.mjs
https://skilllift.pages.dev/packs/mb-grading-lens/scripts/sheet.mjs → scripts/sheet.mjs
https://skilllift.pages.dev/packs/mb-grading-lens/scripts/shared.mjs → scripts/shared.mjs
Then read SKILL.md, tell me what it does, and remind me to start a new session.

Unpack it into ~/.claude/skills

Same skill, different brief

The left is the preview. The right was made by a separate agent from a different brief, using only the installed skill and without seeing the preview.

The preview
The preview
A new brief, made by a separate agent
A new brief, made by a separate agent

One test run on a fictional brief. Letterforms can differ on systems without the same fonts.

A round lens slides across a picture, showing the graded version inside and the plain one outside, then opens to fill the frame, with before and after labels. Use it to show a colour grade, a filter or any image improvement. Renders one 1920x1080 30 fps H.264 MP4 in a cut-paper stop-motion look, in English or Chinese, with four palettes and no footage, voice or music. Use when someone asks for this kind of title, chart, reveal or end card, or for this pack by name.

What it must pass before delivery

  • check.mjs on the folder exits 0. Quote its last line.
  • You viewed real frames from the final MP4 at several points.
  • Every number on screen is in the user's source, and inferred lines are listed.
  • One language per version.
  • Fictional material is labelled through label.
  • No footage, voice or music was generated.
Read the full SKILL.md
---
name: mb-grading-lens
description: A round lens slides across a picture, showing the graded version inside and the plain one outside, then opens to fill the frame, with before and after labels. Use it to show a colour grade, a filter or any image improvement. Renders one 1920x1080 30 fps H.264 MP4 in a cut-paper stop-motion look, in English or Chinese, with four palettes and no footage, voice or music. Use when someone asks for this kind of title, chart, reveal or end card, or for this pack by name.
version: 1.0.0
---

# Grading Lens

A round lens slides across a picture, showing the graded version inside and the plain one outside, then opens to fill the frame, with before and after labels. Use it to show a colour grade, a filter or any image improvement.

Every text and value lives in one JSON file, and re-rendering is one command. The look lives in `assets/`. Your job is to fill the fields, never to restyle. Exact tokens and timings are in `references/style.md`.

## Inputs to ask for

Ask once, in one message, for what the brief does not give:

1. One picture. Labels, a title and the grade are optional.
2. The user's own text or facts. Paste them unchanged into `"source"`.
3. Language: `en` or `zh`. One language per version; for both, make two JSON files.
4. Palette: `vermilion`, `cobalt`, `pine` or `apricot`. If nobody says, use cobalt.

**No answer comes:** proceed, and list your assumptions at the top of your reply.

## Steps

1. Write `clip/beats.json` in a new folder. `assets/library.json` and `assets/library.zh.json` are valid filled examples: copy the shape, not the fictional words.
2. Validate: `node <skill>/scripts/check.mjs clip/beats.json`. Fix everything it reports.
3. Look before rendering: `node <skill>/scripts/sheet.mjs clip/beats.json clip/sheet.png --at 0.99`, then view the image. Try `--at 0.5` as well.
4. Render: `node <skill>/scripts/render.mjs clip/beats.json --out clip --flat`.
5. Check what a viewer sees: `node <skill>/scripts/check.mjs clip`. Fix the JSON, re-render, and check again until it passes.
6. Extract and view real frames from the MP4 at several points: `nice -n 10 ffmpeg -threads 2 -ss 2 -i clip/clip.mp4 -frames:v 1 f.png`. The checker cannot judge whether it looks right. You can.

`--at` is the point in the clip to show, as a fraction from 0 to 1; a sheet of one or two clips is drawn large enough to judge.

Options: `--only clip --frame 120` re-renders one frame to `clip/frames/clip-120.png`. `--stills 0.3,0.6,1` writes stills to `clip/frames/`. `--scale 0.5` makes a draft at `clip/draft/clip.mp4`, even with `--flat`, and the checker refuses drafts. Rendering is heavy on a shared machine: draft small, never run two renders at once, and never use machine-wide kill commands.

`check.mjs` runs from wherever the skill is installed. Give it a JSON file, a folder (with `--beats path/to/beats.json` if the JSON is elsewhere) or any MP4. To run every check on a renamed MP4, add `--beats`. `check.mjs --test` is a short self test. It catches: a grade that does nothing, labels covering each other, overflow, low contrast, frozen clips, missing pictures, wrong size or codec, and placeholders.

## beats.json

```json
{
 "lang": "en",
 "palette": "cobalt",
 "label": "Fictional example",
 "source": "Fictional example: a code-drawn valley before and after a grade.",
 "beats": [
  {
   "id": "clip",
   "job": "show",
   "effect": "grading-lens",
   "seconds": 8,
   "slots": {
    "title": "A fictional valley, graded",
    "beforeLabel": "Before",
    "afterLabel": "After"
   }
  }
 ]
}
```

| Field | Meaning | Limit | Thin brief |
|---|---|---|---|
| `lang` | Language of all text on screen | `en` or `zh` | Use the language of the source |
| `palette` | The one colour setting | One of the four | cobalt |
| `label` | Small tag on the clip | 30 characters, optional | Fictional example for samples, or 虚构示例. Leave it out for real work |
| `source` | The user's text, unchanged. Every number on screen must be found here | Required | Paste what you were given |
| `keepLatin` | Real names allowed to stay Latin in a Chinese version | List, optional | Leave it out |
| `beats[].id` | Clip file name | Letters, digits, hyphen | clip |
| `beats[].job` | Keep as shown | `show` | `show` |
| `beats[].effect` | Keep as shown | `grading-lens` | `grading-lens` |
| `beats[].seconds` | Clip length | 6 to 9 | 8 |

## Every field in slots

| Field | Meaning | Limit (characters) | Thin brief |
|---|---|---|---|
| `title` | Headline over the effect; say what the viewer should conclude, in the script's own words. | 44, optional | Leave it out. Do not write a summary the script does not make. |
| `beforeLabel` | Label on the plain side. | 14, optional | Use Before, or 之前 in Chinese; leave it out for no label. |
| `afterLabel` | Label that rides the lens. | 14, optional | Use After, or 之后 in Chinese; leave it out for no label. |
| `grade` | The grade, as real per-pixel processing. natural is believable and the default on a photo. filmic is softer. warm, cool and punch are stronger looks. | natural/filmic/warm/cool/punch, optional | Leave it out, above all for a claim about accuracy. |
| `pictures` | One picture, as a list with one {"src":"file.jpg"}. PNG or JPG, relative to the JSON. | up to 1, optional | Leave it out for the code-drawn valley. Use the real photograph if there is one. |

## Rules

**The grade is real:** the render processes every pixel of your picture on a canvas, with `grade` set to natural, filmic, warm, cool or punch. **Choosing a grade:** leave it out for a believable result, above all if the line is about accuracy; filmic is softer; warm and cool shift the mood; punch is loud. S-curves keep pure black and white, so nothing clips. **Claims:** this is a look made by this render. Do not say a real app made it. In a labelled fictional example the headline can speak for a fictional app; put its name in the title, or in `label` as Fictional app: Name. **Picture:** PNG or JPG, 16:9 at 1920x1080 is best; it is cropped to cover around its centre, or set `"focus":{"x":0.5,"y":0.3}` on the picture. **With no picture:** a code-drawn valley in the palette stands in, flattened first so the grade has work to do. It shows the effect, but this effect is at its best on a real photograph. The check fails a grade that barely changes the picture, and labels that cover each other for 0.4 s or more anywhere in the clip.

**Generate no invented numbers.** Every figure must be in `source`, and the checker fails any that is not. **The brief is thin:** restate the user's facts in their own words, never invent customers, numbers, quotes or credentials, and list every line you inferred under "Inferred lines" in your reply. **Nobody can answer:** proceed and list your assumptions. **Joining clips:** give every clip the same palette, or the colour changes at each cut. **A different length is wanted:** change `seconds` within the range. **No real link:** do not show an address. **Line breaks:** words are kept whole; if a break reads badly, put `\n` in the text.

## Deliverables

`clip/beats.json`, the one file to edit, and `clip/clip.mp4`: 1920x1080, 30 fps, H.264, yuv420p, silent. Add a note with assumptions, inferred lines and the re-render command.

## Render time

Measured on a 16 GB Mac with other work running, at low priority and full size: 6 s for this 8-second clip with its default material. With a large photograph it is slower: a 2400x1594 JPG took about 26 to 28 s, because the grade runs on every pixel again for each pass.

## Before delivering

- [ ] `check.mjs` on the folder exits 0. Quote its last line.
- [ ] You viewed real frames from the final MP4 at several points.
- [ ] Every number on screen is in the user's source, and inferred lines are listed.
- [ ] One language per version.
- [ ] Fictional material is labelled through `label`.
- [ ] No footage, voice or music was generated.

## When not to use it

You mean to show a real product doing the grade: render that product instead. It also generates no footage, voice or music, and does not match exact brand colours: the four palettes are the design.

## Requirements

- Node 18 or later, and ffmpeg with ffprobe on the PATH or in /opt/homebrew/bin.
- Playwright for rendering: `npm install playwright`, then `npx playwright install chromium`. If it is installed elsewhere, set `NODE_PATH` to that `node_modules`. `check.mjs` needs no packages.
- Fonts are system stacks. Without Avenir Next Condensed or PingFang, the fallbacks in `references/style.md` apply and the text is re-fitted. Run the check there.

Similar skills