motion-anything
AGENTS.md839 starsChanged 5 months agoApache-2.0View on GitHub
This file is the single source of truth for any coding agent (Claude Code, Cursor, Codex, Aider, …) working on motion-anything. If you are an AI picking this project up cold, read this file and PROGRESS.md first — they are designed so the project can be continued by any tool, in any new session, without losing context. motion-anything is an open-source, chat-native motion engine: a curated + standardized library of motion recipes, a "taste engine" (MOTION-SPEC.md), and a router skill…
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,736 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository14 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- skills/gsap/llms.txtllms.txt
- gsap-coreSkill
- gsap-frameworksSkill
- gsap-performanceSkill
- gsap-pluginsSkill
- gsap-reactSkill
- gsap-scrolltriggerSkill
- gsap-timelineSkill
- gsap-utilsSkill
- motion-anythingSkill
- web-cloneSkill
- web-shader-extractorSkill
- web-to-design-mdSkill
The file
We split this AGENTS.md into the rules it gives an agent
11 rules. About 0 are common, 1 is distinctive, and 10 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 17
Read the product thesis in README.md.
- Very specific: line 113
Write recipe.motion.yaml using the schema above.
- Very specific: line 115
Write preview.html: self-contained, opens in any browser, no build, no CDN that can break offline.
- Very specific: line 117
Write the implementation file(s) referenced by implementations.
- Very specific: line 118
Write SKILL.md (Open-Design-compatible frontmatter — copy an existing recipe's and adapt).
- Very specific: line 120
Update PROGRESS.md (move it from "next" to "done").
- Very specific: line 126
Animate transforms & opacity only: Never animate layout properties (width/height/top/left) in a way that thrashes.
- Very specific: line 128
Always provide a
prefers-reduced-motionfallback: No exceptions. Accessibility is non-negotiable. - Distinctive: line 131
Plain files only: No build-time magic that locks the repo to one agent or toolchain.
- Very specific: line 137
Commit messages: imperative, scoped, e.g.
- Very specific: line 139
After any meaningful change, update PROGRESS.md.
≈ “Common” is an estimate: at least 1 in 5 of the 16,597 AGENTS.md 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
AGENTS.md — working agreement for any AI agent on this repo
This file is the single source of truth for any coding agent (Claude Code, Cursor, Codex,
Aider, …) working on motion-anything. If you are an AI picking this project up cold, read this
file and PROGRESS.md first — they are designed so the project can be continued by any tool, in
any new session, without losing context.
What this project is
motion-anything is an open-source, chat-native motion engine: a curated + standardized
library of motion recipes, a "taste engine" (MOTION-SPEC.md), and a router skill that turns one
sentence of intent into produced, tasteful animation. It is an independent product that shares
resources with and interlocks with Open Design:
every recipe is authored as an Open-Design-compatible SKILL.md so it can drop straight into
OD's skills/ and bind to OD design systems' motion section.
Read the product thesis in README.md. Read live status and the task queue in PROGRESS.md.
Repository map
| Path | Role |
recipes/<surface>/<recipe-id>/ | One motion recipe. Surfaces: web/, interaction/, video/. |
recipes/<...>/recipe.motion.yaml | Machine manifest (gallery + router read this). Schema below. |
recipes/<...>/SKILL.md | The portable, Open-Design-compatible skill for this recipe. |
recipes/<...>/preview.html | Self-contained, openable live demo. No build step, no external deps. |
recipes/<...>/*.css, *.js, *.jsx | The reusable implementation(s). |
skills/motion-anything/SKILL.md | The router meta-skill: intent → classify → pick → produce. |
MOTION-SPEC.md | The motion standard. Every recipe and the router MUST obey it. |
gallery/index.html | The possibility gallery (static; reads recipes). |
cli/ | Minimal Node CLI: list, add <recipe>, gallery. |
The recipe manifest schema (recipe.motion.yaml)
Mirrors Open Design / html-video manifests, extended with the three fields that make this product
unique (intent_keywords, avoid_when, restraint).
spec_version: 1
id: like-burst # kebab-case, unique, == folder name
name: Like Burst
description: A celebratory particle burst on tap, for likes / reactions.
surfaces: [web, interaction] # legacy alias of `canvas`; kept for back-compat
# ── 分类五维(建库标准,取值见下方 §"分类标准") ─────────────────────────
canvas: [web] # 场景:用到哪里 → web | slides | video | app
target: [button, icon] # 对象:给什么加 → text|button|card|list|image|icon|section|number|transition|background
intent: feedback-delight # 意图:表达什么 → = MOTION-SPEC category(沿用同一套)
runtime: [css, js] # 技术:怎么实现 → css|js|framer-motion|gsap|motion-one|lottie|rive
export: [skill, motion-json, html] # 可导出:能产出什么 → skill|motion-json|lottie|html|video
# ───────────────────────────────────────────────────────────────────────
category: feedback-delight # alias of `intent` (kept for back-compat / MOTION-SPEC)
tech: [css, js] # alias of `runtime` (kept for back-compat)
dependencies: [] # npm packages required (empty = vanilla)
tags: [like, reaction, particles, celebration, micro-interaction]
# ── the three soul fields ──────────────────────────────────────────────
intent_keywords: # how a human would *describe wanting* this, incl. 中文
- delightful like
- celebration burst
- 点赞特效
- 惊喜感
best_for: # when to reach for it
- Like / favorite / reaction buttons
- Small moments of positive feedback
avoid_when: # when NOT to use it (the restraint layer)
- Destructive or neutral actions (delete, dismiss)
- More than one celebratory burst visible at once
restraint: # usage budget, per MOTION-SPEC.md
max_per_view: 1
notes: One celebratory moment per screen. Never auto-play; trigger on user intent only.
# ───────────────────────────────────────────────────────────────────────
motion:
duration_ms: 600 # within MOTION-SPEC bounds for this category
easing: ease-out
reduced_motion: scale-only # graceful fallback when prefers-reduced-motion
gpu_safe: true # transforms/opacity only — no layout thrash
entry: preview.html
implementations:
- { tech: css+js, files: [like-burst.css, like-burst.js] }
license:
spdx: Apache-2.0
upstream: null # URL if adapted from an upstream library
attribution_required: false
author: { name: nexu.io, url: "https://github.com/nexu-io" }
version: 0.1.0分类标准(五维建库 + 一条品味红线)
每条 recipe 都按五个维度打标签(不是塞进单一目录树)。检索时由 agent 自由组合查询("web 场景里给 按钮加一个有反馈感的动效"= canvas:web × target:button × intent:feedback-delight)。
| 维度 | 字段 | 取值 |
| 场景 用到哪里 | canvas | web(网页)· slides(幻灯片)· video(launch/release 视频)· app(App UI) |
| 对象 给什么加 | target | text · button · card · list · image · icon · section(整页/区块)· number(统计数字)· transition(转场)· background |
| 意图 表达什么 | intent | 沿用 MOTION-SPEC category:entrance · scroll-reveal · hover-press · feedback-delight · emphasis · attention · loading · text-kinetic · ambient(背景氛围)· exit(退出)· page-transition · video-transition |
| 技术 怎么实现 | runtime | css · js · framer-motion · gsap · motion-one · lottie · rive |
| 可导出 能产出什么 | export | skill(SKILL.md 包)· motion-json(便携 JSON)· lottie · html(standalone)· video |
外加一条不进五维、但绝不能省的品味红线:restraint + avoid_when —— "什么时候别用"。
这是 motion-anything 区别于"又一个素材站"的护城河;没有 restraint 的 recipe 视为未完成。来源(GSAP/Lottie…)
只作元数据(license / upstream),不作分类轴。完整盘点与收录梯队见 SOURCES.md。
How to add a new recipe (the golden path)
mkdir recipes/<surface>/<recipe-id>/.- Write
recipe.motion.yamlusing the schema above. Fill all three soul fields honestly — especiallyavoid_whenandrestraint. A recipe without restraint guidance is incomplete. - Write
preview.html: self-contained, opens in any browser, no build, no CDN that can break offline. It must visibly demonstrate the motion and respectprefers-reduced-motion. - Write the implementation file(s) referenced by
implementations. - Write
SKILL.md(Open-Design-compatible frontmatter — copy an existing recipe's and adapt). - Confirm it shows up:
node cli/bin/motion.js list. - Update
PROGRESS.md(move it from "next" to "done").
Hard rules (these are the product, not nitpicks)
- Restraint is a feature. Curate, don't dump. Every recipe must declare
avoid_when+restraint. Quality and taste over quantity — that is the whole differentiator. - Animate transforms & opacity only. Never animate layout properties (width/height/top/left) in a way that thrashes. Keep it GPU-safe.
- Always provide a
prefers-reduced-motionfallback. No exceptions. Accessibility is non-negotiable. - Recipes are tool-agnostic, dependency-honest. Vanilla where possible; declare every dep.
- Stay Open-Design-compatible. Recipe
SKILL.mdfrontmatter must keep theod:block valid. - Plain files only. No build-time magic that locks the repo to one agent or toolchain.
Conventions
- Indent: 2 spaces. Line endings: LF. Filenames: kebab-case.
- Bilingual docs: keep
README.mdandREADME.zh-CN.mdin sync when either changes. - Commit messages: imperative, scoped, e.g.
recipe(web): add scroll-reveal. End AI commits with the Co-Authored-By trailer. - After any meaningful change, update
PROGRESS.md. It is the handoff contract between sessions.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
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.

