language-enforcer-bot
language-enforcer-bot copied to clipboard
Restructure backend
Synopsis
Currently, the bot runs well in a single group. There are a single language and behavior config and single storage of exceptions. This one and only config works for all groups where the bot is used. This creates several problems:
- What if somebody wants to force the bot to enforce English, and somebody other: to enforce German?
- What if somebody wants the bot to mute people and translate messages, and somebody other: to do the exact opposite?
Solutions
This problem seems to be a bit more complicated than the ones we faced previously. The general, high-level solution I can think of now is:
- separate config for every group Every group would have a separate collection in Firebase Firestore, where the group's admins could add exceptions and configure bot's behavior
- setup wizard When the bot is added to the group, ask a few questions and save them (for this specific group)
Any suggestions/help are welcome.
Can't you just run two copies?
On Sun, Apr 12, 2020 at 5:15 PM Bartek Pacia [email protected] wrote:
Synopsis
Currently, the bot runs well in a single group. There are a single language and behavior config and single storage of exceptions. This one and only config works for all groups where the bot is used. This creates several problems:
- What if somebody wants to force the bot to enforce English, and somebody other: to enforce German?
- What if somebody wants the bot to mute people and don't translate messages, and somebody other: to do the exact opposite?
Solutions
This problem seems to be a bit more complicated than the ones we faced previously. The general, high-level solution I can think of now is:
- separate config for every group Every group would have a separate collection in Firebase Firestore, where the group's admins could add exceptions and configure bot's behavior
- setup wizard When the bot is added to the group, ask a few questions and save them (for this specific group)
Any suggestions/help are welcome.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/bartekpacia/telegram-lang-enforcer/issues/20, or unsubscribe https://github.com/notifications/unsubscribe-auth/AN54XP4D67MMAEPVX6VM63TRMJKQRANCNFSM4MGTXYPA .
Only 1 Telegram Bot instance can receive webhook events at the same time. Also, running a single instance for every language and behavior config doesn't sound like a good idea.