Add git diff analysis capability to GDATP agent tooling
#### **Problem**
When English source content is updated , and we need to update existing translations, GDATP currently retranslates the entire file from scratch. This overwrites human-reviewed improvements made by Content Managers, sometimes even for sections where the English source didn't change.
#### **Examples**
1. In https://gitlab.com/gitlab-com/marketing/digital-experience/about-gitlab-com/-/merge_requests/3583#note_3011641796 @mjsibanez improved Spanish translation ("comprar" → "Hágase" for better naturalness). English source had hundreds of lines of changes, and GDATP was asked to update the Spanish translation, it retranslated the entire file and overwrote Maria Jose's improvement back to "comprar."
2. @muchikawa 's feedback on Japanese translations: Approximately 90% of the retranslated content was unnecessary because the English source for those sections hadn't changed. Only 10% actually needed updating based on English changes. (See this Retro note: https://gitlab.com/gitlab-com/localization/localization-team/-/work_items/620#recycle-improvements-what-can-be-improved, as well as screenshot of the Slack thread below in [the internal note](https://gitlab.com/gitlab-com/localization/gitlab-duo-agent-translation-platform/-/issues/18#note_3017297956))
GDATP has no Translation Memory, it can't analyze what changed in the English source. When prompted to "update translations," it starts from zero and retranslates everything, losing all human review work.
We use Phrase TMS for product docs A_powered translation, as an environment that already has Translation Memory, _but we won't be building translation memory functionality in GDATP_
**Proposed solution flor marketing:**
Add git diff analysis capability to GDATP agent tooling. Is it possible with GitLab Commits API? https://docs.gitlab.com/api/commits/
The agent should:
1. Accept commit hash or MR reference as input
2. Use GitLab's "Get Commit Diff" API or similar tooling
3. Parse the diff to identify which sections/lines changed
4. Map those changes to corresponding sections in target language files
5. Only retranslate sections where English actually changed
6. Preserve all existing translations in unchanged sections
**Implementation options:**
* Integrate GitLab's API as an agent tool (preferred , so we keep everything in the GDATP / agent workflow)
* Pre-processing script that analyzes changes and provides context to agent (not preferred, seems like more scripting to mange)
* Manual user input of changed line ranges (could be an interim solution, but need to test)
issue