aws-samples / bedrock-claude-chat

AWS-native chatbot using Bedrock + Claude (+Mistral)
MIT No Attribution
693 stars 237 forks source link

BUG: Chat History Defaults to Spanish Despite English Language Selected #294

Open josephedward opened 2 months ago

josephedward commented 2 months ago

Issue #, if available: https://github.com/aws-samples/bedrock-claude-chat/issues/240

Description of changes:

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

statefb commented 1 month ago

Thank you for your contribution! May I ask you a few things?

@wadabee Please tell us if you have any good suggestion to reflect language to pass it to API (Local storage? We should take a look at React i18next).

josephedward commented 1 month ago

Yes @statefb I will make those modifications, might take me a few days to look at it closely. Lots of possibilities for further integrating language capabilities...you could make a literal with supported languages as the param, like you did with models. And you could do more to detect languages in real-time. Willing to work with @wadabee to introduce react-i18next in the frontend, could be interesting.

statefb commented 1 month ago

@josephedward Thank you, that's totally no problem. Can I ask you about more detail what are you planning for another language feature?

Willing to work with @wadabee to introduce react-i18next in the frontend, could be interesting.

react-i18next is already introduced. According to this stack overflow, we can get current language using useTranslation hook, which would be the best and easiest way to pass it to backend API.

josephedward commented 1 month ago

react-i18next is already introduced

I knew you were using i18n, didn't realize you were already using that specific library.

Can I ask you about more detail what are you planning for another language feature?

If this commit helps, go ahead and merge.

According to this stack overflow, we can get current language using useTranslation hook, which would be the best and easiest way to pass it to backend API.

I will work on this soon if you want to keep this PR open 😊

statefb commented 1 month ago

No problem, this PR would be helpful and thank you again for your willingness for contribution! I'll definitely leave this PR open. Please create a commit when you have time 😄