Help with auto localize chat with TextService

  1. What do you want to achieve? Keep it simple and clear!

I want to have function can auto localize received chat.

  1. What is the issue? Include screenshots / videos if possible!

there seems to have Roblox-built-in function in TextService:FilterAndTranslateStringAsync().
So I’m trying to get string that user will recive from TextChatService.OnIncomingMessage.
And pass through to remoteFunction to translate it and override string with TextChatMessageProperties.

But thing is TextFilterTranslatedResult that is obtained from TextFilterTranslatedResult doesn’t return translated string.
(code like this
TextFilterTranslatedResult:GetTranslations()
)this simply returns empty table with no error.

  1. What solutions have you tried so far? Did you look for solutions on the Developer Hub?

I can think of using third Party translation API. But if possible i want to achive inside of my game.

This is my first time to ask. So let me know if any luck of infomation.

LocalScript Code that detect recieving chat.
override translated string not impremented yet

local textChat = game:GetService("TextChatService")
local textService = game:GetService("TextService")
local localizationService = game:GetService("LocalizationService")
local lang = { 
	localizationService.RobloxLocaleId,
}
local players = game.Players
local pubChat = Enum.TextFilterContext.PublicChat
local remote = game:GetService("ReplicatedStorage").remote
local myself = game.Players.LocalPlayer.UserId

textChat.OnIncomingMessage = function(message: TextChatMessage)
	local properties = Instance.new("TextChatMessageProperties")	
	
	local userId = message.TextSource.UserId
		remote:FireServer(message.Text, userId, lang, pubChat)
	return properties
end

I want to make sure this script print translated string↓

local remote = game:GetService("ReplicatedStorage").remote
local textService = game:GetService("TextService")

remote.OnServerEvent:Connect(function(player, text, userId, lang, pubChat)

	print(textService:FilterAndTranslateStringAsync(text, userId, lang, pubChat))
	--I expected this returns translated string	

end)

Sorry for messy code, these are what I am trying to do.

Can you post your code, The only thing i can think of without seeing so far is maybe its just failing to translate

I added some scripts, thank you for asking.