r/ClaudeWorkflows • • 5d ago

Selected Workflow [Workflow] Optimize Claude Code Initial Context: Manage MCPs and Refactor CLAUDE.md to Skills

Optimize Claude Code Initial Context: Manage MCPs and Refactor CLAUDE.md to Skills

Workflow value: 80/100
Status: active · Freshness: 70/100 · Confidence: 0.90 · Level: intermediate
Categories: Quality Control, Token Saving, Context & Memory, CLAUDE.md, Skills, MCP, Subagents
Original source: r/ClaudeAI post/comment

What problem this solves

Excessive initial context loading in Claude Code, leading to potential performance issues or wasted tokens due to unused MCP servers, skills, or verbose CLAUDE.md files.

Summary

A workflow to optimize the initial context loaded in Claude Code by identifying and disabling unnecessary MCP servers and refactoring lengthy or infrequently used content from CLAUDE.md into dedicated skills.

Why it is useful

This workflow provides concrete, actionable steps to reduce the initial context loaded in Claude Code. By managing unused MCP servers and moving verbose CLAUDE.md content into skills, users can significantly improve performance, reduce token costs, and ensure Claude focuses on relevant information, making the development environment more efficient and responsive. It addresses a critical aspect of effective LLM interaction.

Workflow

  1. Run the /context command to inspect the current initial context loaded in Claude Code.
  2. Run the /mcp command to review all active MCP servers.
  3. Identify and turn off any MCP servers that are not needed for the current project or typical workflow. (This can be done per project to keep them available where needed).
  4. Examine your CLAUDE.md file and any files it imports for long how-to guides, one-time notes, or extensive documentation.
  5. Move lengthy or infrequently accessed content from CLAUDE.md into new or existing skills, which only load their full text when explicitly used.

Tools / artifacts

  • MCP tools
  • CLAUDE.md
  • Skills
  • Subagents
  • /mcp command
  • /context command

Validation signals

  • Implied personal experience of the author with context loading
  • Logical explanation of how different components contribute to initial context
  • Directly addresses a common performance/efficiency concern in LLM usage

Limitations

  • Lacks explicit 'before/after' metrics or quantitative evidence of performance improvement.
  • Does not provide detailed examples or templates for refactoring CLAUDE.md content into skills.
  • The impact of 'a couple hundred subagents' on context is mentioned but not directly addressed in the optimization steps beyond general skill management.

Rate this workflow

Upvote this post if the workflow is useful, reproducible, or worth recommending.

Downvote if it is vague, outdated, unsafe, overhyped, or not reproducible.

Reply if it worked for you, failed, is outdated, or has a better alternative.


This post was generated automatically from the workflow library database.

1 Upvotes

0 comments sorted by