Hey, good request. Reasoning from git diff is a totally valid approach, and you can make it stronger if you keep everything that affects agent behavior under version control.
What you should commit so diffs actually catch changes:
Rules and AGENTS.md for system instructions
MCP config .cursor/mcp.json
Skills and subagent definitions
Hooks
Then any change to prompts, tools, or workflows lands in git history, and you can see what changed between it worked and it broke.
Two things git does not cover directly:
Model version. A common reason for sudden behavior shifts is not your changes but a model update. It helps to pin a specific model instead of auto, so you can remove that variable while debugging.
Memory. It is harder to version, so when you investigate a regression, check it separately.
For tracing LLM calls, LangSmith or Langfuse is a solid pick, but those are external tools, not part of Cursor. Inside Cursor, Debug mode is useful when you want to inspect a specific run.
If you share how you build agents right now, CLI or SDK, cloud agents, or just Composer in the IDE, I can give more specific advice.