Skip to content

Questions with batch machine translation #473

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
ClementChaumel opened this issue May 7, 2025 · 1 comment
Open

Questions with batch machine translation #473

ClementChaumel opened this issue May 7, 2025 · 1 comment

Comments

@ClementChaumel
Copy link

Hi, I tried to add a new language to my project and first I wanted to translate a file at a time.

So I went to Files and clicked on "Translate"
Image

There I encountered a fist issue: when the modal opens it automatically translates the file in English (my second and already translated language) instead of Spanish (my third, newly added language).
I can select Spanish in the dropdown and run it again but it means I will still call the translation API twice for each file.

Image

Then I found a second issue with my approach: once the file translated I expected to find a button to "commit" the translated file. Something to update all the Spanish strings from this file in the project. But I could only close the modal and it was like nothing happened. Is this modal just temporary? Should I copy and paste the content to my local .es file and then run a sync through accent CLI?

I then went back, deleted the Spanish language I just created to recreate it with the "Initialize language with machine translations" option checked

Image

It ran for a bit then when it finished all the Spanish strings were still empty. Turns out I just blew through my free DeepL allowance. I should've been more careful (I didn't know exactly how many chars my project was) but now I have used all the free allowance for the month and I have nothing to show for it 😅. I didn't expect it but maybe it would be nice as an improvement to keep the strings that were able to be translated before hitting the rate limit.

Now I'm wondering if the only method to partially translate a language through ML is to click the translate button on each individual string? or if I could not at least do this by document/file.

I will most likely upgrade my DeepL subscription and try again and if it still doesn't work, write a bash script to update all my .es files locally and then sync.

I'm not sure what response I expect from this issue so feel free to close it. I just wanted to tell you about my experience and maybe ask if there is something obvious I missed here.

Thanks for this project and your hard work on it!

@ClementChaumel
Copy link
Author

ClementChaumel commented May 12, 2025

After investigation, it turns out that the total char length of my source language is 342,667 (including translation keys, so effectively probably even less) and so should be well under DeepL's free 500,000 chars allowance. Could this mean there is a bug with how strings are initialised with machine translation ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant