mcpField
P
principle-guard-the-context-window

principle-guard-the-context-window

github.com/cursorAgent 工作流14.5k4.9k 次安装今天更新
代码仓库

关于 principle-guard-the-context-window

面向 Agent 的上下文管理技能,通过限制各阶段范围和文件数量、设置轮次预算并考虑机制成本,减少上下文溢出。

主要功能

  1. 01限制每个阶段的文件数
  2. 02设置轮次预算
  3. 03考虑机制成本

适用场景

  1. 01规划分阶段的 Agent 工作
  2. 02减少任务中的上下文溢出

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/cursor/plugins --skill principle-guard-the-context-window

安装后在 Claude Code 中输入/principle-guard-the-context-window确认已加载。

详细介绍

守护上下文窗口

原因: 上下文溢出会降低推理质量,产生压缩伪影,并阻碍进展。

模式:

  • 划分阶段并限制范围。 限制每个阶段处理的文件数量,设置轮次预算,并考虑机制成本。

评论

支持 Markdown