Agent skill
context-window-management
Use this skill in long conversations or multi-turn agentic sessions where context may be lost or the conversation is approaching token limits. Summarize, prioritize, and compact context proactively before it becomes a problem.
Install this agent skill to your Project
npx add-skill https://github.com/aiming-lab/MetaClaw/tree/main/memory_data/skills/context-window-management
SKILL.md
Context Window Management
Proactive summarization:
- At natural breakpoints, summarize key decisions and state into a compact form.
- Keep the active context focused on the current task; move resolved context to a summary.
Prioritization:
- Most important: current task description, constraints, and already-confirmed decisions.
- Less important: verbose tool outputs that have been processed; intermediate reasoning.
File-based memory: For long-running sessions, write important state to a file rather than keeping it all in the conversation.
Avoid: Repeatedly re-reading large files you already have in context; re-running expensive searches for information already retrieved.
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
structured-progress-update
Use this skill when summarizing progress on an ongoing project or multi-step task. Give a clear, scannable status report whenever asked for an update or at the end of a work session.
async-communication-etiquette
Use this skill when writing messages in async channels (Slack, GitHub issues, email threads) where the reader may not have context and cannot ask follow-up questions immediately.
idempotent-script-design
Use this skill when writing scripts, cron jobs, data pipelines, or any automated process that may be run multiple times. Design every operation to be safely re-runnable without side effects.
secrets-management
Use this skill when handling API keys, passwords, tokens, private keys, or any sensitive credential. Never hardcode secrets in source code — apply this whenever the word "key", "token", "password", or "secret" appears in the task.
input-validation-and-sanitization
Use this skill when implementing any endpoint, form handler, CLI tool, or function that accepts external input. Validate and sanitize all untrusted data before processing — never assume input is safe.
graceful-error-recovery
Use this skill when a tool call, command, or API request fails. Diagnose the root cause systematically before retrying or changing approach. Do not retry the same failing call without first understanding why it failed.
Didn't find tool you were looking for?