[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75DN3B8RAG6HVXRP2PYKT9J":3,"skill-same:01M75DN3B8RAG6HVXRP2PYKT9J":102},{"skillNo":4,"name":5,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":23,"commitSha":24,"skillDirectory":25,"forksCount":26,"repositoryHtmlUrl":27,"repositoryHomepageUrl":28,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":6,"updatedAt":31,"install":32,"resources":45},"01M75DN3B8RAG6HVXRP2PYKT9J","context-engineering",null,"LongLeo287\u002FSEOSONA-OS","LongLeo287","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F141803367?v=4","01M6JK75C62VCNZKR5BRZ386YV","LongLeo","01M75CK60XQGYJY3YDGGFJQDYT",2,"MIT","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\n\nname: context-engineering\ndescription: \"Context engineering curates the smallest high-signal token set for LLM tasks. The goal: maximize reasoning quality while minimizing token usage.\"\nargument-hint: \"[topic or question]\"\n  Check context usage limits, monitor time remaining, optimize token consumption, debug context failures.\n  Use when asking about context percentage, rate limits, usage warnings, context optimization, agent architectures, memory systems.\nmetadata:\n  author: claudekit\n  version: \"1.0.0\"\n---\n\n# Context Engineering\n\nContext engineering curates the smallest high-signal token set for LLM tasks. The goal: maximize reasoning quality while minimizing token usage.\n\n## When to Activate\n\n- Designing\u002Fdebugging agent systems\n- Context limits constrain performance\n- Optimizing cost\u002Flatency\n- Building multi-agent coordination\n- Implementing memory systems\n- Evaluating agent performance\n- Developing LLM-powered pipelines\n\n## Core Principles\n\n1. **Context quality > quantity** - High-signal tokens beat exhaustive content\n2. **Attention is finite** - U-shaped curve favors beginning\u002Fend positions\n3. **Progressive disclosure** - Load information just-in-time\n4. **Isolation prevents degradation** - Partition work across sub-agents\n5. **Measure before optimizing** - Know your baseline\n\n**IMPORTANT:**\n- Sacrifice grammar for the sake of concision.\n- Ensure token efficiency while maintaining high quality.\n- Pass these rules to subagents.\n\n## Quick Reference\n\n| Topic | When to Use | Reference |\n|-------|-------------|-----------|\n| **Fundamentals** | Understanding context anatomy, attention mechanics | [context-fundamentals.md](.\u002Freferences\u002Fcontext-fundamentals.md) |\n| **Degradation** | Debugging failures, lost-in-middle, poisoning | [context-degradation.md](.\u002Freferences\u002Fcontext-degradation.md) |\n| **Optimization** | Compaction, masking, caching, partitioning | [context-optimization.md](.\u002Freferences\u002Fcontext-optimization.md) |\n| **Compression** | Long sessions, summarization strategies | [context-compression.md](.\u002Freferences\u002Fcontext-compression.md) |\n| **Memory** | Cross-session persistence, knowledge graphs | [memory-systems.md](.\u002Freferences\u002Fmemory-systems.md) |\n| **Multi-Agent** | Coordination patterns, context isolation | [multi-agent-patterns.md](.\u002Freferences\u002Fmulti-agent-patterns.md) |\n| **Evaluation** | Testing agents, LLM-as-Judge, metrics | [evaluation.md](.\u002Freferences\u002Fevaluation.md) |\n| **Tool Design** | Tool consolidation, description engineering | [tool-design.md](.\u002Freferences\u002Ftool-design.md) |\n| **Pipelines** | Project development, batch processing | [project-development.md](.\u002Freferences\u002Fproject-development.md) |\n| **Runtime Awareness** | Usage limits, context window monitoring | [runtime-awareness.md](.\u002Freferences\u002Fruntime-awareness.md) |\n\n## Key Metrics\n\n- **Token utilization**: Warning at 70%, trigger optimization at 80%\n- **Token variance**: Explains 80% of agent performance variance\n- **Multi-agent cost**: ~15x single agent baseline\n- **Compaction target**: 50-70% reduction, \u003C5% quality loss\n- **Cache hit target**: 70%+ for stable workloads\n\n## Four-Bucket Strategy\n\n1. **Write**: Save context externally (scratchpads, files)\n2. **Select**: Pull only relevant context (retrieval, filtering)\n3. **Compress**: Reduce tokens while preserving info (summarization)\n4. **Isolate**: Split across sub-agents (partitioning)\n\n## Anti-Patterns\n\n- Exhaustive context over curated context\n- Critical info in middle positions\n- No compaction triggers before limits\n- Single agent for parallelizable tasks\n- Tools without clear descriptions\n\n## Guidelines\n\n1. Place critical info at beginning\u002Fend of context\n2. Implement compaction at 70-80% utilization\n3. Use sub-agents for context isolation, not role-play\n4. Design tools with 4-question framework (what, when, inputs, returns)\n5. Optimize for tokens-per-task, not tokens-per-request\n6. Validate with probe-based evaluation\n7. Monitor KV-cache hit rates in production\n8. Start minimal, add complexity only when proven necessary\n\n## Runtime Awareness\n\nThe system automatically injects usage awareness via PostToolUse hook:\n\n```xml\n\u003Cusage-awareness>\nClaude Usage Limits: 5h=45%, 7d=32%\nContext Window Usage: 67%\n\u003C\u002Fusage-awareness>\n```\n\n**Thresholds:**\n- 70%: WARNING - consider optimization\u002Fcompaction\n- 90%: CRITICAL - immediate action needed\n\n**Data Sources:**\n- Usage limits: Anthropic OAuth API (`http~\u002F.seosona\u002Fpath\u002F`)\n- Context window: Statusline temp file (`\u002Ftmp\u002Fck-context-{session_id}.json`)\n\n## Scripts\n\n- [context_analyzer.py](.\u002Fscripts\u002Fcontext_analyzer.py) - Context health analysis, degradation detection\n- [compression_evaluator.py](.\u002Fscripts\u002Fcompression_evaluator.py) - Compression quality evaluation\n","# Context Engineering\n\nContext engineering curates the smallest high-signal token set for LLM tasks. The goal: maximize reasoning quality while minimizing token usage.\n\n## When to Activate\n\n- Designing\u002Fdebugging agent systems\n- Context limits constrain performance\n- Optimizing cost\u002Flatency\n- Building multi-agent coordination\n- Implementing memory systems\n- Evaluating agent performance\n- Developing LLM-powered pipelines\n\n## Core Principles\n\n1. **Context quality > quantity** - High-signal tokens beat exhaustive content\n2. **Attention is finite** - U-shaped curve favors beginning\u002Fend positions\n3. **Progressive disclosure** - Load information just-in-time\n4. **Isolation prevents degradation** - Partition work across sub-agents\n5. **Measure before optimizing** - Know your baseline\n\n**IMPORTANT:**\n- Sacrifice grammar for the sake of concision.\n- Ensure token efficiency while maintaining high quality.\n- Pass these rules to subagents.\n\n## Quick Reference\n\n| Topic | When to Use | Reference |\n|-------|-------------|-----------|\n| **Fundamentals** | Understanding context anatomy, attention mechanics | [context-fundamentals.md](.\u002Freferences\u002Fcontext-fundamentals.md) |\n| **Degradation** | Debugging failures, lost-in-middle, poisoning | [context-degradation.md](.\u002Freferences\u002Fcontext-degradation.md) |\n| **Optimization** | Compaction, masking, caching, partitioning | [context-optimization.md](.\u002Freferences\u002Fcontext-optimization.md) |\n| **Compression** | Long sessions, summarization strategies | [context-compression.md](.\u002Freferences\u002Fcontext-compression.md) |\n| **Memory** | Cross-session persistence, knowledge graphs | [memory-systems.md](.\u002Freferences\u002Fmemory-systems.md) |\n| **Multi-Agent** | Coordination patterns, context isolation | [multi-agent-patterns.md](.\u002Freferences\u002Fmulti-agent-patterns.md) |\n| **Evaluation** | Testing agents, LLM-as-Judge, metrics | [evaluation.md](.\u002Freferences\u002Fevaluation.md) |\n| **Tool Design** | Tool consolidation, description engineering | [tool-design.md](.\u002Freferences\u002Ftool-design.md) |\n| **Pipelines** | Project development, batch processing | [project-development.md](.\u002Freferences\u002Fproject-development.md) |\n| **Runtime Awareness** | Usage limits, context window monitoring | [runtime-awareness.md](.\u002Freferences\u002Fruntime-awareness.md) |\n\n## Key Metrics\n\n- **Token utilization**: Warning at 70%, trigger optimization at 80%\n- **Token variance**: Explains 80% of agent performance variance\n- **Multi-agent cost**: ~15x single agent baseline\n- **Compaction target**: 50-70% reduction, \u003C5% quality loss\n- **Cache hit target**: 70%+ for stable workloads\n\n## Four-Bucket Strategy\n\n1. **Write**: Save context externally (scratchpads, files)\n2. **Select**: Pull only relevant context (retrieval, filtering)\n3. **Compress**: Reduce tokens while preserving info (summarization)\n4. **Isolate**: Split across sub-agents (partitioning)\n\n## Anti-Patterns\n\n- Exhaustive context over curated context\n- Critical info in middle positions\n- No compaction triggers before limits\n- Single agent for parallelizable tasks\n- Tools without clear descriptions\n\n## Guidelines\n\n1. Place critical info at beginning\u002Fend of context\n2. Implement compaction at 70-80% utilization\n3. Use sub-agents for context isolation, not role-play\n4. Design tools with 4-question framework (what, when, inputs, returns)\n5. Optimize for tokens-per-task, not tokens-per-request\n6. Validate with probe-based evaluation\n7. Monitor KV-cache hit rates in production\n8. Start minimal, add complexity only when proven necessary\n\n## Runtime Awareness\n\nThe system automatically injects usage awareness via PostToolUse hook:\n\n```xml\n\u003Cusage-awareness>\nClaude Usage Limits: 5h=45%, 7d=32%\nContext Window Usage: 67%\n\u003C\u002Fusage-awareness>\n```\n\n**Thresholds:**\n- 70%: WARNING - consider optimization\u002Fcompaction\n- 90%: CRITICAL - immediate action needed\n\n**Data Sources:**\n- Usage limits: Anthropic OAuth API (`http~\u002F.seosona\u002Fpath\u002F`)\n- Context window: Statusline temp file (`\u002Ftmp\u002Fck-context-{session_id}.json`)\n\n## Scripts\n\n- [context_analyzer.py](.\u002Fscripts\u002Fcontext_analyzer.py) - Context health analysis, degradation detection\n- [compression_evaluator.py](.\u002Fscripts\u002Fcompression_evaluator.py) - Compression quality evaluation\n",{},"main","4fd50b1281e8cd978866b6b4556242605cabf708","2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering",1,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS","https:\u002F\u002Fseosona-os.vercel.app","https:\u002F\u002Fgithub.com\u002FLongLeo287","https:\u002F\u002Fwww.facebook.com\u002FResourceRookie2023","2026-10-09 15:14:13",{"source":7,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add LongLeo287\u002FSEOSONA-OS --skill context-engineering",{"tool":38,"command":39},"bunx","bunx skills add LongLeo287\u002FSEOSONA-OS --skill context-engineering",{"tool":41,"command":42},"pnpm","pnpm dlx skills add LongLeo287\u002FSEOSONA-OS --skill context-engineering","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002FSKILL.md",true,[46,52,56,60,64,68,72,76,80,84,88,94,98],{"path":47,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":50,"sourceHtmlUrl":51},"references\u002Fcontext-compression.md","REFERENCE","参考文档",2335,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fcontext-compression.md",{"path":53,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":54,"sourceHtmlUrl":55},"references\u002Fcontext-degradation.md",3094,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fcontext-degradation.md",{"path":57,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":58,"sourceHtmlUrl":59},"references\u002Fcontext-fundamentals.md",2732,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fcontext-fundamentals.md",{"path":61,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":62,"sourceHtmlUrl":63},"references\u002Fcontext-optimization.md",2333,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fcontext-optimization.md",{"path":65,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":66,"sourceHtmlUrl":67},"references\u002Fevaluation.md",2253,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fevaluation.md",{"path":69,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":70,"sourceHtmlUrl":71},"references\u002Fmemory-systems.md",2570,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fmemory-systems.md",{"path":73,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":74,"sourceHtmlUrl":75},"references\u002Fmulti-agent-patterns.md",2319,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fmulti-agent-patterns.md",{"path":77,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":78,"sourceHtmlUrl":79},"references\u002Fproject-development.md",2142,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fproject-development.md",{"path":81,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":82,"sourceHtmlUrl":83},"references\u002Fruntime-awareness.md",4906,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Fruntime-awareness.md",{"path":85,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":86,"sourceHtmlUrl":87},"references\u002Ftool-design.md",2057,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Freferences\u002Ftool-design.md",{"path":89,"resourceType":90,"resourceTypeDesc":91,"sizeBytes":92,"sourceHtmlUrl":93},"scripts\u002Fcompression_evaluator.py","SCRIPT","脚本",11753,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Fscripts\u002Fcompression_evaluator.py",{"path":95,"resourceType":90,"resourceTypeDesc":91,"sizeBytes":96,"sourceHtmlUrl":97},"scripts\u002Fcontext_analyzer.py",11131,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Fscripts\u002Fcontext_analyzer.py",{"path":99,"resourceType":90,"resourceTypeDesc":91,"sizeBytes":100,"sourceHtmlUrl":101},"scripts\u002Ftests\u002Ftest_edge_cases.py",9651,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fframeworks\u002Fagentic_workflows\u002Fcontext-engineering\u002Fscripts\u002Ftests\u002Ftest_edge_cases.py",[103,110,117,124,131,138],{"skillNo":104,"name":105,"nameZh":6,"description":106,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":107,"categories":108,"keywords":109,"publishedAt":18},"01M75F0T3V3W7JQQ05X26NNN2T","web_crawler_katana","High-speed web crawling using Katana patterns for deep site mapping, URL discovery, and content extraction.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fskills\u002Fseo_technical\u002Fweb_crawler_katana\u002FSKILL.md",[],[],{"skillNo":111,"name":112,"nameZh":6,"description":113,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":114,"categories":115,"keywords":116,"publishedAt":18},"01M75F0Q2QJXDGAFKC7D84GT88","server_log_analyzer","Analyzes Nginx\u002FApache server logs to identify Googlebot crawl patterns, errors, and performance bottlenecks.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fskills\u002Fseo_technical\u002Fserver_log_analyzer\u002FSKILL.md",[],[],{"skillNo":118,"name":119,"nameZh":6,"description":120,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":121,"categories":122,"keywords":123,"publishedAt":18},"01M75F0KZP6D8R8XPN2YT35BAJ","schema_markup_generator","Auto-generates JSON-LD structured data for any page type (Article, Product, FAQ, LocalBusiness, etc.).","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fskills\u002Fseo_technical\u002Fschema_markup_generator\u002FSKILL.md",[],[],{"skillNo":125,"name":126,"nameZh":6,"description":127,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":128,"categories":129,"keywords":130,"publishedAt":18},"01M75F0G3KX4Y86AXJXTKXVEVA","internal_linking_optimizer","Analyzes and optimizes the internal link graph of a website for SEO authority distribution.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fskills\u002Fseo_technical\u002Finternal_linking_optimizer\u002FSKILL.md",[],[],{"skillNo":132,"name":133,"nameZh":6,"description":134,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":135,"categories":136,"keywords":137,"publishedAt":18},"01M75F0CS1RYX4YPJC7N6RAAQJ","google_trends_analyzer","Detects trending topics and seasonal patterns using Google Trends data for content planning and keyword strategy.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fskills\u002Fseo_technical\u002Fgoogle_trends_analyzer\u002FSKILL.md",[],[],{"skillNo":139,"name":140,"nameZh":6,"description":141,"descriptionZh":6,"repositoryFullName":7,"ownerLogin":8,"ownerAvatarUrl":9,"ownerAccountNo":10,"ownerDisplayName":11,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":142,"categories":143,"keywords":144,"publishedAt":18},"01M75F0ASMQ1GKPFX82D19SRTN","brand_context_analyzer","Tracks brand mentions, sentiment, and online reputation across web sources.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FSEOSONA-OS\u002Fblob\u002Fmain\u002F2_KNOWLEDGE\u002Fskills\u002Fseo_technical\u002Fbrand_context_analyzer\u002FSKILL.md",[],[]]