Update claude md

From rajitsaha/100xprism · View interactive version

Update claude md is an AI agent skill from the GitHub repository rajitsaha/100xprism. After any correction from the user, update CLAUDE.md with a rule to prevent the same mistake from recurring. Use when the user corrects your behavior or says "don't do that again". Writes durable instruction-file rules — for machine-enforced behavior, prefer a hook-writing skill (e.g. hookify) or se

How to use this skill

Skill file

Update-Claude — CLAUDE.md Rule Writer

After any correction, update CLAUDE.md with a rule to prevent the same mistake recurring.

How to use


Phase 1 — Identify the pattern

What went wrong? What should have been done instead? Be specific — one clear pattern, not a vague note.


Phase 2 — Write a rule

Formulate as a clear, actionable rule:

- [Rule]: [What to do / not to do]. Why: [brief context].

Short rules stick. Long paragraphs get ignored.


Phase 3 — Update CLAUDE.md

PROJECT_ROOT=$(git rev-parse --show-toplevel)
INSTRUCTION_FILE=$(for f in CLAUDE.md AGENTS.md .cursorrules; do [ -f "$PROJECT_ROOT/$f" ] && echo "$PROJECT_ROOT/$f" && break; done)

Append the rule under a ## Rules or ## Corrections section in the project's instruction file. If no instruction file exists, create CLAUDE.md in the project root.


Phase 4 — Confirm

Tell the user: "Updated [file] with: [rule summary]"

If the rule isn't reducing mistakes after 2–3 sessions: rewrite it — be more specific or more prominent.

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.