一键导入
context-engineering
Manage what goes into the AI agent context window for maximum quality and minimum waste
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Manage what goes into the AI agent context window for maximum quality and minimum waste
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Build UIs that work for all users including keyboard navigation, screen readers, and WCAG 2.2
Design multi-agent systems with robust tool interfaces, state management, and failure handling
Build ML systems with disciplined training, evaluation, deployment, and safety practices
Design APIs that are stable, ergonomic, and evolvable
Design systems at the right scale with explicit trade-off documentation
Design services that are reliable, observable, secure, and maintainable
基于 SOC 职业分类
| name | context-engineering |
| description | Manage what goes into the AI agent context window for maximum quality and minimum waste |
| difficulty | senior |
| domains | ["ai-ml"] |
Context is finite. What you put in the context window determines what the agent can reason about. Too much noise → the relevant signal is diluted. Too little context → the agent makes uninformed decisions. This skill manages context deliberately.
For your model and use case: how many tokens is your budget? Reserve: 20% for the system prompt, 20% for the output, 60% for the dynamic context (documents, history, tools).
Include in this order:
Cut: long documents that contain 1 relevant paragraph, full file contents when only a function is needed, conversation history beyond the last N relevant turns.
Agents pay more attention to the beginning and end of context. Put instructions at the top. Put the most relevant context closest to the task.
Mark different sections clearly:
<system>Your role and constraints</system>
<documents>Retrieved content</documents>
<task>What to do</task>
This prevents the model from confusing instructions with retrieved data.
Summarize long histories. Extract the relevant portions of long documents. Use structured data (JSON, tables) instead of prose where possible.
Track: output quality vs. context length. If longer context is producing worse results, you have a context quality problem, not a context quantity problem.