I asked chatgpt to reply, here you go:
You can integrate AI translation support by allowing users to enter their own API key and model settings in the mod’s configuration. For example, with Google’s Gemini Flash 2.5 (via the Gemini API), it would just need to send the text to translate as a prompt and return the output text.
Here’s the main documentation for Gemini’s API: 🔗 https://ai.google.dev/docs
Specifically, you’d want to look at the Text generation / generative models section — you can send a translation request like this:
POST https://generativelanguage.googleapis.com/v1beta/models/gemini-1.5-flash-latest:generateContent Authorization: Bearer [API_KEY] Content-Type: application/json { "contents": [ {"parts":[{"text": "Translate this Japanese text into English:\n\nこんにちは"}]} ] }
Then you’d parse the response and replace the in-game text accordingly. Let me know if you’d like a sample Python or C# or some other implementation!