code_smart_diff
code_smart_diff takes the current git diff and passes it to an LLM, which returns a plain-language explanation of what changed and what the impact is — scoped to your specific question.
Requires GL_SMART_READ=true in the MCP server environment.
code_smart_diff(question="what changed in the parser?")code_smart_diff(question="are there any breaking changes?", base="HEAD~3")code_smart_diff(question="summarize the security implications")Parameters
Section titled “Parameters”| Parameter | Type | Default | Description |
|---|---|---|---|
question | string | required | What you want to know about the changes |
base | string | HEAD~1 | Base ref to diff against |
Token comparison
Section titled “Token comparison”| Approach | Tokens |
|---|---|
code_diff_context() — full diff + callers | ~4,000 |
code_smart_diff(question="breaking changes?") | ~200 |
80% token savings with a focused, opinionated answer.
When to use
Section titled “When to use”- Code review — understand the intent of a large diff quickly
- Security audit — ask specifically about security implications
- Release preparation — identify breaking changes before tagging
- Requires
GL_SMART_READ=truein the MCP server configuration - For raw diff + caller impact data, use
code_diff_contextinstead - The LLM explanation is guided by your question — a precise question yields a precise answer