aboutsummaryrefslogtreecommitdiff
path: root/markov/markov.py
AgeCommit message (Collapse)Author
2024-03-26teleport: don't teleport within same channel, better textArjun Satarkar
2024-03-20markov: fix bug where append_token could clobber previous tokenArjun Satarkar
Specifically if we had an open paren followed by some other punctuation, the open paren would disappear. Probably this didn't exist before the addition of parens as valid tokens.
2024-03-20markov: avoid float division in uint_to_bytesArjun Satarkar
It seems as though the float division could cause an issue where the actual value should be an integer but the float representation is slightly higher than that, causing the addition of an extra unnecessary byte. Although this works fine as long as the same function is used, it could cause problems if seemingly inconsequential details change. I switch to using divmod and checking for the presence of a remainder. This should ensure use of the exact minimum required number of bytes in the blob.
2024-03-19markov: support brackets, separate out append_token logicArjun Satarkar
2024-03-14markov: support animated emojiArjun Satarkar
Also support the old ping syntax with an exclamation mark. I don't think clients use it but it still works and bots can send it, so better to allow it.
2024-03-14markov: process semicolonsArjun Satarkar
2024-03-13markov: improve exceptionsArjun Satarkar
2024-03-12markov: reduce code duplication, add command to nuke guild dataArjun Satarkar
This also fixes bugs related to inconsistent handling of per-member and whole-guild generation.
2024-03-11markov: escape markdown in exclusion listsArjun Satarkar
2024-03-11Add skeleton of starboard cog; improve menu handlingArjun Satarkar
We were previously not escaping mentions right in `qotd list` and `qotd suggest`. I think everyone and here could have maybe got through? Not sure about the defaults there. Also improved the handling in Markov where previously we'd been 1. allowing mentions but 2. editing the message from a dummy one so they didn't ping, which I think was out of some idea of preserving the exact text of an exclusion but it seems inelegant.
2024-03-09markov: don't add space after forward slashArjun Satarkar
2024-03-07markov: handle threads properlyArjun Satarkar
2024-03-07Add ignored_string feature, refactor, improve tokenizationArjun Satarkar
2024-03-07markov: normalize message content betterArjun Satarkar
We now do NFKC normalization and replace U+2019 with the normal ASCII single quote.
2024-03-07markov: tokenize custom emoji as one tokenArjun Satarkar
2024-03-06markov: small logic improvement in unlikely caseArjun Satarkar
2024-03-06markov: switch from reply to sendArjun Satarkar
This is useful for certain purposes
2024-03-06markov: remove ignore_string, add blacklist_stringArjun Satarkar
2024-03-06markov: ignore non-guild messagesArjun Satarkar
2024-03-06markov: improve ignore_string list formattingArjun Satarkar
2024-03-06markov: add ignored_string commandsArjun Satarkar
2024-03-06markov: don't force to be lowercaseArjun Satarkar
2024-03-06markov: check enabled/opted-in status in generateArjun Satarkar
2024-03-06Add markov cogArjun Satarkar