aboutsummaryrefslogtreecommitdiff
path: root/markov
diff options
context:
space:
mode:
Diffstat (limited to 'markov')
-rw-r--r--markov/data/migrations/init.sql (renamed from markov/data/init.sql)0
-rw-r--r--markov/markov.py5
2 files changed, 3 insertions, 2 deletions
diff --git a/markov/data/init.sql b/markov/data/migrations/init.sql
index 71ec073..71ec073 100644
--- a/markov/data/init.sql
+++ b/markov/data/migrations/init.sql
diff --git a/markov/markov.py b/markov/markov.py
index d7cf14b..9965d65 100644
--- a/markov/markov.py
+++ b/markov/markov.py
@@ -36,7 +36,8 @@ class Markov(commands.Cog):
async def cog_load(self):
with open(
- redbot.core.data_manager.bundled_data_path(self) / "init.sql", "r"
+ redbot.core.data_manager.bundled_data_path(self) / "migrations/init.sql",
+ "r",
) as setup_script_file:
async with aiosqlite.connect(self.db_path) as db:
await db.executescript(setup_script_file.read())
@@ -92,7 +93,7 @@ class Markov(commands.Cog):
+ [
token
for token in re.findall(
- r"[\w']+|[\.,!?\/;\(\)]|<a?:\w+:\d+>|<#\d+>|<@!?\d+>", content
+ r"[\w']+|[\.,!?/;()]|<a?:\w+:\d+>|<#\d+>|<@!?\d+>", content
)
if len(token) <= MAX_TOKEN_LENGTH
]