Agent skill · AI & Agents

optimizing-claude-md

Use when CLAUDE.md is bloated or ineffective. Use when Claude ignores instructions, file exceeds 150 lines, response formatting rules aren't working, or user asks to optimize/restructure their Claude Code configuration.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill optimizing-claude-md --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 5 KB
Bundled scripts: none
Path: skills/ai-llm/optimizing-claude-md/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Optimizing CLAUDE.md ## Overview Claude Code has a **priority hierarchy** for instructions. Most optimization failures come from putting rules in the wrong tier. ## When to Use - CLAUDE.md exceeds 150 lines - Claude ignores rules you've written - Response formatting directives ("be concise") aren't working - Multiple sections marked CRITICAL/MANDATORY - User asks to optimize, restructure, or create CLAUDE.md ## Priority Hierarchy | Tier | Mechanism | Priority | Purpose | |---|---|---|---| | **1. Output styles** | `~/.claude/output-styles/` | System prompt (highest) | Response format, tone, word limits | | **2. CLAUDE.md** | Project root | User message (medium) | Project rules, safety guardrails | | **3. .claude/rules/** | `.claude/rules/*.md` | Same as CLAUDE.md, auto-loaded | Topic-specific reference material | | **4. Auto memory** | `~/.claude/projects/*/memory/` | First 200 lines | Claude's own scratchpad — not for your instructions | **The #1 mistake:** Putting response formatting rules in CLAUDE.md. They belong in an output style (system prompt level). CLAUDE.md formatting rules get ignored under pressure. **Auto memory note:** Don't put instructions in MEMORY.md — it's Clau

What's inside
Steps it walks through
  1. Overview
  2. When to Use
  3. Priority Hierarchy
  4. Decision Framework: Keep, Move, or Cut
  5. Target: Under 150 lines (best teams run 60-80)
  6. Restructuring Workflow
  7. Content Classification
  8. Common Mistakes
  9. When NOT to Use
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the optimizing-claude-md skill do?

Use when CLAUDE.md is bloated or ineffective. Use when Claude ignores instructions, file exceeds 150 lines, response formatting rules aren't working, or user asks to optimize/restructure their Claude Code configuration.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill optimizing-claude-md --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going