@foxden-app/foxclaw 0.5.9 → 0.5.11
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.
- package/CHANGELOG.md +26 -0
- package/README.md +1 -0
- package/README_EN.md +1 -0
- package/dist/auth/mirror.d.ts +6 -0
- package/dist/auth/mirror.js +49 -0
- package/dist/controller/controller.d.ts +21 -2
- package/dist/controller/controller.js +516 -55
- package/dist/i18n.d.ts +36 -6
- package/dist/i18n.js +36 -6
- package/dist/main.js +22 -0
- package/dist/store/database.d.ts +25 -1
- package/dist/store/database.js +321 -0
- package/dist/telegram/gateway.d.ts +1 -0
- package/dist/telegram/gateway.js +1 -0
- package/dist/types.d.ts +53 -0
- package/dist/update.d.ts +3 -0
- package/dist/update.js +72 -3
- package/docs/devlogs//346/212/200/346/234/257/351/200/232/350/256/257/01./346/212/212 Codex /345/270/246/345/210/260/346/234/200/345/220/216/344/270/200/345/205/254/351/207/214/357/274/232FoxClaw /347/232/204 auth /347/224/237/345/221/275/345/221/250/346/234/237/344/270/216/350/267/250/350/212/202/347/202/271/345/220/214/346/255/245.md" +341 -0
- package/docs/release.md +102 -0
- package/docs/zh/release.md +102 -0
- package/package.json +1 -1
package/dist/i18n.d.ts
CHANGED
|
@@ -103,6 +103,7 @@ declare const MESSAGES: {
|
|
|
103
103
|
readonly status_sync_on_turn_complete: "Sync on turn complete: {value}";
|
|
104
104
|
readonly status_pending_approvals: "Pending approvals: {value}";
|
|
105
105
|
readonly status_pending_user_inputs: "Pending questions: {value}";
|
|
106
|
+
readonly status_queued_turns: "Queued turns: {value}";
|
|
106
107
|
readonly status_active_turns: "Active turns: {value}";
|
|
107
108
|
readonly status_codex_account: "Codex account: {value}";
|
|
108
109
|
readonly status_codex_plan: "Codex plan: {value}";
|
|
@@ -133,6 +134,7 @@ declare const MESSAGES: {
|
|
|
133
134
|
readonly status_last_codex_update: "Last Codex update: {value}";
|
|
134
135
|
readonly update_started: "FoxClaw update started. I will report here after installation, checks, and service restart complete.";
|
|
135
136
|
readonly update_succeeded: "FoxClaw updated and restarted: {from} -> {to}.";
|
|
137
|
+
readonly update_changes_title: "What changed:";
|
|
136
138
|
readonly update_codex_result: "Codex CLI: {from} -> {to}.";
|
|
137
139
|
readonly update_failed: "FoxClaw update failed: {error}\nRun foxclaw update in a terminal for details.";
|
|
138
140
|
readonly update_unavailable: "Self-update is unavailable in this runtime. Run foxclaw update in a terminal.";
|
|
@@ -141,8 +143,8 @@ declare const MESSAGES: {
|
|
|
141
143
|
readonly auth_reload_restarting: "Restarting Codex app-server to reload auth...";
|
|
142
144
|
readonly auth_reload_done: "Codex app-server restarted. Current auth has been reloaded.";
|
|
143
145
|
readonly auth_reload_blocked_active: "Cannot reload Codex auth while a turn, approval, or question is active. Wait or use /interrupt first.";
|
|
144
|
-
readonly usage_auth: "Usage: /auth [list [keyword]|filter <all|enabled|attention>|page <n>|use <n>|enable <n>|disable <n>|reload|refresh all [confirm]|sync <status|test|push all>|add <name>]";
|
|
145
|
-
readonly usage_auth_sync: "Usage: /auth sync <status|events [filter]|trace <requestId>|test|push all>";
|
|
146
|
+
readonly usage_auth: "Usage: /auth [list [keyword]|filter <all|enabled|attention>|page <n>|use <n>|enable <n>|disable <n>|reload|refresh all [confirm]|sync <status|test|safe|push all>|add <name>]";
|
|
147
|
+
readonly usage_auth_sync: "Usage: /auth sync <status|events [filter]|trace <requestId>|test|safe|push all>";
|
|
146
148
|
readonly usage_auth_add: "Usage: /auth add <name>. Use letters, numbers, dot, dash, or underscore.";
|
|
147
149
|
readonly auth_list_title: "Codex auth files:";
|
|
148
150
|
readonly auth_bot: "Bot runtime: {value}";
|
|
@@ -210,6 +212,8 @@ declare const MESSAGES: {
|
|
|
210
212
|
readonly auth_sync_test_sent: "Auth sync test complete: sent {sent}, replies {replied}.";
|
|
211
213
|
readonly auth_sync_test_missing: "Missing replies: {value}";
|
|
212
214
|
readonly auth_sync_push_blocked_active: "Cannot push auth sync while any runtime, approval, input, login, or auth mirror write is active.";
|
|
215
|
+
readonly auth_sync_safe_starting: "Safely syncing auth across local bot runtimes and cross-node peers...";
|
|
216
|
+
readonly auth_sync_safe_done: "Safe auth sync complete: local synced {localSynced}, local skipped {localSkipped}; cross-node sent {sent}, skipped {skipped}.";
|
|
213
217
|
readonly auth_sync_push_done: "Auth sync push complete: sent {sent}, skipped {skipped}.";
|
|
214
218
|
readonly auth_sync_status_title: "Cross-node auth sync:";
|
|
215
219
|
readonly auth_sync_status_node: "Node: {value}";
|
|
@@ -233,6 +237,7 @@ declare const MESSAGES: {
|
|
|
233
237
|
readonly auth_sync_trace_missing: "Usage: /auth sync trace <requestId>";
|
|
234
238
|
readonly button_login_device: "🔑 Login";
|
|
235
239
|
readonly button_auth_reload: "🔄 Reload auth";
|
|
240
|
+
readonly button_auth_safe_sync: "🧷 Safe sync";
|
|
236
241
|
readonly button_auth_refresh_all_confirm: "⚠️ Accept risk & refresh";
|
|
237
242
|
readonly button_auth_enable: "✅";
|
|
238
243
|
readonly button_auth_disable: "⏸️";
|
|
@@ -254,8 +259,18 @@ declare const MESSAGES: {
|
|
|
254
259
|
readonly watch_read_only_active: "This chat is watching that turn read-only. Use approval commands if needed, or /unwatch before sending a new prompt.";
|
|
255
260
|
readonly watch_not_enabled: "This chat is not watching any thread.";
|
|
256
261
|
readonly watch_stopped: "Stopped watching thread {threadId}.";
|
|
257
|
-
readonly queued_prompt_set: "Queued. I will send it after the current turn finishes.";
|
|
262
|
+
readonly queued_prompt_set: "Queued #{position} ({id}). I will send it after the current turn finishes.";
|
|
258
263
|
readonly queued_prompt_replaced: "Replaced the queued prompt. I will send the new one after the current turn finishes.";
|
|
264
|
+
readonly attachment_batch_staged: "Attachments staged: {count}. Send the prompt text to use them, or choose an action below.";
|
|
265
|
+
readonly attachment_batch_caption: "Caption: {value}";
|
|
266
|
+
readonly attachment_batch_consumed: "Attachments attached to the next Codex turn.";
|
|
267
|
+
readonly attachment_batch_queued: "Attachments queued as turn #{position} ({id}). I will send it after the current turn finishes.";
|
|
268
|
+
readonly attachment_batch_cleared: "Attachment batch cleared.";
|
|
269
|
+
readonly attachment_batch_missing: "This attachment batch is no longer active.";
|
|
270
|
+
readonly attachment_batch_mismatch: "This attachment batch does not match this message.";
|
|
271
|
+
readonly attachment_batch_default_prompt: "Analyze these attachments.";
|
|
272
|
+
readonly attachment_batch_button_analyze: "Analyze";
|
|
273
|
+
readonly attachment_batch_button_clear: "Clear";
|
|
259
274
|
readonly bound_to_thread: "Bound to thread {threadId}";
|
|
260
275
|
readonly line_title: "Title: {value}";
|
|
261
276
|
readonly line_cwd: "CWD: {value}";
|
|
@@ -744,6 +759,7 @@ declare const MESSAGES: {
|
|
|
744
759
|
readonly status_sync_on_turn_complete: "回复完成后同步:{value}";
|
|
745
760
|
readonly status_pending_approvals: "待审批:{value}";
|
|
746
761
|
readonly status_pending_user_inputs: "待确认问题:{value}";
|
|
762
|
+
readonly status_queued_turns: "排队中的回复:{value}";
|
|
747
763
|
readonly status_active_turns: "进行中的回复:{value}";
|
|
748
764
|
readonly status_codex_account: "Codex 账号:{value}";
|
|
749
765
|
readonly status_codex_plan: "Codex 套餐:{value}";
|
|
@@ -774,6 +790,7 @@ declare const MESSAGES: {
|
|
|
774
790
|
readonly status_last_codex_update: "最近 Codex 升级:{value}";
|
|
775
791
|
readonly update_started: "已开始升级 FoxClaw。安装、自检和服务重启完成后,我会在这里回报结果。";
|
|
776
792
|
readonly update_succeeded: "FoxClaw 已升级并重启:{from} -> {to}。";
|
|
793
|
+
readonly update_changes_title: "更新内容:";
|
|
777
794
|
readonly update_codex_result: "Codex CLI:{from} -> {to}。";
|
|
778
795
|
readonly update_failed: "FoxClaw 升级失败:{error}\n请在终端运行 foxclaw update 查看详情。";
|
|
779
796
|
readonly update_unavailable: "当前运行方式不支持自升级,请在终端运行 foxclaw update。";
|
|
@@ -782,8 +799,8 @@ declare const MESSAGES: {
|
|
|
782
799
|
readonly auth_reload_restarting: "正在重启 Codex app-server 以重新读取 auth...";
|
|
783
800
|
readonly auth_reload_done: "Codex app-server 已重启,当前 auth 已重新读取。";
|
|
784
801
|
readonly auth_reload_blocked_active: "当前有回复、审批或问题在进行中,不能重载 Codex auth。请先等待,或使用 /interrupt。";
|
|
785
|
-
readonly usage_auth: "用法:/auth [list [关键词]|filter <all|enabled|attention>|page <页码>|use <编号>|enable <编号>|disable <编号>|reload|refresh all [confirm]|sync <status|test|push all>|add <名称>]";
|
|
786
|
-
readonly usage_auth_sync: "用法:/auth sync <status|events [过滤]|trace <requestId>|test|push all>";
|
|
802
|
+
readonly usage_auth: "用法:/auth [list [关键词]|filter <all|enabled|attention>|page <页码>|use <编号>|enable <编号>|disable <编号>|reload|refresh all [confirm]|sync <status|test|safe|push all>|add <名称>]";
|
|
803
|
+
readonly usage_auth_sync: "用法:/auth sync <status|events [过滤]|trace <requestId>|test|safe|push all>";
|
|
787
804
|
readonly usage_auth_add: "用法:/auth add <名称>。名称只能包含字母、数字、点、短横线或下划线。";
|
|
788
805
|
readonly auth_list_title: "Codex auth 文件:";
|
|
789
806
|
readonly auth_bot: "Bot runtime:{value}";
|
|
@@ -851,6 +868,8 @@ declare const MESSAGES: {
|
|
|
851
868
|
readonly auth_sync_test_sent: "auth sync 测试完成:已发送 {sent},收到回应 {replied}。";
|
|
852
869
|
readonly auth_sync_test_missing: "未回应:{value}";
|
|
853
870
|
readonly auth_sync_push_blocked_active: "当前有任一 runtime、审批、待输入、登录或 auth 镜像写入在进行中,不能推送 auth 同步。";
|
|
871
|
+
readonly auth_sync_safe_starting: "正在安全同步本机多 bot runtime 和跨节点 auth...";
|
|
872
|
+
readonly auth_sync_safe_done: "安全 auth 同步完成:本机同步 {localSynced},本机跳过 {localSkipped};跨节点发送 {sent},跳过 {skipped}。";
|
|
854
873
|
readonly auth_sync_push_done: "auth 同步推送完成:已发送 {sent},已跳过 {skipped}。";
|
|
855
874
|
readonly auth_sync_status_title: "跨节点 auth 同步:";
|
|
856
875
|
readonly auth_sync_status_node: "节点:{value}";
|
|
@@ -874,6 +893,7 @@ declare const MESSAGES: {
|
|
|
874
893
|
readonly auth_sync_trace_missing: "用法:/auth sync trace <requestId>";
|
|
875
894
|
readonly button_login_device: "🔑 设备登录";
|
|
876
895
|
readonly button_auth_reload: "🔄 重载 auth";
|
|
896
|
+
readonly button_auth_safe_sync: "🧷 安全同步";
|
|
877
897
|
readonly button_auth_refresh_all_confirm: "⚠️ 接受风险并刷新";
|
|
878
898
|
readonly button_auth_enable: "✅";
|
|
879
899
|
readonly button_auth_disable: "⏸️";
|
|
@@ -895,8 +915,18 @@ declare const MESSAGES: {
|
|
|
895
915
|
readonly watch_read_only_active: "当前聊天正在只读观察这轮。需要审批时可用审批命令;要发送新 prompt 请先 /unwatch。";
|
|
896
916
|
readonly watch_not_enabled: "当前没有正在观察的线程。";
|
|
897
917
|
readonly watch_stopped: "已停止观察线程 {threadId}。";
|
|
898
|
-
readonly queued_prompt_set: "
|
|
918
|
+
readonly queued_prompt_set: "已排队 #{position}({id})。当前回复结束后我会自动发送。";
|
|
899
919
|
readonly queued_prompt_replaced: "已替换排队消息。当前回复结束后我会自动发送新的内容。";
|
|
920
|
+
readonly attachment_batch_staged: "附件已暂存:{count} 个。发送下一条文字即可带上这些附件,或使用下面的按钮。";
|
|
921
|
+
readonly attachment_batch_caption: "说明:{value}";
|
|
922
|
+
readonly attachment_batch_consumed: "附件已带入下一轮 Codex。";
|
|
923
|
+
readonly attachment_batch_queued: "附件已作为第 #{position} 个回复排队({id})。当前回复结束后我会自动发送。";
|
|
924
|
+
readonly attachment_batch_cleared: "已清除这组附件。";
|
|
925
|
+
readonly attachment_batch_missing: "这组附件已经不在待处理状态。";
|
|
926
|
+
readonly attachment_batch_mismatch: "这个附件按钮不属于当前消息。";
|
|
927
|
+
readonly attachment_batch_default_prompt: "分析这些附件。";
|
|
928
|
+
readonly attachment_batch_button_analyze: "分析";
|
|
929
|
+
readonly attachment_batch_button_clear: "清除";
|
|
900
930
|
readonly bound_to_thread: "已绑定到线程 {threadId}";
|
|
901
931
|
readonly line_title: "标题:{value}";
|
|
902
932
|
readonly line_cwd: "工作目录:{value}";
|
package/dist/i18n.js
CHANGED
|
@@ -101,6 +101,7 @@ const MESSAGES = {
|
|
|
101
101
|
status_sync_on_turn_complete: 'Sync on turn complete: {value}',
|
|
102
102
|
status_pending_approvals: 'Pending approvals: {value}',
|
|
103
103
|
status_pending_user_inputs: 'Pending questions: {value}',
|
|
104
|
+
status_queued_turns: 'Queued turns: {value}',
|
|
104
105
|
status_active_turns: 'Active turns: {value}',
|
|
105
106
|
status_codex_account: 'Codex account: {value}',
|
|
106
107
|
status_codex_plan: 'Codex plan: {value}',
|
|
@@ -131,6 +132,7 @@ const MESSAGES = {
|
|
|
131
132
|
status_last_codex_update: 'Last Codex update: {value}',
|
|
132
133
|
update_started: 'FoxClaw update started. I will report here after installation, checks, and service restart complete.',
|
|
133
134
|
update_succeeded: 'FoxClaw updated and restarted: {from} -> {to}.',
|
|
135
|
+
update_changes_title: 'What changed:',
|
|
134
136
|
update_codex_result: 'Codex CLI: {from} -> {to}.',
|
|
135
137
|
update_failed: 'FoxClaw update failed: {error}\nRun foxclaw update in a terminal for details.',
|
|
136
138
|
update_unavailable: 'Self-update is unavailable in this runtime. Run foxclaw update in a terminal.',
|
|
@@ -139,8 +141,8 @@ const MESSAGES = {
|
|
|
139
141
|
auth_reload_restarting: 'Restarting Codex app-server to reload auth...',
|
|
140
142
|
auth_reload_done: 'Codex app-server restarted. Current auth has been reloaded.',
|
|
141
143
|
auth_reload_blocked_active: 'Cannot reload Codex auth while a turn, approval, or question is active. Wait or use /interrupt first.',
|
|
142
|
-
usage_auth: 'Usage: /auth [list [keyword]|filter <all|enabled|attention>|page <n>|use <n>|enable <n>|disable <n>|reload|refresh all [confirm]|sync <status|test|push all>|add <name>]',
|
|
143
|
-
usage_auth_sync: 'Usage: /auth sync <status|events [filter]|trace <requestId>|test|push all>',
|
|
144
|
+
usage_auth: 'Usage: /auth [list [keyword]|filter <all|enabled|attention>|page <n>|use <n>|enable <n>|disable <n>|reload|refresh all [confirm]|sync <status|test|safe|push all>|add <name>]',
|
|
145
|
+
usage_auth_sync: 'Usage: /auth sync <status|events [filter]|trace <requestId>|test|safe|push all>',
|
|
144
146
|
usage_auth_add: 'Usage: /auth add <name>. Use letters, numbers, dot, dash, or underscore.',
|
|
145
147
|
auth_list_title: 'Codex auth files:',
|
|
146
148
|
auth_bot: 'Bot runtime: {value}',
|
|
@@ -208,6 +210,8 @@ const MESSAGES = {
|
|
|
208
210
|
auth_sync_test_sent: 'Auth sync test complete: sent {sent}, replies {replied}.',
|
|
209
211
|
auth_sync_test_missing: 'Missing replies: {value}',
|
|
210
212
|
auth_sync_push_blocked_active: 'Cannot push auth sync while any runtime, approval, input, login, or auth mirror write is active.',
|
|
213
|
+
auth_sync_safe_starting: 'Safely syncing auth across local bot runtimes and cross-node peers...',
|
|
214
|
+
auth_sync_safe_done: 'Safe auth sync complete: local synced {localSynced}, local skipped {localSkipped}; cross-node sent {sent}, skipped {skipped}.',
|
|
211
215
|
auth_sync_push_done: 'Auth sync push complete: sent {sent}, skipped {skipped}.',
|
|
212
216
|
auth_sync_status_title: 'Cross-node auth sync:',
|
|
213
217
|
auth_sync_status_node: 'Node: {value}',
|
|
@@ -231,6 +235,7 @@ const MESSAGES = {
|
|
|
231
235
|
auth_sync_trace_missing: 'Usage: /auth sync trace <requestId>',
|
|
232
236
|
button_login_device: '🔑 Login',
|
|
233
237
|
button_auth_reload: '🔄 Reload auth',
|
|
238
|
+
button_auth_safe_sync: '🧷 Safe sync',
|
|
234
239
|
button_auth_refresh_all_confirm: '⚠️ Accept risk & refresh',
|
|
235
240
|
button_auth_enable: '✅',
|
|
236
241
|
button_auth_disable: '⏸️',
|
|
@@ -252,8 +257,18 @@ const MESSAGES = {
|
|
|
252
257
|
watch_read_only_active: 'This chat is watching that turn read-only. Use approval commands if needed, or /unwatch before sending a new prompt.',
|
|
253
258
|
watch_not_enabled: 'This chat is not watching any thread.',
|
|
254
259
|
watch_stopped: 'Stopped watching thread {threadId}.',
|
|
255
|
-
queued_prompt_set: 'Queued. I will send it after the current turn finishes.',
|
|
260
|
+
queued_prompt_set: 'Queued #{position} ({id}). I will send it after the current turn finishes.',
|
|
256
261
|
queued_prompt_replaced: 'Replaced the queued prompt. I will send the new one after the current turn finishes.',
|
|
262
|
+
attachment_batch_staged: 'Attachments staged: {count}. Send the prompt text to use them, or choose an action below.',
|
|
263
|
+
attachment_batch_caption: 'Caption: {value}',
|
|
264
|
+
attachment_batch_consumed: 'Attachments attached to the next Codex turn.',
|
|
265
|
+
attachment_batch_queued: 'Attachments queued as turn #{position} ({id}). I will send it after the current turn finishes.',
|
|
266
|
+
attachment_batch_cleared: 'Attachment batch cleared.',
|
|
267
|
+
attachment_batch_missing: 'This attachment batch is no longer active.',
|
|
268
|
+
attachment_batch_mismatch: 'This attachment batch does not match this message.',
|
|
269
|
+
attachment_batch_default_prompt: 'Analyze these attachments.',
|
|
270
|
+
attachment_batch_button_analyze: 'Analyze',
|
|
271
|
+
attachment_batch_button_clear: 'Clear',
|
|
257
272
|
bound_to_thread: 'Bound to thread {threadId}',
|
|
258
273
|
line_title: 'Title: {value}',
|
|
259
274
|
line_cwd: 'CWD: {value}',
|
|
@@ -742,6 +757,7 @@ const MESSAGES = {
|
|
|
742
757
|
status_sync_on_turn_complete: '回复完成后同步:{value}',
|
|
743
758
|
status_pending_approvals: '待审批:{value}',
|
|
744
759
|
status_pending_user_inputs: '待确认问题:{value}',
|
|
760
|
+
status_queued_turns: '排队中的回复:{value}',
|
|
745
761
|
status_active_turns: '进行中的回复:{value}',
|
|
746
762
|
status_codex_account: 'Codex 账号:{value}',
|
|
747
763
|
status_codex_plan: 'Codex 套餐:{value}',
|
|
@@ -772,6 +788,7 @@ const MESSAGES = {
|
|
|
772
788
|
status_last_codex_update: '最近 Codex 升级:{value}',
|
|
773
789
|
update_started: '已开始升级 FoxClaw。安装、自检和服务重启完成后,我会在这里回报结果。',
|
|
774
790
|
update_succeeded: 'FoxClaw 已升级并重启:{from} -> {to}。',
|
|
791
|
+
update_changes_title: '更新内容:',
|
|
775
792
|
update_codex_result: 'Codex CLI:{from} -> {to}。',
|
|
776
793
|
update_failed: 'FoxClaw 升级失败:{error}\n请在终端运行 foxclaw update 查看详情。',
|
|
777
794
|
update_unavailable: '当前运行方式不支持自升级,请在终端运行 foxclaw update。',
|
|
@@ -780,8 +797,8 @@ const MESSAGES = {
|
|
|
780
797
|
auth_reload_restarting: '正在重启 Codex app-server 以重新读取 auth...',
|
|
781
798
|
auth_reload_done: 'Codex app-server 已重启,当前 auth 已重新读取。',
|
|
782
799
|
auth_reload_blocked_active: '当前有回复、审批或问题在进行中,不能重载 Codex auth。请先等待,或使用 /interrupt。',
|
|
783
|
-
usage_auth: '用法:/auth [list [关键词]|filter <all|enabled|attention>|page <页码>|use <编号>|enable <编号>|disable <编号>|reload|refresh all [confirm]|sync <status|test|push all>|add <名称>]',
|
|
784
|
-
usage_auth_sync: '用法:/auth sync <status|events [过滤]|trace <requestId>|test|push all>',
|
|
800
|
+
usage_auth: '用法:/auth [list [关键词]|filter <all|enabled|attention>|page <页码>|use <编号>|enable <编号>|disable <编号>|reload|refresh all [confirm]|sync <status|test|safe|push all>|add <名称>]',
|
|
801
|
+
usage_auth_sync: '用法:/auth sync <status|events [过滤]|trace <requestId>|test|safe|push all>',
|
|
785
802
|
usage_auth_add: '用法:/auth add <名称>。名称只能包含字母、数字、点、短横线或下划线。',
|
|
786
803
|
auth_list_title: 'Codex auth 文件:',
|
|
787
804
|
auth_bot: 'Bot runtime:{value}',
|
|
@@ -849,6 +866,8 @@ const MESSAGES = {
|
|
|
849
866
|
auth_sync_test_sent: 'auth sync 测试完成:已发送 {sent},收到回应 {replied}。',
|
|
850
867
|
auth_sync_test_missing: '未回应:{value}',
|
|
851
868
|
auth_sync_push_blocked_active: '当前有任一 runtime、审批、待输入、登录或 auth 镜像写入在进行中,不能推送 auth 同步。',
|
|
869
|
+
auth_sync_safe_starting: '正在安全同步本机多 bot runtime 和跨节点 auth...',
|
|
870
|
+
auth_sync_safe_done: '安全 auth 同步完成:本机同步 {localSynced},本机跳过 {localSkipped};跨节点发送 {sent},跳过 {skipped}。',
|
|
852
871
|
auth_sync_push_done: 'auth 同步推送完成:已发送 {sent},已跳过 {skipped}。',
|
|
853
872
|
auth_sync_status_title: '跨节点 auth 同步:',
|
|
854
873
|
auth_sync_status_node: '节点:{value}',
|
|
@@ -872,6 +891,7 @@ const MESSAGES = {
|
|
|
872
891
|
auth_sync_trace_missing: '用法:/auth sync trace <requestId>',
|
|
873
892
|
button_login_device: '🔑 设备登录',
|
|
874
893
|
button_auth_reload: '🔄 重载 auth',
|
|
894
|
+
button_auth_safe_sync: '🧷 安全同步',
|
|
875
895
|
button_auth_refresh_all_confirm: '⚠️ 接受风险并刷新',
|
|
876
896
|
button_auth_enable: '✅',
|
|
877
897
|
button_auth_disable: '⏸️',
|
|
@@ -893,8 +913,18 @@ const MESSAGES = {
|
|
|
893
913
|
watch_read_only_active: '当前聊天正在只读观察这轮。需要审批时可用审批命令;要发送新 prompt 请先 /unwatch。',
|
|
894
914
|
watch_not_enabled: '当前没有正在观察的线程。',
|
|
895
915
|
watch_stopped: '已停止观察线程 {threadId}。',
|
|
896
|
-
queued_prompt_set: '
|
|
916
|
+
queued_prompt_set: '已排队 #{position}({id})。当前回复结束后我会自动发送。',
|
|
897
917
|
queued_prompt_replaced: '已替换排队消息。当前回复结束后我会自动发送新的内容。',
|
|
918
|
+
attachment_batch_staged: '附件已暂存:{count} 个。发送下一条文字即可带上这些附件,或使用下面的按钮。',
|
|
919
|
+
attachment_batch_caption: '说明:{value}',
|
|
920
|
+
attachment_batch_consumed: '附件已带入下一轮 Codex。',
|
|
921
|
+
attachment_batch_queued: '附件已作为第 #{position} 个回复排队({id})。当前回复结束后我会自动发送。',
|
|
922
|
+
attachment_batch_cleared: '已清除这组附件。',
|
|
923
|
+
attachment_batch_missing: '这组附件已经不在待处理状态。',
|
|
924
|
+
attachment_batch_mismatch: '这个附件按钮不属于当前消息。',
|
|
925
|
+
attachment_batch_default_prompt: '分析这些附件。',
|
|
926
|
+
attachment_batch_button_analyze: '分析',
|
|
927
|
+
attachment_batch_button_clear: '清除',
|
|
898
928
|
bound_to_thread: '已绑定到线程 {threadId}',
|
|
899
929
|
line_title: '标题:{value}',
|
|
900
930
|
line_cwd: '工作目录:{value}',
|
package/dist/main.js
CHANGED
|
@@ -289,6 +289,7 @@ async function runServeCli() {
|
|
|
289
289
|
currentBindings: store.countBindings(),
|
|
290
290
|
pendingApprovals: store.countPendingApprovals(),
|
|
291
291
|
pendingUserInputs: store.countPendingUserInputs(),
|
|
292
|
+
queuedTurns: store.countQueuedTurnInputs(),
|
|
292
293
|
activeTurns: statuses.reduce((sum, status) => sum + status.activeTurns, 0)
|
|
293
294
|
+ (weixinStatus?.activeTurns ?? 0),
|
|
294
295
|
lastError: statuses.find((status) => status.lastError)?.lastError
|
|
@@ -341,6 +342,16 @@ async function runServeCli() {
|
|
|
341
342
|
releaseAuthRefreshLease: (leaseId) => authSync?.releaseRefreshLease(leaseId)
|
|
342
343
|
?? localAuthRefreshLease.release(leaseId),
|
|
343
344
|
getAuthSyncStatus: () => authSync?.getStatus() ?? null,
|
|
345
|
+
authSyncSafeAll: async () => {
|
|
346
|
+
const local = await mirror.syncAllRuntimeCandidates();
|
|
347
|
+
const remote = await authSync?.pushAll() ?? { sent: 0, skipped: 0 };
|
|
348
|
+
return {
|
|
349
|
+
localSynced: local.synced,
|
|
350
|
+
localSkipped: local.skipped,
|
|
351
|
+
sent: remote.sent,
|
|
352
|
+
skipped: remote.skipped,
|
|
353
|
+
};
|
|
354
|
+
},
|
|
344
355
|
authSyncPushAll: () => authSync?.pushAll() ?? Promise.resolve({ sent: 0, skipped: 0 }),
|
|
345
356
|
authSyncTest: () => authSync?.testPeers() ?? Promise.resolve({ sent: 0, replied: 0, missing: [] }),
|
|
346
357
|
statusUpdated: () => writeAggregateStatus(),
|
|
@@ -499,6 +510,16 @@ async function runServeCli() {
|
|
|
499
510
|
releaseAuthRefreshLease: (leaseId) => singleAuthSync?.releaseRefreshLease(leaseId)
|
|
500
511
|
?? singleLocalAuthRefreshLease.release(leaseId),
|
|
501
512
|
getAuthSyncStatus: () => singleAuthSync?.getStatus() ?? null,
|
|
513
|
+
authSyncSafeAll: async () => {
|
|
514
|
+
const local = await singleMirror?.syncAllRuntimeCandidates() ?? { synced: 0, skipped: 0 };
|
|
515
|
+
const remote = await singleAuthSync?.pushAll() ?? { sent: 0, skipped: 0 };
|
|
516
|
+
return {
|
|
517
|
+
localSynced: local.synced,
|
|
518
|
+
localSkipped: local.skipped,
|
|
519
|
+
sent: remote.sent,
|
|
520
|
+
skipped: remote.skipped,
|
|
521
|
+
};
|
|
522
|
+
},
|
|
502
523
|
authSyncPushAll: () => singleAuthSync?.pushAll() ?? Promise.resolve({ sent: 0, skipped: 0 }),
|
|
503
524
|
authSyncTest: () => singleAuthSync?.testPeers() ?? Promise.resolve({ sent: 0, replied: 0, missing: [] }),
|
|
504
525
|
statusUpdated: (status) => {
|
|
@@ -585,6 +606,7 @@ async function runServeCli() {
|
|
|
585
606
|
currentBindings: 0,
|
|
586
607
|
pendingApprovals: 0,
|
|
587
608
|
pendingUserInputs: 0,
|
|
609
|
+
queuedTurns: 0,
|
|
588
610
|
activeTurns: 0,
|
|
589
611
|
lastError: null,
|
|
590
612
|
updatedAt: new Date().toISOString(),
|
package/dist/store/database.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AccessPresetValue, ActiveTurnMessageMode, AppLocale, CachedThread, ChatSessionSettings, CollaborationModeValue, PendingApprovalRecord, ReasoningEffortValue, ThreadBinding } from '../types.js';
|
|
1
|
+
import type { AccessPresetValue, ActiveTurnMessageMode, AppLocale, CachedThread, ChatSessionSettings, CollaborationModeValue, GuidedPlanSessionRecord, GuidedPlanSessionState, PendingAttachmentBatchRecord, PendingAttachmentBatchStatus, PendingApprovalRecord, QueuedTurnInputRecord, QueuedTurnInputStatus, ReasoningEffortValue, ThreadBinding } from '../types.js';
|
|
2
2
|
export interface ActiveTurnPreviewRecord {
|
|
3
3
|
turnId: string;
|
|
4
4
|
scopeId: string;
|
|
@@ -84,10 +84,34 @@ export declare class BridgeStore {
|
|
|
84
84
|
markPendingUserInputInterrupted(localId: string): void;
|
|
85
85
|
listPendingUserInputs(): PendingUserInputStoredRecord[];
|
|
86
86
|
countPendingUserInputs(): number;
|
|
87
|
+
saveQueuedTurnInput(record: QueuedTurnInputRecord): void;
|
|
88
|
+
getQueuedTurnInput(queueId: string): QueuedTurnInputRecord | null;
|
|
89
|
+
peekQueuedTurnInput(scopeId: string): QueuedTurnInputRecord | null;
|
|
90
|
+
listQueuedTurnInputs(scopeId?: string): QueuedTurnInputRecord[];
|
|
91
|
+
countQueuedTurnInputs(scopeId?: string): number;
|
|
92
|
+
updateQueuedTurnInputStatus(queueId: string, status: QueuedTurnInputStatus, error?: string | null): void;
|
|
93
|
+
cancelQueuedTurnInputs(scopeId: string): number;
|
|
94
|
+
requeueInterruptedQueuedTurnInputs(): number;
|
|
95
|
+
savePendingAttachmentBatch(record: PendingAttachmentBatchRecord): void;
|
|
96
|
+
getPendingAttachmentBatch(batchId: string): PendingAttachmentBatchRecord | null;
|
|
97
|
+
findPendingAttachmentBatchByMediaGroup(scopeId: string, mediaGroupId: string): PendingAttachmentBatchRecord | null;
|
|
98
|
+
getLatestPendingAttachmentBatch(scopeId: string): PendingAttachmentBatchRecord | null;
|
|
99
|
+
updatePendingAttachmentBatchMessage(batchId: string, messageId: number): void;
|
|
100
|
+
resolvePendingAttachmentBatch(batchId: string, status: PendingAttachmentBatchStatus): void;
|
|
101
|
+
clearPendingAttachmentBatches(scopeId: string): number;
|
|
102
|
+
saveGuidedPlanSession(record: GuidedPlanSessionRecord): void;
|
|
103
|
+
getGuidedPlanSession(sessionId: string): GuidedPlanSessionRecord | null;
|
|
104
|
+
findOpenGuidedPlanSession(scopeId: string, turnId?: string): GuidedPlanSessionRecord | null;
|
|
105
|
+
listOpenGuidedPlanSessions(): GuidedPlanSessionRecord[];
|
|
106
|
+
updateGuidedPlanSessionMessage(sessionId: string, messageId: number): void;
|
|
107
|
+
updateGuidedPlanSessionState(sessionId: string, state: GuidedPlanSessionState): void;
|
|
87
108
|
insertAudit(direction: 'inbound' | 'outbound', chatId: string, eventType: string, summary: string): void;
|
|
88
109
|
close(): void;
|
|
89
110
|
private mapApproval;
|
|
90
111
|
private mapPendingUserInput;
|
|
112
|
+
private mapQueuedTurnInput;
|
|
113
|
+
private mapPendingAttachmentBatch;
|
|
114
|
+
private mapGuidedPlanSession;
|
|
91
115
|
private writeChatSettings;
|
|
92
116
|
getWeixinContextToken(scopeId: string): string | null;
|
|
93
117
|
setWeixinContextToken(scopeId: string, contextToken: string): void;
|