-
Notifications
You must be signed in to change notification settings - Fork 0
ClaireLang - Multi-language support and placeholders #5
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
base: main
Are you sure you want to change the base?
Conversation
Finally getting around to implementing this. If I don't implement it before my planned feature set for v3.5, it will never happen as the complexity of implementing this will go through the roof in the update as planned. Putting this in a separate branch so that when I have downtime at work, I can work on the slow and painful process of migrating everything to this system.
I prefer the idea of this structure, I just don't like the implementation of this structure. Also considered doing one giga-class (technical term :)), but that would've been much less readable than whatever in the fuck this is. Probably would've been easier to understand the intent of though... I will need to write some really good javadoc if I stick with this.
This is the first vaguely working implementation of the language system. /8ball is the only implemented command here. Nothing else is tested at this point because it's not been worked on.
Major L on my part
Incomplete feature added in 0d1b24d. Would be nice to have faster subsequent runs of the /quote command in a given channel but I don't want to be storing messages for any longer than absolutely needed. ClaireBot is not spyware.
Almost entirely courtesy of GPT-5. This wouldn't be finished anytime soon without LLM assistance. The hard part was done by hand, the machine can do the chores. Now the only remaining work (that immediately comes to mind) is the MessageComponents embeds. It looks like I still need to add most (or all) of those fields to the language file so that's gonna wait.
|
ce4acc0 is completely untested |
|
Since machine translation has come so far, I'm slightly curious how well something like Kagi Translate could handle translations. It's obviously nothing that would replace real human translations, but the size of the language file is daunting. I'm not strictly opposed to the idea, but I'm not multilingual, so I can't really evaluate such a thing. Before merging it might be worth adding some documentation/comments clarifying this stance and also poking at a few multi-lingual people I know for opinions on the matter. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add javadoc on what this is for. Best to avoid having to go analyze source-code later on.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For readability purposes it may be best to move all the localization strings to a block at the beginning of this file. At the same time however, I don't expect this to be touched anytime soon.
src/main/java/com/sidpatchy/clairebot/Embed/Commands/Regular/QuoteEmbed.java
Show resolved
Hide resolved
Updates to Robin 2.2.5 which does not use SnakeYAML. Bot should be runnable now.
Yes, I am testing in prod.
|
v3.4.0-alpha.4 is fully broken when the database fails. Need to find the hard dependency and remove/fix it. |
Command Status✅ Fully Working
|
Now returns hexadecimal value as intended.
- Separates concerns in embed construction. - Adds methods for generating embeds from existing pairings. - Implements the ability to randomize pairings by editing the existing embed. - Fixes an issue where the server icon was not properly being set as a footer. - Handles cases where the user is null for language processing.
Addresses potential null pointer exceptions by ensuring context data is properly handled during placeholder replacement. Improves code readability by using `isEmpty()` instead of `length() == 0` for checking empty string builders. Corrects the translation key for the requests channel mention tag. Fixes number emoji reactions for voting options. Improves poll ID parsing and reaction moderation.
This commit REQUIRES ClaireData v1.1.0 due to making use of the locale field in the Guilds table
|
As of most recent commit, we now require ClaireData v1.1.0, which is tragic since there hasn't been a need to update in the >2 years since 698aaaad9790f86e85f7e3aeb9b47b41e5ee85b9 |
Tracker for progress on the implementation of multi-language support.