AutoHotKey script for choosing translaton suggestion from AI Assistant

Hei,

I have tried to write an AutoHotKey script for automatically replacing suggestions from OpenAi provider with suggestion from AI Assistant (keyboard shortcut Alt+W), confirm and go to the next segment. I wanted to automatize this process by pressing F9 key. It seems though that my script has some error, because what happens after applying F9 is that the translation from Open Ai is chosen anyway, not the suggestion from AI Assistant.

Do you have any suggestions what should be replaced in my script?

Thank you so much for your help in advance.

Screenshot of a translation software interface with two panels. The left panel shows text in Norwegian, and the right panel shows the translated text in Polish. There are annotations and suggestions from AI Assistant with highlighted terms and corresponding explanations at the bottom.

; AutoHotkey script to apply translation suggestion from AI Assistant,
; confirm the current segment, and move to the next segment in SDL Trados Studio

; Set a hotkey (e.g., F9) to trigger the commands
F9::
; Activate SDL Trados Studio window
WinActivate, ahk_exe TradosStudio2024_18.0.0.1013.exe ; Adjust the executable name if necessary

; Send the command to apply translation suggestion
; Replace with the actual shortcut you use to apply AI suggestion if needed
Send, ^a ; Assuming Alt+W applies the suggestion

; Confirm the current segment
Send, ^{Enter} ; Assuming Ctrl+Enter confirms the segment


return

   



Generated Image Alt-Text
[edited by: RWS Community AI at 12:56 PM (GMT 0) on 14 Nov 2024]
emoji