narraeon 0.5.3 → 0.5.5
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/dist/node/runtime/play/PlayCallChain.js +2 -2
- package/dist/node/runtime/play/PlayContinuity.js +6 -6
- package/dist/node/runtime/prompt/FileNativePromptCompiler.js +6 -6
- package/dist/node/runtime/prompt/FileNativeToolRegistry.js +2 -2
- package/dist/node/shared/default-play-prompts.js +10 -6
- package/dist/node/shared/default-preset-host.js +24 -16
- package/dist/node/shared/ordered-play-prompts.js +2 -2
- package/dist/web/assets/index-DTFZQan4.js +1223 -0
- package/dist/web/index.html +1 -1
- package/package.json +1 -1
- package/dist/web/assets/index-EIOVZb8X.js +0 -1211
|
@@ -1978,8 +1978,8 @@ function prepareTool(session, working, exchange, call, locale) {
|
|
|
1978
1978
|
? {
|
|
1979
1979
|
ok: true,
|
|
1980
1980
|
markdown: locale === "zh-CN"
|
|
1981
|
-
? "
|
|
1982
|
-
: "Checkpoint registered. It
|
|
1981
|
+
? "检查点已登记;随后非空且无工具调用的最终正文成功提交后生效,边界包含该正文。它仅标记历史重放边界,不结束世界内事件;登记后仍可继续调用工具。玩家随后可自行选择全新上下文。"
|
|
1982
|
+
: "Checkpoint registered. It takes effect after the subsequent nonempty tool-free final prose successfully commits, including that prose in its boundary. It marks a history-replay boundary without ending an in-world event; further tool calls may follow registration. The player may then choose a fresh context.",
|
|
1983
1983
|
}
|
|
1984
1984
|
: {
|
|
1985
1985
|
ok: false,
|
|
@@ -30,8 +30,8 @@ export function checkpointHistory(history, checkpoint) {
|
|
|
30
30
|
}
|
|
31
31
|
export function playerRoundMarker(rounds, hasCheckpoint, locale) {
|
|
32
32
|
const markdown = locale === "zh-CN"
|
|
33
|
-
? `距上次检查点已完成 ${rounds} 回合。${hasCheckpoint ? "" : "当前尚无检查点,以世界起点计数。"}
|
|
34
|
-
: `Completed player rounds since the last checkpoint: ${rounds}
|
|
33
|
+
? `距上次检查点已完成 ${rounds} 回合。${hasCheckpoint ? "" : "当前尚无检查点,以世界起点计数。"}`
|
|
34
|
+
: `Completed player rounds since the last checkpoint: ${rounds}.${hasCheckpoint ? "" : " No checkpoint yet; counting from the world origin."}`;
|
|
35
35
|
return {
|
|
36
36
|
kind: "runtime_notice",
|
|
37
37
|
notice: "checkpoint_rounds",
|
|
@@ -46,8 +46,8 @@ export function continuationNotice(locale) {
|
|
|
46
46
|
kind: "runtime_notice",
|
|
47
47
|
notice: "continuation",
|
|
48
48
|
text: locale === "zh-CN"
|
|
49
|
-
? "[Runtime 续写提示]\n
|
|
50
|
-
: "[Runtime continuation]\nThis send adds no new player input.
|
|
49
|
+
? "[Runtime 续写提示]\n本次发送没有追加新的玩家原文。已有的最终主持正文已展示并提交为历史;本次响应接在其后,不重新提交旧正文。回复提交不表示世界内活动已经结束。"
|
|
50
|
+
: "[Runtime continuation]\nThis send adds no new player input. Existing final narrator prose has been displayed and committed as history; this response follows it without resubmitting it. A committed reply does not mean an in-world activity has ended.",
|
|
51
51
|
};
|
|
52
52
|
}
|
|
53
53
|
export function toolStepNotice(locale) {
|
|
@@ -55,8 +55,8 @@ export function toolStepNotice(locale) {
|
|
|
55
55
|
kind: "runtime_notice",
|
|
56
56
|
notice: "tool_step",
|
|
57
57
|
text: locale === "zh-CN"
|
|
58
|
-
? "[Runtime 结算提示]\n
|
|
59
|
-
: "[Runtime settlement]\nThe previous response called tools, so its text
|
|
58
|
+
? "[Runtime 结算提示]\n上一响应调用了工具,其中的文字尚未作为最终故事展示或提交。工具已按回执结算;请根据回执,用无工具调用的非空最终正文呈现本轮尚未展示的内容,并与已提交状态一致。工具结算不要求在这些内容之后再推进剧情。"
|
|
59
|
+
: "[Runtime settlement]\nThe previous response called tools, so its text has not yet been displayed or committed as final story. The tools have settled as their receipts state. Use those receipts to present this turn’s still-unshown content in nonempty final prose with no tool calls, consistent with committed state. Tool settlement does not require advancing the story beyond that content.",
|
|
60
60
|
};
|
|
61
61
|
}
|
|
62
62
|
export function playerInputAppend(input) {
|
|
@@ -45,14 +45,14 @@ ${historyUseGuidance("en")}`,
|
|
|
45
45
|
operation: `# Runtime call-chain rules
|
|
46
46
|
|
|
47
47
|
- A response with no tool calls may contain player-visible story text and finish the current call-chain step.
|
|
48
|
-
- A response that calls any tool is an intermediate
|
|
48
|
+
- A response that calls any tool is an intermediate step; its text is retained in native continuation and diagnostics without being displayed or committed as final story. After all tool results, use the receipts to present this turn's still-unshown content in a later tool-free response consistent with committed state.
|
|
49
49
|
- Obey only the real tool definitions attached to this request. A tool that is not defined cannot be called.
|
|
50
50
|
- Runtime performs state commits and saves follow-up artifacts. Tool exchanges and internal processing must never appear in player-visible content.`,
|
|
51
51
|
shell: `# Runtime play boundary
|
|
52
52
|
|
|
53
|
-
A nonempty tool-free response ends the model/tool loop started by the current player submission. A response that calls any tool is an intermediate step
|
|
53
|
+
A nonempty tool-free response ends the model/tool loop started by the current player submission. A response that calls any tool is an intermediate step; its text has not yet been displayed or committed as final story. After all tool results, use the receipts to present this turn's still-unshown content in a later tool-free response consistent with committed state.
|
|
54
54
|
|
|
55
|
-
The player's next submission may choose a fresh context; the old model transcript will not enter that request. Fresh contexts include all committed original player inputs and final narratives after the last effective world_checkpoint, excluding tools, reasoning, and the opening. A checkpoint declaration takes effect only after
|
|
55
|
+
The player's next submission may choose a fresh context; the old model transcript will not enter that request. Fresh contexts include all committed original player inputs and final narratives after the last effective world_checkpoint, excluding tools, reasoning, and the opening. A checkpoint declaration takes effect only after the subsequent nonempty tool-free final prose successfully commits, including that prose in its boundary; further tool calls may follow registration. Normal replies need no checkpoint; registration neither ends an in-world event nor switches context. Author instructions decide save timing.
|
|
56
56
|
|
|
57
57
|
Runtime executes only real tool definitions, file validation, and authority commits. This block does not define story content, point of view, style, player agency, or state semantics.
|
|
58
58
|
|
|
@@ -76,14 +76,14 @@ ${historyUseGuidance("zh-CN")}`,
|
|
|
76
76
|
operation: `# Runtime 调用链规则
|
|
77
77
|
|
|
78
78
|
- 不调用工具的响应可以输出玩家可见故事正文,并结束当前调用链步骤。
|
|
79
|
-
-
|
|
79
|
+
- 只要响应调用了任何工具,它就是中间步;其中的文字保留在原生续传与诊断中,不展示或提交为最终故事。收到全部工具结果后,根据回执在后续无工具响应中呈现本轮尚未展示的内容,并与已提交状态一致。
|
|
80
80
|
- 只服从当前请求的真实工具定义;没有定义的工具不可调用。
|
|
81
81
|
- 状态提交与后置产物保存由 Runtime 执行。工具交换与内部处理过程不得混入玩家可见内容。`,
|
|
82
82
|
shell: `# Runtime 游玩边界
|
|
83
83
|
|
|
84
|
-
|
|
84
|
+
非空且不调用工具的响应会结束本次玩家提交触发的模型/工具循环。只要响应调用了任何工具,它就是工具中间步,其中的文字尚未展示或提交为最终故事。收到全部工具结果后,根据回执在后续无工具响应中呈现本轮尚未展示的内容,并与已提交状态一致。
|
|
85
85
|
|
|
86
|
-
下一次玩家提交可以选择“全新上下文”;旧模型 transcript 不会进入那个请求。新上下文会补入最近一次已生效 world_checkpoint
|
|
86
|
+
下一次玩家提交可以选择“全新上下文”;旧模型 transcript 不会进入那个请求。新上下文会补入最近一次已生效 world_checkpoint 之后的全部已提交玩家原文与最终叙事,不含工具、推理和开场白。检查点登记仅在随后非空且无工具调用的最终正文成功提交后生效,边界包含该正文;登记后仍可继续工具调用。正常回复无需检查点,登记不结束世界内事件,也不自动切换上下文。具体保存时机由作者提示规定。
|
|
87
87
|
|
|
88
88
|
Runtime 只执行真实工具定义、文件校验和权威提交;本段不规定故事、人称、文风、玩家代理权或状态语义。
|
|
89
89
|
|
|
@@ -239,7 +239,7 @@ function createToolDefinitions(locale) {
|
|
|
239
239
|
}
|
|
240
240
|
const toolDescriptions = {
|
|
241
241
|
en: {
|
|
242
|
-
world_checkpoint: "
|
|
242
|
+
world_checkpoint: "Register a consolidation declaration and a history-replay boundary. No arguments. Registration takes effect only after the subsequent nonempty tool-free final prose successfully commits, and includes that prose. A fresh context replays committed player inputs and final narratives after this boundary. The player may choose a fresh context; registration neither switches context nor ends an in-world event. Normal replies need no checkpoint. Further tool calls may follow registration; Runtime does not verify semantic completeness.",
|
|
243
243
|
state_list: "List document and state directory handles known to Runtime. parent must be @dir-/ for the state root or an @dir-* handle from the initial directory index or an earlier state_list result; no preliminary listing is needed for an already supplied handle. Catalog directories declared by the frozen world frame remain listed and usable when empty. A cursor is valid only for the same state snapshot, parent, and limit. Pass returned document handles to context_read. This tool never lists committed history.",
|
|
244
244
|
history_list: "Browse committed history on the current timeline. Omit anchors for the latest page; use only before or after with a Runtime ref (including refs in injected history) for the immediately adjacent page, excluding the anchor. Every page is oldest to newest. limit defaults to 20 (1–100 messages). Previews are only the first 120 Unicode code points. Use independent earlierCursor/laterCursor with {cursor} alone; no first-query parameters on continuation. Cursors bind world, tool, query and immutable ordered history. After history_changed rerun the query. Opening messages are queryable. Read full originals with history_read; positions are snapshot locations, not identities or turns.",
|
|
245
245
|
history_search: "Search committed originals on the current timeline with queries: 1–5 nonempty literal strings (max 256 code points each); no query alias or semantic filters. match defaults to any, or all within one message. NFKC normalization always applies; caseSensitive defaults to false (locale-und case folding), normalized duplicate queries collapse. order defaults to newest_first, or oldest_first. limit defaults to 10 (1–50 matching messages). Optional after/before refs exclude timeline boundaries independently of order; after must precede before. Each result has at most 3 partial original fragments, query occurrence counts and complete-original length. Read a hit and nearby context with history_read. Continue with {cursor} alone; history_changed requires a new query.",
|
|
@@ -253,7 +253,7 @@ const toolDescriptions = {
|
|
|
253
253
|
artifact_clear: "Clear the projection of an artifact that this follow-up declared in advance and explicitly allows to be cleared. The call cannot choose a channel, key, or any other output contract.",
|
|
254
254
|
},
|
|
255
255
|
"zh-CN": {
|
|
256
|
-
world_checkpoint: "
|
|
256
|
+
world_checkpoint: "登记整理声明与历史重放边界,参数为空对象。仅在随后非空且无工具调用的最终正文成功提交后生效,边界包含该正文;全新上下文补入边界之后的已提交玩家原文与最终叙事。玩家可自行选择全新上下文,登记不切换上下文,也不结束世界内事件。正常回复无需检查点,登记后仍可继续工具调用;Runtime 不认证语义整理完整。",
|
|
257
257
|
state_list: "列出 Runtime 已知的文档与状态目录句柄。状态根目录的 parent 使用 @dir-/;继续下级时使用初始目录索引或 state_list 返回的 @dir-*;已有句柄无需再次列目录确认。冻结世界 frame 声明的 catalog 目录即使为空,也会继续列出并可用。cursor 只对同一状态快照、parent 和 limit 有效。返回的文档句柄交给 context_read;本工具不列出已提交历史。",
|
|
258
258
|
history_list: "浏览当前时间线已提交历史。无锚点时取最新一页;before 或 after 只能选一个,取锚点紧邻前/后的一页且不含锚点。页内始终由旧到新。limit 默认20,整数1–100。预览仅含前120个Unicode码点;完整原文用history_read。earlierCursor/laterCursor独立翻页,续页只传{cursor},不可混用首次参数。游标绑定世界、工具、查询和有序历史快照;history_changed须重新查询。开场白可查询。提示词注入中的ref可直接使用,无需再次列举;位置不是身份或回合数。",
|
|
259
259
|
history_search: "搜索当前时间线已提交原文。queries必填:1–5个非空字面词,每词最多256个Unicode码点,不接受query别名或语义筛选。match默认any,all限于同一消息。始终NFKC规范化,caseSensitive默认false(locale-und大小写折叠),规范化重复词合并。order默认newest_first,可选oldest_first;limit默认10,整数1–50条命中消息。after/before始终按时间线先后排除边界,after必须早于before,与结果排序无关。每项最多3个部分原文片段、逐词命中次数及完整原文长度;可用history_read读取前后文。续页只传{cursor};history_changed须重新查询。",
|
|
@@ -15,11 +15,13 @@ export const defaultNarrationPromptZhCN = `# 玩家可见叙事规则
|
|
|
15
15
|
|
|
16
16
|
本轮新发生且玩家能感知的结果,要成为具体可读的事:物品怎样递接、人物如何离开、态度变化怎样在话语或行动中显露。文档中补录旧结果、去重和整理不要求再次演出。界面数值不能代替事件表现,叙事也不能与当前值冲突。未向玩家表露的判断和场外事实无需用旁白揭露。
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
具体表演细节随最终叙事保存,可按需追溯;不要假定每次请求自动带着全部旧段落。必须持续保存的结果按状态维护政策处理,不能只留在检查点覆盖的最终原文中。
|
|
19
19
|
|
|
20
20
|
## 停在哪里
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
先按本次玩家授权和互动需要确定停笔位置。持续活动中,新反馈会影响玩家如何接话、调整或继续时,呈现反馈并留下回应机会,即使不涉及重大决定。开始按腿、教学或交谈不默认授权包办全过程;普通走路、敲门、递送的连带动作可以自然完成,明确要求略过过程或做到某个终点时则在授权内推进。
|
|
23
|
+
|
|
24
|
+
当前行动与反应形成有内容的局面便可以停笔;具体动作、原话或环境变化都可以承接下一段,有意义的沉默、独处、休息和等待也可以自然结束。回复结束与截至此刻整理完成都不要求世界内事件结束,检查点适应停笔位置。不要为了结尾形式让 NPC 硬添动作、邀请或承诺。
|
|
23
25
|
|
|
24
26
|
避免“轮到你了”“你打算怎么做”及把同一句套话改成“众人等你开口”的机械交接,也不要在结尾列选项或重复总结局势。真正发生的注视或等待可以描写,不必强行消除。
|
|
25
27
|
|
|
@@ -29,7 +31,7 @@ export const defaultNarrationPromptZhCN = `# 玩家可见叙事规则
|
|
|
29
31
|
|
|
30
32
|
本次只有世界外查询或维护时,按请求简洁回答或说明整理结果,不为满足小说形式添加动作、对话或时间推进。混合请求中的维护要求不成为角色台词或行动。
|
|
31
33
|
|
|
32
|
-
|
|
34
|
+
玩家的决定与回应仍归玩家;表现自然感官与动作细节不能替他表达立场、感情、同意或承诺。已经提交的行动不能用一句普通改口当作从未发生。
|
|
33
35
|
`;
|
|
34
36
|
export const defaultNarrationPromptEn = `# Player-visible narrative rules
|
|
35
37
|
|
|
@@ -41,11 +43,13 @@ When there is new player input, naturally stage its explicit action or dialogue
|
|
|
41
43
|
|
|
42
44
|
Make new perceivable outcomes this turn concrete: an object handed over, a person leaving, an attitude expressed through words or action. Delayed recording, deduplication and maintenance do not require performing old events again. Interface values do not replace dramatization, and prose must agree with current values. Unexpressed judgments and offstage facts need not be revealed in narration.
|
|
43
45
|
|
|
44
|
-
Specific performance details are saved with final narrative and can be retrieved when needed; do not assume every request automatically includes every earlier passage. Handle required durable results under the state-maintenance policy instead of leaving them only in a checkpoint
|
|
46
|
+
Specific performance details are saved with final narrative and can be retrieved when needed; do not assume every request automatically includes every earlier passage. Handle required durable results under the state-maintenance policy instead of leaving them only in the final prose covered by a checkpoint.
|
|
45
47
|
|
|
46
48
|
## Where to stop
|
|
47
49
|
|
|
48
|
-
|
|
50
|
+
First choose where to stop from the player's authorization and the interaction's needs. During an ongoing activity, when new feedback could affect how the player replies, adjusts or continues, present it and leave room to respond even without a consequential decision. Starting a leg massage, lesson or conversation does not by itself authorize the entire activity; ordinary supporting actions in walking, knocking or delivering can complete naturally. Explicit requests to skip the process or reach an endpoint allow advancement within that authorization.
|
|
51
|
+
|
|
52
|
+
You may stop once action and reactions form a meaningful situation. A specific action, actual line of dialogue or environmental change can lead onward; meaningful silence, solitude, rest and waiting can also close naturally. Ending a reply or consolidating records through this moment does not require ending the in-world event; fit checkpoint maintenance to the stopping point. Do not invent an NPC action, invitation or promise to satisfy an ending format.
|
|
49
53
|
|
|
50
54
|
Avoid mechanical handoffs such as “Your turn”, “What do you do?” or their stock substitute “Everyone waits for you to speak”. Do not end by listing options or repeating a situation summary. Actual attention or waiting may be described without being forcibly removed.
|
|
51
55
|
|
|
@@ -55,7 +59,7 @@ In-world narrative uses only the novel's prose, in several natural paragraphs if
|
|
|
55
59
|
|
|
56
60
|
If this request is solely out-of-world inquiry or maintenance, answer or explain the consolidation briefly as requested without adding actions, dialogue or time passage to satisfy novel form. Maintenance instructions within a mixed request do not become character speech or actions.
|
|
57
61
|
|
|
58
|
-
|
|
62
|
+
Decisions and responses belong to the player. Sensory and movement details must not express a stance, feeling, consent or promise for them. A later ordinary change of mind does not mean an already committed action never happened.
|
|
59
63
|
`;
|
|
60
64
|
export const defaultNarrationPrompt = defaultNarrationPromptEn;
|
|
61
65
|
export function defaultNarrationPromptForLocale(locale) {
|
|
@@ -32,7 +32,7 @@ roles:
|
|
|
32
32
|
|
|
33
33
|
## 该慢的地方要慢下来
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
篇幅和节奏随这一刻的分量变化。赶路、例行公事和已经交代的背景可以一两句带过;关系变化、话到关键处、局面翻转或危险临近时,把玩家在意的几秒写具体。一个抬手可以写三行,两小时赶路也可以写一句;详写几秒的体验,不等于一次推进整场活动。
|
|
36
36
|
|
|
37
37
|
详写给出前一句没有的信息:动作怎样接续、声音如何变化、人物注意到什么。注水只是换词重复同一事实或重述已知背景。不要为了固定篇幅给每个人分配一个动作。
|
|
38
38
|
|
|
@@ -46,7 +46,7 @@ roles:
|
|
|
46
46
|
|
|
47
47
|
## 把那一刻拆开
|
|
48
48
|
|
|
49
|
-
|
|
49
|
+
不要跳过过程直接给结论。“你们牵起了手”把整段最值钱的东西省掉了。详写本轮停笔位置以内的那一刻:手伸过去的半路、指尖碰到哪里、对方是迎上来还是没有动、已经握住时的力度。写到对方的新反应时,可以留下回应空间,松手与后续发展按实际授权和进展表现。
|
|
50
50
|
|
|
51
51
|
一个动作可以占三四行。这里的“慢”不是拖,是把玩家真正在意的那几秒补足。
|
|
52
52
|
|
|
@@ -106,7 +106,7 @@ NPC 的回答可以短、冷、有停顿;对话的紧张不要求玩家连续
|
|
|
106
106
|
|
|
107
107
|
## 出手
|
|
108
108
|
|
|
109
|
-
|
|
109
|
+
交手要写得清楚而不冗长:本轮授权内的出手、对方怎么接、气力和位置的变化。写得让人看得懂,而不是堆招式名;新的应对留给玩家,胜负实际已定时再写决定它的那一下。
|
|
110
110
|
|
|
111
111
|
内力、伤势、兵器和轻功以当前世界事实与规则为准,不为某次胜负临时倒造前提。
|
|
112
112
|
|
|
@@ -142,9 +142,9 @@ NPC 的回答可以短、冷、有停顿;对话的紧张不要求玩家连续
|
|
|
142
142
|
|
|
143
143
|
写清楚谁在哪、朝哪动、打到没打到、代价是什么。看不懂的动作场面等于没写。
|
|
144
144
|
|
|
145
|
-
##
|
|
145
|
+
## 按动作顺序写
|
|
146
146
|
|
|
147
|
-
|
|
147
|
+
按时间顺序推进,交代动作之间的衔接。在玩家已授权的范围和本轮停笔位置以内写起手、对方应对、已成立结果和位置变化;对方的新反馈需要玩家应对时保留空间。一段可以承接多个普通动作,不要求每次只写一个动作。
|
|
148
148
|
|
|
149
149
|
写重量和代价:撞上去的地方会疼,挥空了会失衡,跑起来会喘。伤势和体力按世界事实累积,不要打完就恢复。
|
|
150
150
|
|
|
@@ -158,7 +158,7 @@ NPC 的回答可以短、冷、有停顿;对话的紧张不要求玩家连续
|
|
|
158
158
|
|
|
159
159
|
## 后果
|
|
160
160
|
|
|
161
|
-
|
|
161
|
+
本轮停笔时让当前处境清楚:位置、已成立的伤势、正在进行的交手与待应对的变化。胜负尚未分出时保留进行中局面。
|
|
162
162
|
`,
|
|
163
163
|
"blocks/style-literary.md": `# 文风:克制与留白
|
|
164
164
|
|
|
@@ -188,7 +188,9 @@ NPC 的回答可以短、冷、有停顿;对话的紧张不要求玩家连续
|
|
|
188
188
|
|
|
189
189
|
玩家的目标、去向、立场、态度、承诺、给予或接受、动手或收手,以及改变关系、风险和归属的关键选择,必须有玩家的明确表达支持。不要从神态或身体反应替玩家推定这些选择。
|
|
190
190
|
|
|
191
|
-
|
|
191
|
+
想法、愿望、准备和预测不等于实施,尝试也不等于成功。“我去找他”这类日常行动简写可以授权开始并完成通常的连带动作;结果仍由当前世界事实与规则决定。若途中出现未授权的新风险、交易或关键选择,停在需要玩家决定的位置。不能把“去找他”扩展成提出新请求、答应他的条件或交出物品;NPC 预设的提议或回应也不授权补出玩家尚未表达的目标与话语。
|
|
192
|
+
|
|
193
|
+
持续互动中,允许开始不等于包办全过程。对方的新话语、动作或感受反馈会影响玩家如何接话、调整或继续时,把回应留给玩家,不必等到关系、目标或风险的重大选择才交还。明确授权略过过程或推进到终点时可以照办,途中新的未授权关键选择仍归玩家。
|
|
192
194
|
|
|
193
195
|
## 哪些可以替玩家演
|
|
194
196
|
|
|
@@ -234,11 +236,13 @@ summary 是目录简介,用于识别文档和判断是否需要读取。只写
|
|
|
234
236
|
|
|
235
237
|
## 保存时机与整理检查点
|
|
236
238
|
|
|
239
|
+
先按玩家授权与互动需要确定本轮叙事范围和停笔位置,再保存该范围内的事实。保存进行中活动的实际进展、必要原话和待回应事项即可整理截至此刻的状态,不把尚未发生的完成结果提前写入。
|
|
240
|
+
|
|
237
241
|
1. 玩家视图实际绑定的当前值改变,本轮终态叙事前写回。等待、赶路、休息或跨日后按世界粒度更新对应现值;绑定标记只说明界面读取范围。
|
|
238
242
|
2. 需要保存但玩家原文和最终叙事没有记录的信息,当轮保存,包括重要场外进展、未表露的认知和隐蔽后果。工具中间文本不能替代持久记录。
|
|
239
243
|
3. 其余可从玩家原文和最终叙事恢复的持续结果,允许事件收尾或合适的中间整理点归并。
|
|
240
244
|
|
|
241
|
-
|
|
245
|
+
按已确定的叙事范围完成本轮必须保存的写入。只有本轮选择登记检查点时,才核对上次检查点后的交互和本轮范围内的结果,补齐必要记录,更新认知、进程、约定和界面值,结束实际已失效的待办并清理重复。整理可以停在活动中途;准备好该停笔位置的记录后登记检查点,再输出最终叙事。检查点覆盖该叙事,若其中又增加重要结果,继续工具调用补齐。正常回复无需登记检查点,登记回执也不是语义完整性认证。
|
|
242
246
|
|
|
243
247
|
## 整理与连续性
|
|
244
248
|
|
|
@@ -283,7 +287,7 @@ The player character's natural sensory and bodily experience may be stated direc
|
|
|
283
287
|
|
|
284
288
|
## Slow down where it matters
|
|
285
289
|
|
|
286
|
-
Let the moment determine pace and length. Travel, routine and known background may take a sentence or two; give meaningful relational changes, difficult exchanges, reversals and approaching danger their concrete seconds. Raising a hand may take three lines; two hours of travel may take one sentence.
|
|
290
|
+
Let the moment determine pace and length. Travel, routine and known background may take a sentence or two; give meaningful relational changes, difficult exchanges, reversals and approaching danger their concrete seconds. Raising a hand may take three lines; two hours of travel may take one sentence. Detailing a few seconds of experience does not mean advancing an entire activity in one reply.
|
|
287
291
|
|
|
288
292
|
Detail adds information: how an action unfolds, a sound changes or attention shifts. Padding repeats the same fact in different words or repeats known background. Do not assign everyone a gesture to fill a fixed length.
|
|
289
293
|
|
|
@@ -297,7 +301,7 @@ In these scenes, the center is not what happened but what the body and mind expe
|
|
|
297
301
|
|
|
298
302
|
## Separate the moment
|
|
299
303
|
|
|
300
|
-
Do not skip the process and state only the conclusion. “You held hands” discards the most valuable part.
|
|
304
|
+
Do not skip the process and state only the conclusion. “You held hands” discards the most valuable part. Detail the moment within this reply's stopping point: the hand crossing the distance, what the fingertips touch, whether the other person meets it or stays still, and the pressure if the grip has closed. A new reaction can leave room to respond; release and further development follow actual authorization and progress.
|
|
301
305
|
|
|
302
306
|
One action may take three or four lines. “Slow” here does not mean dragging; it means fully rendering the few seconds the player cares about.
|
|
303
307
|
|
|
@@ -357,7 +361,7 @@ Avoid modern vocabulary and concepts such as trauma, stress, or social distance.
|
|
|
357
361
|
|
|
358
362
|
## Exchanges
|
|
359
363
|
|
|
360
|
-
Make combat clear without making it tedious: show
|
|
364
|
+
Make combat clear without making it tedious: show authorized moves this turn, how the opponent answers, and how force and position change. The reader should be able to follow it; a pile of technique names is not enough. Leave new responses to the player, and describe the decisive instant when victory or defeat has actually been determined.
|
|
361
365
|
|
|
362
366
|
Follow current world facts and rules for internal force, wounds, weapons and movement techniques. Do not invent decisive premises for a particular victory or defeat.
|
|
363
367
|
|
|
@@ -393,9 +397,9 @@ Do not assess the degree of danger for the player or promise safety in the narra
|
|
|
393
397
|
|
|
394
398
|
Make clear who is where, which way they move, whether a blow lands, and what it costs. An action scene that cannot be followed has not been written.
|
|
395
399
|
|
|
396
|
-
##
|
|
400
|
+
## Follow the action sequence
|
|
397
401
|
|
|
398
|
-
Advance in chronological order
|
|
402
|
+
Advance in chronological order and connect movements clearly. Within the player's authorization and this reply's stopping point, show initiation, the opponent's response, established results and changed position. Leave room when new feedback calls for the player's response. A passage may connect several ordinary actions; it need not contain just one action per reply.
|
|
399
403
|
|
|
400
404
|
Give movement weight and cost. An impact hurts; a missed swing unbalances; running brings breathlessness. Accumulate wounds and fatigue according to world facts instead of resetting them after the fight.
|
|
401
405
|
|
|
@@ -409,7 +413,7 @@ Terrain, furniture, light, and weather can be used or become obstacles. Make the
|
|
|
409
413
|
|
|
410
414
|
## Consequences
|
|
411
415
|
|
|
412
|
-
|
|
416
|
+
Make the situation at this reply's stopping point clear: positions, established wounds, an ongoing exchange and changes awaiting a response. Retain an ongoing situation while victory or defeat remains undecided.
|
|
413
417
|
`,
|
|
414
418
|
"blocks/style-literary.md": `# Style: restraint and negative space
|
|
415
419
|
|
|
@@ -439,7 +443,9 @@ Use few metaphors and make them exact, according to the passage’s needs. Do no
|
|
|
439
443
|
|
|
440
444
|
The player's goals, destination, stance, attitude, promises, giving or accepting, striking or holding back, and consequential choices about relationships, risk or ownership require the player's explicit expression. Do not infer these choices from gestures or bodily reactions.
|
|
441
445
|
|
|
442
|
-
A thought, wish, preparation or prediction is not execution; an attempt is not success. Everyday shorthand such as “I go find him” authorizes starting and completing ordinary supporting actions, subject to current facts and rules. Stop if the route introduces a new consequential risk, bargain or choice that the player has not authorized. Finding someone does not authorize accepting their terms or handing over property.
|
|
446
|
+
A thought, wish, preparation or prediction is not execution; an attempt is not success. Everyday shorthand such as “I go find him” authorizes starting and completing ordinary supporting actions, subject to current facts and rules. Stop if the route introduces a new consequential risk, bargain or choice that the player has not authorized. Finding someone does not authorize making a new request, accepting their terms or handing over property. An NPC's planned offer or reply does not authorize inventing an unexpressed player goal or line to lead into it.
|
|
447
|
+
|
|
448
|
+
In ongoing interaction, permission to start does not authorize the whole activity. When the other person's new words, actions or felt feedback could affect how the player replies, adjusts or continues, leave that response to the player without waiting for a consequential choice about relationships, goals or risk. Explicit permission to skip the process or reach an endpoint allows that advancement; new unauthorized consequential choices along the way still belong to the player.
|
|
443
449
|
|
|
444
450
|
## What may be performed for the player
|
|
445
451
|
|
|
@@ -485,11 +491,13 @@ summary is a catalog description for identifying a document and deciding whether
|
|
|
485
491
|
|
|
486
492
|
## Save timing and consolidation checkpoints
|
|
487
493
|
|
|
494
|
+
First choose this turn's narrative scope and stopping point from player authorization and interaction needs, then save facts within that scope. Recording actual progress in an ongoing activity, necessary exact wording and matters awaiting a response can complete maintenance through this moment without writing unrealized completion outcomes in advance.
|
|
495
|
+
|
|
488
496
|
1. Write changed current values actually selected by player views before this turn's final narrative. After waiting, travel, rest or a day change, update those values at the world's granularity; binding annotations describe read locations only.
|
|
489
497
|
2. Save needed information absent from player originals and final narrative during this turn, including important offstage progress, unexpressed knowledge and hidden consequences. Intermediate tool text is not a durable substitute.
|
|
490
498
|
3. Other durable outcomes recoverable from player originals and final narrative may be consolidated at event closure or a suitable intermediate point.
|
|
491
499
|
|
|
492
|
-
|
|
500
|
+
Complete required writes within the chosen narrative scope. Only if you choose to register a checkpoint this turn, reconcile interactions since the previous checkpoint and outcomes within this turn's scope: fill necessary records, update knowledge, processes, commitments and interface values, close actually expired pending work and remove duplicates. Maintenance can stop during an activity; prepare records for that stopping point, register the checkpoint, then produce final narrative. The checkpoint covers that narrative; if it adds another important outcome, continue tool calls to save it. A normal reply needs no checkpoint, and registration is not certification of semantic completeness.
|
|
493
501
|
|
|
494
502
|
## Maintenance and continuity
|
|
495
503
|
|
|
@@ -22,7 +22,7 @@ export function builtinPlayPrompts(locale) {
|
|
|
22
22
|
|
|
23
23
|
world_patch 的 YAML locator 可以包含 map key 和从零开始的数组下标;remove 删除一个精确位置。未提供的元数据保持原值。world_retire 从目录注入中退役文档,文档仍可读取、引用和恢复。工具响应的成功状态变化与后续最终叙事分别提交,后续失败不回滚已提交变化。成功写入回执表示当前值已改变;以真实回执的结算状态为准,模型文字不能提交世界。
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
包含工具调用的响应属于中间步,其中的文字尚未展示或提交为最终叙事。收到全部工具结果后,根据回执在最终正文中呈现本轮尚未展示的内容,并与已提交状态一致;没有工具调用的非空正文结束本次循环并由 Runtime 提交。world_checkpoint 仅登记整理声明与历史重放边界,在随后非空且无工具调用的最终正文成功提交后生效,边界包含该正文;登记后仍可继续工具调用。正常回复无需检查点,登记不结束世界内事件,也不自动切换上下文,玩家自行选择。全新上下文补入边界后的已提交玩家原文与最终叙事,排除开场白、工具和推理。
|
|
26
26
|
|
|
27
27
|
${historyUseGuidance(locale)}`
|
|
28
28
|
: `# Tools and response settlement
|
|
@@ -31,7 +31,7 @@ Use only attached tools. Directories use @dir-* handles from the preload or tool
|
|
|
31
31
|
|
|
32
32
|
YAML world_patch locators accept map keys and zero-based array indexes; remove deletes one exact location. Omitted metadata remains unchanged. world_retire removes a document from catalog injection while keeping it readable, referenceable and restorable. Successful tool-response state changes and later final narrative commit separately; later failure does not roll back committed changes. Successful write receipts change current values; the actual receipt determines settlement, not model prose.
|
|
33
33
|
|
|
34
|
-
Responses containing tool calls are intermediate steps; their text
|
|
34
|
+
Responses containing tool calls are intermediate steps; their text has not yet been displayed or committed as final narrative. After all tool results, use the receipts to present this turn's still-unshown content in final prose consistent with committed state. A nonempty tool-free response ends this loop and Runtime commits it. world_checkpoint only registers a consolidation declaration and history-replay boundary; it takes effect after the subsequent nonempty tool-free final prose successfully commits, including that prose. Further tool calls may follow registration. Normal replies need no checkpoint; registration neither ends an in-world event nor switches context, which the player chooses. Fresh-context replay contains committed player originals and final narratives after the boundary, excluding the opening, tools and reasoning.
|
|
35
35
|
|
|
36
36
|
${historyUseGuidance(locale)}`,
|
|
37
37
|
},
|