pbijdens / raidbot

Telegram bot for Pokemon GO raids
Apache License 2.0
1 stars 1 forks source link

Prevent multiple people from publishing the same raid #1

Open pbijdens opened 6 years ago

pbijdens commented 6 years ago

It would be nice if it would be possible to prevent multiple people from publishing the same raid.

Implementation suggestions: Since people have to manually enter the name of the Pokémon and Gym, using those to detect the situation is probably not the most reliable solution. We could use the location of the Gym and then warn a user that the raid is already published before they 'Save' it. Also we can render a warning triangle on the publish button if another raid was already published nearby.

FractionalRadix commented 6 years ago

If two raids are in gyms with very similar names, we could warn the user ("A very similar raid is already published. Are you sure this is a different raid?") We could use Levenshtein distance for this purpose; possibly removing things like "The"/"De" from a gym name before doing the comparison.

We could also have a file of known gyms, and compare the input to these.

pbijdens commented 6 years ago

Agreed. Those are solid ideas. I think we need not even use the name of the raid in the comparison, the odds that on another gym at roughly the same location (40 m apart) at almost exactly the same time a different raid occurs are sufficiently low. I will see what I can do.

As for gym names, I am considering adding a custom keyboard for previously used gym names at that location.

On Tue, 6 Feb 2018 at 13:17, FractionalRadix notifications@github.com wrote:

If two raids are in gyms with very similar names, we could warn the user ("A very similar raid is already published. Are you sure this is a different raid?") We could use Levenshtein distance for this purpose; possibly removing things like "The"/"De" from a gym name before doing the comparison.

We could also have a file of known gyms, and compare the input to these.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/pbijdens/raidbot/issues/1#issuecomment-363405294, or mute the thread https://github.com/notifications/unsubscribe-auth/APSZ9wiJ5LyMfeMyqaIr_eh3-Oro18Dnks5tSELkgaJpZM4RJkkz .