/claude-code-enhance:refresh-codemapfrom claude-code-enhance
Regenerates the project codemap files (hotfiles.md, recent.md) from git history. Run weekly or before starting major architectural work to keep the SessionStart-injected codemap fresh. Triggers on user prompts like "refresh codemap", "update hotfiles", "regenerate codemap", "what's been hot lately", "what changed this month", "rebuild project map", or after significant rebases / merges that may have shifted the change-frequency picture. Does NOT regenerate overview.md — that's hand-curated and should only be edited when the architecture genuinely changes.
Ships in claude-code-enhance. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Regenerates the auto-generated portions of the project codemap.
test -d .codemap || { echo "No .codemap/ in current directory tree"; exit 1; }
If no .codemap/, the project hasn't been bootstrapped yet. Tell the user
to run codemap bootstrap manually (write .codemap/overview.md and create
the directory) before this skill can help.
cd "$(git rev-parse --show-toplevel)" || exit 1
cat > .codemap/hotfiles.md << 'EOF'
# Hot Files — <project name>
Top files by 90-day change frequency. **Where 80% of recent activity happens =
where 80% of new bugs hide.** Extra care when touching anything in this list.
Generated: <YYYY-MM-DD>
| Changes | File |
|---|---|
EOF
git log --since="90 days ago" --name-only --pretty=format: 2>/dev/null \
| grep -v '^$' | sort | uniq -c | sort -rn | head -20 \
| awk '{printf "| %s | `%s` |\n", $1, $2}' \
>> .codemap/hotfiles.md
After regeneration:
The user audits the annotations before committing. The auto-generated table is the data; the annotations are the judgment.
cd "$(git rev-parse --show-toplevel)" || exit 1
git log --since="30 days ago" --pretty="format:%ad|%s" --date=short 2>/dev/null
Use the output to write a NEW .codemap/recent.md that summarizes:
Style: terse, judgment-laden, action-oriented. Not a commit log replay.
bash ~/.claude/hooks/inject-project-codemap.sh | jq -e '.hookSpecificOutput.hookEventName == "SessionStart"' \
&& echo "✓ codemap hook valid"
Report total injected size:
chars=$(~/.claude/hooks/inject-project-codemap.sh | jq -r '.hookSpecificOutput.additionalContext' | wc -c | tr -d ' ')
echo "Codemap injection: $chars chars (~$((chars / 4)) tokens)"
If injection size exceeds ~6000 tokens, suggest the user trim overview.md or split hotfiles into a top-10 instead of top-20.
The codemap is gitignored by default — see if .gitignore already has
.codemap/ listed. If not, ask the user whether they want it committed
(useful for team sharing) or kept local (keeps repo clean).
.codemap/ exists yet — that's a bootstrap task, not a refresh task.The codemap covers what Serena does NOT: architectural narrative, git-derived heat maps, recent activity summaries. Serena handles structural queries (find_symbol, find_references, get_symbol_overview) — those don't go in the codemap because they're answered live by Serena. Don't try to capture Serena's domain in the codemap; you'll just create staleness.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
3 skills in this plugin
/consult-scarsScar-tissue retrieval. Loads relevant past lessons from ~/.claude/lessons/
before producing any architectural plan, so you don't repeat mistakes that
already cost time/money. Use this skill at the START of any task involving:
authentication, JWT, OAuth, RBAC, sessions, multi-tenancy, permissions,
caching (any layer), cache invalidation, TTLs, database migrations, schema
changes, ORM upgrades, indexes, distributed locking, payment flows, refunds,
webhook handling, queue processing, retry logic, error recovery, rate
limiting, deploys, infrastructure changes, API contract design, response
wrappers, response formats, frontend-backend type contracts, NestJS modules,
NestJS DI, Prisma client setup, Next.js layouts, Server Components, seed
data, demo data, fake data generation. Triggers on prompts containing
"design", "refactor", "migrate", "introduce", "implement", "build",
"set up", "fix", "upgrade", "add caching", "add auth", "ship", "deploy",
"schema change", "data model", "memory system", "agent architecture",
"tune Claude", "context optimization", "improve Claude" or any combination
of action verbs with the topics above. ALSO use when user asks to plan,
spec, or architect anything non-trivial. The cost of skipping this skill
is repeating a known-broken pattern; the cost of running it is ~30 seconds
and ~500 tokens.
/enhanceAugment-style prompt enhancer for Claude Code. Takes a rough developer
intent and produces a production-quality, codebase-aware, lesson-cross-
referenced, prompt-engineering-optimized prompt that the user reviews and
approves before execution.
USE THIS SKILL when the user types "/enhance <rough idea>", "enhance:
<idea>", "improve this prompt: <idea>", "structure this: <idea>",
"expand this: <idea>", "make this prompt better:", "rephrase as a proper
prompt:", or asks for a better-written/structured version of their
request before any actual work begins. ALSO use when the user gives a
vague high-level request with multiple possible interpretations and you
want to align with them BEFORE coding — the enhancement output surfaces
ambiguities as explicit questions.
The skill loads project context (codemap, lessons, CLAUDE.md, recent git
activity) and applies real prompt engineering principles (clear goal,
scope, constraints, success criteria, suggested approach, anti-patterns,
verification). The user can submit, edit, or scrap the enhanced version.
This is a USER-FACING enhancement tool. The user must approve the
enhanced version before it becomes the actual instruction. Never auto-
apply the enhanced prompt without explicit user confirmation.
Generated from the plugin's indexed repository (tenxengineer/claude-code-enhance) — no native marketplace selected
npx claudepluginhub p/tenxengineer-claude-code-enhance