Skip to content
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

Allow all commands that start with !eval to overcome spam rules #967

Merged
merged 3 commits into from
May 31, 2024

Conversation

eduherminio
Copy link
Contributor

@eduherminio eduherminio commented May 26, 2024

Type of pull request:

  • Bug fix
  • Feature
  • Other

Description:

Context

When watching bot games, chat spam become very strict when trying to send the same command multiple times, which usually happens for !eval command.
This seems to be the piece of code responsible of detecting a message as spam. It basically detects duplicated messages (thanks @tsoj!)

There was an attempt to improve this on lichess side Relaxing spam rules for when being a normal user alone with just BOT accounts in chat, but it didn't make it.

Proposal

We can improve spectator experience on our side by allowing multiple commands to return our bot's eval.
The easiest way I could think of is doing so for every command that starts with (!eval), i.e. !eval1234, !evalplease, !eval with spaces.

This change has been applied to my bot and can be verified right now by watching any of his games and entering those commands one after each other.

Related Issues:

Checklist:

  • I have read and followed the contribution guidelines.
  • I have added necessary documentation (if applicable).
  • The changes pass all existing tests.

Screenshots/logs (if applicable):

image

i.e. `!eval`, `!eval1`, `!evalplease`, `!eval with spaces`
@eduherminio
Copy link
Contributor Author

If this moves forward, happy to update any related documentation before or after merging.

lib/conversation.py Outdated Show resolved Hide resolved
@eduherminio eduherminio requested a review from MarkZH May 29, 2024 11:23
@AttackingOrDefending AttackingOrDefending merged commit 7c83143 into lichess-bot-devs:master May 31, 2024
15 checks passed
@eduherminio eduherminio deleted the patch-2 branch May 31, 2024 10:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants