vault: add ECC methodology deep-dive and zettelkasten insights
New resource note with 6 core methodologies, community best practices, pitfalls, and practical examples. Three zettelkasten notes extract key insights: hook vs prompt reliability, MCP context tradeoffs, and the instinct learning system. Updated existing guides with cross-links.
This commit is contained in:
28
6 - Zettelkasten/20260319120200 MCP数量与上下文窗口的反比关系.md
Normal file
28
6 - Zettelkasten/20260319120200 MCP数量与上下文窗口的反比关系.md
Normal file
@@ -0,0 +1,28 @@
|
||||
---
|
||||
created: "2026-03-19 12:02"
|
||||
type: zettel
|
||||
tags: [claude-code, context-window, performance, mcp]
|
||||
source: "https://github.com/affaan-m/everything-claude-code"
|
||||
---
|
||||
|
||||
# MCP 数量与上下文窗口的反比关系
|
||||
|
||||
每个启用的 MCP Server 都会占用上下文窗口空间(工具定义、schema 描述等)。实测数据:
|
||||
|
||||
- 0-5 个 MCP: 有效上下文接近 200K tokens
|
||||
- 10+ 个 MCP: 有效上下文降至 ~70K tokens(降幅 65%)
|
||||
|
||||
**最佳实践**:
|
||||
- 活跃 MCP <= 10 个,活跃工具总数 <= 80 个
|
||||
- 用 `disabledMcpServers` 动态禁用不用的
|
||||
- 重操作优先用 CLI(如 `gh`)而不是 MCP
|
||||
- 使用 `llms.txt` 模式获取文档,避免 MCP 常驻开销
|
||||
|
||||
这是 Claude Code 性能优化中**最重要的单一因素** — 比任何 Agent 或 Skill 都重要。
|
||||
|
||||
---
|
||||
|
||||
## Related
|
||||
|
||||
- [[Everything Claude Code 方法论与最佳实践]]
|
||||
- [[Hook驱动优于提示词驱动]]
|
||||
Reference in New Issue
Block a user