sopel-ai 1.2.0__py3-none-any.whl → 1.3.0__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- sopel_ai/core.py +4 -3
- {sopel_ai-1.2.0.dist-info → sopel_ai-1.3.0.dist-info}/METADATA +2 -2
- sopel_ai-1.3.0.dist-info/RECORD +11 -0
- sopel_ai-1.2.0.dist-info/RECORD +0 -11
- {sopel_ai-1.2.0.dist-info → sopel_ai-1.3.0.dist-info}/LICENSE.txt +0 -0
- {sopel_ai-1.2.0.dist-info → sopel_ai-1.3.0.dist-info}/WHEEL +0 -0
- {sopel_ai-1.2.0.dist-info → sopel_ai-1.3.0.dist-info}/entry_points.txt +0 -0
- {sopel_ai-1.2.0.dist-info → sopel_ai-1.3.0.dist-info}/top_level.txt +0 -0
sopel_ai/core.py
CHANGED
@@ -54,6 +54,7 @@ def _checkDB(fileName: str) -> TinyDB:
|
|
54
54
|
|
55
55
|
if not _database:
|
56
56
|
_database = TinyDB(fileName)
|
57
|
+
_database.table('_default', cache_size = 0)
|
57
58
|
|
58
59
|
return _database
|
59
60
|
|
@@ -201,10 +202,10 @@ def setModelForUser(modelID: int, nick: str, fileNameDB: str, key = None) -> str
|
|
201
202
|
if modelID not in range(len(models)):
|
202
203
|
raise SopelAIError('modelID outside of available models index range')
|
203
204
|
|
204
|
-
|
205
|
+
query = Query()
|
205
206
|
|
206
|
-
if _database.search(
|
207
|
-
_database.update({ 'model': models[modelID], },
|
207
|
+
if _database.search(query.nick == nick):
|
208
|
+
_database.update({ 'model': models[modelID], }, query.nick == nick)
|
208
209
|
else:
|
209
210
|
_database.insert({ 'nick': nick, 'model': models[modelID], })
|
210
211
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: sopel-ai
|
3
|
-
Version: 1.
|
3
|
+
Version: 1.3.0
|
4
4
|
Summary: Sopel AI - an LLM enhanced chat bot plug-in
|
5
5
|
Author-email: The SopelAI team <sopel_ai@cime.net>
|
6
6
|
License: BSD-3-Clause
|
@@ -24,7 +24,7 @@ Requires-Dist: perplexipy
|
|
24
24
|
Requires-Dist: sopel (>=7.1)
|
25
25
|
Requires-Dist: tinydb
|
26
26
|
|
27
|
-
% sopel_ai(1) Version 1.
|
27
|
+
% sopel_ai(1) Version 1.3.0 chatbot plugin
|
28
28
|
|
29
29
|
Name
|
30
30
|
====
|
@@ -0,0 +1,11 @@
|
|
1
|
+
sopel_ai/__init__.py,sha256=UXSuXZj_p860rLAiewSe5nbKg-qbIEcXq6jkqYmaMnI,2531
|
2
|
+
sopel_ai/config.py,sha256=y0vbvfeDjjfLUOvTJ3W56mAGVpJxeizrXJbCaFW4ZXk,867
|
3
|
+
sopel_ai/core.py,sha256=x34P4We66tgo5Q229qvlBvY7VuC2ziq9vXkUULVs06M,7277
|
4
|
+
sopel_ai/errors.py,sha256=XMVgFk4Rw64Z0UO3ZInp-N6LP0GRG8NFIuXKnhu5rLo,192
|
5
|
+
sopel_ai/plugin.py,sha256=51mYp6B_mUtgS6mL-IMhK8Qiz_Rw_qAwmTLdML-qQ2o,6800
|
6
|
+
sopel_ai-1.3.0.dist-info/LICENSE.txt,sha256=I8aHapysmbM9F3y-rUfp011GQoosNO5L8pzl7IKgPnE,1531
|
7
|
+
sopel_ai-1.3.0.dist-info/METADATA,sha256=icj0eXGIZ4KFL1vh0FKLdV6yefIEdTyz0cUV0qLNE7k,6200
|
8
|
+
sopel_ai-1.3.0.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
9
|
+
sopel_ai-1.3.0.dist-info/entry_points.txt,sha256=7Juxcn6L4j6F83TjkviiTwiyXLM4gZxAAXFQDR2G_m4,43
|
10
|
+
sopel_ai-1.3.0.dist-info/top_level.txt,sha256=kpNMzNEGbhCXkyn7oc3uQPmrX1J6qLxn59IcZBpwSYg,9
|
11
|
+
sopel_ai-1.3.0.dist-info/RECORD,,
|
sopel_ai-1.2.0.dist-info/RECORD
DELETED
@@ -1,11 +0,0 @@
|
|
1
|
-
sopel_ai/__init__.py,sha256=UXSuXZj_p860rLAiewSe5nbKg-qbIEcXq6jkqYmaMnI,2531
|
2
|
-
sopel_ai/config.py,sha256=y0vbvfeDjjfLUOvTJ3W56mAGVpJxeizrXJbCaFW4ZXk,867
|
3
|
-
sopel_ai/core.py,sha256=r5lnH8lcXenc2Ln3Qha2hoAggWUP5ZyZniZrdl9IIsQ,7240
|
4
|
-
sopel_ai/errors.py,sha256=XMVgFk4Rw64Z0UO3ZInp-N6LP0GRG8NFIuXKnhu5rLo,192
|
5
|
-
sopel_ai/plugin.py,sha256=51mYp6B_mUtgS6mL-IMhK8Qiz_Rw_qAwmTLdML-qQ2o,6800
|
6
|
-
sopel_ai-1.2.0.dist-info/LICENSE.txt,sha256=I8aHapysmbM9F3y-rUfp011GQoosNO5L8pzl7IKgPnE,1531
|
7
|
-
sopel_ai-1.2.0.dist-info/METADATA,sha256=mzBWiQuuRZjTrk9efPFkhOXnvUr7PmAz7lttRYazRtc,6200
|
8
|
-
sopel_ai-1.2.0.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
|
9
|
-
sopel_ai-1.2.0.dist-info/entry_points.txt,sha256=7Juxcn6L4j6F83TjkviiTwiyXLM4gZxAAXFQDR2G_m4,43
|
10
|
-
sopel_ai-1.2.0.dist-info/top_level.txt,sha256=kpNMzNEGbhCXkyn7oc3uQPmrX1J6qLxn59IcZBpwSYg,9
|
11
|
-
sopel_ai-1.2.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|