pygpt-net 2.4.38__py3-none-any.whl → 2.4.40__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- CHANGELOG.md +19 -0
- README.md +25 -2
- pygpt_net/CHANGELOG.txt +19 -0
- pygpt_net/__init__.py +3 -3
- pygpt_net/controller/__init__.py +7 -3
- pygpt_net/controller/audio/__init__.py +9 -1
- pygpt_net/controller/calendar/__init__.py +3 -1
- pygpt_net/controller/chat/input.py +2 -1
- pygpt_net/controller/chat/render.py +8 -5
- pygpt_net/controller/ctx/__init__.py +33 -25
- pygpt_net/controller/ctx/common.py +3 -2
- pygpt_net/controller/debug/__init__.py +13 -2
- pygpt_net/controller/dialogs/confirm.py +2 -2
- pygpt_net/controller/kernel/__init__.py +2 -1
- pygpt_net/controller/lang/custom.py +2 -7
- pygpt_net/controller/lang/mapping.py +2 -2
- pygpt_net/controller/layout.py +2 -2
- pygpt_net/controller/notepad.py +14 -10
- pygpt_net/controller/theme/nodes.py +2 -5
- pygpt_net/controller/tools/__init__.py +37 -1
- pygpt_net/controller/ui/__init__.py +1 -5
- pygpt_net/controller/ui/tabs.py +295 -60
- pygpt_net/core/command.py +3 -1
- pygpt_net/core/ctx/__init__.py +16 -2
- pygpt_net/core/ctx/container.py +18 -11
- pygpt_net/core/ctx/output.py +86 -67
- pygpt_net/core/debug/tabs.py +5 -2
- pygpt_net/core/filesystem/url.py +7 -3
- pygpt_net/core/render/base.py +14 -3
- pygpt_net/core/render/markdown/renderer.py +3 -1
- pygpt_net/core/render/plain/renderer.py +3 -3
- pygpt_net/core/render/web/body.py +10 -4
- pygpt_net/core/render/web/renderer.py +213 -41
- pygpt_net/core/tabs/__init__.py +268 -98
- pygpt_net/core/tabs/tab.py +16 -4
- pygpt_net/core/web.py +127 -1
- pygpt_net/data/config/config.json +12 -5
- pygpt_net/data/config/models.json +3 -3
- pygpt_net/data/config/modes.json +3 -3
- pygpt_net/data/css/web-blocks.css +18 -0
- pygpt_net/data/css/web-blocks.light.css +7 -0
- pygpt_net/data/css/web-chatgpt.css +8 -0
- pygpt_net/data/css/web-chatgpt_wide.css +8 -0
- pygpt_net/data/icons/split_screen.svg +1 -0
- pygpt_net/data/locale/locale.de.ini +3 -0
- pygpt_net/data/locale/locale.en.ini +6 -1
- pygpt_net/data/locale/locale.es.ini +3 -0
- pygpt_net/data/locale/locale.fr.ini +3 -0
- pygpt_net/data/locale/locale.it.ini +3 -0
- pygpt_net/data/locale/locale.pl.ini +4 -1
- pygpt_net/data/locale/locale.uk.ini +3 -0
- pygpt_net/data/locale/locale.zh.ini +3 -0
- pygpt_net/data/locale/plugin.cmd_web.de.ini +2 -0
- pygpt_net/data/locale/plugin.cmd_web.en.ini +20 -10
- pygpt_net/data/locale/plugin.cmd_web.es.ini +2 -0
- pygpt_net/data/locale/plugin.cmd_web.fr.ini +2 -0
- pygpt_net/data/locale/plugin.cmd_web.it.ini +2 -0
- pygpt_net/data/locale/plugin.cmd_web.pl.ini +2 -0
- pygpt_net/data/locale/plugin.cmd_web.uk.ini +2 -0
- pygpt_net/data/locale/plugin.cmd_web.zh.ini +2 -0
- pygpt_net/icons.qrc +1 -0
- pygpt_net/icons_rc.py +165 -136
- pygpt_net/item/ctx.py +46 -24
- pygpt_net/plugin/audio_input/simple.py +4 -2
- pygpt_net/plugin/audio_output/__init__.py +4 -1
- pygpt_net/plugin/base/plugin.py +18 -4
- pygpt_net/plugin/cmd_code_interpreter/__init__.py +39 -37
- pygpt_net/plugin/cmd_code_interpreter/runner.py +25 -12
- pygpt_net/plugin/cmd_web/__init__.py +46 -6
- pygpt_net/plugin/cmd_web/config.py +74 -48
- pygpt_net/plugin/cmd_web/websearch.py +61 -28
- pygpt_net/plugin/cmd_web/worker.py +79 -13
- pygpt_net/provider/core/config/patch.py +29 -1
- pygpt_net/provider/core/ctx/base.py +4 -1
- pygpt_net/provider/core/ctx/db_sqlite/__init__.py +10 -1
- pygpt_net/provider/core/ctx/db_sqlite/storage.py +22 -1
- pygpt_net/tools/__init__.py +9 -1
- pygpt_net/tools/base.py +15 -1
- pygpt_net/tools/code_interpreter/__init__.py +174 -75
- pygpt_net/tools/code_interpreter/ui/dialogs.py +21 -103
- pygpt_net/tools/code_interpreter/ui/widgets.py +284 -9
- pygpt_net/tools/html_canvas/__init__.py +78 -23
- pygpt_net/tools/html_canvas/ui/dialogs.py +46 -62
- pygpt_net/tools/html_canvas/ui/widgets.py +96 -3
- pygpt_net/ui/base/context_menu.py +2 -2
- pygpt_net/ui/layout/chat/input.py +10 -18
- pygpt_net/ui/layout/chat/output.py +26 -44
- pygpt_net/ui/layout/ctx/ctx_list.py +13 -4
- pygpt_net/ui/layout/toolbox/footer.py +18 -2
- pygpt_net/ui/main.py +2 -2
- pygpt_net/ui/menu/debug.py +11 -1
- pygpt_net/ui/widget/filesystem/explorer.py +2 -2
- pygpt_net/ui/widget/lists/context.py +26 -5
- pygpt_net/ui/widget/tabs/Input.py +2 -2
- pygpt_net/ui/widget/tabs/body.py +2 -1
- pygpt_net/ui/widget/tabs/layout.py +195 -0
- pygpt_net/ui/widget/tabs/output.py +209 -55
- pygpt_net/ui/widget/textarea/html.py +11 -1
- pygpt_net/ui/widget/textarea/output.py +10 -1
- pygpt_net/ui/widget/textarea/web.py +49 -9
- {pygpt_net-2.4.38.dist-info → pygpt_net-2.4.40.dist-info}/METADATA +26 -3
- {pygpt_net-2.4.38.dist-info → pygpt_net-2.4.40.dist-info}/RECORD +105 -103
- {pygpt_net-2.4.38.dist-info → pygpt_net-2.4.40.dist-info}/LICENSE +0 -0
- {pygpt_net-2.4.38.dist-info → pygpt_net-2.4.40.dist-info}/WHEEL +0 -0
- {pygpt_net-2.4.38.dist-info → pygpt_net-2.4.40.dist-info}/entry_points.txt +0 -0
@@ -50,6 +50,8 @@ prompt_summarize_url.description = Шаблон для підсумування
|
|
50
50
|
prompt_summarize_url.label = Шаблон підсумування (відкриття URL)
|
51
51
|
provider.description = Виберіть провайдера пошукової системи, за замовчуванням: Google.
|
52
52
|
provider.label = Провайдер
|
53
|
+
raw.label = Використовувати сирий контент (без узагальнення)
|
54
|
+
raw.description = Повернути сирий контент з пошуку в Інтернеті замість узагальненого контенту
|
53
55
|
summary_max_tokens.description = Максимальна кількість токенів у виводі при створенні підсумку.
|
54
56
|
summary_max_tokens.label = Макс. токенів підсумування
|
55
57
|
summary_model.description = Модель, яка використовується для підсумування вебсторінок, за замовчуванням: gpt-3.5-turbo-1106.
|
@@ -50,6 +50,8 @@ prompt_summarize_url.description = 用于总结指定URL页面的提示。
|
|
50
50
|
prompt_summarize_url.label = 总结URL页面的提示
|
51
51
|
provider.description = 选择搜索引擎提供者,默认为Google。
|
52
52
|
provider.label = 提供者
|
53
|
+
raw.label = 使用原始内容(不进行总结)
|
54
|
+
raw.description = 返回来自网络搜索的原始内容,而不是总结的内容
|
53
55
|
summary_max_tokens.description = 在生成总结时输出的最大代币数。
|
54
56
|
summary_max_tokens.label = 总结的最大代币数
|
55
57
|
summary_model.description = 用于总结网页的模型,默认为:gpt-3.5-turbo-1106。
|
pygpt_net/icons.qrc
CHANGED
@@ -107,6 +107,7 @@
|
|
107
107
|
<file alias="share.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/share.svg</file>
|
108
108
|
<file alias="shedule.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/shedule.svg</file>
|
109
109
|
<file alias="sort.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/sort.svg</file>
|
110
|
+
<file alias="split_screen.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/split_screen.svg</file>
|
110
111
|
<file alias="stack.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/stack.svg</file>
|
111
112
|
<file alias="stacks.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/stacks.svg</file>
|
112
113
|
<file alias="star.svg">/home/marcin/Dev/py-gpt/bin/../src/pygpt_net/data/icons/star.svg</file>
|
pygpt_net/icons_rc.py
CHANGED
@@ -84,6 +84,29 @@ v80h-80Zm160 0v-\
|
|
84
84
|
0Zm0-160v-80h80v\
|
85
85
|
80h-80Z\x22/></svg>\
|
86
86
|
\
|
87
|
+
\x00\x00\x01P\
|
88
|
+
<\
|
89
|
+
svg xmlns=\x22http:\
|
90
|
+
//www.w3.org/200\
|
91
|
+
0/svg\x22 height=\x222\
|
92
|
+
4px\x22 viewBox=\x220 \
|
93
|
+
-960 960 960\x22 wi\
|
94
|
+
dth=\x2224px\x22 fill=\
|
95
|
+
\x22#686868\x22><path \
|
96
|
+
d=\x22M520-320h200v\
|
97
|
+
-320H520v320Zm-2\
|
98
|
+
80 0h200v-320H24\
|
99
|
+
0v320Zm-80 160q-\
|
100
|
+
33 0-56.5-23.5T8\
|
101
|
+
0-240v-480q0-33 \
|
102
|
+
23.5-56.5T160-80\
|
103
|
+
0h640q33 0 56.5 \
|
104
|
+
23.5T880-720v480\
|
105
|
+
q0 33-23.5 56.5T\
|
106
|
+
800-160H160Zm640\
|
107
|
+
-560H160v480h640\
|
108
|
+
v-480Zm-640 0v48\
|
109
|
+
0-480Z\x22/></svg>\
|
87
110
|
\x00\x00\x01C\
|
88
111
|
<\
|
89
112
|
svg xmlns=\x22http:\
|
@@ -3696,6 +3719,10 @@ qt_resource_name = b"\
|
|
3696
3719
|
\x01\x0bC\x87\
|
3697
3720
|
\x00r\
|
3698
3721
|
\x00e\x00s\x00i\x00z\x00e\x00.\x00s\x00v\x00g\
|
3722
|
+
\x00\x10\
|
3723
|
+
\x0b\x12\xf3\x07\
|
3724
|
+
\x00s\
|
3725
|
+
\x00p\x00l\x00i\x00t\x00_\x00s\x00c\x00r\x00e\x00e\x00n\x00.\x00s\x00v\x00g\
|
3699
3726
|
\x00\x08\
|
3700
3727
|
\x08zW\xa7\
|
3701
3728
|
\x00d\
|
@@ -4243,281 +4270,283 @@ qt_resource_name = b"\
|
|
4243
4270
|
qt_resource_struct = b"\
|
4244
4271
|
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
|
4245
4272
|
\x00\x00\x00\x00\x00\x00\x00\x00\
|
4246
|
-
\x00\x00\x00\x00\x00\x02\x00\x00\x00\
|
4273
|
+
\x00\x00\x00\x00\x00\x02\x00\x00\x00\x8a\x00\x00\x00\x02\
|
4247
4274
|
\x00\x00\x00\x00\x00\x00\x00\x00\
|
4248
|
-
\x00\x00\x0c\
|
4275
|
+
\x00\x00\x0c\xb2\x00\x00\x00\x00\x00\x01\x00\x00\xb8\xae\
|
4249
4276
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4250
|
-
\x00\x00\
|
4277
|
+
\x00\x00\x0e\x98\x00\x00\x00\x00\x00\x01\x00\x00\xd2\xa6\
|
4251
4278
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4252
|
-
\x00\x00\x0a\
|
4279
|
+
\x00\x00\x0a\xf8\x00\x00\x00\x00\x00\x01\x00\x00\x9e\x5c\
|
4253
4280
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4254
|
-
\x00\x00\x06\
|
4281
|
+
\x00\x00\x06\xd8\x00\x00\x00\x00\x00\x01\x00\x00^\xa4\
|
4255
4282
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4256
|
-
\x00\x00\x02\
|
4283
|
+
\x00\x00\x02\xe6\x00\x00\x00\x00\x00\x01\x00\x00&\x9e\
|
4257
4284
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4258
|
-
\x00\x00\x02\
|
4285
|
+
\x00\x00\x02\xfc\x00\x00\x00\x00\x00\x01\x00\x00(\x8d\
|
4259
4286
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4260
4287
|
\x00\x00\x00B\x00\x00\x00\x00\x00\x01\x00\x00\x02\xda\
|
4261
4288
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4262
|
-
\x00\x00\x09\
|
4289
|
+
\x00\x00\x09\x82\x00\x00\x00\x00\x00\x01\x00\x00\x8a\x22\
|
4263
4290
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4264
|
-
\x00\x00\x08\
|
4291
|
+
\x00\x00\x08\xda\x00\x00\x00\x00\x00\x01\x00\x00\x81;\
|
4265
4292
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4266
|
-
\x00\x00\x08\
|
4293
|
+
\x00\x00\x08\xc0\x00\x00\x00\x00\x00\x01\x00\x00\x7f\xa7\
|
4267
4294
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4268
|
-
\x00\x00\
|
4295
|
+
\x00\x00\x08$\x00\x00\x00\x00\x00\x01\x00\x00t\x80\
|
4269
4296
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4270
|
-
\x00\x00\x08\
|
4297
|
+
\x00\x00\x08\xee\x00\x00\x00\x00\x00\x01\x00\x00\x83\x5c\
|
4271
4298
|
\x00\x00\x01\x8d\xf2\xd5$j\
|
4272
|
-
\x00\x00\x06\
|
4299
|
+
\x00\x00\x06\xb8\x00\x00\x00\x00\x00\x01\x00\x00]\x97\
|
4273
4300
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4274
|
-
\x00\x00\
|
4301
|
+
\x00\x00\x08t\x00\x00\x00\x00\x00\x01\x00\x00x/\
|
4275
4302
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4276
|
-
\x00\x00\
|
4303
|
+
\x00\x00\x07R\x00\x00\x00\x00\x00\x01\x00\x00g\xd0\
|
4277
4304
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4278
|
-
\x00\x00\
|
4305
|
+
\x00\x00\x02^\x00\x00\x00\x00\x00\x01\x00\x00\x1e\xb1\
|
4279
4306
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4280
|
-
\x00\x00\
|
4307
|
+
\x00\x00\x0d\x04\x00\x00\x00\x00\x00\x01\x00\x00\xbe;\
|
4281
4308
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4282
|
-
\x00\x00\x0a\
|
4309
|
+
\x00\x00\x0a\xe4\x00\x00\x00\x00\x00\x01\x00\x00\x9c\x99\
|
4283
4310
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4284
|
-
\x00\x00\
|
4311
|
+
\x00\x00\x02\x02\x00\x00\x00\x00\x00\x01\x00\x00\x18\x91\
|
4285
4312
|
\x00\x00\x01\x8f:\xa4\xe8\xf6\
|
4286
4313
|
\x00\x00\x00,\x00\x00\x00\x00\x00\x01\x00\x00\x01\xbc\
|
4287
4314
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4288
|
-
\x00\x00\
|
4315
|
+
\x00\x00\x04N\x00\x00\x00\x00\x00\x01\x00\x00:}\
|
4289
4316
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4290
|
-
\x00\x00\
|
4317
|
+
\x00\x00\x01J\x00\x00\x00\x00\x00\x01\x00\x00\x0ev\
|
4291
4318
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4292
|
-
\x00\x00\
|
4319
|
+
\x00\x00\x07|\x00\x00\x00\x00\x00\x01\x00\x00kK\
|
4293
4320
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4294
|
-
\x00\x00\x06
|
4321
|
+
\x00\x00\x06&\x00\x00\x00\x00\x00\x01\x00\x00U\x99\
|
4295
4322
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4296
|
-
\x00\x00\
|
4323
|
+
\x00\x00\x05\x98\x00\x00\x00\x00\x00\x01\x00\x00M\x06\
|
4297
4324
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4298
|
-
\x00\x00\x07\
|
4325
|
+
\x00\x00\x07\xae\x00\x00\x00\x00\x00\x01\x00\x00ny\
|
4299
4326
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4300
|
-
\x00\x00\x08
|
4327
|
+
\x00\x00\x08:\x00\x00\x00\x00\x00\x01\x00\x00u>\
|
4301
4328
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4302
|
-
\x00\x00\
|
4329
|
+
\x00\x00\x03\x18\x00\x00\x00\x00\x00\x01\x00\x00)\xc7\
|
4303
4330
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4304
|
-
\x00\x00\
|
4331
|
+
\x00\x00\x01\x96\x00\x00\x00\x00\x00\x01\x00\x00\x13\xba\
|
4305
4332
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4306
|
-
\x00\x00\
|
4333
|
+
\x00\x00\x0b\x10\x00\x00\x00\x00\x00\x01\x00\x00\xa0>\
|
4307
4334
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4308
|
-
\x00\x00\x02
|
4335
|
+
\x00\x00\x02*\x00\x00\x00\x00\x00\x01\x00\x00\x19\xfd\
|
4309
4336
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4310
|
-
\x00\x00\x01\
|
4337
|
+
\x00\x00\x01\xae\x00\x00\x00\x00\x00\x01\x00\x00\x15Y\
|
4311
4338
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4312
|
-
\x00\x00\
|
4339
|
+
\x00\x00\x0a|\x00\x00\x00\x00\x00\x01\x00\x00\x98s\
|
4313
4340
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4314
4341
|
\x00\x00\x00\x10\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
|
4315
4342
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4316
|
-
\x00\x00\
|
4343
|
+
\x00\x00\x0cZ\x00\x00\x00\x00\x00\x01\x00\x00\xb5\x94\
|
4317
4344
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4318
|
-
\x00\x00\x0b\
|
4345
|
+
\x00\x00\x0b\xfe\x00\x00\x00\x00\x00\x01\x00\x00\xb0A\
|
4319
4346
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4320
|
-
\x00\x00\x01\
|
4347
|
+
\x00\x00\x01\xec\x00\x00\x00\x00\x00\x01\x00\x00\x17=\
|
4321
4348
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4322
|
-
\x00\x00\
|
4349
|
+
\x00\x00\x0b\xa0\x00\x00\x00\x00\x00\x01\x00\x00\xa9\x97\
|
4323
4350
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4324
|
-
\x00\x00\x02\
|
4351
|
+
\x00\x00\x02\xcc\x00\x00\x00\x00\x00\x01\x00\x00$\xeb\
|
4325
4352
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4326
|
-
\x00\x00\x0d
|
4353
|
+
\x00\x00\x0d&\x00\x00\x00\x00\x00\x01\x00\x00\xbf8\
|
4327
4354
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4328
|
-
\x00\x00\
|
4355
|
+
\x00\x00\x05\x0e\x00\x00\x00\x00\x00\x01\x00\x00D\xac\
|
4329
4356
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4330
|
-
\x00\x00\
|
4357
|
+
\x00\x00\x08\x92\x00\x00\x00\x00\x00\x01\x00\x00y|\
|
4331
4358
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4332
|
-
\x00\x00\
|
4359
|
+
\x00\x00\x0bn\x00\x00\x00\x00\x00\x01\x00\x00\xa6M\
|
4333
4360
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4334
|
-
\x00\x00\x0e
|
4361
|
+
\x00\x00\x0e*\x00\x00\x00\x00\x00\x01\x00\x00\xcd\xb0\
|
4335
4362
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4336
|
-
\x00\x00\
|
4363
|
+
\x00\x00\x0e\x5c\x00\x00\x00\x00\x00\x01\x00\x00\xd0\x07\
|
4337
4364
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4338
|
-
\x00\x00\x0d
|
4365
|
+
\x00\x00\x0d<\x00\x00\x00\x00\x00\x01\x00\x00\xbf\xf9\
|
4339
4366
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4340
|
-
\x00\x00\x0c
|
4367
|
+
\x00\x00\x0c\x86\x00\x00\x00\x00\x00\x01\x00\x00\xb7\x03\
|
4341
4368
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4342
|
-
\x00\x00\
|
4369
|
+
\x00\x00\x05D\x00\x00\x00\x00\x00\x01\x00\x00FF\
|
4343
4370
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4344
|
-
\x00\x00\
|
4371
|
+
\x00\x00\x074\x00\x00\x00\x00\x00\x01\x00\x00e\xf7\
|
4345
4372
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4346
|
-
\x00\x00\x01
|
4373
|
+
\x00\x00\x01*\x00\x00\x00\x00\x00\x01\x00\x00\x0c\xe7\
|
4347
4374
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4348
|
-
\x00\x00\x09\
|
4375
|
+
\x00\x00\x09\xe8\x00\x01\x00\x00\x00\x01\x00\x00\x8e\x85\
|
4349
4376
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4350
|
-
\x00\x00\
|
4377
|
+
\x00\x00\x0bD\x00\x00\x00\x00\x00\x01\x00\x00\xa3\x10\
|
4351
4378
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4352
|
-
\x00\x00\x09\
|
4379
|
+
\x00\x00\x09\xca\x00\x00\x00\x00\x00\x01\x00\x00\x8dW\
|
4353
4380
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4354
|
-
\x00\x00\
|
4381
|
+
\x00\x00\x0cp\x00\x00\x00\x00\x00\x01\x00\x00\xb6F\
|
4355
4382
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4356
|
-
\x00\x00\
|
4383
|
+
\x00\x00\x03\x5c\x00\x00\x00\x00\x00\x01\x00\x00-o\
|
4357
4384
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4358
|
-
\x00\x00\x05\
|
4385
|
+
\x00\x00\x05\xb2\x00\x00\x00\x00\x00\x01\x00\x00NS\
|
4359
4386
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4360
|
-
\x00\x00\
|
4387
|
+
\x00\x00\x05z\x00\x00\x00\x00\x00\x01\x00\x00Ic\
|
4361
4388
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4362
|
-
\x00\x00\x0b\
|
4389
|
+
\x00\x00\x0b\xe6\x00\x00\x00\x00\x00\x01\x00\x00\xae\xec\
|
4363
4390
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4364
|
-
\x00\x00\x04\
|
4391
|
+
\x00\x00\x04\xc2\x00\x00\x00\x00\x00\x01\x00\x00@\xbc\
|
4365
4392
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4366
|
-
\x00\x00\x05\
|
4393
|
+
\x00\x00\x05\xf6\x00\x00\x00\x00\x00\x01\x00\x00S\xa0\
|
4367
4394
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4368
|
-
\x00\x00\
|
4395
|
+
\x00\x00\x06t\x00\x00\x00\x00\x00\x01\x00\x00[\x87\
|
4369
4396
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4370
|
-
\x00\x00\
|
4397
|
+
\x00\x00\x06\x9a\x00\x00\x00\x00\x00\x01\x00\x00\x5c\x81\
|
4371
4398
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4372
|
-
\x00\x00\x0a\
|
4399
|
+
\x00\x00\x0a\xa8\x00\x00\x00\x00\x00\x01\x00\x00\x9a6\
|
4373
4400
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4374
|
-
\x00\x00\x0a
|
4401
|
+
\x00\x00\x0a,\x00\x00\x00\x00\x00\x01\x00\x00\x94\xf8\
|
4375
4402
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4376
|
-
\x00\x00\x00\
|
4403
|
+
\x00\x00\x00\x82\x00\x00\x00\x00\x00\x01\x00\x00\x05\xc3\
|
4377
4404
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4378
|
-
\x00\x00\x09\
|
4405
|
+
\x00\x00\x09\xfe\x00\x00\x00\x00\x00\x01\x00\x00\x8f\xb2\
|
4379
4406
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4380
|
-
\x00\x00\
|
4407
|
+
\x00\x00\x0d\x90\x00\x00\x00\x00\x00\x01\x00\x00\xc4\xc8\
|
4381
4408
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4382
|
-
\x00\x00\x0d\
|
4409
|
+
\x00\x00\x0d\xa8\x00\x00\x00\x00\x00\x01\x00\x00\xc6\xfa\
|
4383
4410
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4384
|
-
\x00\x00\
|
4411
|
+
\x00\x00\x02v\x00\x00\x00\x00\x00\x01\x00\x00 \x94\
|
4385
4412
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4386
|
-
\x00\x00\
|
4413
|
+
\x00\x00\x0c\x1a\x00\x00\x00\x00\x00\x01\x00\x00\xb2\xd9\
|
4387
4414
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4388
|
-
\x00\x00\
|
4415
|
+
\x00\x00\x04\x0c\x00\x00\x00\x00\x00\x01\x00\x007J\
|
4389
4416
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4390
|
-
\x00\x00\
|
4417
|
+
\x00\x00\x07\x98\x00\x00\x00\x00\x00\x01\x00\x00l\xf5\
|
4391
4418
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4392
|
-
\x00\x00\x0b
|
4419
|
+
\x00\x00\x0b.\x00\x00\x00\x00\x00\x01\x00\x00\xa1A\
|
4393
4420
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4394
|
-
\x00\x00\
|
4421
|
+
\x00\x00\x03F\x00\x00\x00\x00\x00\x01\x00\x00,c\
|
4395
4422
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4396
|
-
\x00\x00\
|
4423
|
+
\x00\x00\x08\x0c\x00\x00\x00\x00\x00\x01\x00\x00rg\
|
4397
4424
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4398
|
-
\x00\x00\
|
4425
|
+
\x00\x00\x06\x5c\x00\x00\x00\x00\x00\x01\x00\x00Y\x1c\
|
4399
4426
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4400
|
-
\x00\x00\x01\
|
4427
|
+
\x00\x00\x01\xd2\x00\x00\x00\x00\x00\x01\x00\x00\x16\x0d\
|
4401
4428
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4402
|
-
\x00\x00\x02
|
4429
|
+
\x00\x00\x02@\x00\x00\x00\x00\x00\x01\x00\x00\x1a\xe1\
|
4403
4430
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4404
|
-
\x00\x00\x03\
|
4431
|
+
\x00\x00\x03\xd0\x00\x00\x00\x00\x00\x01\x00\x005\x04\
|
4405
4432
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4406
|
-
\x00\x00\
|
4433
|
+
\x00\x00\x04\x8a\x00\x00\x00\x00\x00\x01\x00\x00>\xac\
|
4407
4434
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4408
|
-
\x00\x00\x02\
|
4435
|
+
\x00\x00\x02\xb2\x00\x00\x00\x00\x00\x01\x00\x00#\xb5\
|
4409
4436
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4410
|
-
\x00\x00\
|
4437
|
+
\x00\x00\x06B\x00\x00\x00\x00\x00\x01\x00\x00W\x82\
|
4411
4438
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4412
|
-
\x00\x00\x04\
|
4439
|
+
\x00\x00\x04\xda\x00\x00\x00\x00\x00\x01\x00\x00A\xdb\
|
4413
4440
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4414
|
-
\x00\x00\
|
4441
|
+
\x00\x00\x0e\x08\x00\x00\x00\x00\x00\x01\x00\x00\xcc \
|
4415
4442
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4416
|
-
\x00\x00\
|
4443
|
+
\x00\x00\x0b\x8c\x00\x00\x00\x00\x00\x01\x00\x00\xa8V\
|
4417
4444
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4418
|
-
\x00\x00\x0d
|
4445
|
+
\x00\x00\x0d`\x00\x00\x00\x00\x00\x01\x00\x00\xc1\xad\
|
4419
4446
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4420
|
-
\x00\x00\x04\
|
4447
|
+
\x00\x00\x04\xf6\x00\x00\x00\x00\x00\x01\x00\x00Cg\
|
4421
4448
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4422
|
-
\x00\x00\x05\
|
4449
|
+
\x00\x00\x05\xde\x00\x00\x00\x00\x00\x01\x00\x00Q\xed\
|
4423
4450
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4424
|
-
\x00\x00\x03
|
4451
|
+
\x00\x00\x03\xa4\x00\x00\x00\x00\x00\x01\x00\x001\x0f\
|
4425
4452
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4426
|
-
\x00\x00\x03\
|
4453
|
+
\x00\x00\x03\xbc\x00\x00\x00\x00\x00\x01\x00\x002f\
|
4427
4454
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4428
|
-
\x00\x00\x0b\
|
4455
|
+
\x00\x00\x0b\xcc\x00\x00\x00\x00\x00\x01\x00\x00\xad\xbf\
|
4429
4456
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4430
|
-
\x00\x00\x06\
|
4457
|
+
\x00\x00\x06\xf4\x00\x00\x00\x00\x00\x01\x00\x00a\x02\
|
4431
4458
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4432
|
-
\x00\x00\x05
|
4433
|
-
\x00\x00\x01\x93\
|
4434
|
-
\x00\x00\x00\
|
4459
|
+
\x00\x00\x05&\x00\x00\x00\x00\x00\x01\x00\x00E\x8a\
|
4460
|
+
\x00\x00\x01\x93]\x82\x92\xc0\
|
4461
|
+
\x00\x00\x00\xb0\x00\x00\x00\x00\x00\x01\x00\x00\x08\x08\
|
4435
4462
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4436
|
-
\x00\x00\x07\
|
4463
|
+
\x00\x00\x07\xc8\x00\x00\x00\x00\x00\x01\x00\x00o\x91\
|
4437
4464
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4438
|
-
\x00\x00\
|
4465
|
+
\x00\x00\x00\x5c\x00\x00\x00\x00\x00\x01\x00\x00\x04o\
|
4466
|
+
\x00\x00\x01\x93\xb8\x90b\xd4\
|
4467
|
+
\x00\x00\x0d\xc2\x00\x00\x00\x00\x00\x01\x00\x00\xc8r\
|
4439
4468
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4440
|
-
\x00\x00\x08
|
4469
|
+
\x00\x00\x08\xa4\x00\x00\x00\x00\x00\x01\x00\x00|U\
|
4441
4470
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4442
|
-
\x00\x00\
|
4471
|
+
\x00\x00\x030\x00\x00\x00\x00\x00\x01\x00\x00+\xa3\
|
4443
4472
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4444
|
-
\x00\x00\
|
4473
|
+
\x00\x00\x03t\x00\x00\x00\x00\x00\x01\x00\x00.\xf5\
|
4445
4474
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4446
|
-
\x00\x00\x03\
|
4475
|
+
\x00\x00\x03\xf2\x00\x00\x00\x00\x00\x01\x00\x005\xcd\
|
4447
4476
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4448
|
-
\x00\x00\x09
|
4477
|
+
\x00\x00\x09*\x00\x00\x00\x00\x00\x01\x00\x00\x85\xea\
|
4449
4478
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4450
|
-
\x00\x00\x00\
|
4479
|
+
\x00\x00\x00\xc6\x00\x00\x00\x00\x00\x01\x00\x00\x09Q\
|
4451
4480
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4452
|
-
\x00\x00\x00\
|
4481
|
+
\x00\x00\x00\xe0\x00\x00\x00\x00\x00\x01\x00\x00\x0aY\
|
4453
4482
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4454
|
-
\x00\x00\
|
4483
|
+
\x00\x00\x06\x0e\x00\x00\x00\x00\x00\x01\x00\x00T\xe7\
|
4455
4484
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4456
|
-
\x00\x00\x04\
|
4485
|
+
\x00\x00\x04\xaa\x00\x00\x00\x00\x00\x01\x00\x00?s\
|
4457
4486
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4458
|
-
\x00\x00\
|
4487
|
+
\x00\x00\x0bX\x00\x00\x00\x00\x00\x01\x00\x00\xa5.\
|
4459
4488
|
\x00\x00\x01\x8d\x5c(\xc7\x04\
|
4460
|
-
\x00\x00\
|
4489
|
+
\x00\x00\x04l\x00\x00\x00\x00\x00\x01\x00\x00;\xa9\
|
4461
4490
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4462
|
-
\x00\x00\
|
4491
|
+
\x00\x00\x0c4\x00\x00\x00\x00\x00\x01\x00\x00\xb4\x99\
|
4463
4492
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4464
|
-
\x00\x00\
|
4493
|
+
\x00\x00\x03\x8e\x00\x00\x00\x00\x00\x01\x00\x000I\
|
4465
4494
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4466
|
-
\x00\x00\x0b\
|
4495
|
+
\x00\x00\x0b\xb6\x00\x00\x00\x00\x00\x01\x00\x00\xab\x08\
|
4467
4496
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4468
|
-
\x00\x00\
|
4497
|
+
\x00\x00\x09B\x00\x00\x00\x00\x00\x01\x00\x00\x86\xad\
|
4469
4498
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4470
|
-
\x00\x00\x0d\
|
4499
|
+
\x00\x00\x0d\xe0\x00\x00\x00\x00\x00\x01\x00\x00\xc9\xc6\
|
4471
4500
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4472
|
-
\x00\x00\
|
4501
|
+
\x00\x00\x01\x80\x00\x00\x00\x00\x00\x01\x00\x00\x12\x82\
|
4473
4502
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4474
|
-
\x00\x00\
|
4503
|
+
\x00\x00\x0af\x00\x00\x00\x00\x00\x01\x00\x00\x97\xb2\
|
4475
4504
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4476
|
-
\x00\x00\x09\
|
4505
|
+
\x00\x00\x09\xa6\x00\x00\x00\x00\x00\x01\x00\x00\x8b\xcc\
|
4477
4506
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4478
|
-
\x00\x00\
|
4507
|
+
\x00\x00\x0dv\x00\x00\x00\x00\x00\x01\x00\x00\xc2\xd4\
|
4479
4508
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4480
|
-
\x00\x00\
|
4509
|
+
\x00\x00\x00\x98\x00\x00\x00\x00\x00\x01\x00\x00\x07\x0a\
|
4481
4510
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4482
|
-
\x00\x00\x0c\
|
4511
|
+
\x00\x00\x0c\xec\x00\x00\x00\x00\x00\x01\x00\x00\xbc\x90\
|
4483
4512
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4484
|
-
\x00\x00\
|
4513
|
+
\x00\x00\x07f\x00\x00\x00\x00\x00\x01\x00\x00i\x5c\
|
4485
4514
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4486
|
-
\x00\x00\
|
4515
|
+
\x00\x00\x09\x10\x00\x00\x00\x00\x00\x01\x00\x00\x84\xd7\
|
4487
4516
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4488
|
-
\x00\x00\x01
|
4517
|
+
\x00\x00\x01`\x00\x00\x00\x00\x00\x01\x00\x00\x10\x8d\
|
4489
4518
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4490
|
-
\x00\x00\x07\
|
4519
|
+
\x00\x00\x07\xf0\x00\x00\x00\x00\x00\x01\x00\x00p\x8e\
|
4491
4520
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4492
|
-
\x00\x00\
|
4521
|
+
\x00\x00\x0a\x92\x00\x00\x00\x00\x00\x01\x00\x00\x99f\
|
4493
4522
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4494
|
-
\x00\x00\
|
4523
|
+
\x00\x00\x08P\x00\x00\x00\x00\x00\x01\x00\x00w1\
|
4495
4524
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4496
|
-
\x00\x00\
|
4525
|
+
\x00\x00\x0aH\x00\x00\x00\x00\x00\x01\x00\x00\x95\xb6\
|
4497
4526
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4498
|
-
\x00\x00\
|
4527
|
+
\x00\x00\x07\x0e\x00\x00\x00\x00\x00\x01\x00\x00d-\
|
4499
4528
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4500
|
-
\x00\x00\
|
4529
|
+
\x00\x00\x09\x5c\x00\x00\x00\x00\x00\x01\x00\x00\x88'\
|
4501
4530
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4502
|
-
\x00\x00\
|
4531
|
+
\x00\x00\x0ez\x00\x00\x00\x00\x00\x01\x00\x00\xd1\x97\
|
4503
4532
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4504
|
-
\x00\x00\
|
4533
|
+
\x00\x00\x0eD\x00\x00\x00\x00\x00\x01\x00\x00\xce\xc5\
|
4505
4534
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4506
|
-
\x00\x00\
|
4535
|
+
\x00\x00\x02\x8c\x00\x00\x00\x00\x00\x01\x00\x00!\xe6\
|
4507
4536
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4508
|
-
\x00\x00\
|
4537
|
+
\x00\x00\x048\x00\x00\x00\x00\x00\x01\x00\x009)\
|
4509
4538
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4510
|
-
\x00\x00\x0a\
|
4539
|
+
\x00\x00\x0a\xc2\x00\x00\x00\x00\x00\x01\x00\x00\x9a\xe8\
|
4511
4540
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4512
|
-
\x00\x00\x0c\
|
4541
|
+
\x00\x00\x0c\xca\x00\x00\x00\x00\x00\x01\x00\x00\xba\xbd\
|
4513
4542
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4514
|
-
\x00\x00\
|
4543
|
+
\x00\x00\x05X\x00\x00\x00\x00\x00\x01\x00\x00H\x03\
|
4515
4544
|
\x00\x00\x01\x8d[e\x92\xcd\
|
4516
|
-
\x00\x00\
|
4545
|
+
\x00\x00\x01\x0c\x00\x00\x00\x00\x00\x01\x00\x00\x0b\xd1\
|
4517
4546
|
\x00\x00\x01\x8d[e\x92\xd1\
|
4518
|
-
\x00\x00\x05\
|
4547
|
+
\x00\x00\x05\xc6\x00\x00\x00\x00\x00\x01\x00\x00O\x09\
|
4519
4548
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4520
|
-
\x00\x00\
|
4549
|
+
\x00\x00\x0a\x16\x00\x00\x00\x00\x00\x01\x00\x00\x92\xce\
|
4521
4550
|
\x00\x00\x01\x8d[e\x92\xd5\
|
4522
4551
|
"
|
4523
4552
|
|
pygpt_net/item/ctx.py
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
# GitHub: https://github.com/szczyglis-dev/py-gpt #
|
7
7
|
# MIT License #
|
8
8
|
# Created By : Marcin Szczygliński #
|
9
|
-
# Updated Date: 2024.
|
9
|
+
# Updated Date: 2024.12.13 19:00:00 #
|
10
10
|
# ================================================== #
|
11
11
|
|
12
12
|
import copy
|
@@ -31,10 +31,13 @@ class CtxItem:
|
|
31
31
|
self.cmds_before = []
|
32
32
|
self.results = []
|
33
33
|
self.urls = []
|
34
|
+
self.urls_before = []
|
34
35
|
self.images = []
|
35
36
|
self.images_before = []
|
36
37
|
self.files = []
|
38
|
+
self.files_before = []
|
37
39
|
self.attachments = []
|
40
|
+
self.attachments_before = []
|
38
41
|
self.additional_ctx = []
|
39
42
|
self.reply = False
|
40
43
|
self.input = None
|
@@ -110,12 +113,21 @@ class CtxItem:
|
|
110
113
|
"""Clear current reply output"""
|
111
114
|
if self.reply:
|
112
115
|
self.urls = []
|
116
|
+
self.urls_before = []
|
113
117
|
|
114
118
|
def from_previous(self):
|
115
119
|
"""Copy data from previous context reply to current context"""
|
116
120
|
if self.prev_ctx is not None:
|
117
121
|
self.urls = copy.deepcopy(self.prev_ctx.urls)
|
118
|
-
self.images = copy.deepcopy(self.prev_ctx.
|
122
|
+
self.images = copy.deepcopy(self.prev_ctx.images)
|
123
|
+
if self.prev_ctx.images_before:
|
124
|
+
self.images = copy.deepcopy(self.prev_ctx.images_before)
|
125
|
+
if self.prev_ctx.files_before:
|
126
|
+
self.files = copy.deepcopy(self.prev_ctx.files_before)
|
127
|
+
if self.prev_ctx.attachments_before:
|
128
|
+
self.attachments = copy.deepcopy(self.prev_ctx.attachments_before)
|
129
|
+
if self.prev_ctx.urls_before:
|
130
|
+
self.urls = copy.deepcopy(self.prev_ctx.urls_before)
|
119
131
|
|
120
132
|
def has_commands(self) -> bool:
|
121
133
|
"""
|
@@ -178,20 +190,40 @@ class CtxItem:
|
|
178
190
|
"""
|
179
191
|
return {
|
180
192
|
"id": self.id,
|
181
|
-
"meta": self.meta.to_dict() if type(self.meta) == CtxMeta else self.meta,
|
182
193
|
"meta_id": self.meta_id,
|
194
|
+
"idx": self.idx,
|
195
|
+
"first": self.first,
|
196
|
+
"live": self.live,
|
197
|
+
"hidden": False,
|
198
|
+
"internal": self.internal,
|
183
199
|
"external_id": self.external_id,
|
184
200
|
# "stream": self.stream, # <-- do not dump stream response object
|
201
|
+
"reply": self.reply,
|
202
|
+
"current": self.current,
|
203
|
+
"stopped": self.stopped,
|
204
|
+
"is_audio": self.is_audio,
|
205
|
+
"is_vision": self.is_vision,
|
206
|
+
"agent_call": self.agent_call,
|
207
|
+
"tool_calls": self.tool_calls,
|
208
|
+
"index_meta": self.index_meta,
|
209
|
+
"doc_ids": self.doc_ids,
|
210
|
+
"sub_calls": 0,
|
211
|
+
"sub_call": False,
|
212
|
+
"sub_reply": False,
|
213
|
+
"extra": self.extra,
|
214
|
+
"extra_ctx": self.extra_ctx,
|
185
215
|
"cmds": self.cmds,
|
216
|
+
"cmds_before": self.cmds_before,
|
186
217
|
"results": self.results,
|
187
218
|
"urls": self.urls,
|
219
|
+
"urls_before": self.urls_before,
|
188
220
|
"images": self.images,
|
189
221
|
"images_before": self.images_before,
|
190
222
|
"files": self.files,
|
223
|
+
"files_before": self.files_before,
|
191
224
|
"attachments": self.attachments,
|
192
|
-
"
|
193
|
-
"
|
194
|
-
"output": self.output,
|
225
|
+
"attachments_before": self.attachments_before,
|
226
|
+
"pid": self.pid,
|
195
227
|
"mode": self.mode,
|
196
228
|
"model": self.model,
|
197
229
|
"thread": self.thread,
|
@@ -199,31 +231,18 @@ class CtxItem:
|
|
199
231
|
"run_id": self.run_id,
|
200
232
|
"audio_id": self.audio_id,
|
201
233
|
"audio_expires_ts": self.audio_expires_ts,
|
234
|
+
"input": self.input,
|
235
|
+
"output": self.output,
|
236
|
+
'hidden_input': self.hidden_input,
|
237
|
+
'hidden_output': self.hidden_output,
|
202
238
|
"input_name": self.input_name,
|
203
239
|
"output_name": self.output_name,
|
204
240
|
"input_timestamp": self.input_timestamp,
|
205
241
|
"output_timestamp": self.output_timestamp,
|
206
|
-
'hidden_input': self.hidden_input,
|
207
|
-
'hidden_output': self.hidden_output,
|
208
242
|
"input_tokens": self.input_tokens,
|
209
243
|
"output_tokens": self.output_tokens,
|
210
244
|
"total_tokens": self.total_tokens,
|
211
|
-
"
|
212
|
-
"extra_ctx": self.extra_ctx,
|
213
|
-
"current": self.current,
|
214
|
-
"internal": self.internal,
|
215
|
-
"is_vision": self.is_vision,
|
216
|
-
"idx": self.idx,
|
217
|
-
"first": self.first,
|
218
|
-
"agent_call": self.agent_call,
|
219
|
-
"tool_calls": self.tool_calls,
|
220
|
-
"index_meta": self.index_meta,
|
221
|
-
"doc_ids": self.doc_ids,
|
222
|
-
"sub_calls": 0,
|
223
|
-
"sub_call": False,
|
224
|
-
"sub_reply": False,
|
225
|
-
"hidden": False,
|
226
|
-
"live": self.live,
|
245
|
+
"meta": self.meta.to_dict() if type(self.meta) == CtxMeta else self.meta,
|
227
246
|
}
|
228
247
|
|
229
248
|
def from_dict(self, data: dict):
|
@@ -240,10 +259,13 @@ class CtxItem:
|
|
240
259
|
self.cmds = data.get("cmds", [])
|
241
260
|
self.results = data.get("results", [])
|
242
261
|
self.urls = data.get("urls", [])
|
262
|
+
self.urls_before = data.get("urls_before", [])
|
243
263
|
self.images = data.get("images", [])
|
244
264
|
self.images_before = data.get("images_before", [])
|
245
265
|
self.files = data.get("files", [])
|
266
|
+
self.files_before = data.get("files_before", [])
|
246
267
|
self.attachments = data.get("attachments", [])
|
268
|
+
self.attachments_before = data.get("attachments_before", [])
|
247
269
|
self.reply = data.get("reply", False)
|
248
270
|
self.input = data.get("input", None)
|
249
271
|
self.output = data.get("output", None)
|
@@ -151,9 +151,11 @@ class Simple:
|
|
151
151
|
self.plugin.window.dispatch(AppEvent(AppEvent.VOICE_CONTROL_STOPPED)) # app event
|
152
152
|
return
|
153
153
|
wf = wave.open(path, 'wb')
|
154
|
-
|
154
|
+
channels = int(self.plugin.window.core.config.get('audio.input.channels', 1))
|
155
|
+
rate = int(self.plugin.window.core.config.get('audio.input.rate', 44100))
|
156
|
+
wf.setnchannels(channels)
|
155
157
|
wf.setsampwidth(self.p.get_sample_size(pyaudio.paInt16))
|
156
|
-
wf.setframerate(
|
158
|
+
wf.setframerate(rate)
|
157
159
|
wf.writeframes(b''.join(self.frames))
|
158
160
|
wf.close()
|
159
161
|
self.plugin.handle_thread(True) # handle transcription in simple mode
|