claude-code-plugin-ref…
Explain plugin, skill, command, agent, and hook mechanics used here. Use when authoring or debugging plugins. Do not use for ops;…
Optimizes context window via MECW principles and memory tiering. Use when context exceeds 30% or before long multi-step tasks.
Claude Code
$ npx -y skills add athola/claude-night-market --skill context-optimization --agent claude-code
Codex
$ npx skills add athola/claude-night-market --skill context-optimization -a codex -y
Cursor
$ npx skills add athola/claude-night-market --skill context-optimization -a cursor -y
Gemini CLI
$ npx skills add athola/claude-night-market --skill context-optimization -a gemini-cli -y
GitHub Copilot
$ npx skills add athola/claude-night-market --skill context-optimization -a github-copilot -y
OpenCode
$ npx skills add athola/claude-night-market --skill context-optimization -a opencode -y
Windsurf
$ npx skills add athola/claude-night-market --skill context-optimization -a windsurf -y
name: context-optimization description: Optimizes context window via MECW principles and memory tiering. Use when context exceeds 30% or before long multi-step tasks. alwaysApply: false category: conservation token_budget: 150 progressive_loading: true modules: - modules/context-waiting.md - modules/findings-format.md - modules/mecw-assessment.md - modules/mecw-principles.md - modules/memory-tiers.md - modules/session-routing.md - modules/subagent-coordination.md - modules/belief-clarity.md - modules/cache-aligned-prefixes.md - modules/compression-strategies.md - modules/reversible-compression.md - modules/log-debugging-hygiene.md role: hook-target
1. Assess context pressure and MECW compliance. 2. Route to appropriate specialized modules. 3. Coordinate subagent-based workflows. 4. Manage token budget allocation across modules. 5. Synthesize results from modular execution.
def select_optimal_modules(context_situation, task_complexity):
if context_situation == "CRITICAL":
return ["mecw-assessment", "subagent-coordination"]
elif task_complexity == "high":
return ["mecw-principles", "subagent-coordination"]
else:
return ["mecw-assessment"]| Utilization | Status | Action | |-------------|--------|--------| | < 30% | LOW | Continue normally | | 30-50% | MODERATE | Monitor, apply principles | | > 50% | CRITICAL | Immediate optimization required |
**Behavior Change**: Large bash command and tool outputs are saved to disk instead of being truncated; file references are provided for access.
| Scenario | Before 2.1.2 | After 2.1.2 | |----------|--------------|-------------| | Large test output | Truncated, partial data | Full output via file reference | | Verbose build logs | Lost after 30K chars | Complete, accessible on-demand | | Context pressure | Less from truncation | Same - only loaded when read |
of `/clear` and `/catchup`, a continuation agent, archive and summarize, or delegation, with savings and risk.
archiving an oversized output to a retrievable handle.
before any compression. `/filter-log` anchors on it.
If context usage remains high after optimization, check for large files that were read entirely rather than selectively. If MECW assessments fail, ensure that your environment provides accurate token count metadata. For permission errors when writing output logs to `/tmp`, verify that the project's temporary directory is writable.
against `modules/cache-aligned-prefixes.md` (stable first, volatile last)
(cache writes cost more than they save on non-repeated prefixes)
A plugin marketplace for Claude Code. Install only the plugins you need to run git workflows, code review, spec-driven development, and autonomous agents from inside your Claude Code session.
Explain plugin, skill, command, agent, and hook mechanics used here. Use when authoring or debugging plugins. Do not use for ops;…
States load-bearing decisions, invariants, and weak points. Use when judging a design change. Do not use for gating; use…
Rebuild the dev environment: uv, Python tiers, pins, traps. Use when onboarding or toolchain breaks. Do not use for daily…
Classify, gate, and review changes. Use when landing a PR, releasing, or amending rules. Do not use for failure triage; use…
Search and record project memory (Discussions, journal, ADRs). Use before re-investigating anything. Do not use for settled…
Bind loop 'done' to unfakeable gates. Use to harden egregore/herald loops or promote completion_integrity. Not for QA gates; use…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.