AGENT SKILL

simplify

Use this skill automatically when you feel your code is ready for human review, and whenever writing or reviewing code comments. Ready means the code works and achieves a stated goal, verified by your own tests and/or, if you deem it necessary, human testing.

License 许可
GPL-3.0
所属仓库
UNRULYEON/skills
最近更新
2026-11-13
Stars
★ 0
Forks
0

01 前言 Front Matter

name
simplify
description
Use this skill automatically when you feel your code is ready for human review, and whenever writing or reviewing code comments. Ready means the code works and achieves a stated goal, verified by your own tests and/or, if you deem it necessary, human testing.

02 资源文件 1

03 SKILL.md 正文

Review changes in the current branch, or in the scope the user specifies. Apply these criteria without changing behavior. Only touch code in that scope, and run the relevant existing checks after changes.

Word choice in code and comments

Variable names, function names, and comments are all prose. Apply Orwell's rules ("Politics and the English Language") to each:

Never use a long word where a short one will do.

If it is possible to cut a word out, always cut it out.

Never use the passive where you can use the active.

Never use a foreign phrase, a scientific word, or a jargon word if you can think of an everyday English equivalent.

Latinate vocabulary (reconcile, coalesce, normalize, reconciliation) sounds technical and abstract; Anglo-Saxon words (prune, run, watch, stop, drop, walk) are short and physical. Prefer the Saxon word.

Names

  1. One word per concept, one concept per word. Keep a vocabulary. If sync names "pulling remote changes," it cannot also name "flushing edits to disk;" rename one of them.
  2. Cut words the context already carries. A module named workspaceWatcher does not need startNativeWorkspaceWatcher; watchWorkspace says the same thing.
  3. A compound name is usually a hedge:
  • ❌ lastObservedDiskContent is a specification to defend
  • ✅ baseline is a readable description

Comments

State, in plain English, the constraint the code cannot show: why the non-obvious exists.

  • ✅ If code is complex and the implementation is non-obvious, add a comment.
  • ✅ If a function contains complex behaviors or side effects, add a doc comment.
  • 🗑️ If a comment narrates change history from the conversation, delete it.
  • 🗑️ If a comment restates code whose behavior is self-evident, delete it.

Code structure

  1. Inverted pyramid. Within a file, lead with the exported or significant functions and push helpers below them. Don't bury the lead.
  2. Related concepts over monoliths. Break a large file into modules that each own one concept.
  3. Combine overlapping concepts. If two types, functions, or constants overlap significantly, merge them. The fewer distinct concepts a reader must hold in their head, the better.
  4. Use shared code. Common utilities (ex. file path parsing) may exist in the codebase already. Check for library or utility functions before inlining.
  5. Derivability. If a value can be computed from values already in scope, don't pass or store it separately. Removing derivable state often simplifies signatures, types, and control flow in one move. Example: an isDirty parameter that is always editorContent !== baseline can be dropped.

Overfitting

Code must stand on its own. If a change only makes sense to someone who watched it happen (this conversation, this PR), it is overfitted. Write for the reader who arrives with no history.

  • If a name or comment needs the conversation to be understood, rewrite it against the codebase's own vocabulary.
  • No backwards compatibility with unshipped code. Supporting an old signature, alias, or data shape that only existed earlier in the same branch is compatibility with something that was never deployed. Delete the old path and update its callers.

04 同仓库更多 Skills

UNRULYEON
UNRULYEON/skills

writing-for-agents

Writing documents for agents. Use when creating or editing skills, or modifying AGENTS.md or CLAUDE.md.

★ 0
UNRULYEON
UNRULYEON/skills

untangle-codebase

Untangle a whole codebase in one pass, so agents working in it read less per change, break less without noticing, and debug faster.

★ 0
UNRULYEON
UNRULYEON/skills

ui-sh

The ui.sh design system's tools for building and adapting UI: designing new UI from scratch, adding dark mode, generating a brand identity or marketing mockup board, cleaning up Tailwind classes, extracting reusable components, creating dark-mode raster image variants, comparing UI options in-browser with the ui.sh picker, making an existing UI responsive across breakpoints, and converting a screenshot, Figma export, mockup, or wireframe into semantic unstyled markup. Triggers on: design new UI, build a page or section, dark mode, add dark mode, brand kit, visual identity, marketing mockup, canonicalize Tailwind classes, clean up Tailwind, componentize, extract components, dark-mode image variant, ui.sh picker, compare UI options, make responsive, breakpoints, mobile/tablet/desktop layout, markup from image, screenshot to markup, Figma export to code, wireframe to markup.

★ 0
UNRULYEON
UNRULYEON/skills

transitions

Production-ready CSS transitions for web apps, plus tuning for motion that already exists. Use when implementing notification badges, dropdowns, modals, panel reveals, page transitions, card resizes, number pop-ins, text swaps, icon swaps, success checks, avatar group hovers, error state shakes, search/input clear, skeleton loaders, shimmer text, sliding tabs, tooltips, staggered text reveals, card hover tilt, plus-to-menu morph, or accordions. Triggers on "add a transition", "animate the dropdown", "make the modal open smoothly", "swap icon", "page slide", "stagger animation", "open / close transition", "make it animate", "fade between", "success animation", "form error", "shake on invalid", "hover lift", "avatar stack hover", "clear the search", "skeleton loader", "loading shimmer", "shimmer text", "sliding tabs", "segmented control", "tooltip", "reveal text", "tilt card", "3D hover tilt", "cursor glare", "plus to menu", "FAB morph", "accordion", "collapsible", "expand / collapse", "disclosure". Also covers polishing motion that already animates — "polish my transitions", "refine the motion", "tune the timing / easing", "make the animation feel better / less janky", "tighten the durations", "fix the stagger", "align to the motion tokens", "audit the motion", "review my animations", "scan for ad-hoc transitions", "tokenize my animations", "timing feels off", "too slow / too fast", "open close timing", "hover in out". Also the commands transitions reveal, transitions review, transitions apply, transitions polish.

★ 0
UNRULYEON
UNRULYEON/skills

review-pr

Review a pull request or local branch diff for correctness, security, lifecycle, error handling, tests, and meaningful performance risks. Use when asked to review PR changes, a branch, a commit range, or the current working tree and return a structured review.

★ 0
UNRULYEON
UNRULYEON/skills

record-take

Record a reproducible screen video of a web page with CleanShot X from a scripted take. Use when the user wants a demo, showcase or looping video of a web app, or wants to write, change, rehearse or re-record a take.

★ 0