Omh frontend refactor

From rlaope/oh-my-hermes · View interactive version

Omh frontend refactor is an AI agent skill from the GitHub repository rlaope/oh-my-hermes. [omh] Oversized or tangled UI component: behavior-preserving refactor of UI code - preview the full change plan first, apply as a second explicit step, and work impact-ordered from state architecture down to naming polish. Use when the user says: frontend-refactor, front-refactor, frontend refactor,

How to use this skill

Skill file

Frontend Refactor

Required: the target files or component, and the framework in use, current behavior evidence: tests, or the characterization checks to write first, the diff budget: micro pass only, one macro tier, or full ladder. Output: preview change plan with per-change line refs, before/after, safety reason, and category counts, impact-ordered pass selection naming what is deferred and why, characterization-test gate verdict before any macro change, apply-step handoff with the unsafe-in-isolation changes listed under notes, never half-applied.

Why This Exists

frontend-refactor exists so UI restructuring runs as a previewed, behavior-locked, impact-ordered process instead of ad-hoc rewrites: the plan comes before any edit, state fixes come before polish, and every change carries its safety reason.

Contract: references/full-contract.md (examples, sibling boundaries, full artifact details).

Workflow Lane

When to Use

Use when existing UI code needs restructuring without behavior change - an oversized component, boolean-flag state, effect chains, prop drilling - and the user wants a previewed, pass-ordered refactor plan rather than a new build or a verdict-only review.

Strong routing signals: frontend-refactor, front-refactor, frontend refactor, refactor this component, refactor the component, refactor my component, component refactor, react refactor, refactor this hook, split this component, split the component, this component is too big, component is too large, state management review, state management, state colocation, too many useeffects, useeffect cleanup, clean up useeffect, prop drilling, 컴포넌트 리팩터링, 컴포넌트 리팩토링, 컴포넌트 분리, 컴포넌트가 너무 커, 상태 관리 정리, 상태 관리 리뷰, 프론트 리팩터링, 프론트엔드 리팩터링, useEffect 정리, рефакторинг компонента, раздели компонент, компонент слишком большой, рефакторинг фронта, разбей компонент

Catalog Metadata

Category: maintenance

Phase: frontend-refactor

Hermes role: handoff-guide

Quality tier: behavior-lock-gated

Reasoning demand: heavy

Quality bar:

Handoff policy:

Hermes prepares the preview plan, pass order, and characterization-test gate; the apply step is coding work for the selected executor lane, and behavior preservation is claimed only from observed test runs before and after apply.

Executor readiness:

Delegation transparency:

Safety rules:

Completion Checklist

Recovery Notes

Runtime Evidence

Preferred harness for this skill: coding-handling.

omh runtime record --skill frontend-refactor --harness coding-handling --status started

Record observed delegation results; otherwise return not_available or not_observed.

Prepared OMH routing is not execution, review, CI, merge-readiness, or merge evidence.

Preserve workflow intent and stop conditions; verify before claiming completion.

Reply in the user's own words and the host's own voice: its SOUL.md persona owns reply language, tone, speech level, and sentence endings, progress updates included (where it sets no language, use the one the user wrote in), and OMH shapes structure and content only. When the requested output is delivered, put any open points inside the result and end with no question or offer; only when the person asked to choose or decide and that choice is still theirs, end with one specific question about it, not a list, a generic offer, or a footer; the shared rail's Reply Language And Host Voice and Turn Ending sections hold the full rule.

Use Hermes-native subagent/delegation features when available: native subagents -> Hermes delegation when available, otherwise sequential lanes.

Shared product, compatibility, topology, memory, harness, and execution rules: skill_view(name='omh-routing', file_path='references/skill-common-rail.md'). Load it when applicable; otherwise name an unavailable capability.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.