Choose an interface by combining invocation frequency with input and output complexity. CLI calls usually suit infrequent tools with concise output; MCP wrappers earn their cost for frequent calls or structured filtering. section 9.5.1
Apply the heuristic with these checks:
- Prefer CLI when a tool runs once or twice per session, accepts simple arguments, and returns a few lines. section 9.5.1
- Prefer MCP when a tool runs ten or more times per session, requires complex parsing, or must reduce large outputs to relevant data. section 9.5.1
- Check the aggregate context budget first; individually justified servers can still consume roughly a third of the context window. section 9.5.1
Table 9.6 Context Usage claude-sonnet-4-5
|
Source
|
Tokens
|
Share
|
|
System prompt
|
3,900 tokens
|
2%
|
|
MCP tools
|
58,400 tokens
|
29%
|
|
Memory files
|
1,200 tokens
|
1%
|
|
Messages
|
42,000 tokens
|
21%
|
|
Free space
|
94,500 tokens
|
47%
|
Use the context breakdown to assess whether persistent tool definitions leave enough working space. section 9.5.1
