@dsh-agentic-roleplay/core 0.11.1 → 0.12.0
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/lib/{access-Md1YTSX1.js → access-DAw54-NI.js} +3 -15
- package/lib/{authoring-tools-BFdw7ahj.js → authoring-tools-4NgDhIJV.js} +51 -11
- package/lib/authoring.js +8 -8
- package/lib/{child-C9nPIy9j.js → child-D3QUNb3m.js} +121 -2
- package/lib/client.js +1013 -449
- package/lib/client.js.map +1 -1
- package/lib/compaction.js +3 -3
- package/lib/doctor.js +3 -3
- package/lib/{gallery-BWHmjogd.js → gallery-Ct6nm4UQ.js} +3 -3
- package/lib/{generator-QCdm8nUh.js → generator-CI8fOnXy.js} +2 -2
- package/lib/helper.js +13 -1
- package/lib/{hooks-C2U1-8ur.js → hooks-BNeoGMHZ.js} +722 -334
- package/lib/images.js +4 -4
- package/lib/index.js +234 -20
- package/lib/jail-BIF79PJO.js +107 -0
- package/lib/{library-4zmCAshR.js → library-BF9ZMSFz.js} +3 -3
- package/lib/{lorebook-author-tools-Bjfjt3bg.js → lorebook-author-tools-DBk-V0hp.js} +7 -7
- package/lib/lorebook-authoring.js +4 -4
- package/lib/{narration-b_VBEUWn.js → narration-xvErE2yp.js} +29 -2
- package/lib/orchestration.js +593 -47
- package/lib/{pack-jail-Ci9bIeDI.js → pack-jail-C8EyX9Ix.js} +12 -11
- package/lib/{packs-CYkozh8Q.js → packs-S0SzrVv-.js} +2 -2
- package/lib/{presenter-agent-CqkAL03Q.js → presenter-agent-Bc478nTA.js} +6 -6
- package/lib/{preset-B-35yUmt.js → preset-SJZyw0kt.js} +4 -4
- package/lib/{preset-author-tools-BUymqZM5.js → preset-author-tools-CzogjK42.js} +7 -7
- package/lib/preset-authoring.js +5 -5
- package/lib/{presets-_U-xroo0.js → presets-DQ5rioMh.js} +231 -48
- package/lib/{reflection-B9N0z3KY.js → reflection-buQiSdvq.js} +15 -8
- package/lib/service-mRKwpWjX.js +140 -0
- package/lib/{text-C2AGl7Je.js → text-Dfv8S8eq.js} +27 -2
- package/lib/{turn-guard-C0M3rXEN.js → turn-guard-BSAba8sp.js} +3 -3
- package/package.json +3 -3
- package/prompts/en/import/finish-ok.md +1 -1
- package/prompts/en/import/generator.md +1 -1
- package/prompts/en/import/style.md +1 -1
- package/prompts/en/import/variables.md +2 -1
- package/prompts/en/roleplay/character-lookup.md +1 -1
- package/prompts/en/roleplay/decide-errand.md +1 -0
- package/prompts/en/roleplay/decide-message.md +1 -0
- package/prompts/en/roleplay/dream.md +1 -0
- package/prompts/en/roleplay/gate-repeat.md +1 -0
- package/prompts/zh/import/finish-ok.md +1 -1
- package/prompts/zh/import/generator.md +1 -1
- package/prompts/zh/import/style.md +1 -1
- package/prompts/zh/import/variables.md +2 -1
- package/prompts/zh/roleplay/character-lookup.md +1 -1
- package/prompts/zh/roleplay/decide-errand.md +1 -0
- package/prompts/zh/roleplay/decide-message.md +1 -0
- package/prompts/zh/roleplay/dream.md +1 -0
- package/prompts/zh/roleplay/gate-repeat.md +1 -0
package/lib/client.js
CHANGED
|
@@ -35,8 +35,8 @@ window.__ModuleLoader__.load({
|
|
|
35
35
|
}
|
|
36
36
|
tag$40.textContent = css$40;
|
|
37
37
|
var PageTabs_module_css_default = {
|
|
38
|
-
"
|
|
39
|
-
"
|
|
38
|
+
"tab": "rp_LrKukW_tab",
|
|
39
|
+
"tabs": "rp_LrKukW_tabs"
|
|
40
40
|
};
|
|
41
41
|
// src/client/widgets/page-tabs/PageTabs.tsx
|
|
42
42
|
/** Underlined text tabs; arrow keys, Home and End move between them. */
|
|
@@ -89,9 +89,9 @@ window.__ModuleLoader__.load({
|
|
|
89
89
|
}
|
|
90
90
|
tag$39.textContent = css$39;
|
|
91
91
|
var RoleplayPanel_module_css_default = {
|
|
92
|
-
"body": "rp_ua5gBa_body",
|
|
93
92
|
"panel": "rp_ua5gBa_panel",
|
|
94
93
|
"header": "rp_ua5gBa_header",
|
|
94
|
+
"body": "rp_ua5gBa_body",
|
|
95
95
|
"title": "rp_ua5gBa_title"
|
|
96
96
|
};
|
|
97
97
|
// src/client/panel/RoleplayPanel.tsx
|
|
@@ -427,34 +427,34 @@ window.__ModuleLoader__.load({
|
|
|
427
427
|
}
|
|
428
428
|
tag$38.textContent = css$38;
|
|
429
429
|
var ImportCard_module_css_default = {
|
|
430
|
-
"tags": "rp_5cvtma_tags",
|
|
431
|
-
"entryHead": "rp_5cvtma_entryHead",
|
|
432
430
|
"section": "rp_5cvtma_section",
|
|
433
|
-
"header": "rp_5cvtma_header",
|
|
434
|
-
"entry": "rp_5cvtma_entry",
|
|
435
|
-
"fieldMeta": "rp_5cvtma_fieldMeta",
|
|
436
|
-
"title": "rp_5cvtma_title",
|
|
437
|
-
"choice": "rp_5cvtma_choice",
|
|
438
|
-
"heading": "rp_5cvtma_heading",
|
|
439
431
|
"page": "rp_5cvtma_page",
|
|
432
|
+
"row": "rp_5cvtma_row",
|
|
440
433
|
"error": "rp_5cvtma_error",
|
|
441
|
-
"
|
|
442
|
-
"
|
|
443
|
-
"entryOff": "rp_5cvtma_entryOff",
|
|
434
|
+
"entry": "rp_5cvtma_entry",
|
|
435
|
+
"header": "rp_5cvtma_header",
|
|
444
436
|
"space": "rp_5cvtma_space",
|
|
445
|
-
"
|
|
446
|
-
"
|
|
437
|
+
"noPicture": "rp_5cvtma_noPicture",
|
|
438
|
+
"label": "rp_5cvtma_label",
|
|
447
439
|
"fieldHead": "rp_5cvtma_fieldHead",
|
|
448
|
-
"
|
|
449
|
-
"
|
|
440
|
+
"choice": "rp_5cvtma_choice",
|
|
441
|
+
"body": "rp_5cvtma_body",
|
|
450
442
|
"picture": "rp_5cvtma_picture",
|
|
451
|
-
"about": "rp_5cvtma_about",
|
|
452
|
-
"note": "rp_5cvtma_note",
|
|
453
443
|
"field": "rp_5cvtma_field",
|
|
444
|
+
"choiceText": "rp_5cvtma_choiceText",
|
|
445
|
+
"entryOff": "rp_5cvtma_entryOff",
|
|
446
|
+
"note": "rp_5cvtma_note",
|
|
447
|
+
"heading": "rp_5cvtma_heading",
|
|
448
|
+
"preview": "rp_5cvtma_preview",
|
|
449
|
+
"top": "rp_5cvtma_top",
|
|
450
|
+
"about": "rp_5cvtma_about",
|
|
451
|
+
"entryHead": "rp_5cvtma_entryHead",
|
|
452
|
+
"entryTitle": "rp_5cvtma_entryTitle",
|
|
454
453
|
"fieldTitle": "rp_5cvtma_fieldTitle",
|
|
455
|
-
"
|
|
456
|
-
"
|
|
457
|
-
"text": "rp_5cvtma_text"
|
|
454
|
+
"fieldMeta": "rp_5cvtma_fieldMeta",
|
|
455
|
+
"title": "rp_5cvtma_title",
|
|
456
|
+
"text": "rp_5cvtma_text",
|
|
457
|
+
"tags": "rp_5cvtma_tags"
|
|
458
458
|
};
|
|
459
459
|
// src/client/widgets/import-card/ImportCard.tsx
|
|
460
460
|
const pictureUrl = (id) => `${API_PREFIX}/worlds/import/picture?id=${encodeURIComponent(id)}`;
|
|
@@ -943,37 +943,37 @@ window.__ModuleLoader__.load({
|
|
|
943
943
|
}
|
|
944
944
|
tag$37.textContent = css$37;
|
|
945
945
|
var CataloguePage_module_css_default = {
|
|
946
|
-
"
|
|
947
|
-
"
|
|
948
|
-
"toolbar": "rp_qK1u-G_toolbar",
|
|
949
|
-
"warning": "rp_qK1u-G_warning",
|
|
950
|
-
"cover": "rp_qK1u-G_cover",
|
|
951
|
-
"body": "rp_qK1u-G_body",
|
|
952
|
-
"status": "rp_qK1u-G_status",
|
|
953
|
-
"updates": "rp_qK1u-G_updates",
|
|
954
|
-
"page": "rp_qK1u-G_page",
|
|
955
|
-
"changes": "rp_qK1u-G_changes",
|
|
956
|
-
"message": "rp_qK1u-G_message",
|
|
946
|
+
"detail": "rp_qK1u-G_detail",
|
|
947
|
+
"form": "rp_qK1u-G_form",
|
|
957
948
|
"search": "rp_qK1u-G_search",
|
|
958
|
-
"
|
|
959
|
-
"more": "rp_qK1u-G_more",
|
|
960
|
-
"description": "rp_qK1u-G_description",
|
|
949
|
+
"changes": "rp_qK1u-G_changes",
|
|
961
950
|
"actions": "rp_qK1u-G_actions",
|
|
951
|
+
"toolbar": "rp_qK1u-G_toolbar",
|
|
962
952
|
"update": "rp_qK1u-G_update",
|
|
963
|
-
"
|
|
964
|
-
"
|
|
953
|
+
"tags": "rp_qK1u-G_tags",
|
|
954
|
+
"name": "rp_qK1u-G_name",
|
|
965
955
|
"notice": "rp_qK1u-G_notice",
|
|
956
|
+
"grid": "rp_qK1u-G_grid",
|
|
957
|
+
"kinds": "rp_qK1u-G_kinds",
|
|
958
|
+
"page": "rp_qK1u-G_page",
|
|
966
959
|
"spacer": "rp_qK1u-G_spacer",
|
|
967
|
-
"tags": "rp_qK1u-G_tags",
|
|
968
960
|
"viewport": "rp_qK1u-G_viewport",
|
|
969
|
-
"
|
|
970
|
-
"
|
|
971
|
-
"
|
|
961
|
+
"field": "rp_qK1u-G_field",
|
|
962
|
+
"warning": "rp_qK1u-G_warning",
|
|
963
|
+
"meta": "rp_qK1u-G_meta",
|
|
972
964
|
"success": "rp_qK1u-G_success",
|
|
973
|
-
"
|
|
974
|
-
"
|
|
965
|
+
"cover": "rp_qK1u-G_cover",
|
|
966
|
+
"updates": "rp_qK1u-G_updates",
|
|
967
|
+
"kind": "rp_qK1u-G_kind",
|
|
975
968
|
"card": "rp_qK1u-G_card",
|
|
969
|
+
"description": "rp_qK1u-G_description",
|
|
970
|
+
"message": "rp_qK1u-G_message",
|
|
971
|
+
"body": "rp_qK1u-G_body",
|
|
972
|
+
"placeholder": "rp_qK1u-G_placeholder",
|
|
976
973
|
"select": "rp_qK1u-G_select",
|
|
974
|
+
"image": "rp_qK1u-G_image",
|
|
975
|
+
"more": "rp_qK1u-G_more",
|
|
976
|
+
"status": "rp_qK1u-G_status",
|
|
977
977
|
"label": "rp_qK1u-G_label"
|
|
978
978
|
};
|
|
979
979
|
// src/client/pages/catalogue/ImportUrlDialog.tsx
|
|
@@ -1046,7 +1046,7 @@ window.__ModuleLoader__.load({
|
|
|
1046
1046
|
});
|
|
1047
1047
|
}
|
|
1048
1048
|
// src/client/import-selection-api.ts
|
|
1049
|
-
async function reply$
|
|
1049
|
+
async function reply$6(response) {
|
|
1050
1050
|
if (!response.ok) {
|
|
1051
1051
|
const body = await response.json().catch(() => void 0);
|
|
1052
1052
|
throw new Error(typeof body?.message === "string" ? body.message : `${response.status} ${response.statusText}`.trim());
|
|
@@ -1062,7 +1062,7 @@ window.__ModuleLoader__.load({
|
|
|
1062
1062
|
});
|
|
1063
1063
|
/** Sends a preset or lorebook file to the host to be read: the answer is what it offers to import. */
|
|
1064
1064
|
async function stageFile(kind, file, signal) {
|
|
1065
|
-
return await reply$
|
|
1065
|
+
return await reply$6(await fetch(`${API_PREFIX}/import/stage?kind=${kind}`, {
|
|
1066
1066
|
method: "POST",
|
|
1067
1067
|
credentials: "same-origin",
|
|
1068
1068
|
headers: {
|
|
@@ -1075,7 +1075,7 @@ window.__ModuleLoader__.load({
|
|
|
1075
1075
|
}
|
|
1076
1076
|
/** The same for a release of a catalogue, which the host downloads. */
|
|
1077
1077
|
async function stageRelease(kind, source, versionId, signal) {
|
|
1078
|
-
return await reply$
|
|
1078
|
+
return await reply$6(await fetch(`${API_PREFIX}/catalogue/stage`, post$1({
|
|
1079
1079
|
source,
|
|
1080
1080
|
versionId,
|
|
1081
1081
|
kind
|
|
@@ -1083,20 +1083,20 @@ window.__ModuleLoader__.load({
|
|
|
1083
1083
|
}
|
|
1084
1084
|
/** Imports a staged preset into a new library preset, named `name`, or after `title` when there is no name; its authoring chat turns the chosen prompts into the preset's own. */
|
|
1085
1085
|
async function importStagedPreset(choice, extra, signal) {
|
|
1086
|
-
return await reply$
|
|
1086
|
+
return await reply$6(await fetch(`${API_PREFIX}/presets/import/staged`, post$1({
|
|
1087
1087
|
...choice,
|
|
1088
1088
|
...extra
|
|
1089
1089
|
}, signal)));
|
|
1090
1090
|
}
|
|
1091
1091
|
async function importStagedLorebook(choice, extra, signal) {
|
|
1092
|
-
return await reply$
|
|
1092
|
+
return await reply$6(await fetch(`${API_PREFIX}/lorebooks/import/staged`, post$1({
|
|
1093
1093
|
...choice,
|
|
1094
1094
|
...extra
|
|
1095
1095
|
}, signal)));
|
|
1096
1096
|
}
|
|
1097
1097
|
/** Imports a staged preset into a world, whose authoring chat turns the chosen prompts into the world's prose prompts. */
|
|
1098
1098
|
async function importStagedToWorld(worldId, choice, language) {
|
|
1099
|
-
return await reply$
|
|
1099
|
+
return await reply$6(await fetch(`${API_PREFIX}/worlds/import/preset/staged`, post$1({
|
|
1100
1100
|
...choice,
|
|
1101
1101
|
worldId,
|
|
1102
1102
|
language
|
|
@@ -1104,21 +1104,21 @@ window.__ModuleLoader__.load({
|
|
|
1104
1104
|
}
|
|
1105
1105
|
/** Imports the chosen entries of a staged lorebook as they are, with no assistant; the answer names the new lorebook. */
|
|
1106
1106
|
async function importVerbatimLorebook(choice, extra, signal) {
|
|
1107
|
-
return await reply$
|
|
1107
|
+
return await reply$6(await fetch(`${API_PREFIX}/lorebooks/import/verbatim`, post$1({
|
|
1108
1108
|
...choice,
|
|
1109
1109
|
...extra
|
|
1110
1110
|
}, signal)));
|
|
1111
1111
|
}
|
|
1112
1112
|
/** Imports the chosen prompts of a staged preset as they are, with no assistant; the answer names the new preset. */
|
|
1113
1113
|
async function importVerbatimPreset(choice, extra, signal) {
|
|
1114
|
-
return await reply$
|
|
1114
|
+
return await reply$6(await fetch(`${API_PREFIX}/presets/import/verbatim`, post$1({
|
|
1115
1115
|
...choice,
|
|
1116
1116
|
...extra
|
|
1117
1117
|
}, signal)));
|
|
1118
1118
|
}
|
|
1119
1119
|
/** Puts the chosen prompts of a staged preset into a world as its narration style, word for word, with no assistant. */
|
|
1120
1120
|
async function importVerbatimToWorld(worldId, choice, signal) {
|
|
1121
|
-
return await reply$
|
|
1121
|
+
return await reply$6(await fetch(`${API_PREFIX}/worlds/import/preset/verbatim`, post$1({
|
|
1122
1122
|
...choice,
|
|
1123
1123
|
worldId
|
|
1124
1124
|
}, signal)));
|
|
@@ -1178,19 +1178,19 @@ window.__ModuleLoader__.load({
|
|
|
1178
1178
|
}
|
|
1179
1179
|
tag$36.textContent = css$36;
|
|
1180
1180
|
var ImportSelection_module_css_default = {
|
|
1181
|
-
"bar": "rp_Jx0l4q_bar",
|
|
1182
|
-
"error": "rp_Jx0l4q_error",
|
|
1183
|
-
"body": "rp_Jx0l4q_body",
|
|
1184
|
-
"count": "rp_Jx0l4q_count",
|
|
1185
|
-
"row": "rp_Jx0l4q_row",
|
|
1186
|
-
"list": "rp_Jx0l4q_list",
|
|
1187
1181
|
"text": "rp_Jx0l4q_text",
|
|
1188
|
-
"
|
|
1182
|
+
"count": "rp_Jx0l4q_count",
|
|
1189
1183
|
"meta": "rp_Jx0l4q_meta",
|
|
1190
|
-
"
|
|
1184
|
+
"bar": "rp_Jx0l4q_bar",
|
|
1191
1185
|
"full": "rp_Jx0l4q_full",
|
|
1186
|
+
"body": "rp_Jx0l4q_body",
|
|
1192
1187
|
"sampling": "rp_Jx0l4q_sampling",
|
|
1193
|
-
"
|
|
1188
|
+
"error": "rp_Jx0l4q_error",
|
|
1189
|
+
"row": "rp_Jx0l4q_row",
|
|
1190
|
+
"note": "rp_Jx0l4q_note",
|
|
1191
|
+
"extra": "rp_Jx0l4q_extra",
|
|
1192
|
+
"help": "rp_Jx0l4q_help",
|
|
1193
|
+
"list": "rp_Jx0l4q_list"
|
|
1194
1194
|
};
|
|
1195
1195
|
// src/client/widgets/import-selection/ImportSelection.tsx
|
|
1196
1196
|
const messageOf$14 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
@@ -3122,46 +3122,46 @@ window.__ModuleLoader__.load({
|
|
|
3122
3122
|
}
|
|
3123
3123
|
tag$35.textContent = css$35;
|
|
3124
3124
|
var CharactersPanel_module_css_default = {
|
|
3125
|
-
"
|
|
3126
|
-
"questionTitle": "rp_5ZMIxq_questionTitle",
|
|
3127
|
-
"portraitAction": "rp_5ZMIxq_portraitAction",
|
|
3125
|
+
"tabs": "rp_5ZMIxq_tabs",
|
|
3128
3126
|
"portrait": "rp_5ZMIxq_portrait",
|
|
3129
|
-
"
|
|
3130
|
-
"
|
|
3131
|
-
"
|
|
3132
|
-
"tabOn": "rp_5ZMIxq_tabOn",
|
|
3127
|
+
"initial": "rp_5ZMIxq_initial",
|
|
3128
|
+
"row": "rp_5ZMIxq_row",
|
|
3129
|
+
"questionActions": "rp_5ZMIxq_questionActions",
|
|
3133
3130
|
"body": "rp_5ZMIxq_body",
|
|
3134
|
-
"
|
|
3135
|
-
"
|
|
3131
|
+
"barText": "rp_5ZMIxq_barText",
|
|
3132
|
+
"empty": "rp_5ZMIxq_empty",
|
|
3133
|
+
"portraitError": "rp_5ZMIxq_portraitError",
|
|
3134
|
+
"tab": "rp_5ZMIxq_tab",
|
|
3135
|
+
"portraitBox": "rp_5ZMIxq_portraitBox",
|
|
3136
|
+
"tabsSpace": "rp_5ZMIxq_tabsSpace",
|
|
3136
3137
|
"itemActions": "rp_5ZMIxq_itemActions",
|
|
3137
|
-
"optionFields": "rp_5ZMIxq_optionFields",
|
|
3138
3138
|
"sectionTitle": "rp_5ZMIxq_sectionTitle",
|
|
3139
|
-
"
|
|
3140
|
-
"
|
|
3139
|
+
"questionTitle": "rp_5ZMIxq_questionTitle",
|
|
3140
|
+
"voiceInline": "rp_5ZMIxq_voiceInline",
|
|
3141
|
+
"field": "rp_5ZMIxq_field",
|
|
3142
|
+
"bar": "rp_5ZMIxq_bar",
|
|
3143
|
+
"help": "rp_5ZMIxq_help",
|
|
3144
|
+
"error": "rp_5ZMIxq_error",
|
|
3145
|
+
"sheet": "rp_5ZMIxq_sheet",
|
|
3146
|
+
"question": "rp_5ZMIxq_question",
|
|
3147
|
+
"panel": "rp_5ZMIxq_panel",
|
|
3148
|
+
"tabOn": "rp_5ZMIxq_tabOn",
|
|
3141
3149
|
"goal": "rp_5ZMIxq_goal",
|
|
3142
3150
|
"head": "rp_5ZMIxq_head",
|
|
3143
|
-
"portraitBox": "rp_5ZMIxq_portraitBox",
|
|
3144
|
-
"questionActions": "rp_5ZMIxq_questionActions",
|
|
3145
|
-
"panel": "rp_5ZMIxq_panel",
|
|
3146
|
-
"meta": "rp_5ZMIxq_meta",
|
|
3147
|
-
"sheet": "rp_5ZMIxq_sheet",
|
|
3148
|
-
"portraitError": "rp_5ZMIxq_portraitError",
|
|
3149
3151
|
"portraitHint": "rp_5ZMIxq_portraitHint",
|
|
3150
|
-
"
|
|
3151
|
-
"nameInput": "rp_5ZMIxq_nameInput",
|
|
3152
|
-
"voiceInline": "rp_5ZMIxq_voiceInline",
|
|
3152
|
+
"meta": "rp_5ZMIxq_meta",
|
|
3153
3153
|
"select": "rp_5ZMIxq_select",
|
|
3154
|
-
"
|
|
3155
|
-
"
|
|
3156
|
-
"
|
|
3154
|
+
"missing": "rp_5ZMIxq_missing",
|
|
3155
|
+
"grid": "rp_5ZMIxq_grid",
|
|
3156
|
+
"nameInput": "rp_5ZMIxq_nameInput",
|
|
3157
|
+
"portraitAction": "rp_5ZMIxq_portraitAction",
|
|
3158
|
+
"wide": "rp_5ZMIxq_wide",
|
|
3159
|
+
"label": "rp_5ZMIxq_label",
|
|
3160
|
+
"optionFields": "rp_5ZMIxq_optionFields",
|
|
3161
|
+
"optionTitle": "rp_5ZMIxq_optionTitle",
|
|
3157
3162
|
"section": "rp_5ZMIxq_section",
|
|
3158
|
-
"tab": "rp_5ZMIxq_tab",
|
|
3159
|
-
"error": "rp_5ZMIxq_error",
|
|
3160
3163
|
"area": "rp_5ZMIxq_area",
|
|
3161
|
-
"placeholder": "rp_5ZMIxq_placeholder"
|
|
3162
|
-
"barText": "rp_5ZMIxq_barText",
|
|
3163
|
-
"optionTitle": "rp_5ZMIxq_optionTitle",
|
|
3164
|
-
"row": "rp_5ZMIxq_row"
|
|
3164
|
+
"placeholder": "rp_5ZMIxq_placeholder"
|
|
3165
3165
|
};
|
|
3166
3166
|
// src/client/world-editor/EditorTabs.tsx
|
|
3167
3167
|
/** Adds expected arrow, Home and End navigation to an existing editor tab strip. */
|
|
@@ -4880,39 +4880,39 @@ window.__ModuleLoader__.load({
|
|
|
4880
4880
|
}
|
|
4881
4881
|
tag$34.textContent = css$34;
|
|
4882
4882
|
var RelationsPanel_module_css_default = {
|
|
4883
|
-
"
|
|
4884
|
-
"node_character": "rp_7pEHTW_node_character",
|
|
4885
|
-
"check": "rp_7pEHTW_check",
|
|
4883
|
+
"node": "rp_7pEHTW_node",
|
|
4886
4884
|
"node_location": "rp_7pEHTW_node_location",
|
|
4887
|
-
"
|
|
4888
|
-
"inspector": "rp_7pEHTW_inspector",
|
|
4885
|
+
"panel": "rp_7pEHTW_panel",
|
|
4889
4886
|
"workspace": "rp_7pEHTW_workspace",
|
|
4887
|
+
"list": "rp_7pEHTW_list",
|
|
4888
|
+
"notice": "rp_7pEHTW_notice",
|
|
4889
|
+
"wide": "rp_7pEHTW_wide",
|
|
4890
|
+
"node_character": "rp_7pEHTW_node_character",
|
|
4891
|
+
"filterOn": "rp_7pEHTW_filterOn",
|
|
4892
|
+
"head": "rp_7pEHTW_head",
|
|
4893
|
+
"check": "rp_7pEHTW_check",
|
|
4894
|
+
"metrics": "rp_7pEHTW_metrics",
|
|
4895
|
+
"node_faction": "rp_7pEHTW_node_faction",
|
|
4896
|
+
"error": "rp_7pEHTW_error",
|
|
4890
4897
|
"empty": "rp_7pEHTW_empty",
|
|
4898
|
+
"graphInspector": "rp_7pEHTW_graphInspector",
|
|
4899
|
+
"edgeOn": "rp_7pEHTW_edgeOn",
|
|
4900
|
+
"filter": "rp_7pEHTW_filter",
|
|
4891
4901
|
"graphEdgeOn": "rp_7pEHTW_graphEdgeOn",
|
|
4892
|
-
"
|
|
4893
|
-
"
|
|
4902
|
+
"edgeTitle": "rp_7pEHTW_edgeTitle",
|
|
4903
|
+
"status": "rp_7pEHTW_status",
|
|
4904
|
+
"inspector": "rp_7pEHTW_inspector",
|
|
4905
|
+
"form": "rp_7pEHTW_form",
|
|
4906
|
+
"graph": "rp_7pEHTW_graph",
|
|
4894
4907
|
"edgeKind": "rp_7pEHTW_edgeKind",
|
|
4895
|
-
"
|
|
4896
|
-
"
|
|
4897
|
-
"perspective": "rp_7pEHTW_perspective",
|
|
4898
|
-
"edge": "rp_7pEHTW_edge",
|
|
4908
|
+
"actions": "rp_7pEHTW_actions",
|
|
4909
|
+
"graphEdge": "rp_7pEHTW_graphEdge",
|
|
4899
4910
|
"space": "rp_7pEHTW_space",
|
|
4900
|
-
"
|
|
4901
|
-
"graphInspector": "rp_7pEHTW_graphInspector",
|
|
4902
|
-
"filter": "rp_7pEHTW_filter",
|
|
4903
|
-
"edgeOn": "rp_7pEHTW_edgeOn",
|
|
4904
|
-
"list": "rp_7pEHTW_list",
|
|
4911
|
+
"perspective": "rp_7pEHTW_perspective",
|
|
4905
4912
|
"entities": "rp_7pEHTW_entities",
|
|
4906
|
-
"actions": "rp_7pEHTW_actions",
|
|
4907
|
-
"panel": "rp_7pEHTW_panel",
|
|
4908
|
-
"notice": "rp_7pEHTW_notice",
|
|
4909
|
-
"error": "rp_7pEHTW_error",
|
|
4910
|
-
"metrics": "rp_7pEHTW_metrics",
|
|
4911
|
-
"wide": "rp_7pEHTW_wide",
|
|
4912
4913
|
"node_item": "rp_7pEHTW_node_item",
|
|
4913
|
-
"
|
|
4914
|
-
"
|
|
4915
|
-
"head": "rp_7pEHTW_head"
|
|
4914
|
+
"toolbar": "rp_7pEHTW_toolbar",
|
|
4915
|
+
"edge": "rp_7pEHTW_edge"
|
|
4916
4916
|
};
|
|
4917
4917
|
// src/client/world-editor/RelationsPanel.tsx
|
|
4918
4918
|
const title = (relation) => `${relation.from.name} → ${relation.to.name}`;
|
|
@@ -6283,10 +6283,10 @@ window.__ModuleLoader__.load({
|
|
|
6283
6283
|
var PackFrame_module_css_default = {
|
|
6284
6284
|
"message": "rp_h_sbFq_message",
|
|
6285
6285
|
"fill": "rp_h_sbFq_fill",
|
|
6286
|
+
"hud": "rp_h_sbFq_hud",
|
|
6286
6287
|
"tab": "rp_h_sbFq_tab",
|
|
6287
|
-
"frame": "rp_h_sbFq_frame",
|
|
6288
6288
|
"problems": "rp_h_sbFq_problems",
|
|
6289
|
-
"
|
|
6289
|
+
"frame": "rp_h_sbFq_frame"
|
|
6290
6290
|
};
|
|
6291
6291
|
// src/client/widgets/pack-frame/theme.ts
|
|
6292
6292
|
/** The colours of DSH a surface is given, so that it looks right in light and dark. */
|
|
@@ -6545,13 +6545,13 @@ window.__ModuleLoader__.load({
|
|
|
6545
6545
|
}
|
|
6546
6546
|
tag$32.textContent = css$32;
|
|
6547
6547
|
var PacksPanel_module_css_default = {
|
|
6548
|
+
"stageTall": "rp_FLaP7q_stageTall",
|
|
6549
|
+
"group": "rp_FLaP7q_group",
|
|
6550
|
+
"files": "rp_FLaP7q_files",
|
|
6548
6551
|
"stage": "rp_FLaP7q_stage",
|
|
6549
6552
|
"log": "rp_FLaP7q_log",
|
|
6550
|
-
"files": "rp_FLaP7q_files",
|
|
6551
|
-
"controls": "rp_FLaP7q_controls",
|
|
6552
6553
|
"note": "rp_FLaP7q_note",
|
|
6553
|
-
"
|
|
6554
|
-
"group": "rp_FLaP7q_group"
|
|
6554
|
+
"controls": "rp_FLaP7q_controls"
|
|
6555
6555
|
};
|
|
6556
6556
|
// src/client/world-editor/PacksPanel.tsx
|
|
6557
6557
|
const WIDTHS = {
|
|
@@ -7444,7 +7444,7 @@ window.__ModuleLoader__.load({
|
|
|
7444
7444
|
});
|
|
7445
7445
|
}
|
|
7446
7446
|
// src/client/lorebooks-api.ts
|
|
7447
|
-
async function reply$
|
|
7447
|
+
async function reply$5(response) {
|
|
7448
7448
|
if (!response.ok) {
|
|
7449
7449
|
const body = await response.json().catch(() => void 0);
|
|
7450
7450
|
throw new Error(typeof body?.message === "string" ? body.message : `${response.status} ${response.statusText}`.trim());
|
|
@@ -7459,38 +7459,38 @@ window.__ModuleLoader__.load({
|
|
|
7459
7459
|
});
|
|
7460
7460
|
const named = (name) => `name=${encodeURIComponent(name)}`;
|
|
7461
7461
|
async function listLorebooks(signal) {
|
|
7462
|
-
return await reply$
|
|
7462
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks`, {
|
|
7463
7463
|
credentials: "same-origin",
|
|
7464
7464
|
signal
|
|
7465
7465
|
}));
|
|
7466
7466
|
}
|
|
7467
7467
|
async function readLorebook(name, signal) {
|
|
7468
|
-
return await reply$
|
|
7468
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks/item?${named(name)}`, {
|
|
7469
7469
|
credentials: "same-origin",
|
|
7470
7470
|
signal
|
|
7471
7471
|
}));
|
|
7472
7472
|
}
|
|
7473
7473
|
async function createLorebook(request, signal) {
|
|
7474
|
-
return await reply$
|
|
7474
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks`, {
|
|
7475
7475
|
...json$2("POST", request),
|
|
7476
7476
|
signal
|
|
7477
7477
|
}));
|
|
7478
7478
|
}
|
|
7479
7479
|
async function updateLorebookInfo(name, change, signal) {
|
|
7480
|
-
return await reply$
|
|
7480
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks/item?${named(name)}`, {
|
|
7481
7481
|
...json$2("PUT", change),
|
|
7482
7482
|
signal
|
|
7483
7483
|
}));
|
|
7484
7484
|
}
|
|
7485
7485
|
async function writeLorebookEntry(name, entry, signal) {
|
|
7486
7486
|
const { id, ...rest } = entry;
|
|
7487
|
-
return await reply$
|
|
7487
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks/entry?${named(name)}&id=${encodeURIComponent(id)}`, {
|
|
7488
7488
|
...json$2("PUT", rest),
|
|
7489
7489
|
signal
|
|
7490
7490
|
}));
|
|
7491
7491
|
}
|
|
7492
7492
|
async function removeLorebookEntry(name, id, signal) {
|
|
7493
|
-
return await reply$
|
|
7493
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks/entry?${named(name)}&id=${encodeURIComponent(id)}`, {
|
|
7494
7494
|
method: "DELETE",
|
|
7495
7495
|
credentials: "same-origin",
|
|
7496
7496
|
signal
|
|
@@ -7502,37 +7502,37 @@ window.__ModuleLoader__.load({
|
|
|
7502
7502
|
credentials: "same-origin",
|
|
7503
7503
|
signal
|
|
7504
7504
|
});
|
|
7505
|
-
if (!response.ok) await reply$
|
|
7505
|
+
if (!response.ok) await reply$5(response);
|
|
7506
7506
|
}
|
|
7507
7507
|
/** Opens the authoring chat of a lorebook. */
|
|
7508
7508
|
async function authorLorebook(name, language, signal) {
|
|
7509
|
-
return await reply$
|
|
7509
|
+
return await reply$5(await fetch(`${API_PREFIX}/lorebooks/authoring?${named(name)}`, {
|
|
7510
7510
|
...json$2("POST", { language }),
|
|
7511
7511
|
signal
|
|
7512
7512
|
}));
|
|
7513
7513
|
}
|
|
7514
7514
|
async function loadStoryLorebooks(session, signal) {
|
|
7515
|
-
return await reply$
|
|
7515
|
+
return await reply$5(await fetch(`${API_PREFIX}/sessions/lorebooks?id=${encodeURIComponent(session)}`, {
|
|
7516
7516
|
credentials: "same-origin",
|
|
7517
7517
|
signal
|
|
7518
7518
|
}));
|
|
7519
7519
|
}
|
|
7520
7520
|
/** Copies a library lorebook into the chat's story; the notes say what could not be carried over. */
|
|
7521
7521
|
async function addStoryLorebook(session, name, signal) {
|
|
7522
|
-
return await reply$
|
|
7522
|
+
return await reply$5(await fetch(`${API_PREFIX}/sessions/lorebooks?id=${encodeURIComponent(session)}`, {
|
|
7523
7523
|
...json$2("POST", { name }),
|
|
7524
7524
|
signal
|
|
7525
7525
|
}));
|
|
7526
7526
|
}
|
|
7527
7527
|
async function removeStoryLorebook(session, name, signal) {
|
|
7528
|
-
return await reply$
|
|
7528
|
+
return await reply$5(await fetch(`${API_PREFIX}/sessions/lorebooks?id=${encodeURIComponent(session)}&${named(name)}`, {
|
|
7529
7529
|
method: "DELETE",
|
|
7530
7530
|
credentials: "same-origin",
|
|
7531
7531
|
signal
|
|
7532
7532
|
}));
|
|
7533
7533
|
}
|
|
7534
7534
|
// src/client/presets-api.ts
|
|
7535
|
-
async function reply$
|
|
7535
|
+
async function reply$4(response) {
|
|
7536
7536
|
if (!response.ok) {
|
|
7537
7537
|
const body = await response.json().catch(() => void 0);
|
|
7538
7538
|
throw new Error(typeof body?.message === "string" ? body.message : `${response.status} ${response.statusText}`.trim());
|
|
@@ -7546,75 +7546,75 @@ window.__ModuleLoader__.load({
|
|
|
7546
7546
|
body: JSON.stringify(body)
|
|
7547
7547
|
});
|
|
7548
7548
|
async function listPresets(signal) {
|
|
7549
|
-
return await reply$
|
|
7549
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets`, {
|
|
7550
7550
|
credentials: "same-origin",
|
|
7551
7551
|
signal
|
|
7552
7552
|
}));
|
|
7553
7553
|
}
|
|
7554
7554
|
/** Makes a preset of the prose prompts a world carries. */
|
|
7555
7555
|
async function savePresetFromWorld(request, signal) {
|
|
7556
|
-
return await reply$
|
|
7556
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets`, {
|
|
7557
7557
|
...json$1("POST", request),
|
|
7558
7558
|
signal
|
|
7559
7559
|
}));
|
|
7560
7560
|
}
|
|
7561
7561
|
async function loadPresetStatus(session, signal) {
|
|
7562
|
-
return await reply$
|
|
7562
|
+
return await reply$4(await fetch(`${API_PREFIX}/sessions/preset?id=${encodeURIComponent(session)}`, {
|
|
7563
7563
|
credentials: "same-origin",
|
|
7564
7564
|
signal
|
|
7565
7565
|
}));
|
|
7566
7566
|
}
|
|
7567
7567
|
/** Puts a preset into the chat's story, or takes its preset out when no name is given. */
|
|
7568
7568
|
async function applyPreset(session, name, signal) {
|
|
7569
|
-
return await reply$
|
|
7569
|
+
return await reply$4(await fetch(`${API_PREFIX}/sessions/preset?id=${encodeURIComponent(session)}`, {
|
|
7570
7570
|
...json$1("POST", name === void 0 ? {} : { name }),
|
|
7571
7571
|
signal
|
|
7572
7572
|
}));
|
|
7573
7573
|
}
|
|
7574
7574
|
const empty = async (response) => {
|
|
7575
|
-
if (!response.ok) await reply$
|
|
7575
|
+
if (!response.ok) await reply$4(response);
|
|
7576
7576
|
};
|
|
7577
7577
|
async function readPreset(name, signal) {
|
|
7578
|
-
return await reply$
|
|
7578
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets/item?name=${encodeURIComponent(name)}`, {
|
|
7579
7579
|
credentials: "same-origin",
|
|
7580
7580
|
signal
|
|
7581
7581
|
}));
|
|
7582
7582
|
}
|
|
7583
7583
|
/** Makes a preset holding the shipped prose prompts, as a starting point to edit. */
|
|
7584
7584
|
async function createPreset(request, signal) {
|
|
7585
|
-
return await reply$
|
|
7585
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets`, {
|
|
7586
7586
|
...json$1("POST", request),
|
|
7587
7587
|
signal
|
|
7588
7588
|
}));
|
|
7589
7589
|
}
|
|
7590
7590
|
async function updatePresetInfo(name, change, signal) {
|
|
7591
|
-
return await reply$
|
|
7591
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets/item?name=${encodeURIComponent(name)}`, {
|
|
7592
7592
|
...json$1("PUT", change),
|
|
7593
7593
|
signal
|
|
7594
7594
|
}));
|
|
7595
7595
|
}
|
|
7596
7596
|
/** The prompts with rules of the game that the preset could take over from the shipped ones. */
|
|
7597
7597
|
async function listRulesPrompts(name, language, signal) {
|
|
7598
|
-
return await reply$
|
|
7598
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets/prompts?name=${encodeURIComponent(name)}&language=${encodeURIComponent(language)}`, {
|
|
7599
7599
|
credentials: "same-origin",
|
|
7600
7600
|
signal
|
|
7601
7601
|
}));
|
|
7602
7602
|
}
|
|
7603
7603
|
/** A prompt as a story with the preset gets it: the preset's own, else the shipped one. */
|
|
7604
7604
|
async function readPresetPrompt(name, language, id, signal) {
|
|
7605
|
-
return (await reply$
|
|
7605
|
+
return (await reply$4(await fetch(`${API_PREFIX}/presets/prompt?name=${encodeURIComponent(name)}&language=${encodeURIComponent(language)}&id=${encodeURIComponent(id)}`, {
|
|
7606
7606
|
credentials: "same-origin",
|
|
7607
7607
|
signal
|
|
7608
7608
|
}))).text;
|
|
7609
7609
|
}
|
|
7610
7610
|
async function writePresetPrompt(name, language, id, text, signal) {
|
|
7611
|
-
return await reply$
|
|
7611
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets/prompt?name=${encodeURIComponent(name)}&language=${encodeURIComponent(language)}&id=${encodeURIComponent(id)}`, {
|
|
7612
7612
|
...json$1("PUT", { text }),
|
|
7613
7613
|
signal
|
|
7614
7614
|
}));
|
|
7615
7615
|
}
|
|
7616
7616
|
async function removePresetPrompt(name, language, id, signal) {
|
|
7617
|
-
return await reply$
|
|
7617
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets/prompt?name=${encodeURIComponent(name)}&language=${encodeURIComponent(language)}&id=${encodeURIComponent(id)}`, {
|
|
7618
7618
|
method: "DELETE",
|
|
7619
7619
|
credentials: "same-origin",
|
|
7620
7620
|
signal
|
|
@@ -7629,7 +7629,7 @@ window.__ModuleLoader__.load({
|
|
|
7629
7629
|
}
|
|
7630
7630
|
/** Opens the authoring chat of a preset. */
|
|
7631
7631
|
async function authorPreset(name, language, signal) {
|
|
7632
|
-
return await reply$
|
|
7632
|
+
return await reply$4(await fetch(`${API_PREFIX}/presets/authoring?name=${encodeURIComponent(name)}`, {
|
|
7633
7633
|
...json$1("POST", { language }),
|
|
7634
7634
|
signal
|
|
7635
7635
|
}));
|
|
@@ -7646,12 +7646,12 @@ window.__ModuleLoader__.load({
|
|
|
7646
7646
|
}
|
|
7647
7647
|
tag$31.textContent = css$31;
|
|
7648
7648
|
var SamplingFields_module_css_default = {
|
|
7649
|
-
"
|
|
7649
|
+
"field": "rp_9vxYSG_field",
|
|
7650
7650
|
"label": "rp_9vxYSG_label",
|
|
7651
|
+
"input": "rp_9vxYSG_input",
|
|
7652
|
+
"help": "rp_9vxYSG_help",
|
|
7651
7653
|
"root": "rp_9vxYSG_root",
|
|
7652
|
-
"grid": "rp_9vxYSG_grid"
|
|
7653
|
-
"field": "rp_9vxYSG_field",
|
|
7654
|
-
"help": "rp_9vxYSG_help"
|
|
7654
|
+
"grid": "rp_9vxYSG_grid"
|
|
7655
7655
|
};
|
|
7656
7656
|
// src/client/widgets/sampling-fields/SamplingFields.tsx
|
|
7657
7657
|
const samplingTexts = (sampling) => Object.fromEntries(SAMPLING_KEYS.map((key) => [key, sampling[key]?.toString() ?? ""]));
|
|
@@ -8045,6 +8045,7 @@ window.__ModuleLoader__.load({
|
|
|
8045
8045
|
timeZone: info.timeZone,
|
|
8046
8046
|
startingTime: info.startingTime,
|
|
8047
8047
|
version: info.version,
|
|
8048
|
+
autonomy: info.autonomy,
|
|
8048
8049
|
preset: info.preset,
|
|
8049
8050
|
lorebooks: info.lorebooks,
|
|
8050
8051
|
sampling: samplingTexts(info.sampling),
|
|
@@ -8067,6 +8068,7 @@ window.__ModuleLoader__.load({
|
|
|
8067
8068
|
"version",
|
|
8068
8069
|
"preset"
|
|
8069
8070
|
]) if (draft[key].trim() !== saved[key].trim()) edit[key] = draft[key];
|
|
8071
|
+
if (draft.autonomy !== saved.autonomy) edit["autonomy"] = draft.autonomy;
|
|
8070
8072
|
if (JSON.stringify(draft.lorebooks) !== JSON.stringify(saved.lorebooks)) edit["lorebooks"] = draft.lorebooks;
|
|
8071
8073
|
if (JSON.stringify(samplingOfTexts(draft.sampling)) !== JSON.stringify(samplingOfTexts(saved.sampling))) edit["sampling"] = samplingOfTexts(draft.sampling);
|
|
8072
8074
|
if (JSON.stringify(words(draft.tags)) !== JSON.stringify(words(saved.tags))) edit["tags"] = words(draft.tags);
|
|
@@ -8376,6 +8378,31 @@ window.__ModuleLoader__.load({
|
|
|
8376
8378
|
field("authorUrl", "infoAuthorUrl", void 0, { placeholder: "https://" }),
|
|
8377
8379
|
field("timeZone", "infoTimeZone", "infoTimeZoneHelp", { placeholder: "Europe/London" }),
|
|
8378
8380
|
field("startingTime", "infoStartingTime", "infoStartingTimeHelp", { placeholder: "1912-04-14T23:40:00" }),
|
|
8381
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
8382
|
+
className: CharactersPanel_module_css_default.field,
|
|
8383
|
+
children: [
|
|
8384
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
8385
|
+
className: CharactersPanel_module_css_default.label,
|
|
8386
|
+
children: t("infoAutonomy")
|
|
8387
|
+
}),
|
|
8388
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
8389
|
+
type: "checkbox",
|
|
8390
|
+
checked: draft.autonomy,
|
|
8391
|
+
"data-testid": "roleplay-world-autonomy",
|
|
8392
|
+
onChange: (event) => {
|
|
8393
|
+
setDraft({
|
|
8394
|
+
...draft,
|
|
8395
|
+
autonomy: event.target.checked
|
|
8396
|
+
});
|
|
8397
|
+
setStatus({ state: "idle" });
|
|
8398
|
+
}
|
|
8399
|
+
}),
|
|
8400
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
8401
|
+
className: CharactersPanel_module_css_default.help,
|
|
8402
|
+
children: t("infoAutonomyHelp")
|
|
8403
|
+
})
|
|
8404
|
+
]
|
|
8405
|
+
}),
|
|
8379
8406
|
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
8380
8407
|
className: CharactersPanel_module_css_default.field,
|
|
8381
8408
|
children: [
|
|
@@ -9025,6 +9052,24 @@ window.__ModuleLoader__.load({
|
|
|
9025
9052
|
t("routineInterruptible")
|
|
9026
9053
|
] })
|
|
9027
9054
|
}),
|
|
9055
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("label", {
|
|
9056
|
+
className: CharactersPanel_module_css_default.field,
|
|
9057
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", { children: [
|
|
9058
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
9059
|
+
type: "checkbox",
|
|
9060
|
+
checked: window.sleep === true,
|
|
9061
|
+
onChange: (event) => {
|
|
9062
|
+
const { sleep: _s, ...rest } = window;
|
|
9063
|
+
change(draft.map((item, at) => at === index ? {
|
|
9064
|
+
...rest,
|
|
9065
|
+
...event.target.checked ? { sleep: true } : {}
|
|
9066
|
+
} : item));
|
|
9067
|
+
}
|
|
9068
|
+
}),
|
|
9069
|
+
" ",
|
|
9070
|
+
t("routineSleep")
|
|
9071
|
+
] })
|
|
9072
|
+
}),
|
|
9028
9073
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
9029
9074
|
variant: "ghost",
|
|
9030
9075
|
size: "sm",
|
|
@@ -9409,17 +9454,17 @@ window.__ModuleLoader__.load({
|
|
|
9409
9454
|
}
|
|
9410
9455
|
tag$30.textContent = css$30;
|
|
9411
9456
|
var ToolSwitches_module_css_default = {
|
|
9457
|
+
"help": "rp_CjoFLq_help",
|
|
9458
|
+
"toolText": "rp_CjoFLq_toolText",
|
|
9459
|
+
"root": "rp_CjoFLq_root",
|
|
9412
9460
|
"default": "rp_CjoFLq_default",
|
|
9461
|
+
"external": "rp_CjoFLq_external",
|
|
9413
9462
|
"agent": "rp_CjoFLq_agent",
|
|
9414
|
-
"tool": "rp_CjoFLq_tool",
|
|
9415
|
-
"hint": "rp_CjoFLq_hint",
|
|
9416
|
-
"error": "rp_CjoFLq_error",
|
|
9417
|
-
"help": "rp_CjoFLq_help",
|
|
9418
9463
|
"title": "rp_CjoFLq_title",
|
|
9419
|
-
"
|
|
9464
|
+
"hint": "rp_CjoFLq_hint",
|
|
9420
9465
|
"agentName": "rp_CjoFLq_agentName",
|
|
9421
|
-
"
|
|
9422
|
-
"
|
|
9466
|
+
"error": "rp_CjoFLq_error",
|
|
9467
|
+
"tool": "rp_CjoFLq_tool"
|
|
9423
9468
|
};
|
|
9424
9469
|
// src/client/widgets/tool-switches/ToolSwitches.tsx
|
|
9425
9470
|
/**
|
|
@@ -10426,35 +10471,35 @@ window.__ModuleLoader__.load({
|
|
|
10426
10471
|
}
|
|
10427
10472
|
tag$29.textContent = css$29;
|
|
10428
10473
|
var GalleryView_module_css_default = {
|
|
10429
|
-
"
|
|
10430
|
-
"
|
|
10431
|
-
"
|
|
10432
|
-
"
|
|
10433
|
-
"detail": "rp_9pSHmG_detail",
|
|
10474
|
+
"count": "rp_9pSHmG_count",
|
|
10475
|
+
"status": "rp_9pSHmG_status",
|
|
10476
|
+
"actions": "rp_9pSHmG_actions",
|
|
10477
|
+
"facts": "rp_9pSHmG_facts",
|
|
10434
10478
|
"edit": "rp_9pSHmG_edit",
|
|
10435
|
-
"
|
|
10479
|
+
"caption": "rp_9pSHmG_caption",
|
|
10480
|
+
"page": "rp_9pSHmG_page",
|
|
10436
10481
|
"large": "rp_9pSHmG_large",
|
|
10437
10482
|
"editArea": "rp_9pSHmG_editArea",
|
|
10438
|
-
"
|
|
10483
|
+
"editButton": "rp_9pSHmG_editButton",
|
|
10439
10484
|
"image": "rp_9pSHmG_image",
|
|
10485
|
+
"detail": "rp_9pSHmG_detail",
|
|
10440
10486
|
"tags": "rp_9pSHmG_tags",
|
|
10441
|
-
"message": "rp_9pSHmG_message",
|
|
10442
10487
|
"toolbar": "rp_9pSHmG_toolbar",
|
|
10488
|
+
"editLabel": "rp_9pSHmG_editLabel",
|
|
10443
10489
|
"error": "rp_9pSHmG_error",
|
|
10444
|
-
"
|
|
10445
|
-
"
|
|
10446
|
-
"open": "rp_9pSHmG_open",
|
|
10447
|
-
"actions": "rp_9pSHmG_actions",
|
|
10490
|
+
"statusError": "rp_9pSHmG_statusError",
|
|
10491
|
+
"editHelp": "rp_9pSHmG_editHelp",
|
|
10448
10492
|
"editInput": "rp_9pSHmG_editInput",
|
|
10449
|
-
"
|
|
10493
|
+
"open": "rp_9pSHmG_open",
|
|
10494
|
+
"select": "rp_9pSHmG_select",
|
|
10495
|
+
"thumb": "rp_9pSHmG_thumb",
|
|
10496
|
+
"note": "rp_9pSHmG_note",
|
|
10450
10497
|
"editField": "rp_9pSHmG_editField",
|
|
10451
|
-
"
|
|
10452
|
-
"
|
|
10453
|
-
"facts": "rp_9pSHmG_facts",
|
|
10454
|
-
"reusable": "rp_9pSHmG_reusable",
|
|
10455
|
-
"editButton": "rp_9pSHmG_editButton",
|
|
10498
|
+
"message": "rp_9pSHmG_message",
|
|
10499
|
+
"pre": "rp_9pSHmG_pre",
|
|
10456
10500
|
"grid": "rp_9pSHmG_grid",
|
|
10457
|
-
"
|
|
10501
|
+
"cell": "rp_9pSHmG_cell",
|
|
10502
|
+
"reusable": "rp_9pSHmG_reusable"
|
|
10458
10503
|
};
|
|
10459
10504
|
// src/client/widgets/gallery-view/GalleryView.tsx
|
|
10460
10505
|
/** How often the list is read again while pictures are waiting to be described. */
|
|
@@ -10793,13 +10838,13 @@ window.__ModuleLoader__.load({
|
|
|
10793
10838
|
}
|
|
10794
10839
|
tag$28.textContent = css$28;
|
|
10795
10840
|
var WorldEditor_module_css_default = {
|
|
10796
|
-
"warning": "rp__swA3a_warning",
|
|
10797
|
-
"drawer": "rp__swA3a_drawer",
|
|
10798
10841
|
"drawerItem": "rp__swA3a_drawerItem",
|
|
10842
|
+
"drawer": "rp__swA3a_drawer",
|
|
10799
10843
|
"drawerItemOn": "rp__swA3a_drawerItemOn",
|
|
10800
|
-
"view": "rp__swA3a_view",
|
|
10801
10844
|
"content": "rp__swA3a_content",
|
|
10802
|
-
"message": "rp__swA3a_message"
|
|
10845
|
+
"message": "rp__swA3a_message",
|
|
10846
|
+
"view": "rp__swA3a_view",
|
|
10847
|
+
"warning": "rp__swA3a_warning"
|
|
10803
10848
|
};
|
|
10804
10849
|
// src/client/world-editor/WorldEditor.tsx
|
|
10805
10850
|
const SECTIONS = [
|
|
@@ -11193,27 +11238,27 @@ window.__ModuleLoader__.load({
|
|
|
11193
11238
|
}
|
|
11194
11239
|
tag$27.textContent = css$27;
|
|
11195
11240
|
var AvatarsPage_module_css_default = {
|
|
11196
|
-
"placeholder": "rp_pQOzEG_placeholder",
|
|
11197
|
-
"page": "rp_pQOzEG_page",
|
|
11198
|
-
"open": "rp_pQOzEG_open",
|
|
11199
|
-
"actions": "rp_pQOzEG_actions",
|
|
11200
|
-
"toolbar": "rp_pQOzEG_toolbar",
|
|
11201
|
-
"card": "rp_pQOzEG_card",
|
|
11202
|
-
"name": "rp_pQOzEG_name",
|
|
11203
11241
|
"grid": "rp_pQOzEG_grid",
|
|
11204
|
-
"
|
|
11205
|
-
"message": "rp_pQOzEG_message",
|
|
11206
|
-
"count": "rp_pQOzEG_count",
|
|
11242
|
+
"card": "rp_pQOzEG_card",
|
|
11207
11243
|
"editHeader": "rp_pQOzEG_editHeader",
|
|
11208
|
-
"editBody": "rp_pQOzEG_editBody",
|
|
11209
|
-
"text": "rp_pQOzEG_text",
|
|
11210
|
-
"summary": "rp_pQOzEG_summary",
|
|
11211
|
-
"error": "rp_pQOzEG_error",
|
|
11212
11244
|
"editTitle": "rp_pQOzEG_editTitle",
|
|
11213
|
-
"field": "rp_pQOzEG_field",
|
|
11214
11245
|
"form": "rp_pQOzEG_form",
|
|
11215
11246
|
"label": "rp_pQOzEG_label",
|
|
11216
|
-
"
|
|
11247
|
+
"open": "rp_pQOzEG_open",
|
|
11248
|
+
"name": "rp_pQOzEG_name",
|
|
11249
|
+
"portrait": "rp_pQOzEG_portrait",
|
|
11250
|
+
"error": "rp_pQOzEG_error",
|
|
11251
|
+
"field": "rp_pQOzEG_field",
|
|
11252
|
+
"editBody": "rp_pQOzEG_editBody",
|
|
11253
|
+
"count": "rp_pQOzEG_count",
|
|
11254
|
+
"summary": "rp_pQOzEG_summary",
|
|
11255
|
+
"text": "rp_pQOzEG_text",
|
|
11256
|
+
"viewport": "rp_pQOzEG_viewport",
|
|
11257
|
+
"message": "rp_pQOzEG_message",
|
|
11258
|
+
"page": "rp_pQOzEG_page",
|
|
11259
|
+
"toolbar": "rp_pQOzEG_toolbar",
|
|
11260
|
+
"actions": "rp_pQOzEG_actions",
|
|
11261
|
+
"placeholder": "rp_pQOzEG_placeholder"
|
|
11217
11262
|
};
|
|
11218
11263
|
// src/client/pages/avatars/AvatarsPage.tsx
|
|
11219
11264
|
const hueOf$2 = (name) => Array.from(name).reduce((hash, char) => (hash * 31 + char.charCodeAt(0)) % 360, 0);
|
|
@@ -11709,6 +11754,7 @@ window.__ModuleLoader__.load({
|
|
|
11709
11754
|
routineFeature: "Spot in the place",
|
|
11710
11755
|
routinePosition: "Where exactly",
|
|
11711
11756
|
routineInterruptible: "Would drop it for something that comes up",
|
|
11757
|
+
routineSleep: "Asleep in this window",
|
|
11712
11758
|
routineRemove: "Remove window",
|
|
11713
11759
|
routineAdd: "Add a window",
|
|
11714
11760
|
day_mon: "Mon",
|
|
@@ -11769,6 +11815,8 @@ window.__ModuleLoader__.load({
|
|
|
11769
11815
|
infoAuthorUrl: "Author link",
|
|
11770
11816
|
infoTimeZone: "Time zone",
|
|
11771
11817
|
infoTimeZoneHelp: "An IANA name such as Europe/London. Empty means UTC.",
|
|
11818
|
+
infoAutonomy: "Stories go on while the player is away",
|
|
11819
|
+
infoAutonomyHelp: "Off unless you switch it on. A story of this world then starts on the real clock with the characters keeping to their days while nobody plays, and one may write to the player; the player can still turn it off for their story, and it stops by itself after a few things with no reply.",
|
|
11772
11820
|
infoStartingTime: "Story starts at",
|
|
11773
11821
|
infoStartingTimeHelp: "Date and time in that zone, like 1912-04-14T23:40:00.",
|
|
11774
11822
|
promptsLanguage: "Language",
|
|
@@ -12008,6 +12056,7 @@ window.__ModuleLoader__.load({
|
|
|
12008
12056
|
routineFeature: "地点中的位置",
|
|
12009
12057
|
routinePosition: "具体位置",
|
|
12010
12058
|
routineInterruptible: "有事发生时会放下它",
|
|
12059
|
+
routineSleep: "这个时段在睡觉",
|
|
12011
12060
|
routineRemove: "移除时段",
|
|
12012
12061
|
routineAdd: "添加时段",
|
|
12013
12062
|
day_mon: "周一",
|
|
@@ -12068,6 +12117,8 @@ window.__ModuleLoader__.load({
|
|
|
12068
12117
|
infoAuthorUrl: "作者链接",
|
|
12069
12118
|
infoTimeZone: "时区",
|
|
12070
12119
|
infoTimeZoneHelp: "IANA 名称,例如 Europe/London;留空为 UTC。",
|
|
12120
|
+
infoAutonomy: "玩家不在时故事继续",
|
|
12121
|
+
infoAutonomyHelp: "默认关闭,需要你打开。这个世界的故事会使用真实时钟,没人玩的时候角色按各自日程行事,其中一人可能给玩家写消息;玩家仍可为自己的故事关闭它,没有回复时它会在几件事之后自动停下。",
|
|
12071
12122
|
infoStartingTime: "故事开始于",
|
|
12072
12123
|
infoStartingTimeHelp: "该时区的日期和时间,例如 1912-04-14T23:40:00。",
|
|
12073
12124
|
promptsLanguage: "语言",
|
|
@@ -12704,37 +12755,37 @@ window.__ModuleLoader__.load({
|
|
|
12704
12755
|
}
|
|
12705
12756
|
tag$26.textContent = css$26;
|
|
12706
12757
|
var LorebooksPage_module_css_default = {
|
|
12758
|
+
"grid": "rp_VV-Eha_grid",
|
|
12759
|
+
"field": "rp_VV-Eha_field",
|
|
12760
|
+
"message": "rp_VV-Eha_message",
|
|
12761
|
+
"entryArea": "rp_VV-Eha_entryArea",
|
|
12762
|
+
"help": "rp_VV-Eha_help",
|
|
12707
12763
|
"title": "rp_VV-Eha_title",
|
|
12708
|
-
"
|
|
12709
|
-
"
|
|
12764
|
+
"ok": "rp_VV-Eha_ok",
|
|
12765
|
+
"cardActions": "rp_VV-Eha_cardActions",
|
|
12766
|
+
"card": "rp_VV-Eha_card",
|
|
12767
|
+
"name": "rp_VV-Eha_name",
|
|
12768
|
+
"warning": "rp_VV-Eha_warning",
|
|
12710
12769
|
"meta": "rp_VV-Eha_meta",
|
|
12711
|
-
"
|
|
12712
|
-
"form": "rp_VV-Eha_form",
|
|
12713
|
-
"label": "rp_VV-Eha_label",
|
|
12714
|
-
"editHeader": "rp_VV-Eha_editHeader",
|
|
12715
|
-
"toolbar": "rp_VV-Eha_toolbar",
|
|
12770
|
+
"description": "rp_VV-Eha_description",
|
|
12716
12771
|
"viewport": "rp_VV-Eha_viewport",
|
|
12717
12772
|
"input": "rp_VV-Eha_input",
|
|
12718
|
-
"cardActions": "rp_VV-Eha_cardActions",
|
|
12719
|
-
"ok": "rp_VV-Eha_ok",
|
|
12720
|
-
"field": "rp_VV-Eha_field",
|
|
12721
|
-
"editBody": "rp_VV-Eha_editBody",
|
|
12722
|
-
"description": "rp_VV-Eha_description",
|
|
12723
12773
|
"actions": "rp_VV-Eha_actions",
|
|
12724
|
-
"
|
|
12774
|
+
"editHeader": "rp_VV-Eha_editHeader",
|
|
12775
|
+
"form": "rp_VV-Eha_form",
|
|
12776
|
+
"select": "rp_VV-Eha_select",
|
|
12777
|
+
"count": "rp_VV-Eha_count",
|
|
12725
12778
|
"editTitle": "rp_VV-Eha_editTitle",
|
|
12779
|
+
"section": "rp_VV-Eha_section",
|
|
12780
|
+
"label": "rp_VV-Eha_label",
|
|
12781
|
+
"toolbar": "rp_VV-Eha_toolbar",
|
|
12726
12782
|
"row": "rp_VV-Eha_row",
|
|
12727
|
-
"area": "rp_VV-Eha_area",
|
|
12728
|
-
"select": "rp_VV-Eha_select",
|
|
12729
|
-
"grid": "rp_VV-Eha_grid",
|
|
12730
|
-
"card": "rp_VV-Eha_card",
|
|
12731
|
-
"error": "rp_VV-Eha_error",
|
|
12732
12783
|
"sectionTitle": "rp_VV-Eha_sectionTitle",
|
|
12733
|
-
"
|
|
12734
|
-
"
|
|
12735
|
-
"name": "rp_VV-Eha_name",
|
|
12784
|
+
"page": "rp_VV-Eha_page",
|
|
12785
|
+
"area": "rp_VV-Eha_area",
|
|
12736
12786
|
"head": "rp_VV-Eha_head",
|
|
12737
|
-
"
|
|
12787
|
+
"error": "rp_VV-Eha_error",
|
|
12788
|
+
"editBody": "rp_VV-Eha_editBody"
|
|
12738
12789
|
};
|
|
12739
12790
|
// src/client/pages/lorebooks/LorebookEditor.tsx
|
|
12740
12791
|
const messageOf$9 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
@@ -13773,35 +13824,35 @@ window.__ModuleLoader__.load({
|
|
|
13773
13824
|
}
|
|
13774
13825
|
tag$25.textContent = css$25;
|
|
13775
13826
|
var PresetsPage_module_css_default = {
|
|
13776
|
-
"
|
|
13777
|
-
"
|
|
13778
|
-
"
|
|
13827
|
+
"title": "rp_ZK89ba_title",
|
|
13828
|
+
"editTitle": "rp_ZK89ba_editTitle",
|
|
13829
|
+
"sectionTitle": "rp_ZK89ba_sectionTitle",
|
|
13830
|
+
"card": "rp_ZK89ba_card",
|
|
13831
|
+
"help": "rp_ZK89ba_help",
|
|
13832
|
+
"warning": "rp_ZK89ba_warning",
|
|
13833
|
+
"cardActions": "rp_ZK89ba_cardActions",
|
|
13834
|
+
"ok": "rp_ZK89ba_ok",
|
|
13835
|
+
"page": "rp_ZK89ba_page",
|
|
13836
|
+
"section": "rp_ZK89ba_section",
|
|
13837
|
+
"meta": "rp_ZK89ba_meta",
|
|
13838
|
+
"actions": "rp_ZK89ba_actions",
|
|
13839
|
+
"editHeader": "rp_ZK89ba_editHeader",
|
|
13779
13840
|
"name": "rp_ZK89ba_name",
|
|
13780
13841
|
"label": "rp_ZK89ba_label",
|
|
13781
|
-
"page": "rp_ZK89ba_page",
|
|
13782
13842
|
"grid": "rp_ZK89ba_grid",
|
|
13783
|
-
"
|
|
13784
|
-
"ok": "rp_ZK89ba_ok",
|
|
13785
|
-
"help": "rp_ZK89ba_help",
|
|
13843
|
+
"viewport": "rp_ZK89ba_viewport",
|
|
13786
13844
|
"error": "rp_ZK89ba_error",
|
|
13787
|
-
"
|
|
13788
|
-
"actions": "rp_ZK89ba_actions",
|
|
13789
|
-
"meta": "rp_ZK89ba_meta",
|
|
13845
|
+
"field": "rp_ZK89ba_field",
|
|
13790
13846
|
"area": "rp_ZK89ba_area",
|
|
13791
|
-
"
|
|
13847
|
+
"form": "rp_ZK89ba_form",
|
|
13848
|
+
"input": "rp_ZK89ba_input",
|
|
13792
13849
|
"message": "rp_ZK89ba_message",
|
|
13793
|
-
"
|
|
13794
|
-
"
|
|
13850
|
+
"row": "rp_ZK89ba_row",
|
|
13851
|
+
"toolbar": "rp_ZK89ba_toolbar",
|
|
13795
13852
|
"head": "rp_ZK89ba_head",
|
|
13796
|
-
"form": "rp_ZK89ba_form",
|
|
13797
|
-
"description": "rp_ZK89ba_description",
|
|
13798
|
-
"cardActions": "rp_ZK89ba_cardActions",
|
|
13799
|
-
"warning": "rp_ZK89ba_warning",
|
|
13800
13853
|
"count": "rp_ZK89ba_count",
|
|
13801
|
-
"
|
|
13802
|
-
"
|
|
13803
|
-
"sectionTitle": "rp_ZK89ba_sectionTitle",
|
|
13804
|
-
"viewport": "rp_ZK89ba_viewport"
|
|
13854
|
+
"description": "rp_ZK89ba_description",
|
|
13855
|
+
"editBody": "rp_ZK89ba_editBody"
|
|
13805
13856
|
};
|
|
13806
13857
|
// src/client/pages/presets/PresetEditor.tsx
|
|
13807
13858
|
const messageOf$6 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
@@ -14830,7 +14881,7 @@ window.__ModuleLoader__.load({
|
|
|
14830
14881
|
}, PresetsPage));
|
|
14831
14882
|
}
|
|
14832
14883
|
// src/client/prompts-api.ts
|
|
14833
|
-
async function reply$
|
|
14884
|
+
async function reply$3(response) {
|
|
14834
14885
|
if (!response.ok) {
|
|
14835
14886
|
const body = await response.json().catch(() => void 0);
|
|
14836
14887
|
throw new Error(typeof body?.message === "string" ? body.message : `${response.status} ${response.statusText}`.trim());
|
|
@@ -14839,19 +14890,19 @@ window.__ModuleLoader__.load({
|
|
|
14839
14890
|
}
|
|
14840
14891
|
const address$1 = (id, language, suffix = "") => `${API_PREFIX}/prompts/item${suffix}?id=${encodeURIComponent(id)}&language=${encodeURIComponent(language)}`;
|
|
14841
14892
|
async function listPrompts(signal) {
|
|
14842
|
-
return await reply$
|
|
14893
|
+
return await reply$3(await fetch(`${API_PREFIX}/prompts`, {
|
|
14843
14894
|
credentials: "same-origin",
|
|
14844
14895
|
signal
|
|
14845
14896
|
}));
|
|
14846
14897
|
}
|
|
14847
14898
|
async function readPrompt(id, language, signal) {
|
|
14848
|
-
return await reply$
|
|
14899
|
+
return await reply$3(await fetch(address$1(id, language), {
|
|
14849
14900
|
credentials: "same-origin",
|
|
14850
14901
|
signal
|
|
14851
14902
|
}));
|
|
14852
14903
|
}
|
|
14853
14904
|
async function savePrompt(id, language, text, signal) {
|
|
14854
|
-
return await reply$
|
|
14905
|
+
return await reply$3(await fetch(address$1(id, language), {
|
|
14855
14906
|
method: "PUT",
|
|
14856
14907
|
credentials: "same-origin",
|
|
14857
14908
|
headers: { "content-type": "application/json" },
|
|
@@ -14861,7 +14912,7 @@ window.__ModuleLoader__.load({
|
|
|
14861
14912
|
}
|
|
14862
14913
|
/** Replaces the file with the shipped text; the host keeps the old file in the trash. */
|
|
14863
14914
|
async function resetPrompt(id, language, signal) {
|
|
14864
|
-
return await reply$
|
|
14915
|
+
return await reply$3(await fetch(address$1(id, language, "/reset"), {
|
|
14865
14916
|
method: "POST",
|
|
14866
14917
|
credentials: "same-origin",
|
|
14867
14918
|
signal
|
|
@@ -14893,34 +14944,34 @@ window.__ModuleLoader__.load({
|
|
|
14893
14944
|
}
|
|
14894
14945
|
tag$24.textContent = css$24;
|
|
14895
14946
|
var PromptsPage_module_css_default = {
|
|
14896
|
-
"
|
|
14897
|
-
"
|
|
14947
|
+
"error": "rp_DLg_5G_error",
|
|
14948
|
+
"row": "rp_DLg_5G_row",
|
|
14898
14949
|
"editBody": "rp_DLg_5G_editBody",
|
|
14899
|
-
"
|
|
14900
|
-
"
|
|
14901
|
-
"spacer": "rp_DLg_5G_spacer",
|
|
14902
|
-
"viewport": "rp_DLg_5G_viewport",
|
|
14903
|
-
"check": "rp_DLg_5G_check",
|
|
14904
|
-
"group": "rp_DLg_5G_group",
|
|
14950
|
+
"pane": "rp_DLg_5G_pane",
|
|
14951
|
+
"help": "rp_DLg_5G_help",
|
|
14905
14952
|
"ok": "rp_DLg_5G_ok",
|
|
14906
|
-
"
|
|
14907
|
-
"
|
|
14908
|
-
"row": "rp_DLg_5G_row",
|
|
14953
|
+
"editTitle": "rp_DLg_5G_editTitle",
|
|
14954
|
+
"panes": "rp_DLg_5G_panes",
|
|
14909
14955
|
"sign": "rp_DLg_5G_sign",
|
|
14910
|
-
"
|
|
14956
|
+
"viewport": "rp_DLg_5G_viewport",
|
|
14957
|
+
"list": "rp_DLg_5G_list",
|
|
14911
14958
|
"area": "rp_DLg_5G_area",
|
|
14959
|
+
"missing": "rp_DLg_5G_missing",
|
|
14960
|
+
"rowName": "rp_DLg_5G_rowName",
|
|
14961
|
+
"message": "rp_DLg_5G_message",
|
|
14962
|
+
"actions": "rp_DLg_5G_actions",
|
|
14912
14963
|
"shipped": "rp_DLg_5G_shipped",
|
|
14913
|
-
"
|
|
14914
|
-
"
|
|
14915
|
-
"
|
|
14916
|
-
"
|
|
14964
|
+
"page": "rp_DLg_5G_page",
|
|
14965
|
+
"count": "rp_DLg_5G_count",
|
|
14966
|
+
"editHeader": "rp_DLg_5G_editHeader",
|
|
14967
|
+
"check": "rp_DLg_5G_check",
|
|
14917
14968
|
"toolbar": "rp_DLg_5G_toolbar",
|
|
14918
|
-
"
|
|
14919
|
-
"
|
|
14920
|
-
"
|
|
14921
|
-
"
|
|
14922
|
-
"
|
|
14923
|
-
"
|
|
14969
|
+
"group": "rp_DLg_5G_group",
|
|
14970
|
+
"rowLanguage": "rp_DLg_5G_rowLanguage",
|
|
14971
|
+
"spacer": "rp_DLg_5G_spacer",
|
|
14972
|
+
"label": "rp_DLg_5G_label",
|
|
14973
|
+
"line": "rp_DLg_5G_line",
|
|
14974
|
+
"warning": "rp_DLg_5G_warning"
|
|
14924
14975
|
};
|
|
14925
14976
|
// src/client/pages/prompts/PromptEditor.tsx
|
|
14926
14977
|
const messageOf$3 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
@@ -15474,8 +15525,8 @@ window.__ModuleLoader__.load({
|
|
|
15474
15525
|
}
|
|
15475
15526
|
tag$23.textContent = css$23;
|
|
15476
15527
|
var Pager_module_css_default = {
|
|
15477
|
-
"
|
|
15478
|
-
"
|
|
15528
|
+
"pager": "rp_KBAD0W_pager",
|
|
15529
|
+
"position": "rp_KBAD0W_position"
|
|
15479
15530
|
};
|
|
15480
15531
|
// src/client/widgets/pager/Pager.tsx
|
|
15481
15532
|
/** Previous and next buttons around the current position; the owner supplies every label. */
|
|
@@ -15544,11 +15595,11 @@ window.__ModuleLoader__.load({
|
|
|
15544
15595
|
}
|
|
15545
15596
|
tag$21.textContent = css$21;
|
|
15546
15597
|
var DeleteSessionDialog_module_css_default = {
|
|
15598
|
+
"warning": "rp_FifHrW_warning",
|
|
15599
|
+
"question": "rp_FifHrW_question",
|
|
15547
15600
|
"error": "rp_FifHrW_error",
|
|
15548
15601
|
"body": "rp_FifHrW_body",
|
|
15549
|
-
"
|
|
15550
|
-
"choice": "rp_FifHrW_choice",
|
|
15551
|
-
"warning": "rp_FifHrW_warning"
|
|
15602
|
+
"choice": "rp_FifHrW_choice"
|
|
15552
15603
|
};
|
|
15553
15604
|
// src/client/pages/sessions/DeleteSessionDialog.tsx
|
|
15554
15605
|
/** Asks for confirmation before a session and everything saved with it is removed. */
|
|
@@ -15682,7 +15733,7 @@ window.__ModuleLoader__.load({
|
|
|
15682
15733
|
const SYNC_PASSWORD_REF = "ROLEPLAY_SYNC_RCLONE_CONFIG_PASS";
|
|
15683
15734
|
const SYNC_CHANGED = "roleplay-sync-changed";
|
|
15684
15735
|
// src/client/sync-api.ts
|
|
15685
|
-
async function reply$
|
|
15736
|
+
async function reply$2(response) {
|
|
15686
15737
|
if (!response.ok) {
|
|
15687
15738
|
const body = await response.json().catch(() => void 0);
|
|
15688
15739
|
throw new Error(typeof body?.message === "string" ? body.message : `${response.status} ${response.statusText}`.trim());
|
|
@@ -15696,20 +15747,20 @@ window.__ModuleLoader__.load({
|
|
|
15696
15747
|
body: JSON.stringify(body)
|
|
15697
15748
|
});
|
|
15698
15749
|
async function loadSyncStatus(signal) {
|
|
15699
|
-
return await reply$
|
|
15750
|
+
return await reply$2(await fetch(`${API_PREFIX}/sync/status`, {
|
|
15700
15751
|
credentials: "same-origin",
|
|
15701
15752
|
signal
|
|
15702
15753
|
}));
|
|
15703
15754
|
}
|
|
15704
15755
|
/** Syncs every unit, or only the named ones; resolves when the run is over. */
|
|
15705
15756
|
async function runSync(units, signal) {
|
|
15706
|
-
return await reply$
|
|
15757
|
+
return await reply$2(await fetch(`${API_PREFIX}/sync/run`, {
|
|
15707
15758
|
...json("POST", units === void 0 ? {} : { units }),
|
|
15708
15759
|
signal
|
|
15709
15760
|
}));
|
|
15710
15761
|
}
|
|
15711
15762
|
async function resolveSync(unit, side, signal) {
|
|
15712
|
-
return await reply$
|
|
15763
|
+
return await reply$2(await fetch(`${API_PREFIX}/sync/resolve`, {
|
|
15713
15764
|
...json("POST", {
|
|
15714
15765
|
unit,
|
|
15715
15766
|
side
|
|
@@ -15719,27 +15770,27 @@ window.__ModuleLoader__.load({
|
|
|
15719
15770
|
}
|
|
15720
15771
|
/** Stops syncing a unit that was deleted here; the remote's copy stays and is not brought back until `restoreSync`. */
|
|
15721
15772
|
async function forgetSync(unit, signal) {
|
|
15722
|
-
await reply$
|
|
15773
|
+
await reply$2(await fetch(`${API_PREFIX}/sync/forget`, {
|
|
15723
15774
|
...json("POST", { unit }),
|
|
15724
15775
|
signal
|
|
15725
15776
|
}));
|
|
15726
15777
|
}
|
|
15727
15778
|
/** Lets a unit that was forgotten sync again, which brings the remote's copy back on the next run. */
|
|
15728
15779
|
async function restoreSync(unit, signal) {
|
|
15729
|
-
await reply$
|
|
15780
|
+
await reply$2(await fetch(`${API_PREFIX}/sync/restore`, {
|
|
15730
15781
|
...json("POST", { unit }),
|
|
15731
15782
|
signal
|
|
15732
15783
|
}));
|
|
15733
15784
|
}
|
|
15734
15785
|
async function describePassword(reference, signal) {
|
|
15735
|
-
return await reply$
|
|
15786
|
+
return await reply$2(await fetch(`${API_PREFIX}/sync/password?ref=${encodeURIComponent(reference)}`, {
|
|
15736
15787
|
credentials: "same-origin",
|
|
15737
15788
|
signal
|
|
15738
15789
|
}));
|
|
15739
15790
|
}
|
|
15740
15791
|
/** Stores the password of the rclone configuration file, or removes it when the value is empty; the value is never sent back. */
|
|
15741
15792
|
async function storePassword(reference, value, signal) {
|
|
15742
|
-
const status = await reply$
|
|
15793
|
+
const status = await reply$2(await fetch(`${API_PREFIX}/sync/password`, {
|
|
15743
15794
|
...json("PUT", {
|
|
15744
15795
|
ref: reference,
|
|
15745
15796
|
value
|
|
@@ -16072,28 +16123,28 @@ window.__ModuleLoader__.load({
|
|
|
16072
16123
|
}
|
|
16073
16124
|
tag$20.textContent = css$20;
|
|
16074
16125
|
var SessionsPage_module_css_default = {
|
|
16126
|
+
"badge": "rp_24z4eW_badge",
|
|
16075
16127
|
"notice": "rp_24z4eW_notice",
|
|
16076
|
-
"page": "rp_24z4eW_page",
|
|
16077
|
-
"count": "rp_24z4eW_count",
|
|
16078
|
-
"viewport": "rp_24z4eW_viewport",
|
|
16079
|
-
"table": "rp_24z4eW_table",
|
|
16080
16128
|
"nameColumn": "rp_24z4eW_nameColumn",
|
|
16081
|
-
"
|
|
16129
|
+
"turnsColumn": "rp_24z4eW_turnsColumn",
|
|
16130
|
+
"page": "rp_24z4eW_page",
|
|
16131
|
+
"archived": "rp_24z4eW_archived",
|
|
16132
|
+
"spinning": "rp_24z4eW_spinning",
|
|
16133
|
+
"message": "rp_24z4eW_message",
|
|
16134
|
+
"scrolls": "rp_24z4eW_scrolls",
|
|
16082
16135
|
"secondary": "rp_24z4eW_secondary",
|
|
16136
|
+
"number": "rp_24z4eW_number",
|
|
16137
|
+
"toolbar": "rp_24z4eW_toolbar",
|
|
16138
|
+
"fits": "rp_24z4eW_fits",
|
|
16083
16139
|
"name": "rp_24z4eW_name",
|
|
16084
16140
|
"actions": "rp_24z4eW_actions",
|
|
16085
|
-
"message": "rp_24z4eW_message",
|
|
16086
16141
|
"timeColumn": "rp_24z4eW_timeColumn",
|
|
16087
|
-
"
|
|
16088
|
-
"
|
|
16142
|
+
"count": "rp_24z4eW_count",
|
|
16143
|
+
"viewport": "rp_24z4eW_viewport",
|
|
16089
16144
|
"spin": "rp_24z4eW_spin",
|
|
16090
|
-
"
|
|
16145
|
+
"table": "rp_24z4eW_table",
|
|
16091
16146
|
"actionsColumn": "rp_24z4eW_actionsColumn",
|
|
16092
|
-
"
|
|
16093
|
-
"spinning": "rp_24z4eW_spinning",
|
|
16094
|
-
"number": "rp_24z4eW_number",
|
|
16095
|
-
"toolbar": "rp_24z4eW_toolbar",
|
|
16096
|
-
"scrolls": "rp_24z4eW_scrolls"
|
|
16147
|
+
"worldColumn": "rp_24z4eW_worldColumn"
|
|
16097
16148
|
};
|
|
16098
16149
|
// src/client/pages/sessions/SessionsPage.tsx
|
|
16099
16150
|
/** The sessions as a table, one page at a time, the most recently played first. */
|
|
@@ -16514,29 +16565,29 @@ window.__ModuleLoader__.load({
|
|
|
16514
16565
|
}
|
|
16515
16566
|
tag$19.textContent = css$19;
|
|
16516
16567
|
var SyncPage_module_css_default = {
|
|
16517
|
-
"
|
|
16568
|
+
"page": "rp_Gk-byG_page",
|
|
16518
16569
|
"kindColumn": "rp_Gk-byG_kindColumn",
|
|
16519
|
-
"actionsColumn": "rp_Gk-byG_actionsColumn",
|
|
16520
|
-
"failed": "rp_Gk-byG_failed",
|
|
16521
|
-
"unitColumn": "rp_Gk-byG_unitColumn",
|
|
16522
|
-
"conflict": "rp_Gk-byG_conflict",
|
|
16523
16570
|
"choices": "rp_Gk-byG_choices",
|
|
16524
|
-
"
|
|
16525
|
-
"message": "rp_Gk-byG_message",
|
|
16526
|
-
"error": "rp_Gk-byG_error",
|
|
16527
|
-
"syncedColumn": "rp_Gk-byG_syncedColumn",
|
|
16528
|
-
"stateColumn": "rp_Gk-byG_stateColumn",
|
|
16571
|
+
"actionsColumn": "rp_Gk-byG_actionsColumn",
|
|
16529
16572
|
"actions": "rp_Gk-byG_actions",
|
|
16573
|
+
"message": "rp_Gk-byG_message",
|
|
16574
|
+
"confirmation": "rp_Gk-byG_confirmation",
|
|
16575
|
+
"meta": "rp_Gk-byG_meta",
|
|
16530
16576
|
"toolbar": "rp_Gk-byG_toolbar",
|
|
16577
|
+
"problem": "rp_Gk-byG_problem",
|
|
16578
|
+
"stateColumn": "rp_Gk-byG_stateColumn",
|
|
16531
16579
|
"detail": "rp_Gk-byG_detail",
|
|
16532
16580
|
"actionHeading": "rp_Gk-byG_actionHeading",
|
|
16533
|
-
"
|
|
16581
|
+
"unitColumn": "rp_Gk-byG_unitColumn",
|
|
16582
|
+
"viewport": "rp_Gk-byG_viewport",
|
|
16534
16583
|
"detailsColumn": "rp_Gk-byG_detailsColumn",
|
|
16584
|
+
"failed": "rp_Gk-byG_failed",
|
|
16585
|
+
"error": "rp_Gk-byG_error",
|
|
16535
16586
|
"table": "rp_Gk-byG_table",
|
|
16536
|
-
"
|
|
16537
|
-
"
|
|
16587
|
+
"caption": "rp_Gk-byG_caption",
|
|
16588
|
+
"conflict": "rp_Gk-byG_conflict",
|
|
16538
16589
|
"unit": "rp_Gk-byG_unit",
|
|
16539
|
-
"
|
|
16590
|
+
"syncedColumn": "rp_Gk-byG_syncedColumn"
|
|
16540
16591
|
};
|
|
16541
16592
|
// src/client/pages/sync/SyncPage.tsx
|
|
16542
16593
|
const when = (iso, never, locale) => iso === void 0 ? never : new Date(iso).toLocaleString(locale);
|
|
@@ -17049,16 +17100,16 @@ window.__ModuleLoader__.load({
|
|
|
17049
17100
|
}
|
|
17050
17101
|
tag$18.textContent = css$18;
|
|
17051
17102
|
var WorldCard_module_css_default = {
|
|
17052
|
-
"name": "rp_Bvxx5q_name",
|
|
17053
17103
|
"card": "rp_Bvxx5q_card",
|
|
17054
|
-
"
|
|
17104
|
+
"image": "rp_Bvxx5q_image",
|
|
17055
17105
|
"placeholder": "rp_Bvxx5q_placeholder",
|
|
17056
17106
|
"play": "rp_Bvxx5q_play",
|
|
17057
|
-
"
|
|
17058
|
-
"openButton": "rp_Bvxx5q_openButton",
|
|
17107
|
+
"name": "rp_Bvxx5q_name",
|
|
17059
17108
|
"cover": "rp_Bvxx5q_cover",
|
|
17060
17109
|
"tag": "rp_Bvxx5q_tag",
|
|
17061
|
-
"
|
|
17110
|
+
"info": "rp_Bvxx5q_info",
|
|
17111
|
+
"tags": "rp_Bvxx5q_tags",
|
|
17112
|
+
"openButton": "rp_Bvxx5q_openButton"
|
|
17062
17113
|
};
|
|
17063
17114
|
// src/client/widgets/world-card/WorldCard.tsx
|
|
17064
17115
|
/** Stable hue per name, so a world without a cover keeps the same colour. */
|
|
@@ -17155,10 +17206,10 @@ window.__ModuleLoader__.load({
|
|
|
17155
17206
|
}
|
|
17156
17207
|
tag$17.textContent = css$17;
|
|
17157
17208
|
var AvatarChoices_module_css_default = {
|
|
17158
|
-
"
|
|
17159
|
-
"summary": "rp_YCstOG_summary",
|
|
17209
|
+
"option": "rp_YCstOG_option",
|
|
17160
17210
|
"name": "rp_YCstOG_name",
|
|
17161
|
-
"
|
|
17211
|
+
"text": "rp_YCstOG_text",
|
|
17212
|
+
"summary": "rp_YCstOG_summary"
|
|
17162
17213
|
};
|
|
17163
17214
|
// src/client/widgets/avatar-choices/AvatarChoices.tsx
|
|
17164
17215
|
/** A list of avatars to tick: the ones brought into a world or a session. */
|
|
@@ -17196,18 +17247,18 @@ window.__ModuleLoader__.load({
|
|
|
17196
17247
|
}
|
|
17197
17248
|
tag$16.textContent = css$16;
|
|
17198
17249
|
var StartSessionDialog_module_css_default = {
|
|
17199
|
-
"advancedToggle": "rp_AnbLKG_advancedToggle",
|
|
17200
|
-
"form": "rp_AnbLKG_form",
|
|
17201
|
-
"advancedBody": "rp_AnbLKG_advancedBody",
|
|
17202
|
-
"optionName": "rp_AnbLKG_optionName",
|
|
17203
17250
|
"option": "rp_AnbLKG_option",
|
|
17204
|
-
"
|
|
17251
|
+
"optionText": "rp_AnbLKG_optionText",
|
|
17252
|
+
"optionName": "rp_AnbLKG_optionName",
|
|
17205
17253
|
"message": "rp_AnbLKG_message",
|
|
17206
17254
|
"advanced": "rp_AnbLKG_advanced",
|
|
17255
|
+
"advancedToggle": "rp_AnbLKG_advancedToggle",
|
|
17256
|
+
"advancedBody": "rp_AnbLKG_advancedBody",
|
|
17207
17257
|
"label": "rp_AnbLKG_label",
|
|
17208
|
-
"
|
|
17209
|
-
"
|
|
17210
|
-
"
|
|
17258
|
+
"form": "rp_AnbLKG_form",
|
|
17259
|
+
"optionSummary": "rp_AnbLKG_optionSummary",
|
|
17260
|
+
"error": "rp_AnbLKG_error",
|
|
17261
|
+
"field": "rp_AnbLKG_field"
|
|
17211
17262
|
};
|
|
17212
17263
|
// src/client/pages/worlds/AddAvatarsDialog.tsx
|
|
17213
17264
|
/** Asks which avatars become characters of a world's own files. */
|
|
@@ -17302,8 +17353,11 @@ window.__ModuleLoader__.load({
|
|
|
17302
17353
|
"reflection",
|
|
17303
17354
|
"agency",
|
|
17304
17355
|
"refusal",
|
|
17356
|
+
"repeats",
|
|
17305
17357
|
"rules",
|
|
17306
17358
|
"secrets",
|
|
17359
|
+
"messages",
|
|
17360
|
+
"errands",
|
|
17307
17361
|
"variables",
|
|
17308
17362
|
"reuse"
|
|
17309
17363
|
];
|
|
@@ -17323,6 +17377,12 @@ window.__ModuleLoader__.load({
|
|
|
17323
17377
|
];
|
|
17324
17378
|
/** What a gate can be set to: the modes of any site, or off. */
|
|
17325
17379
|
const GATE_MODES = ["off", ...DECISION_MODES];
|
|
17380
|
+
/** What the repeat check can be set to: a gate's modes, or `strict`, which refuses every repeated sentence by code alone, with no model, and so may refuse a repeat that was meant. */
|
|
17381
|
+
const REPEAT_MODES = [
|
|
17382
|
+
"off",
|
|
17383
|
+
"strict",
|
|
17384
|
+
...DECISION_MODES
|
|
17385
|
+
];
|
|
17326
17386
|
// src/shared/rules.ts
|
|
17327
17387
|
/** The longest text of the player's own rules. */
|
|
17328
17388
|
const MAX_OWN_RULES = 2e3;
|
|
@@ -17401,6 +17461,18 @@ window.__ModuleLoader__.load({
|
|
|
17401
17461
|
joint: flag(true),
|
|
17402
17462
|
summary: flag(true)
|
|
17403
17463
|
},
|
|
17464
|
+
schedule: { enabled: flag(true) },
|
|
17465
|
+
autonomy: {
|
|
17466
|
+
enabled: flag(false),
|
|
17467
|
+
messages: flag(true),
|
|
17468
|
+
maxUnanswered: integer(1, 20, 3),
|
|
17469
|
+
idleMinutes: integer(1, 10080, 15),
|
|
17470
|
+
awayHours: integer(1, 720, 12),
|
|
17471
|
+
chance: ratio(0, 1, .05),
|
|
17472
|
+
decay: ratio(0, 1, .5),
|
|
17473
|
+
transitionChance: ratio(0, 1, .4),
|
|
17474
|
+
messageGapMinutes: integer(5, 10080, 180)
|
|
17475
|
+
},
|
|
17404
17476
|
sampling: {
|
|
17405
17477
|
master: ratio(0, 2, .7),
|
|
17406
17478
|
characters: ratio(0, 2, .8),
|
|
@@ -17453,11 +17525,17 @@ window.__ModuleLoader__.load({
|
|
|
17453
17525
|
reflection: choice(DECISION_MODES, "llm"),
|
|
17454
17526
|
agency: choice(GATE_MODES, "off"),
|
|
17455
17527
|
refusal: choice(GATE_MODES, "off"),
|
|
17528
|
+
repeats: choice(REPEAT_MODES, "off"),
|
|
17529
|
+
repeatTurns: integer(1, 30, 6),
|
|
17530
|
+
repeatChars: integer(6, 60, 12),
|
|
17456
17531
|
rules: choice(EXTRA_MODES, "off"),
|
|
17457
17532
|
secrets: choice(EXTRA_MODES, "off"),
|
|
17533
|
+
messages: choice(EXTRA_MODES, "off"),
|
|
17534
|
+
errands: choice(EXTRA_MODES, "on"),
|
|
17458
17535
|
variables: choice(GATE_MODES, "llm"),
|
|
17459
17536
|
reuse: choice(EXTRA_MODES, "off"),
|
|
17460
17537
|
gateThreshold: ratio(.1, .95, .5),
|
|
17538
|
+
reuseThreshold: ratio(.1, .95, .85),
|
|
17461
17539
|
confidence: ratio(0, 1, .7)
|
|
17462
17540
|
},
|
|
17463
17541
|
interface: { pack: text$2(60, "") },
|
|
@@ -17861,6 +17939,50 @@ window.__ModuleLoader__.load({
|
|
|
17861
17939
|
}
|
|
17862
17940
|
]
|
|
17863
17941
|
},
|
|
17942
|
+
{
|
|
17943
|
+
path: ["decisions", "repeats"],
|
|
17944
|
+
kind: "choice",
|
|
17945
|
+
label: "decisionsRepeats",
|
|
17946
|
+
help: "decisionsRepeatsHelp",
|
|
17947
|
+
choices: [
|
|
17948
|
+
{
|
|
17949
|
+
value: "off",
|
|
17950
|
+
label: "decisionOff"
|
|
17951
|
+
},
|
|
17952
|
+
{
|
|
17953
|
+
value: "strict",
|
|
17954
|
+
label: "decisionStrict"
|
|
17955
|
+
},
|
|
17956
|
+
{
|
|
17957
|
+
value: "llm",
|
|
17958
|
+
label: "decisionLlm"
|
|
17959
|
+
},
|
|
17960
|
+
{
|
|
17961
|
+
value: "decision",
|
|
17962
|
+
label: "decisionDecision"
|
|
17963
|
+
},
|
|
17964
|
+
{
|
|
17965
|
+
value: "hybrid",
|
|
17966
|
+
label: "decisionHybrid"
|
|
17967
|
+
},
|
|
17968
|
+
{
|
|
17969
|
+
value: "shadow",
|
|
17970
|
+
label: "decisionShadow"
|
|
17971
|
+
}
|
|
17972
|
+
]
|
|
17973
|
+
},
|
|
17974
|
+
{
|
|
17975
|
+
path: ["decisions", "repeatTurns"],
|
|
17976
|
+
kind: "integer",
|
|
17977
|
+
label: "decisionsRepeatTurns",
|
|
17978
|
+
help: "decisionsRepeatTurnsHelp"
|
|
17979
|
+
},
|
|
17980
|
+
{
|
|
17981
|
+
path: ["decisions", "repeatChars"],
|
|
17982
|
+
kind: "integer",
|
|
17983
|
+
label: "decisionsRepeatChars",
|
|
17984
|
+
help: "decisionsRepeatCharsHelp"
|
|
17985
|
+
},
|
|
17864
17986
|
{
|
|
17865
17987
|
path: ["decisions", "variables"],
|
|
17866
17988
|
kind: "choice",
|
|
@@ -17915,6 +18037,32 @@ window.__ModuleLoader__.load({
|
|
|
17915
18037
|
label: "decisionOn"
|
|
17916
18038
|
}]
|
|
17917
18039
|
},
|
|
18040
|
+
{
|
|
18041
|
+
path: ["decisions", "errands"],
|
|
18042
|
+
kind: "choice",
|
|
18043
|
+
label: "decisionsErrands",
|
|
18044
|
+
help: "decisionsErrandsHelp",
|
|
18045
|
+
choices: [{
|
|
18046
|
+
value: "off",
|
|
18047
|
+
label: "decisionOff"
|
|
18048
|
+
}, {
|
|
18049
|
+
value: "on",
|
|
18050
|
+
label: "decisionOn"
|
|
18051
|
+
}]
|
|
18052
|
+
},
|
|
18053
|
+
{
|
|
18054
|
+
path: ["decisions", "messages"],
|
|
18055
|
+
kind: "choice",
|
|
18056
|
+
label: "decisionsMessages",
|
|
18057
|
+
help: "decisionsMessagesHelp",
|
|
18058
|
+
choices: [{
|
|
18059
|
+
value: "off",
|
|
18060
|
+
label: "decisionOff"
|
|
18061
|
+
}, {
|
|
18062
|
+
value: "on",
|
|
18063
|
+
label: "decisionOn"
|
|
18064
|
+
}]
|
|
18065
|
+
},
|
|
17918
18066
|
{
|
|
17919
18067
|
path: ["decisions", "secrets"],
|
|
17920
18068
|
kind: "choice",
|
|
@@ -17934,6 +18082,12 @@ window.__ModuleLoader__.load({
|
|
|
17934
18082
|
label: "decisionsGateThreshold",
|
|
17935
18083
|
help: "decisionsGateThresholdHelp"
|
|
17936
18084
|
},
|
|
18085
|
+
{
|
|
18086
|
+
path: ["decisions", "reuseThreshold"],
|
|
18087
|
+
kind: "decimal",
|
|
18088
|
+
label: "decisionsReuseThreshold",
|
|
18089
|
+
help: "decisionsReuseThresholdHelp"
|
|
18090
|
+
},
|
|
17937
18091
|
{
|
|
17938
18092
|
path: ["decisions", "confidence"],
|
|
17939
18093
|
kind: "decimal",
|
|
@@ -18221,6 +18375,66 @@ window.__ModuleLoader__.load({
|
|
|
18221
18375
|
label: "offstageSummary",
|
|
18222
18376
|
help: "offstageSummaryHelp"
|
|
18223
18377
|
},
|
|
18378
|
+
{
|
|
18379
|
+
path: ["schedule", "enabled"],
|
|
18380
|
+
kind: "flag",
|
|
18381
|
+
label: "scheduleEnabled",
|
|
18382
|
+
help: "scheduleEnabledHelp"
|
|
18383
|
+
},
|
|
18384
|
+
{
|
|
18385
|
+
path: ["autonomy", "enabled"],
|
|
18386
|
+
kind: "flag",
|
|
18387
|
+
label: "autonomyEnabled",
|
|
18388
|
+
help: "autonomyEnabledHelp"
|
|
18389
|
+
},
|
|
18390
|
+
{
|
|
18391
|
+
path: ["autonomy", "messages"],
|
|
18392
|
+
kind: "flag",
|
|
18393
|
+
label: "autonomyMessages",
|
|
18394
|
+
help: "autonomyMessagesHelp"
|
|
18395
|
+
},
|
|
18396
|
+
{
|
|
18397
|
+
path: ["autonomy", "maxUnanswered"],
|
|
18398
|
+
kind: "integer",
|
|
18399
|
+
label: "autonomyMaxUnanswered",
|
|
18400
|
+
help: "autonomyMaxUnansweredHelp"
|
|
18401
|
+
},
|
|
18402
|
+
{
|
|
18403
|
+
path: ["autonomy", "idleMinutes"],
|
|
18404
|
+
kind: "integer",
|
|
18405
|
+
label: "autonomyIdleMinutes",
|
|
18406
|
+
help: "autonomyIdleMinutesHelp"
|
|
18407
|
+
},
|
|
18408
|
+
{
|
|
18409
|
+
path: ["autonomy", "awayHours"],
|
|
18410
|
+
kind: "integer",
|
|
18411
|
+
label: "autonomyAwayHours",
|
|
18412
|
+
help: "autonomyAwayHoursHelp"
|
|
18413
|
+
},
|
|
18414
|
+
{
|
|
18415
|
+
path: ["autonomy", "chance"],
|
|
18416
|
+
kind: "decimal",
|
|
18417
|
+
label: "autonomyChance",
|
|
18418
|
+
help: "autonomyChanceHelp"
|
|
18419
|
+
},
|
|
18420
|
+
{
|
|
18421
|
+
path: ["autonomy", "decay"],
|
|
18422
|
+
kind: "decimal",
|
|
18423
|
+
label: "autonomyDecay",
|
|
18424
|
+
help: "autonomyDecayHelp"
|
|
18425
|
+
},
|
|
18426
|
+
{
|
|
18427
|
+
path: ["autonomy", "transitionChance"],
|
|
18428
|
+
kind: "decimal",
|
|
18429
|
+
label: "autonomyTransition",
|
|
18430
|
+
help: "autonomyTransitionHelp"
|
|
18431
|
+
},
|
|
18432
|
+
{
|
|
18433
|
+
path: ["autonomy", "messageGapMinutes"],
|
|
18434
|
+
kind: "integer",
|
|
18435
|
+
label: "autonomyMessageGap",
|
|
18436
|
+
help: "autonomyMessageGapHelp"
|
|
18437
|
+
},
|
|
18224
18438
|
{
|
|
18225
18439
|
path: ["context", "limitTokens"],
|
|
18226
18440
|
kind: "integer",
|
|
@@ -18364,7 +18578,7 @@ window.__ModuleLoader__.load({
|
|
|
18364
18578
|
}
|
|
18365
18579
|
return next;
|
|
18366
18580
|
}
|
|
18367
|
-
// ../../node_modules/.pnpm/@dsh-ai-providers+core@0.
|
|
18581
|
+
// ../../node_modules/.pnpm/@dsh-ai-providers+core@0.7.0_@deepseek-ai+cordis@4.0.5_@deepseek-ai+dsh-llm@0.2.2-rc.1_@deepseek-ai+cordis@4.0.5_/node_modules/@dsh-ai-providers/core/lib/index.js
|
|
18368
18582
|
/**
|
|
18369
18583
|
* The browser API of the main plugin, which the UI of the main plugin and of every vendor plugin
|
|
18370
18584
|
* uses. Paths are relative to the prefix, and the browser calls them with relative URLs so that a
|
|
@@ -18424,14 +18638,14 @@ window.__ModuleLoader__.load({
|
|
|
18424
18638
|
}
|
|
18425
18639
|
tag$15.textContent = css$15;
|
|
18426
18640
|
var SettingsFields_module_css_default = {
|
|
18641
|
+
"groupTitle": "rp_Rhi3yq_groupTitle",
|
|
18427
18642
|
"error": "rp_Rhi3yq_error",
|
|
18428
18643
|
"field": "rp_Rhi3yq_field",
|
|
18644
|
+
"row": "rp_Rhi3yq_row",
|
|
18429
18645
|
"label": "rp_Rhi3yq_label",
|
|
18430
|
-
"
|
|
18646
|
+
"area": "rp_Rhi3yq_area",
|
|
18431
18647
|
"help": "rp_Rhi3yq_help",
|
|
18432
|
-
"
|
|
18433
|
-
"group": "rp_Rhi3yq_group",
|
|
18434
|
-
"area": "rp_Rhi3yq_area"
|
|
18648
|
+
"group": "rp_Rhi3yq_group"
|
|
18435
18649
|
};
|
|
18436
18650
|
// src/client/settings-form/SettingsFields.tsx
|
|
18437
18651
|
/** The settings of a chat as editable fields: one control with its explanation under each. */
|
|
@@ -18733,9 +18947,9 @@ window.__ModuleLoader__.load({
|
|
|
18733
18947
|
tag$14.textContent = css$14;
|
|
18734
18948
|
var TranslateBanner_module_css_default = {
|
|
18735
18949
|
"banner": "rp_Lx8vJa_banner",
|
|
18736
|
-
"bannerActions": "rp_Lx8vJa_bannerActions",
|
|
18737
18950
|
"error": "rp_Lx8vJa_error",
|
|
18738
|
-
"text": "rp_Lx8vJa_text"
|
|
18951
|
+
"text": "rp_Lx8vJa_text",
|
|
18952
|
+
"bannerActions": "rp_Lx8vJa_bannerActions"
|
|
18739
18953
|
};
|
|
18740
18954
|
// src/client/pages/worlds/TranslateBanner.tsx
|
|
18741
18955
|
const languageName = (t, language) => language === "zh" ? t("languageChinese") : t("languageEnglish");
|
|
@@ -19357,26 +19571,26 @@ window.__ModuleLoader__.load({
|
|
|
19357
19571
|
}
|
|
19358
19572
|
tag$13.textContent = css$13;
|
|
19359
19573
|
var WorldsPage_module_css_default = {
|
|
19360
|
-
"page": "rp_FHUyRq_page",
|
|
19361
|
-
"spinning": "rp_FHUyRq_spinning",
|
|
19362
19574
|
"grid": "rp_FHUyRq_grid",
|
|
19363
|
-
"
|
|
19575
|
+
"cell": "rp_FHUyRq_cell",
|
|
19576
|
+
"starters": "rp_FHUyRq_starters",
|
|
19364
19577
|
"editTitle": "rp_FHUyRq_editTitle",
|
|
19365
|
-
"scrolls": "rp_FHUyRq_scrolls",
|
|
19366
|
-
"fits": "rp_FHUyRq_fits",
|
|
19367
|
-
"editActions": "rp_FHUyRq_editActions",
|
|
19368
|
-
"toolbarActions": "rp_FHUyRq_toolbarActions",
|
|
19369
|
-
"editBody": "rp_FHUyRq_editBody",
|
|
19370
19578
|
"starter": "rp_FHUyRq_starter",
|
|
19579
|
+
"editBody": "rp_FHUyRq_editBody",
|
|
19371
19580
|
"toolbar": "rp_FHUyRq_toolbar",
|
|
19372
|
-
"
|
|
19373
|
-
"
|
|
19581
|
+
"notice": "rp_FHUyRq_notice",
|
|
19582
|
+
"viewport": "rp_FHUyRq_viewport",
|
|
19583
|
+
"page": "rp_FHUyRq_page",
|
|
19584
|
+
"editActions": "rp_FHUyRq_editActions",
|
|
19585
|
+
"editHeader": "rp_FHUyRq_editHeader",
|
|
19586
|
+
"scrolls": "rp_FHUyRq_scrolls",
|
|
19587
|
+
"spinning": "rp_FHUyRq_spinning",
|
|
19374
19588
|
"message": "rp_FHUyRq_message",
|
|
19589
|
+
"fits": "rp_FHUyRq_fits",
|
|
19590
|
+
"spin": "rp_FHUyRq_spin",
|
|
19375
19591
|
"count": "rp_FHUyRq_count",
|
|
19376
|
-
"
|
|
19377
|
-
"
|
|
19378
|
-
"viewport": "rp_FHUyRq_viewport",
|
|
19379
|
-
"notice": "rp_FHUyRq_notice"
|
|
19592
|
+
"info": "rp_FHUyRq_info",
|
|
19593
|
+
"toolbarActions": "rp_FHUyRq_toolbarActions"
|
|
19380
19594
|
};
|
|
19381
19595
|
// src/client/pages/worlds/StarterWorlds.tsx
|
|
19382
19596
|
/** The worlds that ship with the plugin and are not yet the person's, offered where the list of worlds is empty. */
|
|
@@ -20556,10 +20770,19 @@ window.__ModuleLoader__.load({
|
|
|
20556
20770
|
decisionsReuseHelp: "Before a scene picture is made on its own after a turn, the decision model is asked about the description of each close stored picture (those you brought and those marked reusable): does it show this moment? If one does, it is shown again and nothing is made. Without a decision model nothing changes. Off by default.",
|
|
20557
20771
|
decisionsRefusal: "Checking the output for stepping out of the story",
|
|
20558
20772
|
decisionsRefusalHelp: "Checks each output for a refusal to continue, an apology, a content warning, a disclaimer or a remark to you outside the story, which some hosted models add, and sends it back to the game master to write as the story (at most twice, then it is delivered as it is). Off by default. The same choices as for the check above.",
|
|
20773
|
+
decisionsRepeats: "Checking the narration for repeated sentences",
|
|
20774
|
+
decisionsRepeatsHelp: "Looks for a sentence the narration already told in one of the last turns, and sends it back to the game master to say differently (at most twice, then it is delivered as it is). Only sentences found by comparing words are asked about: the decision model or the language model says whether the repeat is meant (a refrain, a catchphrase, a ritual) or stale filler. \"Strict\" needs no model at all and sends back every repeat, so it is the cheapest, and it may refuse a repeat that was meant: use it only for a world with nothing that should repeat. Off by default.",
|
|
20775
|
+
decisionsRepeatTurns: "Turns compared for repeats",
|
|
20776
|
+
decisionsRepeatTurnsHelp: "How many of the turns before this one a sentence is compared against, from 1 to 30.",
|
|
20777
|
+
decisionsRepeatChars: "Shortest sentence that counts as a repeat",
|
|
20778
|
+
decisionsRepeatCharsHelp: "In characters, from 6 to 60. Shorter sentences (a name, \"Yes.\") may come back.",
|
|
20779
|
+
decisionStrict: "Strict: every repeat, no model",
|
|
20559
20780
|
decisionsRules: "Checking actions against the rules",
|
|
20560
20781
|
decisionsRulesHelp: "When the game master judges your action allowed, a decision model also checks it against every rule of the world and your own rules in one fast pass. A rule it thinks is broken is put to the game master once, to judge again. Only a decision model does this: off by default, and off the story plays as it always did. Needs a decision service; without one nothing is checked.",
|
|
20561
20782
|
decisionsSecrets: "Checking the output for giving away secrets",
|
|
20562
20783
|
decisionsSecretsHelp: "A decision model checks each output for stating hidden lore that your character does not know (lore listed for other characters only) and sends it back to the game master to rewrite (at most twice, then it is delivered as it is). A revelation the story means to make can still go through the second time. Off by default, and off nothing changes. Needs a decision service; without one nothing is checked.",
|
|
20784
|
+
decisionsReuseThreshold: "Probability that counts as a fitting picture",
|
|
20785
|
+
decisionsReuseThresholdHelp: "For picture reuse: the probability from which the decision model's answer that a stored picture shows the moment counts as a yes, from 0.1 to 0.95. Measured with a 9B decision model, 0.5 showed a wrong picture in 6 of 72 asks, 0.8 to 0.9 none; 0.93 and above finds too few. Raise it if a wrong picture is shown, lower it if no picture is ever reused.",
|
|
20563
20786
|
decisionsGateThreshold: "Probability that counts as a fault",
|
|
20564
20787
|
decisionsGateThresholdHelp: "For the two checks above: the probability from which the decision model's answer counts as a fault, from 0.1 to 0.95; a little below it (0.15) the model is not sure, and the language model is asked in the mixed mode. Decision models give a rare fault a low probability even when they see it, so this is not the confidence below. Lower it if faults are missed, raise it if clean passages are sent back; the comparing mode shows the probabilities of the disagreements.",
|
|
20565
20788
|
decisionOff: "Off",
|
|
@@ -20621,6 +20844,30 @@ window.__ModuleLoader__.load({
|
|
|
20621
20844
|
interfacePackHelp: "The interface pack this story uses. Empty uses the first pack the story carries; \"none\" turns packs off and shows the plain chat; a name picks that pack of the story, or of your roleplay folder's ui folder.",
|
|
20622
20845
|
diagnosticsKeepRuns: "Keep what the helpers were told",
|
|
20623
20846
|
diagnosticsKeepRunsHelp: "Each helper run (a character, the record keeper, the suggestions) keeps its instructions, what it was asked, its tool calls and its result, for the latest 60 runs. Open a run in the activity list to see why it said or wrote what it did. The texts include what the characters know in private, so leave it off unless you are looking for a problem.",
|
|
20847
|
+
scheduleEnabled: "Characters keep to their days",
|
|
20848
|
+
scheduleEnabledHelp: "On by default. The characters who have a daily routine are where it puts them and sleep when it says so, and what you do can take them off it for a while (they pick it up again at the next change in their day). Off, nobody keeps a routine or sleeps, and nothing moves by itself: for a story whose characters have no days to keep.",
|
|
20849
|
+
autonomyEnabled: "The story goes on while I am away",
|
|
20850
|
+
autonomyEnabledHelp: "Off by default. On, and with the real clock, the characters keep to their days while you are not in the chat (they are where their routines have them, and the story knows it when you come back) and may write to you. It costs model requests while nobody is reading, and stops by itself after the limit below until you write.",
|
|
20851
|
+
autonomyMessages: "Characters may write to me",
|
|
20852
|
+
autonomyMessagesHelp: "While you are away, a character who is awake and who knows you may write a short message, shown beside the story and told to the story at your next message. Needs the setting above.",
|
|
20853
|
+
autonomyMaxUnanswered: "Most things in a row without a reply from me",
|
|
20854
|
+
autonomyMaxUnansweredHelp: "After this many things the characters did on their own with no message from you in between, nothing more runs until you write: a story left alone does not keep asking the model.",
|
|
20855
|
+
autonomyAwayHours: "Hours away after which nothing more happens",
|
|
20856
|
+
autonomyAwayHoursHelp: "A player who has been gone this long is not written to any more, until they come back and write.",
|
|
20857
|
+
autonomyChance: "Chance of a message at each look",
|
|
20858
|
+
autonomyChanceHelp: "Once the idle time has passed, at each look (every 30 seconds by default) this is the chance that someone writes. Each message already sent with no reply multiplies it by the easing-off below, so a story left alone gets a couple of messages and then goes quiet. A decision model, when one is on below, also says whether the character has a reason to write; without one chance alone decides.",
|
|
20859
|
+
autonomyDecay: "Easing off for each unanswered message",
|
|
20860
|
+
autonomyDecayHelp: "From 0 (one message and then quiet) to 1 (no easing off): what each message sent with no reply multiplies the chance by.",
|
|
20861
|
+
autonomyTransition: "Chance when a character's day changes",
|
|
20862
|
+
autonomyTransitionHelp: "The chance that a character whose day has just changed (work is over, it woke up) writes at that look, on top of the chance above.",
|
|
20863
|
+
decisionsErrands: "Keeping characters who wait for you",
|
|
20864
|
+
decisionsErrandsHelp: "After each turn a decision model says which characters were told, or chose, to stay, wait or watch until you come back to them, or to go on an errand that ends with you. They then stay where the story left them, whatever their routine says, until you are with them again or a day has passed. On by default. Needs a decision service; without one, or when it fails, only what the game master marks keeps a character waiting.",
|
|
20865
|
+
decisionsMessages: "Checking that a character has a reason to write",
|
|
20866
|
+
decisionsMessagesHelp: "When chance has picked a character to write to you while you are away, a decision model first says whether that character has a reason to write now, from what it is doing and what just changed. Off by default. Needs a decision service; without one, or when it fails, chance alone decides.",
|
|
20867
|
+
autonomyIdleMinutes: "Minutes away before characters act",
|
|
20868
|
+
autonomyIdleMinutesHelp: "The characters act on their own only after you have been away this long.",
|
|
20869
|
+
autonomyMessageGap: "Minutes between messages from one character",
|
|
20870
|
+
autonomyMessageGapHelp: "The least time between two messages from the same character.",
|
|
20624
20871
|
offstageJoint: "Meetings happen between people",
|
|
20625
20872
|
offstageJointHelp: "The people of one off-stage commitment decide one after another, each told who has already meant to come, so they meet instead of each guessing. It takes longer in the background but asks the same number of times. Off: each decides alone, all at once.",
|
|
20626
20873
|
offstageSummary: "Tell me what happened meanwhile",
|
|
@@ -20773,10 +21020,19 @@ window.__ModuleLoader__.load({
|
|
|
20773
21020
|
decisionsReuseHelp: "回合结束后自动生成场景图之前,先让决策模型逐个判断相近的已存图片(你上传的和标记为可复用的)的描述:它是否表现了这一刻?如果有,就再次展示它,不再生成。没有决策模型时不起作用。默认关闭。",
|
|
20774
21021
|
decisionsRefusal: "检查输出是否跳出了故事",
|
|
20775
21022
|
decisionsRefusalHelp: "检查每次输出里有没有拒绝继续、道歉、内容警告、免责声明或对你说的故事之外的话(有些托管模型会加上这些),如有则退回给游戏主持人按故事重写(最多两次,之后原样交付)。默认关闭。选项与上一项相同。",
|
|
21023
|
+
decisionsRepeats: "检查旁白里的重复句子",
|
|
21024
|
+
decisionsRepeatsHelp: "查找旁白在最近几个回合里已经讲过的句子,退回给游戏主持人换一种说法(最多两次,之后原样交付)。只有通过比对文字找到的句子才会被判断:由决策模型或语言模型说明这次重复是有意的(叠句、口头禅、仪式)还是陈词滥调。“严格”完全不用模型,把每个重复都退回,所以最省,但可能退回有意的重复:只在没有任何东西该重复的世界里使用。默认关闭。",
|
|
21025
|
+
decisionsRepeatTurns: "比对重复的回合数",
|
|
21026
|
+
decisionsRepeatTurnsHelp: "一个句子与本回合之前多少个回合比对,取值 1 到 30。",
|
|
21027
|
+
decisionsRepeatChars: "算作重复的最短句子",
|
|
21028
|
+
decisionsRepeatCharsHelp: "以字符数计,取值 6 到 60。更短的句子(一个名字、“好。”)可以再次出现。",
|
|
21029
|
+
decisionStrict: "严格:每个重复都退回,不用模型",
|
|
20776
21030
|
decisionsRules: "按规则检查行动",
|
|
20777
21031
|
decisionsRulesHelp: "当游戏主持人判定你的行动可行时,决策模型会再一次快速地把它与世界的每条规则以及你自己的规则逐条对照。它认为被违反的规则会交给游戏主持人重新判断一次。只有决策模型能做这件事:默认关闭,关闭时故事与以往完全一样。需要决策服务;没有时不做任何检查。",
|
|
20778
21032
|
decisionsSecrets: "检查输出是否泄露秘密",
|
|
20779
21033
|
decisionsSecretsHelp: "决策模型检查每次输出有没有写出你的角色不知道的隐藏背景(只列给其他角色的背景),如有则退回给游戏主持人重写(最多两次,之后原样交付)。故事有意安排的揭示,第二次仍可通过。默认关闭,关闭时没有任何变化。需要决策服务;没有时不做任何检查。",
|
|
21034
|
+
decisionsReuseThreshold: "算作合适图片的概率",
|
|
21035
|
+
decisionsReuseThresholdHelp: "针对图片复用:决策模型认为已存图片符合当前时刻的答案达到多大概率才算“是”,取值 0.1 到 0.95。用 9B 决策模型实测:0.5 时 72 次询问中有 6 次选错图片,0.8 到 0.9 没有;0.93 及以上找到的太少。选错了图片就调高,从不复用就调低。",
|
|
20780
21036
|
decisionsGateThreshold: "算作问题的概率",
|
|
20781
21037
|
decisionsGateThresholdHelp: "针对上面两项检查:决策模型的答案达到多大概率才算有问题,取值 0.1 到 0.95;略低于它(低 0.15 以内)时模型没有把握,混合模式下会交给语言模型。决策模型即使看出了罕见的问题,给出的概率也偏低,所以这不是下面的“所需把握”。漏掉问题就调低,把正常的文字退回去就调高;对比模式会显示分歧的概率。",
|
|
20782
21038
|
decisionOff: "关闭",
|
|
@@ -20838,6 +21094,30 @@ window.__ModuleLoader__.load({
|
|
|
20838
21094
|
interfacePackHelp: "此故事使用的界面包。留空则使用故事自带的第一个包;填 \"none\" 则关闭界面包并显示普通聊天;填名称则选用故事中的该包,或角色扮演目录 ui 文件夹中的该包。",
|
|
20839
21095
|
diagnosticsKeepRuns: "保留助手收到的内容",
|
|
20840
21096
|
diagnosticsKeepRunsHelp: "每次助手运行(角色、记录员、建议)都会保存它的指令、被问的内容、工具调用和结果,保留最近 60 次。在活动列表中打开一次运行,可查看它为何那样说或写。内容包含角色私下所知的信息,因此除非要排查问题,请保持关闭。",
|
|
21097
|
+
scheduleEnabled: "角色按各自的日程生活",
|
|
21098
|
+
scheduleEnabledHelp: "默认开启。有日常作息的角色会在作息安排的地方,并在作息规定时睡觉;你的行动可以让他们暂时偏离作息(到他们一天中的下一个变化时再回到作息)。关闭后,没有人遵循作息或睡觉,也不会有任何东西自行移动:适合角色没有日程的故事。",
|
|
21099
|
+
autonomyEnabled: "我不在时故事继续",
|
|
21100
|
+
autonomyEnabledHelp: "默认关闭。开启并使用真实时钟时,你不在聊天里,角色们仍按各自的日程行事(他们在日程所在的地方,你回来时故事知道这一点),也可能给你发消息。你不在时会消耗模型请求,达到下面的上限后自动停止,直到你再发言。",
|
|
21101
|
+
autonomyMessages: "角色可以给我发消息",
|
|
21102
|
+
autonomyMessagesHelp: "你不在时,醒着且认识你的角色可能发一条简短的消息,显示在故事旁,并在你的下一条消息时告知故事。需要上面的设置。",
|
|
21103
|
+
autonomyMaxUnanswered: "没有我回复时连续最多做几件事",
|
|
21104
|
+
autonomyMaxUnansweredHelp: "角色自行做了这么多件事而你没有任何消息之后,不再运行任何东西,直到你发言:无人理会的故事不会一直请求模型。",
|
|
21105
|
+
autonomyAwayHours: "离开多少小时后不再发生任何事",
|
|
21106
|
+
autonomyAwayHoursHelp: "玩家离开这么久之后,不再给他们写消息,直到他们回来并发言。",
|
|
21107
|
+
autonomyChance: "每次查看时发消息的概率",
|
|
21108
|
+
autonomyChanceHelp: "空闲时间过去之后,每次查看(默认每 30 秒一次)有这么大的概率有人写消息。每条已发出而没有回复的消息,会让它乘以下面的递减系数,所以无人理会的故事会有几条消息然后安静下来。若下面开启了决策模型,它还会判断该角色此刻是否有理由写消息;没有决策模型时只由概率决定。",
|
|
21109
|
+
autonomyDecay: "每条未回复消息的递减系数",
|
|
21110
|
+
autonomyDecayHelp: "从 0(一条消息之后就安静)到 1(不递减):每条已发出而没有回复的消息使概率乘以它。",
|
|
21111
|
+
autonomyTransition: "角色日程转换时的概率",
|
|
21112
|
+
autonomyTransitionHelp: "刚刚换了日程的角色(下班了、醒来了)在那次查看时写消息的概率,与上面的概率叠加。",
|
|
21113
|
+
decisionsErrands: "让等你的角色留在原地",
|
|
21114
|
+
decisionsErrandsHelp: "每回合结束后,决策模型会判断哪些角色被吩咐或自己决定留下、等候或守望,直到你回到他们身边,或去办一件以回到你身边为结束的差事。之后无论日程怎么说,他们都留在故事让他们停留的地方,直到你再次与他们在一起,或过了一天。默认开启。需要决策服务;没有时或失败时,只有游戏主持人标记过的角色才会继续等候。",
|
|
21115
|
+
decisionsMessages: "检查角色是否有理由写消息",
|
|
21116
|
+
decisionsMessagesHelp: "当概率选中某个角色在你不在时给你写消息,决策模型会先根据它正在做的事和刚刚发生的变化,判断它此刻是否有理由写。默认关闭。需要决策服务;没有时或失败时只由概率决定。",
|
|
21117
|
+
autonomyIdleMinutes: "离开多少分钟后角色才行动",
|
|
21118
|
+
autonomyIdleMinutesHelp: "只有你离开这么久之后,角色才会自行行动。",
|
|
21119
|
+
autonomyMessageGap: "同一角色两条消息之间的最短分钟数",
|
|
21120
|
+
autonomyMessageGapHelp: "同一角色两条消息之间的最短间隔。",
|
|
20841
21121
|
offstageJoint: "约定在人与人之间发生",
|
|
20842
21122
|
offstageJointHelp: "同一个台下约定的人依次决定,后者会被告知谁已决定前来,因此他们会碰面而不是各自猜测。后台耗时更长,但请求次数不变。关闭则各自同时独立决定。",
|
|
20843
21123
|
offstageSummary: "告诉我期间发生了什么",
|
|
@@ -21553,8 +21833,8 @@ window.__ModuleLoader__.load({
|
|
|
21553
21833
|
}
|
|
21554
21834
|
tag$12.textContent = css$12;
|
|
21555
21835
|
var BranchDialog_module_css_default = {
|
|
21556
|
-
"field": "rp_Dy1TaW_field",
|
|
21557
21836
|
"form": "rp_Dy1TaW_form",
|
|
21837
|
+
"field": "rp_Dy1TaW_field",
|
|
21558
21838
|
"error": "rp_Dy1TaW_error",
|
|
21559
21839
|
"label": "rp_Dy1TaW_label"
|
|
21560
21840
|
};
|
|
@@ -21674,12 +21954,12 @@ window.__ModuleLoader__.load({
|
|
|
21674
21954
|
}
|
|
21675
21955
|
tag$11.textContent = css$11;
|
|
21676
21956
|
var SidebarGuideEntry_module_css_default = {
|
|
21677
|
-
"entry": "rp_Okaj1q_entry",
|
|
21678
21957
|
"main": "rp_Okaj1q_main",
|
|
21679
21958
|
"icon": "rp_Okaj1q_icon",
|
|
21959
|
+
"entry": "rp_Okaj1q_entry",
|
|
21680
21960
|
"text": "rp_Okaj1q_text",
|
|
21681
|
-
"
|
|
21682
|
-
"
|
|
21961
|
+
"description": "rp_Okaj1q_description",
|
|
21962
|
+
"title": "rp_Okaj1q_title"
|
|
21683
21963
|
};
|
|
21684
21964
|
// src/client/widgets/sidebar-guide/SidebarGuideEntry.tsx
|
|
21685
21965
|
/** A card of the right sidebar's new-tab guide, drawn like DSH's own entries. */
|
|
@@ -21726,9 +22006,9 @@ window.__ModuleLoader__.load({
|
|
|
21726
22006
|
}
|
|
21727
22007
|
tag$10.textContent = css$10;
|
|
21728
22008
|
var GalleryTab_module_css_default = {
|
|
21729
|
-
"page": "rp_W688Pa_page",
|
|
21730
22009
|
"bar": "rp_W688Pa_bar",
|
|
21731
|
-
"message": "rp_W688Pa_message"
|
|
22010
|
+
"message": "rp_W688Pa_message",
|
|
22011
|
+
"page": "rp_W688Pa_page"
|
|
21732
22012
|
};
|
|
21733
22013
|
// src/client/gallery/GalleryTab.tsx
|
|
21734
22014
|
/** The kind of the tab type, and the identity it registers its card and body under. */
|
|
@@ -22117,17 +22397,17 @@ window.__ModuleLoader__.load({
|
|
|
22117
22397
|
}
|
|
22118
22398
|
tag$9.textContent = css$9;
|
|
22119
22399
|
var SidebarPage_module_css_default = {
|
|
22120
|
-
"main": "rp_Ptco8a_main",
|
|
22121
|
-
"icon": "rp_Ptco8a_icon",
|
|
22122
|
-
"text": "rp_Ptco8a_text",
|
|
22123
|
-
"description": "rp_Ptco8a_description",
|
|
22124
|
-
"page": "rp_Ptco8a_page",
|
|
22125
|
-
"content": "rp_Ptco8a_content",
|
|
22126
22400
|
"bar": "rp_Ptco8a_bar",
|
|
22401
|
+
"icon": "rp_Ptco8a_icon",
|
|
22127
22402
|
"message": "rp_Ptco8a_message",
|
|
22128
|
-
"
|
|
22403
|
+
"main": "rp_Ptco8a_main",
|
|
22129
22404
|
"name": "rp_Ptco8a_name",
|
|
22130
|
-
"entry": "rp_Ptco8a_entry"
|
|
22405
|
+
"entry": "rp_Ptco8a_entry",
|
|
22406
|
+
"text": "rp_Ptco8a_text",
|
|
22407
|
+
"title": "rp_Ptco8a_title",
|
|
22408
|
+
"page": "rp_Ptco8a_page",
|
|
22409
|
+
"description": "rp_Ptco8a_description",
|
|
22410
|
+
"content": "rp_Ptco8a_content"
|
|
22131
22411
|
};
|
|
22132
22412
|
// src/client/interface/SidebarPage.tsx
|
|
22133
22413
|
/** The kind of the tab type, and the identity it registers its card and body under. */
|
|
@@ -22467,24 +22747,24 @@ window.__ModuleLoader__.load({
|
|
|
22467
22747
|
}
|
|
22468
22748
|
tag$8.textContent = css$8;
|
|
22469
22749
|
var RecallTab_module_css_default = {
|
|
22750
|
+
"item": "rp_jl9CIq_item",
|
|
22751
|
+
"body": "rp_jl9CIq_body",
|
|
22752
|
+
"name": "rp_jl9CIq_name",
|
|
22753
|
+
"meta": "rp_jl9CIq_meta",
|
|
22470
22754
|
"person": "rp_jl9CIq_person",
|
|
22471
|
-
"form": "rp_jl9CIq_form",
|
|
22472
|
-
"error": "rp_jl9CIq_error",
|
|
22473
22755
|
"field": "rp_jl9CIq_field",
|
|
22474
22756
|
"area": "rp_jl9CIq_area",
|
|
22475
|
-
"
|
|
22476
|
-
"
|
|
22477
|
-
"name": "rp_jl9CIq_name",
|
|
22478
|
-
"actions": "rp_jl9CIq_actions",
|
|
22757
|
+
"error": "rp_jl9CIq_error",
|
|
22758
|
+
"label": "rp_jl9CIq_label",
|
|
22479
22759
|
"bar": "rp_jl9CIq_bar",
|
|
22480
|
-
"hint": "rp_jl9CIq_hint",
|
|
22481
22760
|
"note": "rp_jl9CIq_note",
|
|
22482
|
-
"
|
|
22761
|
+
"actions": "rp_jl9CIq_actions",
|
|
22483
22762
|
"place": "rp_jl9CIq_place",
|
|
22484
|
-
"
|
|
22763
|
+
"list": "rp_jl9CIq_list",
|
|
22485
22764
|
"heading": "rp_jl9CIq_heading",
|
|
22486
|
-
"
|
|
22487
|
-
"
|
|
22765
|
+
"form": "rp_jl9CIq_form",
|
|
22766
|
+
"page": "rp_jl9CIq_page",
|
|
22767
|
+
"hint": "rp_jl9CIq_hint"
|
|
22488
22768
|
};
|
|
22489
22769
|
// src/client/recall/RecallTab.tsx
|
|
22490
22770
|
/** The kind of the tab type, and the identity it registers its card and body under. */
|
|
@@ -22737,6 +23017,11 @@ window.__ModuleLoader__.load({
|
|
|
22737
23017
|
notRoleplay: "This chat is not a roleplay session, so it has no reference.",
|
|
22738
23018
|
loading: "Loading…",
|
|
22739
23019
|
failed: "Could not load this page: {message}",
|
|
23020
|
+
status: "Status",
|
|
23021
|
+
noStatus: "Nothing is tracked yet.",
|
|
23022
|
+
statusWorld: "The world",
|
|
23023
|
+
statusYou: "you",
|
|
23024
|
+
statusHint: "Every tracked value you can read: the world's, yours, this place's, and those of the people and things you know of.",
|
|
22740
23025
|
profile: "Profile",
|
|
22741
23026
|
noProfile: "There is no character of yours in this story yet.",
|
|
22742
23027
|
aliases: "Also called {list}",
|
|
@@ -22807,6 +23092,11 @@ window.__ModuleLoader__.load({
|
|
|
22807
23092
|
notRoleplay: "此对话不是角色扮演存档,没有资料。",
|
|
22808
23093
|
loading: "正在加载…",
|
|
22809
23094
|
failed: "无法加载此页:{message}",
|
|
23095
|
+
status: "状态",
|
|
23096
|
+
noStatus: "暂时没有被追踪的数值。",
|
|
23097
|
+
statusWorld: "世界",
|
|
23098
|
+
statusYou: "你",
|
|
23099
|
+
statusHint: "你能看到的所有被追踪的数值:世界的、你自己的、此地的,以及你认识的人和物品的。",
|
|
22810
23100
|
profile: "档案",
|
|
22811
23101
|
noProfile: "这个故事里还没有你的角色。",
|
|
22812
23102
|
aliases: "又称{list}",
|
|
@@ -22880,11 +23170,11 @@ window.__ModuleLoader__.load({
|
|
|
22880
23170
|
}
|
|
22881
23171
|
tag$7.textContent = css$7;
|
|
22882
23172
|
var ReferenceTab_module_css_default = {
|
|
22883
|
-
"
|
|
23173
|
+
"bar": "rp_7BGO2a_bar",
|
|
22884
23174
|
"page": "rp_7BGO2a_page",
|
|
22885
23175
|
"body": "rp_7BGO2a_body",
|
|
22886
|
-
"
|
|
22887
|
-
"
|
|
23176
|
+
"message": "rp_7BGO2a_message",
|
|
23177
|
+
"nav": "rp_7BGO2a_nav"
|
|
22888
23178
|
};
|
|
22889
23179
|
// src/client/reference/ReferenceTab.tsx
|
|
22890
23180
|
/** The kind of the tab type, and the identity it registers its card and body under. */
|
|
@@ -23004,28 +23294,28 @@ window.__ModuleLoader__.load({
|
|
|
23004
23294
|
}
|
|
23005
23295
|
tag$6.textContent = css$6;
|
|
23006
23296
|
var Page_module_css_default = {
|
|
23297
|
+
"placeName": "rp_bG1sCa_placeName",
|
|
23298
|
+
"title": "rp_bG1sCa_title",
|
|
23007
23299
|
"entry": "rp_bG1sCa_entry",
|
|
23008
|
-
"list": "rp_bG1sCa_list",
|
|
23009
|
-
"text": "rp_bG1sCa_text",
|
|
23010
|
-
"meta": "rp_bG1sCa_meta",
|
|
23011
|
-
"heading": "rp_bG1sCa_heading",
|
|
23012
|
-
"notes": "rp_bG1sCa_notes",
|
|
23013
|
-
"way": "rp_bG1sCa_way",
|
|
23014
|
-
"sub": "rp_bG1sCa_sub",
|
|
23015
|
-
"link": "rp_bG1sCa_link",
|
|
23016
|
-
"opened": "rp_bG1sCa_opened",
|
|
23017
|
-
"tag": "rp_bG1sCa_tag",
|
|
23018
23300
|
"place": "rp_bG1sCa_place",
|
|
23019
|
-
"
|
|
23301
|
+
"meta": "rp_bG1sCa_meta",
|
|
23302
|
+
"text": "rp_bG1sCa_text",
|
|
23020
23303
|
"head": "rp_bG1sCa_head",
|
|
23021
23304
|
"message": "rp_bG1sCa_message",
|
|
23305
|
+
"map": "rp_bG1sCa_map",
|
|
23022
23306
|
"name": "rp_bG1sCa_name",
|
|
23023
|
-
"title": "rp_bG1sCa_title",
|
|
23024
23307
|
"block": "rp_bG1sCa_block",
|
|
23308
|
+
"list": "rp_bG1sCa_list",
|
|
23309
|
+
"way": "rp_bG1sCa_way",
|
|
23310
|
+
"journal": "rp_bG1sCa_journal",
|
|
23311
|
+
"link": "rp_bG1sCa_link",
|
|
23312
|
+
"sub": "rp_bG1sCa_sub",
|
|
23313
|
+
"notes": "rp_bG1sCa_notes",
|
|
23025
23314
|
"closedWay": "rp_bG1sCa_closedWay",
|
|
23026
23315
|
"here": "rp_bG1sCa_here",
|
|
23027
|
-
"
|
|
23028
|
-
"
|
|
23316
|
+
"heading": "rp_bG1sCa_heading",
|
|
23317
|
+
"tag": "rp_bG1sCa_tag",
|
|
23318
|
+
"opened": "rp_bG1sCa_opened"
|
|
23029
23319
|
};
|
|
23030
23320
|
// src/client/reference/sections/Journal.tsx
|
|
23031
23321
|
/** How long typing pauses before the notes are saved. */
|
|
@@ -23447,6 +23737,43 @@ window.__ModuleLoader__.load({
|
|
|
23447
23737
|
}
|
|
23448
23738
|
// src/client/reference/sections/sections.tsx
|
|
23449
23739
|
const unit = (count) => count === 1 ? "" : ` ×${count}`;
|
|
23740
|
+
/** Every tracked value the player may read, one block for each subject that has any. */
|
|
23741
|
+
function StatusPage({ t, sessionId, visible }) {
|
|
23742
|
+
const { reading } = useReference(sessionId, "status", visible);
|
|
23743
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Page, {
|
|
23744
|
+
reading,
|
|
23745
|
+
className: Page_module_css_default.message ?? "",
|
|
23746
|
+
loading: t("loading"),
|
|
23747
|
+
failed: (message) => t("failed", { message }),
|
|
23748
|
+
empty: t("noStatus"),
|
|
23749
|
+
children: (groups) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
23750
|
+
className: Page_module_css_default.meta,
|
|
23751
|
+
children: t("statusHint")
|
|
23752
|
+
}), groups.map((group) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(Block, {
|
|
23753
|
+
title: group.name ?? t("statusWorld"),
|
|
23754
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
23755
|
+
className: Page_module_css_default.head,
|
|
23756
|
+
children: [group.subject === "player" && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
23757
|
+
className: Page_module_css_default.tag,
|
|
23758
|
+
children: t("statusYou")
|
|
23759
|
+
}), group.subject !== "player" && group.here === true && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
23760
|
+
className: Page_module_css_default.tag,
|
|
23761
|
+
children: t("here")
|
|
23762
|
+
})]
|
|
23763
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
|
|
23764
|
+
className: Page_module_css_default.list,
|
|
23765
|
+
children: group.values.map((value) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("li", {
|
|
23766
|
+
className: Page_module_css_default.text,
|
|
23767
|
+
children: [
|
|
23768
|
+
value.name,
|
|
23769
|
+
": ",
|
|
23770
|
+
value.value
|
|
23771
|
+
]
|
|
23772
|
+
}, value.name))
|
|
23773
|
+
})]
|
|
23774
|
+
}, `${group.subject}-${group.key ?? ""}-${group.here === true ? "here" : ""}`))] })
|
|
23775
|
+
});
|
|
23776
|
+
}
|
|
23450
23777
|
function PeoplePage({ t, sessionId, visible }) {
|
|
23451
23778
|
const { reading } = useReference(sessionId, "people", visible);
|
|
23452
23779
|
const [open, setOpen] = (0, react.useState)();
|
|
@@ -23880,6 +24207,12 @@ window.__ModuleLoader__.load({
|
|
|
23880
24207
|
const sections = createSlotList(ctx, "roleplay.reference.section");
|
|
23881
24208
|
ctx.effect(() => sections.start(), "roleplay: reference page list");
|
|
23882
24209
|
const pages = [
|
|
24210
|
+
{
|
|
24211
|
+
id: "status",
|
|
24212
|
+
order: 3,
|
|
24213
|
+
label: "status",
|
|
24214
|
+
component: StatusPage
|
|
24215
|
+
},
|
|
23883
24216
|
{
|
|
23884
24217
|
id: "profile",
|
|
23885
24218
|
order: 5,
|
|
@@ -24065,28 +24398,28 @@ window.__ModuleLoader__.load({
|
|
|
24065
24398
|
}
|
|
24066
24399
|
tag$5.textContent = css$5;
|
|
24067
24400
|
var ChatSettingsView_module_css_default = {
|
|
24068
|
-
"link": "rp_wLpbxW_link",
|
|
24069
|
-
"title": "rp_wLpbxW_title",
|
|
24070
|
-
"field": "rp_wLpbxW_field",
|
|
24071
|
-
"activity": "rp_wLpbxW_activity",
|
|
24072
|
-
"reasons": "rp_wLpbxW_reasons",
|
|
24073
24401
|
"saved": "rp_wLpbxW_saved",
|
|
24074
|
-
"
|
|
24075
|
-
"
|
|
24076
|
-
"
|
|
24402
|
+
"description": "rp_wLpbxW_description",
|
|
24403
|
+
"error": "rp_wLpbxW_error",
|
|
24404
|
+
"field": "rp_wLpbxW_field",
|
|
24077
24405
|
"label": "rp_wLpbxW_label",
|
|
24078
|
-
"
|
|
24079
|
-
"
|
|
24406
|
+
"link": "rp_wLpbxW_link",
|
|
24407
|
+
"title": "rp_wLpbxW_title",
|
|
24080
24408
|
"table": "rp_wLpbxW_table",
|
|
24081
24409
|
"run": "rp_wLpbxW_run",
|
|
24082
|
-
"
|
|
24410
|
+
"help": "rp_wLpbxW_help",
|
|
24411
|
+
"pre": "rp_wLpbxW_pre",
|
|
24412
|
+
"reasons": "rp_wLpbxW_reasons",
|
|
24413
|
+
"select": "rp_wLpbxW_select",
|
|
24414
|
+
"activity": "rp_wLpbxW_activity",
|
|
24415
|
+
"message": "rp_wLpbxW_message",
|
|
24416
|
+
"tableViewport": "rp_wLpbxW_tableViewport",
|
|
24083
24417
|
"view": "rp_wLpbxW_view",
|
|
24084
|
-
"
|
|
24085
|
-
"notice": "rp_wLpbxW_notice",
|
|
24418
|
+
"actions": "rp_wLpbxW_actions",
|
|
24086
24419
|
"activityBody": "rp_wLpbxW_activityBody",
|
|
24087
|
-
"
|
|
24088
|
-
"
|
|
24089
|
-
"
|
|
24420
|
+
"notice": "rp_wLpbxW_notice",
|
|
24421
|
+
"row": "rp_wLpbxW_row",
|
|
24422
|
+
"list": "rp_wLpbxW_list"
|
|
24090
24423
|
};
|
|
24091
24424
|
// src/client/chat-settings/settings-api.ts
|
|
24092
24425
|
/** The chat is not a roleplay session, so it has no settings. */
|
|
@@ -24211,17 +24544,21 @@ window.__ModuleLoader__.load({
|
|
|
24211
24544
|
decision: "decisionDecision",
|
|
24212
24545
|
hybrid: "decisionHybrid",
|
|
24213
24546
|
shadow: "decisionShadow",
|
|
24547
|
+
strict: "decisionStrict",
|
|
24214
24548
|
on: "decisionOn"
|
|
24215
24549
|
};
|
|
24216
24550
|
const SITE_LABEL = {
|
|
24217
24551
|
reuse: "decisionsSiteReuse",
|
|
24552
|
+
errands: "decisionsSiteErrands",
|
|
24218
24553
|
variables: "decisionsSiteVariables",
|
|
24219
24554
|
triggers: "decisionsSiteTriggers",
|
|
24220
24555
|
reflection: "decisionsSiteReflection",
|
|
24221
24556
|
agency: "decisionsSiteAgency",
|
|
24222
24557
|
refusal: "decisionsSiteRefusal",
|
|
24558
|
+
repeats: "decisionsSiteRepeats",
|
|
24223
24559
|
rules: "decisionsSiteRules",
|
|
24224
|
-
secrets: "decisionsSiteSecrets"
|
|
24560
|
+
secrets: "decisionsSiteSecrets",
|
|
24561
|
+
messages: "decisionsSiteMessages"
|
|
24225
24562
|
};
|
|
24226
24563
|
/** Whether a decision model is there, and how the sites set to use one have done in this story. */
|
|
24227
24564
|
function DecisionsSection({ t, session, modes }) {
|
|
@@ -24390,7 +24727,7 @@ window.__ModuleLoader__.load({
|
|
|
24390
24727
|
});
|
|
24391
24728
|
}
|
|
24392
24729
|
// src/client/chat-settings/InterfaceSection.tsx
|
|
24393
|
-
const message$
|
|
24730
|
+
const message$5 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
24394
24731
|
/**
|
|
24395
24732
|
* The interface pack of the story: which one is in use or why none is, a choice of the packs the story could use (kept
|
|
24396
24733
|
* with the other settings, so it is saved with them), and, when the world's packs are not what the story copied, a way
|
|
@@ -24408,7 +24745,7 @@ window.__ModuleLoader__.load({
|
|
|
24408
24745
|
setStatus(next);
|
|
24409
24746
|
setFailure(void 0);
|
|
24410
24747
|
}, (error) => {
|
|
24411
|
-
if (!abort.signal.aborted) setFailure(message$
|
|
24748
|
+
if (!abort.signal.aborted) setFailure(message$5(error));
|
|
24412
24749
|
});
|
|
24413
24750
|
return () => {
|
|
24414
24751
|
abort.abort();
|
|
@@ -24429,7 +24766,7 @@ window.__ModuleLoader__.load({
|
|
|
24429
24766
|
setVersion((number) => number + 1);
|
|
24430
24767
|
}, (error) => {
|
|
24431
24768
|
setReport(void 0);
|
|
24432
|
-
setFailure(t("packSyncFailed", { message: message$
|
|
24769
|
+
setFailure(t("packSyncFailed", { message: message$5(error) }));
|
|
24433
24770
|
});
|
|
24434
24771
|
};
|
|
24435
24772
|
if (status === void 0) return failure === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
@@ -24543,7 +24880,7 @@ window.__ModuleLoader__.load({
|
|
|
24543
24880
|
});
|
|
24544
24881
|
}
|
|
24545
24882
|
// src/client/chat-settings/LorebookSection.tsx
|
|
24546
|
-
const message$
|
|
24883
|
+
const message$4 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
24547
24884
|
/** The lorebooks the story holds, with a way to add one from the library or take one out. */
|
|
24548
24885
|
function LorebookSection({ t, session, disabled }) {
|
|
24549
24886
|
const [status, setStatus] = (0, react.useState)();
|
|
@@ -24558,7 +24895,7 @@ window.__ModuleLoader__.load({
|
|
|
24558
24895
|
setStatus(next);
|
|
24559
24896
|
setFailure(void 0);
|
|
24560
24897
|
}, (error) => {
|
|
24561
|
-
if (!abort.signal.aborted) setFailure(message$
|
|
24898
|
+
if (!abort.signal.aborted) setFailure(message$4(error));
|
|
24562
24899
|
});
|
|
24563
24900
|
return () => {
|
|
24564
24901
|
abort.abort();
|
|
@@ -24574,7 +24911,7 @@ window.__ModuleLoader__.load({
|
|
|
24574
24911
|
const refused = (error) => {
|
|
24575
24912
|
setReport([]);
|
|
24576
24913
|
setLeaving(void 0);
|
|
24577
|
-
setFailure(t("lorebookFailed", { message: message$
|
|
24914
|
+
setFailure(t("lorebookFailed", { message: message$4(error) }));
|
|
24578
24915
|
};
|
|
24579
24916
|
const add = () => {
|
|
24580
24917
|
addStoryLorebook(session, choice, new AbortController().signal).then((added) => {
|
|
@@ -24675,6 +25012,150 @@ window.__ModuleLoader__.load({
|
|
|
24675
25012
|
]
|
|
24676
25013
|
});
|
|
24677
25014
|
}
|
|
25015
|
+
// src/client/folders-api.ts
|
|
25016
|
+
async function reply$1(response) {
|
|
25017
|
+
if (!response.ok) {
|
|
25018
|
+
const body = await response.json().catch(() => void 0);
|
|
25019
|
+
throw new Error(typeof body?.message === "string" ? body.message : `${response.status} ${response.statusText}`.trim());
|
|
25020
|
+
}
|
|
25021
|
+
return await response.json();
|
|
25022
|
+
}
|
|
25023
|
+
async function loadStoryFolders(session, signal) {
|
|
25024
|
+
return await reply$1(await fetch(`${API_PREFIX}/sessions/folders?id=${encodeURIComponent(session)}`, {
|
|
25025
|
+
credentials: "same-origin",
|
|
25026
|
+
signal
|
|
25027
|
+
}));
|
|
25028
|
+
}
|
|
25029
|
+
async function saveStoryFolders(session, folders, signal) {
|
|
25030
|
+
return await reply$1(await fetch(`${API_PREFIX}/sessions/folders?id=${encodeURIComponent(session)}`, {
|
|
25031
|
+
method: "PUT",
|
|
25032
|
+
credentials: "same-origin",
|
|
25033
|
+
headers: { "content-type": "application/json" },
|
|
25034
|
+
body: JSON.stringify({ folders }),
|
|
25035
|
+
signal
|
|
25036
|
+
}));
|
|
25037
|
+
}
|
|
25038
|
+
// src/client/chat-settings/FoldersSection.tsx
|
|
25039
|
+
const message$3 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
25040
|
+
/** The folders the file tools of this story reach: the workspace every story shares, and the folders this story was given. */
|
|
25041
|
+
function FoldersSection({ t, session, disabled }) {
|
|
25042
|
+
const [status, setStatus] = (0, react.useState)();
|
|
25043
|
+
const [path, setPath] = (0, react.useState)("");
|
|
25044
|
+
const [access, setAccess] = (0, react.useState)("read");
|
|
25045
|
+
const [failure, setFailure] = (0, react.useState)();
|
|
25046
|
+
(0, react.useEffect)(() => {
|
|
25047
|
+
const abort = new AbortController();
|
|
25048
|
+
loadStoryFolders(session, abort.signal).then((next) => {
|
|
25049
|
+
setStatus(next);
|
|
25050
|
+
setFailure(void 0);
|
|
25051
|
+
}, (error) => {
|
|
25052
|
+
if (!abort.signal.aborted) setFailure(message$3(error));
|
|
25053
|
+
});
|
|
25054
|
+
return () => {
|
|
25055
|
+
abort.abort();
|
|
25056
|
+
};
|
|
25057
|
+
}, [session]);
|
|
25058
|
+
const save = (folders) => {
|
|
25059
|
+
saveStoryFolders(session, folders, new AbortController().signal).then((next) => {
|
|
25060
|
+
setStatus(next);
|
|
25061
|
+
setPath("");
|
|
25062
|
+
setFailure(void 0);
|
|
25063
|
+
}, (error) => {
|
|
25064
|
+
setFailure(t("foldersFailed", { message: message$3(error) }));
|
|
25065
|
+
});
|
|
25066
|
+
};
|
|
25067
|
+
if (status === void 0) return failure === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
25068
|
+
className: ChatSettingsView_module_css_default.error,
|
|
25069
|
+
role: "alert",
|
|
25070
|
+
children: t("foldersLoadFailed", { message: failure })
|
|
25071
|
+
});
|
|
25072
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
|
|
25073
|
+
className: ChatSettingsView_module_css_default.activity,
|
|
25074
|
+
"data-testid": "roleplay-folders",
|
|
25075
|
+
children: [
|
|
25076
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", { children: t("foldersTitle") }),
|
|
25077
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
25078
|
+
className: ChatSettingsView_module_css_default.description,
|
|
25079
|
+
children: t("foldersHelp", { workspace: status.workspace })
|
|
25080
|
+
}),
|
|
25081
|
+
status.folders.length === 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
25082
|
+
className: ChatSettingsView_module_css_default.description,
|
|
25083
|
+
children: t("foldersNone")
|
|
25084
|
+
}),
|
|
25085
|
+
status.folders.map((folder) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", { children: [
|
|
25086
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", { children: t(folder.access === "write" ? "foldersRowWrite" : "foldersRowRead", { path: folder.path }) }),
|
|
25087
|
+
" ",
|
|
25088
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
25089
|
+
variant: "ghost",
|
|
25090
|
+
size: "sm",
|
|
25091
|
+
disabled,
|
|
25092
|
+
onClick: () => {
|
|
25093
|
+
save(status.folders.filter((other) => other.path !== folder.path));
|
|
25094
|
+
},
|
|
25095
|
+
children: t("foldersRemove")
|
|
25096
|
+
})
|
|
25097
|
+
] }, folder.path)),
|
|
25098
|
+
status.folders.length < status.limit && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [
|
|
25099
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
25100
|
+
className: ChatSettingsView_module_css_default.field,
|
|
25101
|
+
style: { maxWidth: "none" },
|
|
25102
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
25103
|
+
className: ChatSettingsView_module_css_default.label,
|
|
25104
|
+
children: t("foldersPath")
|
|
25105
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("input", {
|
|
25106
|
+
className: ChatSettingsView_module_css_default.select,
|
|
25107
|
+
type: "text",
|
|
25108
|
+
value: path,
|
|
25109
|
+
disabled,
|
|
25110
|
+
placeholder: "/home/…",
|
|
25111
|
+
onChange: (event) => {
|
|
25112
|
+
setPath(event.target.value);
|
|
25113
|
+
}
|
|
25114
|
+
})]
|
|
25115
|
+
}),
|
|
25116
|
+
/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("label", {
|
|
25117
|
+
className: ChatSettingsView_module_css_default.field,
|
|
25118
|
+
style: { maxWidth: "none" },
|
|
25119
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
25120
|
+
className: ChatSettingsView_module_css_default.label,
|
|
25121
|
+
children: t("foldersAccess")
|
|
25122
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("select", {
|
|
25123
|
+
className: ChatSettingsView_module_css_default.select,
|
|
25124
|
+
value: access,
|
|
25125
|
+
disabled,
|
|
25126
|
+
onChange: (event) => {
|
|
25127
|
+
setAccess(event.target.value);
|
|
25128
|
+
},
|
|
25129
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
|
|
25130
|
+
value: "read",
|
|
25131
|
+
children: t("foldersRead")
|
|
25132
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("option", {
|
|
25133
|
+
value: "write",
|
|
25134
|
+
children: t("foldersWrite")
|
|
25135
|
+
})]
|
|
25136
|
+
})]
|
|
25137
|
+
}),
|
|
25138
|
+
path.trim() !== "" && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
|
|
25139
|
+
variant: "ghost",
|
|
25140
|
+
size: "sm",
|
|
25141
|
+
disabled,
|
|
25142
|
+
onClick: () => {
|
|
25143
|
+
save([...status.folders, {
|
|
25144
|
+
path: path.trim(),
|
|
25145
|
+
access
|
|
25146
|
+
}]);
|
|
25147
|
+
},
|
|
25148
|
+
children: t("foldersAdd")
|
|
25149
|
+
}) })
|
|
25150
|
+
] }),
|
|
25151
|
+
failure !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
|
|
25152
|
+
className: ChatSettingsView_module_css_default.error,
|
|
25153
|
+
role: "alert",
|
|
25154
|
+
children: failure
|
|
25155
|
+
})
|
|
25156
|
+
]
|
|
25157
|
+
});
|
|
25158
|
+
}
|
|
24678
25159
|
// src/client/chat-settings/PresetSection.tsx
|
|
24679
25160
|
const message$2 = (failure) => failure instanceof Error ? failure.message : String(failure);
|
|
24680
25161
|
/** The writing preset the story's prompts came from, whether it still matches the library, and a way to switch or take it out. */
|
|
@@ -25952,6 +26433,11 @@ window.__ModuleLoader__.load({
|
|
|
25952
26433
|
session,
|
|
25953
26434
|
disabled: saving
|
|
25954
26435
|
}),
|
|
26436
|
+
session !== void 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(FoldersSection, {
|
|
26437
|
+
t,
|
|
26438
|
+
session,
|
|
26439
|
+
disabled: saving
|
|
26440
|
+
}),
|
|
25955
26441
|
/* @__PURE__ */ (0, react_jsx_runtime.jsx)(ToolSwitches, {
|
|
25956
26442
|
board: payload.settings.tools,
|
|
25957
26443
|
onChange: setTools,
|
|
@@ -26064,6 +26550,7 @@ window.__ModuleLoader__.load({
|
|
|
26064
26550
|
decisionsAgreement: "Agreement",
|
|
26065
26551
|
decisionsDecisionTime: "Decision model per run",
|
|
26066
26552
|
decisionsLlmTime: "Language model per run",
|
|
26553
|
+
decisionsSiteRepeats: "Repeated sentences",
|
|
26067
26554
|
decisionsSiteVariables: "Tracked values",
|
|
26068
26555
|
decisionsSiteReuse: "Stored pictures",
|
|
26069
26556
|
decisionsSiteTriggers: "Trigger statements",
|
|
@@ -26072,6 +26559,8 @@ window.__ModuleLoader__.load({
|
|
|
26072
26559
|
decisionsSiteRefusal: "Output out of the story",
|
|
26073
26560
|
decisionsSiteRules: "Actions against the rules",
|
|
26074
26561
|
decisionsSiteSecrets: "Output giving away secrets",
|
|
26562
|
+
decisionsSiteMessages: "Messages while you are away",
|
|
26563
|
+
decisionsSiteErrands: "Characters who wait for you",
|
|
26075
26564
|
decisionsProblem: "{site}: the decision model could not be used the last time ({message}).",
|
|
26076
26565
|
decisionsSamples: "{site}: latest disagreements",
|
|
26077
26566
|
decisionsSample: "Turn {turn}: {what} (decision model {probability}% yes, so {decision}; language model {llm})",
|
|
@@ -26227,6 +26716,19 @@ window.__ModuleLoader__.load({
|
|
|
26227
26716
|
lorebookRemoved: "Done: {count} entries removed.",
|
|
26228
26717
|
lorebookFailed: "Could not change the lorebooks: {message}",
|
|
26229
26718
|
lorebookLoadFailed: "Could not read the lorebooks: {message}",
|
|
26719
|
+
foldersTitle: "Folders for the file tools",
|
|
26720
|
+
foldersHelp: "When the file tools are switched on for an agent of this story, they reach only the workspace every story shares ({workspace}) and the folders given here, always by whole path. Give a folder read-only unless the agent should change it. Shell and terminal tools are not held to these folders.",
|
|
26721
|
+
foldersNone: "No other folder is given to this story.",
|
|
26722
|
+
foldersRowRead: "{path} (read only)",
|
|
26723
|
+
foldersRowWrite: "{path} (read and write)",
|
|
26724
|
+
foldersRemove: "Remove",
|
|
26725
|
+
foldersPath: "Folder (whole path)",
|
|
26726
|
+
foldersAccess: "Access",
|
|
26727
|
+
foldersRead: "Read only",
|
|
26728
|
+
foldersWrite: "Read and write",
|
|
26729
|
+
foldersAdd: "Give this folder",
|
|
26730
|
+
foldersFailed: "The folder was not given: {message}",
|
|
26731
|
+
foldersLoadFailed: "Could not read the folders: {message}",
|
|
26230
26732
|
packTitle: "Interface pack",
|
|
26231
26733
|
packHelp: "A pack changes how this story looks and can add a status strip, buttons, an opening card, a backdrop or a tab. A world can carry packs; yours go in the ui folder of your roleplay folder.",
|
|
26232
26734
|
packActive: "In use: {name}",
|
|
@@ -26275,6 +26777,7 @@ window.__ModuleLoader__.load({
|
|
|
26275
26777
|
decisionsAgreement: "一致率",
|
|
26276
26778
|
decisionsDecisionTime: "决策模型每次",
|
|
26277
26779
|
decisionsLlmTime: "语言模型每次",
|
|
26780
|
+
decisionsSiteRepeats: "重复的句子",
|
|
26278
26781
|
decisionsSiteVariables: "被追踪的数值",
|
|
26279
26782
|
decisionsSiteReuse: "已存图片",
|
|
26280
26783
|
decisionsSiteTriggers: "触发器陈述",
|
|
@@ -26283,6 +26786,8 @@ window.__ModuleLoader__.load({
|
|
|
26283
26786
|
decisionsSiteRefusal: "输出跳出故事",
|
|
26284
26787
|
decisionsSiteRules: "按规则检查行动",
|
|
26285
26788
|
decisionsSiteSecrets: "输出泄露秘密",
|
|
26789
|
+
decisionsSiteMessages: "你不在时的消息",
|
|
26790
|
+
decisionsSiteErrands: "等你的角色",
|
|
26286
26791
|
decisionsProblem: "{site}:上一次无法使用决策模型({message})。",
|
|
26287
26792
|
decisionsSamples: "{site}:最近的分歧",
|
|
26288
26793
|
decisionsSample: "第 {turn} 回合:{what}(决策模型认为 {probability}% 为是,因此为{decision};语言模型为{llm})",
|
|
@@ -26438,6 +26943,19 @@ window.__ModuleLoader__.load({
|
|
|
26438
26943
|
lorebookRemoved: "完成:删除了 {count} 条。",
|
|
26439
26944
|
lorebookFailed: "无法更改世界书:{message}",
|
|
26440
26945
|
lorebookLoadFailed: "无法读取世界书:{message}",
|
|
26946
|
+
foldersTitle: "文件工具可用的文件夹",
|
|
26947
|
+
foldersHelp: "这个故事里的某个智能体打开文件工具后,只能访问所有故事共用的工作区({workspace})和这里给出的文件夹,并且一律使用完整路径。除非智能体需要修改,否则只给只读。终端和命令行工具不受这些文件夹限制。",
|
|
26948
|
+
foldersNone: "没有给这个故事其他文件夹。",
|
|
26949
|
+
foldersRowRead: "{path}(只读)",
|
|
26950
|
+
foldersRowWrite: "{path}(可读可写)",
|
|
26951
|
+
foldersRemove: "移除",
|
|
26952
|
+
foldersPath: "文件夹(完整路径)",
|
|
26953
|
+
foldersAccess: "权限",
|
|
26954
|
+
foldersRead: "只读",
|
|
26955
|
+
foldersWrite: "可读可写",
|
|
26956
|
+
foldersAdd: "给出这个文件夹",
|
|
26957
|
+
foldersFailed: "没有给出这个文件夹:{message}",
|
|
26958
|
+
foldersLoadFailed: "无法读取文件夹:{message}",
|
|
26441
26959
|
packTitle: "界面包",
|
|
26442
26960
|
packHelp: "界面包会改变此故事的外观,并可添加状态条、按钮、开场卡片、背景或标签页。世界可以自带界面包;你自己的放在角色扮演目录的 ui 文件夹中。",
|
|
26443
26961
|
packActive: "使用中:{name}",
|
|
@@ -26504,16 +27022,16 @@ window.__ModuleLoader__.load({
|
|
|
26504
27022
|
}
|
|
26505
27023
|
tag$4.textContent = css$4;
|
|
26506
27024
|
var CatalogueSettings_module_css_default = {
|
|
26507
|
-
"
|
|
26508
|
-
"title": "rp_KPhXDa_title",
|
|
27025
|
+
"problem": "rp_KPhXDa_problem",
|
|
26509
27026
|
"keyArea": "rp_KPhXDa_keyArea",
|
|
27027
|
+
"row": "rp_KPhXDa_row",
|
|
26510
27028
|
"label": "rp_KPhXDa_label",
|
|
27029
|
+
"title": "rp_KPhXDa_title",
|
|
27030
|
+
"hint": "rp_KPhXDa_hint",
|
|
26511
27031
|
"actions": "rp_KPhXDa_actions",
|
|
26512
|
-
"problem": "rp_KPhXDa_problem",
|
|
26513
|
-
"section": "rp_KPhXDa_section",
|
|
26514
27032
|
"keyHint": "rp_KPhXDa_keyHint",
|
|
26515
|
-
"
|
|
26516
|
-
"
|
|
27033
|
+
"field": "rp_KPhXDa_field",
|
|
27034
|
+
"section": "rp_KPhXDa_section"
|
|
26517
27035
|
};
|
|
26518
27036
|
// src/client/settings/AuthoringToolSettings.tsx
|
|
26519
27037
|
const boardOf = (text) => {
|
|
@@ -26706,6 +27224,14 @@ window.__ModuleLoader__.load({
|
|
|
26706
27224
|
min: 0,
|
|
26707
27225
|
max: 3650,
|
|
26708
27226
|
placeholder: "30"
|
|
27227
|
+
},
|
|
27228
|
+
{
|
|
27229
|
+
field: "autonomyTickSeconds",
|
|
27230
|
+
group: "limits",
|
|
27231
|
+
kind: "integer",
|
|
27232
|
+
min: 0,
|
|
27233
|
+
max: 3600,
|
|
27234
|
+
placeholder: "30"
|
|
26709
27235
|
}
|
|
26710
27236
|
];
|
|
26711
27237
|
/** A draft is empty (the default), or a value the host accepts; anything else cannot be saved. */
|
|
@@ -26747,16 +27273,16 @@ window.__ModuleLoader__.load({
|
|
|
26747
27273
|
var AssistantSettings_module_css_default = {
|
|
26748
27274
|
"head": "rp_ZwzM4q_head",
|
|
26749
27275
|
"badges": "rp_ZwzM4q_badges",
|
|
26750
|
-
"
|
|
27276
|
+
"fields": "rp_ZwzM4q_fields",
|
|
27277
|
+
"fieldHint": "rp_ZwzM4q_fieldHint",
|
|
26751
27278
|
"reset": "rp_ZwzM4q_reset",
|
|
26752
27279
|
"select": "rp_ZwzM4q_select",
|
|
26753
27280
|
"title": "rp_ZwzM4q_title",
|
|
26754
|
-
"
|
|
26755
|
-
"invalid": "rp_ZwzM4q_invalid",
|
|
26756
|
-
"fields": "rp_ZwzM4q_fields",
|
|
26757
|
-
"fieldHint": "rp_ZwzM4q_fieldHint",
|
|
27281
|
+
"label": "rp_ZwzM4q_label",
|
|
26758
27282
|
"field": "rp_ZwzM4q_field",
|
|
26759
|
-
"
|
|
27283
|
+
"invalid": "rp_ZwzM4q_invalid",
|
|
27284
|
+
"hint": "rp_ZwzM4q_hint",
|
|
27285
|
+
"section": "rp_ZwzM4q_section"
|
|
26760
27286
|
};
|
|
26761
27287
|
// src/client/settings/AssistantSettings.tsx
|
|
26762
27288
|
function ChoiceField({ t, spec, state, disabled, onEdit, onReset }) {
|
|
@@ -27820,6 +28346,8 @@ window.__ModuleLoader__.load({
|
|
|
27820
28346
|
catalogueMaxBytesLabel: "Largest catalogue download (bytes)",
|
|
27821
28347
|
catalogueMaxBytesHint: "The most a world downloaded from a catalogue may be, compressed and again unpacked. Default 268435456 (256 MB).",
|
|
27822
28348
|
catalogueTrashDaysLabel: "Days to keep replaced files",
|
|
28349
|
+
autonomyTickSecondsLabel: "Seconds between looks at stories that go on without you",
|
|
28350
|
+
autonomyTickSecondsHint: "How often the stories that switched on \"the story goes on while I am away\" are looked at: characters take up their days, and one may write to you. 0 never looks; the least is 5. Default 30.",
|
|
27823
28351
|
catalogueTrashDaysHint: "How long the files an update replaced stay in the trash folder before they are deleted. 0 keeps them for good. Default 30.",
|
|
27824
28352
|
offload: "Models that cannot be loaded together",
|
|
27825
28353
|
offloadHint: "When the models of a story do not fit in memory at once, put the ones that exclude each other in a group: before one of them is used, the server unloads the others, and loads what is asked of it again on its own. Every switch costs the time of loading a model, so group a large model with another only when you have to, and leave this empty when everything fits. The chat's own model is \"Story model\"; the others need the route of the model server (as set in the AI providers) and the model's name there. Unloading needs a provider that supports it (LocalAI and Ollama do).",
|
|
@@ -27930,6 +28458,8 @@ window.__ModuleLoader__.load({
|
|
|
27930
28458
|
catalogueMaxBytesLabel: "目录下载大小上限(字节)",
|
|
27931
28459
|
catalogueMaxBytesHint: "从目录下载的世界的最大体积,压缩后和解压后都不得超过。默认 268435456(256 MB)。",
|
|
27932
28460
|
catalogueTrashDaysLabel: "被替换文件的保留天数",
|
|
28461
|
+
autonomyTickSecondsLabel: "查看无人在场继续进行的故事的间隔(秒)",
|
|
28462
|
+
autonomyTickSecondsHint: "多久查看一次打开了“我不在时故事继续”的故事:角色按各自日程行事,其中一人可能给你写消息。0 表示从不查看,最短 5 秒。默认 30。",
|
|
27933
28463
|
catalogueTrashDaysHint: "更新替换下来的文件在回收文件夹中保留多少天后删除。0 表示永久保留。默认 30。",
|
|
27934
28464
|
offload: "不能同时加载的模型",
|
|
27935
28465
|
offloadHint: "如果故事用到的模型无法同时放进内存,就把互相排斥的模型放进同一组:使用其中一个之前,服务器会先卸载其他的,之后再被请求时会自行重新加载。每次切换都要花一次加载模型的时间,所以只在不得不这样做时才把大模型和别的模型分在一组;如果所有模型都放得下,请留空。聊天本身使用的模型是“故事模型”;其他模型需要填模型服务器的路由(在 AI 提供方中设置的那个)以及模型在服务器上的名称。卸载需要提供方支持(LocalAI 和 Ollama 支持)。",
|
|
@@ -28284,28 +28814,28 @@ window.__ModuleLoader__.load({
|
|
|
28284
28814
|
}
|
|
28285
28815
|
tag$2.textContent = css$2;
|
|
28286
28816
|
var NarrationView_module_css_default = {
|
|
28287
|
-
"
|
|
28288
|
-
"
|
|
28289
|
-
"preview": "rp_NFPimG_preview",
|
|
28290
|
-
"imageStatus": "rp_NFPimG_imageStatus",
|
|
28817
|
+
"diceSummary": "rp_NFPimG_diceSummary",
|
|
28818
|
+
"oocRefused": "rp_NFPimG_oocRefused",
|
|
28291
28819
|
"name": "rp_NFPimG_name",
|
|
28820
|
+
"imageError": "rp_NFPimG_imageError",
|
|
28821
|
+
"preview": "rp_NFPimG_preview",
|
|
28822
|
+
"words": "rp_NFPimG_words",
|
|
28823
|
+
"diceList": "rp_NFPimG_diceList",
|
|
28824
|
+
"output": "rp_NFPimG_output",
|
|
28825
|
+
"oocNote": "rp_NFPimG_oocNote",
|
|
28826
|
+
"avatar": "rp_NFPimG_avatar",
|
|
28827
|
+
"images": "rp_NFPimG_images",
|
|
28292
28828
|
"note": "rp_NFPimG_note",
|
|
28829
|
+
"imageStatus": "rp_NFPimG_imageStatus",
|
|
28293
28830
|
"playAll": "rp_NFPimG_playAll",
|
|
28831
|
+
"playLine": "rp_NFPimG_playLine",
|
|
28832
|
+
"speech": "rp_NFPimG_speech",
|
|
28294
28833
|
"line": "rp_NFPimG_line",
|
|
28295
|
-
"
|
|
28834
|
+
"narration": "rp_NFPimG_narration",
|
|
28835
|
+
"oocLabel": "rp_NFPimG_oocLabel",
|
|
28296
28836
|
"imageButton": "rp_NFPimG_imageButton",
|
|
28297
28837
|
"dice": "rp_NFPimG_dice",
|
|
28298
|
-
"
|
|
28299
|
-
"narration": "rp_NFPimG_narration",
|
|
28300
|
-
"images": "rp_NFPimG_images",
|
|
28301
|
-
"output": "rp_NFPimG_output",
|
|
28302
|
-
"playLine": "rp_NFPimG_playLine",
|
|
28303
|
-
"diceSummary": "rp_NFPimG_diceSummary",
|
|
28304
|
-
"avatar": "rp_NFPimG_avatar",
|
|
28305
|
-
"words": "rp_NFPimG_words",
|
|
28306
|
-
"oocRefused": "rp_NFPimG_oocRefused",
|
|
28307
|
-
"imageError": "rp_NFPimG_imageError",
|
|
28308
|
-
"diceList": "rp_NFPimG_diceList"
|
|
28838
|
+
"sceneImage": "rp_NFPimG_sceneImage"
|
|
28309
28839
|
};
|
|
28310
28840
|
// src/client/transcript/PreviewNode.tsx
|
|
28311
28841
|
/**
|
|
@@ -28565,16 +29095,18 @@ window.__ModuleLoader__.load({
|
|
|
28565
29095
|
}
|
|
28566
29096
|
tag$1.textContent = css$1;
|
|
28567
29097
|
var SuggestionsDock_module_css_default = {
|
|
28568
|
-
"chip": "rp_rWH4DG_chip",
|
|
28569
|
-
"card": "rp_rWH4DG_card",
|
|
28570
29098
|
"lines": "rp_rWH4DG_lines",
|
|
28571
29099
|
"dock": "rp_rWH4DG_dock",
|
|
29100
|
+
"chip": "rp_rWH4DG_chip",
|
|
29101
|
+
"card": "rp_rWH4DG_card",
|
|
28572
29102
|
"label": "rp_rWH4DG_label"
|
|
28573
29103
|
};
|
|
28574
29104
|
// src/client/transcript/SuggestionsDock.tsx
|
|
28575
29105
|
/** The suggestions are made after the output is shown, so they are asked for until they are there. */
|
|
28576
29106
|
const POLL_MS = 2e3;
|
|
28577
29107
|
const GIVE_UP_AFTER = 45;
|
|
29108
|
+
/** Messages from characters arrive while nobody is playing, so they are looked for all the while the dock is open, slowly. */
|
|
29109
|
+
const MESSAGE_POLL_MS = 3e4;
|
|
28578
29110
|
/**
|
|
28579
29111
|
* What the player could do next, as chips stacked above the input; clicking one fills the input (the player may
|
|
28580
29112
|
* edit it before sending). They are made in the background once the output of a turn is shown, so the dock asks
|
|
@@ -28593,6 +29125,25 @@ window.__ModuleLoader__.load({
|
|
|
28593
29125
|
const [meanwhile, setMeanwhile] = (0, react.useState)([]);
|
|
28594
29126
|
const [unfinished, setUnfinished] = (0, react.useState)([]);
|
|
28595
29127
|
const [unwritten, setUnwritten] = (0, react.useState)(0);
|
|
29128
|
+
const [messages, setMessages] = (0, react.useState)([]);
|
|
29129
|
+
(0, react.useEffect)(() => {
|
|
29130
|
+
let stopped = false;
|
|
29131
|
+
const look = () => {
|
|
29132
|
+
notes().then((found) => {
|
|
29133
|
+
if (stopped) return;
|
|
29134
|
+
const lines = found.find((note) => note.kind === "message")?.lines ?? [];
|
|
29135
|
+
setMessages((previous) => previous.join("\n") === lines.join("\n") ? previous : lines);
|
|
29136
|
+
}).catch((error) => {
|
|
29137
|
+
console.warn("roleplay: the notes could not be read", error);
|
|
29138
|
+
});
|
|
29139
|
+
};
|
|
29140
|
+
look();
|
|
29141
|
+
const timer = setInterval(look, MESSAGE_POLL_MS);
|
|
29142
|
+
return () => {
|
|
29143
|
+
stopped = true;
|
|
29144
|
+
clearInterval(timer);
|
|
29145
|
+
};
|
|
29146
|
+
}, [notes]);
|
|
28596
29147
|
(0, react.useEffect)(() => {
|
|
28597
29148
|
setOffered([]);
|
|
28598
29149
|
setMeanwhile([]);
|
|
@@ -28625,7 +29176,7 @@ window.__ModuleLoader__.load({
|
|
|
28625
29176
|
if (timer !== void 0) clearTimeout(timer);
|
|
28626
29177
|
};
|
|
28627
29178
|
}, [latest, notes]);
|
|
28628
|
-
if (running || offered.length === 0 && meanwhile.length === 0 && unfinished.length === 0 && unwritten === 0) return null;
|
|
29179
|
+
if (running || offered.length === 0 && meanwhile.length === 0 && unfinished.length === 0 && unwritten === 0 && messages.length === 0) return null;
|
|
28629
29180
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
28630
29181
|
className: SuggestionsDock_module_css_default.dock,
|
|
28631
29182
|
"data-testid": "roleplay-suggestions",
|
|
@@ -28647,6 +29198,17 @@ window.__ModuleLoader__.load({
|
|
|
28647
29198
|
children: unfinished.map((line) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("li", { children: line }, line))
|
|
28648
29199
|
})]
|
|
28649
29200
|
}),
|
|
29201
|
+
messages.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
29202
|
+
className: SuggestionsDock_module_css_default.card,
|
|
29203
|
+
"data-testid": "roleplay-messages",
|
|
29204
|
+
children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
29205
|
+
className: SuggestionsDock_module_css_default.label,
|
|
29206
|
+
children: t("messagesAway")
|
|
29207
|
+
}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
|
|
29208
|
+
className: SuggestionsDock_module_css_default.lines,
|
|
29209
|
+
children: messages.map((line) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("li", { children: line }, line))
|
|
29210
|
+
})]
|
|
29211
|
+
}),
|
|
28650
29212
|
meanwhile.length > 0 && /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
28651
29213
|
className: SuggestionsDock_module_css_default.card,
|
|
28652
29214
|
"data-testid": "roleplay-meanwhile",
|
|
@@ -28687,15 +29249,15 @@ window.__ModuleLoader__.load({
|
|
|
28687
29249
|
}
|
|
28688
29250
|
tag.textContent = css;
|
|
28689
29251
|
var TurnsDock_module_css_default = {
|
|
28690
|
-
"dock": "rp_f4YLlq_dock",
|
|
28691
29252
|
"button": "rp_f4YLlq_button",
|
|
28692
|
-
"
|
|
29253
|
+
"count": "rp_f4YLlq_count",
|
|
28693
29254
|
"comparisonSubject": "rp_f4YLlq_comparisonSubject",
|
|
28694
|
-
"
|
|
29255
|
+
"group": "rp_f4YLlq_group",
|
|
28695
29256
|
"error": "rp_f4YLlq_error",
|
|
28696
|
-
"comparisonHead": "rp_f4YLlq_comparisonHead",
|
|
28697
|
-
"count": "rp_f4YLlq_count",
|
|
28698
29257
|
"select": "rp_f4YLlq_select",
|
|
29258
|
+
"dock": "rp_f4YLlq_dock",
|
|
29259
|
+
"comparisonHead": "rp_f4YLlq_comparisonHead",
|
|
29260
|
+
"comparison": "rp_f4YLlq_comparison",
|
|
28699
29261
|
"comparisonLine": "rp_f4YLlq_comparisonLine"
|
|
28700
29262
|
};
|
|
28701
29263
|
// src/client/transcript/withdrawn.ts
|
|
@@ -29075,6 +29637,7 @@ window.__ModuleLoader__.load({
|
|
|
29075
29637
|
repaired: "Corrected so that every spoken line is exactly what the character said.",
|
|
29076
29638
|
suggestions: "You could",
|
|
29077
29639
|
meanwhile: "Meanwhile",
|
|
29640
|
+
messagesAway: "Messages while you were away",
|
|
29078
29641
|
worldFindings: "Unfinished in this world",
|
|
29079
29642
|
suggestionHint: "Put it in the input box",
|
|
29080
29643
|
sceneImage: "Illustration of this scene",
|
|
@@ -29128,6 +29691,7 @@ window.__ModuleLoader__.load({
|
|
|
29128
29691
|
repaired: "已修正,确保每句台词与角色原话一致。",
|
|
29129
29692
|
suggestions: "你可以",
|
|
29130
29693
|
meanwhile: "与此同时",
|
|
29694
|
+
messagesAway: "你不在时的消息",
|
|
29131
29695
|
worldFindings: "这个世界尚未完善之处",
|
|
29132
29696
|
suggestionHint: "填入输入框",
|
|
29133
29697
|
sceneImage: "本场景插图",
|