@dsh-agentic-roleplay/core 0.7.2 → 0.7.3
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/README.md +1 -1
- package/lib/{authoring-tools-q34iq3hW.js → authoring-tools-CIsWbq0B.js} +197 -20
- package/lib/authoring.js +251 -331
- package/lib/client.js +613 -331
- package/lib/client.js.map +1 -1
- package/lib/doctor.js +1 -1
- package/lib/{gallery-BxZGOgMb.js → gallery-DmBZ2L5l.js} +2 -2
- package/lib/{generator-BFmSYvR8.js → generator-BmdoTIL2.js} +2 -2
- package/lib/{hooks-HnqXO8mM.js → hooks-C8eELrni.js} +2 -2
- package/lib/images.js +4 -4
- package/lib/index.js +70 -563
- package/lib/{library-BGxPKs9a.js → library-lVNf9qG_.js} +37 -4
- package/lib/{lorebook-author-tools-D9RrMK5g.js → lorebook-author-tools-BDOs4i5C.js} +6 -6
- package/lib/lorebook-authoring.js +3 -3
- package/lib/orchestration.js +8 -8
- package/lib/{pack-jail-MPekqSuQ.js → pack-jail-DeTscGT2.js} +1255 -12
- package/lib/{packs-jowC-MN_.js → packs-CY8ms8v_.js} +2 -2
- package/lib/{presenter-agent-DvZtnf0Q.js → presenter-agent-cFR4sos3.js} +4 -4
- package/lib/{preset-author-tools-8kv1Glxe.js → preset-author-tools-2m4BLtws.js} +6 -6
- package/lib/preset-authoring.js +4 -4
- package/lib/{preset-VatN-845.js → preset-n4-j6k4S.js} +2 -2
- package/lib/{reflection-CvOZGjmn.js → reflection-CJB5s0ip.js} +6 -6
- package/lib/{route-DRTJ_vcA.js → route-C6SHz9j2.js} +2 -2
- package/lib/{text-JbWfTHbr.js → text-Cwl5s0j0.js} +3 -1
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { W as Reader } from "./hooks-
|
|
1
|
+
import { W as Reader } from "./hooks-C8eELrni.js";
|
|
2
2
|
import { dirname, extname, join, posix, sep } from "node:path";
|
|
3
3
|
import { copyFileSync, cpSync, existsSync, lstatSync, mkdirSync, readFileSync, readdirSync, renameSync } from "node:fs";
|
|
4
4
|
import { createHash } from "node:crypto";
|
|
@@ -840,4 +840,4 @@ function anyTab(bases) {
|
|
|
840
840
|
//#endregion
|
|
841
841
|
export { API_PREFIX as _, packIds as a, describePack as c, packPath as d, readPack as f, SURFACE_NAMES as g, PACK_MEDIA_TYPES as h, inheritPacks as i, isPackId as l, PACK_LIMITS as m, anyTab as n, syncWorldPacks as o, PACK_ACTIONS as p, copyWorldPacks as r, worldPackStates as s, activePack as t, packFile as u };
|
|
842
842
|
|
|
843
|
-
//# sourceMappingURL=packs-
|
|
843
|
+
//# sourceMappingURL=packs-CY8ms8v_.js.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { t as promptFor } from "./access-DtOxFKBK.js";
|
|
2
2
|
import { c as runChild } from "./child-CyCViUKa.js";
|
|
3
|
-
import { c as
|
|
4
|
-
import { n as generateTransientImage, t as generateReferenceImage } from "./generator-
|
|
5
|
-
import { i as updateImage, n as galleryFile, r as listGallery } from "./gallery-
|
|
3
|
+
import { c as nextSceneSerial, u as referenceImagePath } from "./library-lVNf9qG_.js";
|
|
4
|
+
import { n as generateTransientImage, t as generateReferenceImage } from "./generator-BmdoTIL2.js";
|
|
5
|
+
import { i as updateImage, n as galleryFile, r as listGallery } from "./gallery-DmBZ2L5l.js";
|
|
6
6
|
import { dirname, join, relative } from "node:path";
|
|
7
7
|
import { existsSync } from "node:fs";
|
|
8
8
|
import { createHash, randomUUID } from "node:crypto";
|
|
@@ -852,4 +852,4 @@ async function runImagePresenter(job) {
|
|
|
852
852
|
//#endregion
|
|
853
853
|
export { tokensOf as a, searchImages as i, interpretImage as n, present as o, imageTools as r, presentedFor as s, runImagePresenter as t };
|
|
854
854
|
|
|
855
|
-
//# sourceMappingURL=presenter-agent-
|
|
855
|
+
//# sourceMappingURL=presenter-agent-cFR4sos3.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "./access-DtOxFKBK.js";
|
|
2
|
-
import {
|
|
3
|
-
import { C as readWorldPrompt, S as listWorldPrompts, b as PROSE_PROMPTS, h as readPreset, m as presetDirectory, s as PRESET_FILE, w as writeWorldPrompt, x as deleteWorldPrompt, y as updatePresetInfo } from "./route-
|
|
4
|
-
import { Q as languageOf, nt as shippedPromptsDirectory, tt as shippedLanguages } from "./hooks-
|
|
5
|
-
import { i as translator, r as languageOf$1 } from "./text-
|
|
6
|
-
import { n as readPreset$1 } from "./preset-
|
|
2
|
+
import { Dt as IMPORT_FOLDER, ct as extractStyleFrom, i as contextOf, mt as withPlayer } from "./authoring-tools-CIsWbq0B.js";
|
|
3
|
+
import { C as readWorldPrompt, S as listWorldPrompts, b as PROSE_PROMPTS, h as readPreset, m as presetDirectory, s as PRESET_FILE, w as writeWorldPrompt, x as deleteWorldPrompt, y as updatePresetInfo } from "./route-C6SHz9j2.js";
|
|
4
|
+
import { Q as languageOf, nt as shippedPromptsDirectory, tt as shippedLanguages } from "./hooks-C8eELrni.js";
|
|
5
|
+
import { i as translator, r as languageOf$1 } from "./text-Cwl5s0j0.js";
|
|
6
|
+
import { n as readPreset$1 } from "./preset-n4-j6k4S.js";
|
|
7
7
|
import { join } from "node:path";
|
|
8
8
|
import { existsSync } from "node:fs";
|
|
9
9
|
import { defineTool } from "@deepseek-ai/dsh-tools";
|
|
@@ -280,4 +280,4 @@ async function presetApproval(exec, next, carries) {
|
|
|
280
280
|
//#endregion
|
|
281
281
|
export { presetChatSessionId as a, presetAuthorTools as i, narrationImportMessage as n, presetOfChat as o, presetApproval as r, PresetReader as t };
|
|
282
282
|
|
|
283
|
-
//# sourceMappingURL=preset-author-tools-
|
|
283
|
+
//# sourceMappingURL=preset-author-tools-2m4BLtws.js.map
|
package/lib/preset-authoring.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { n as limitAuthoringAgents } from "./authoring-tools-
|
|
2
|
-
import { i as presetAuthorTools, o as presetOfChat, r as presetApproval, t as PresetReader } from "./preset-author-tools-
|
|
3
|
-
import { m as presetDirectory } from "./route-
|
|
4
|
-
import "./hooks-
|
|
1
|
+
import { n as limitAuthoringAgents } from "./authoring-tools-CIsWbq0B.js";
|
|
2
|
+
import { i as presetAuthorTools, o as presetOfChat, r as presetApproval, t as PresetReader } from "./preset-author-tools-2m4BLtws.js";
|
|
3
|
+
import { m as presetDirectory } from "./route-C6SHz9j2.js";
|
|
4
|
+
import "./hooks-C8eELrni.js";
|
|
5
5
|
import { t as guardAuthoringTurns } from "./turn-guard-BvCs1VxB.js";
|
|
6
6
|
import { join } from "node:path";
|
|
7
7
|
import { existsSync } from "node:fs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { dt as cleanText, r as MAX_PREVIEW_TEXT, un as ImportCardError } from "./authoring-tools-CIsWbq0B.js";
|
|
2
2
|
import { l as SAMPLING_RANGES } from "./child-CyCViUKa.js";
|
|
3
3
|
//#region src/host/import/preset.ts
|
|
4
4
|
/** The older preset layout keeps its texts under fixed keys. */
|
|
@@ -239,4 +239,4 @@ function selectPrompts(file, enabled, keepSampling) {
|
|
|
239
239
|
//#endregion
|
|
240
240
|
export { readPreset as n, selectPrompts as r, previewPreset as t };
|
|
241
241
|
|
|
242
|
-
//# sourceMappingURL=preset-
|
|
242
|
+
//# sourceMappingURL=preset-n4-j6k4S.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { o as roleplaySessionOf, t as promptFor } from "./access-DtOxFKBK.js";
|
|
2
|
-
import { a as routeVerdicts, f as listPresets, i as noAt, n as askYesNo, o as yesAt, p as loadPreset, r as mergeReports, t as announceProblem, v as sha } from "./route-
|
|
3
|
-
import { A as answerLimits, D as describeWhen, E as describeTime, J as PROMPTS_FOLDER, R as wrongLanguage, Z as inheritPrompts } from "./hooks-
|
|
4
|
-
import { i as translator, r as languageOf, t as trimCharacters } from "./text-
|
|
2
|
+
import { a as routeVerdicts, f as listPresets, i as noAt, n as askYesNo, o as yesAt, p as loadPreset, r as mergeReports, t as announceProblem, v as sha } from "./route-C6SHz9j2.js";
|
|
3
|
+
import { A as answerLimits, D as describeWhen, E as describeTime, J as PROMPTS_FOLDER, R as wrongLanguage, Z as inheritPrompts } from "./hooks-C8eELrni.js";
|
|
4
|
+
import { i as translator, r as languageOf, t as trimCharacters } from "./text-Cwl5s0j0.js";
|
|
5
5
|
import { a as childTrace, c as runChild, n as childModel, r as childSampling, v as estimateAnswer } from "./child-CyCViUKa.js";
|
|
6
|
-
import {
|
|
7
|
-
import { i as inheritPacks } from "./packs-
|
|
6
|
+
import { s as inheritImages } from "./library-lVNf9qG_.js";
|
|
7
|
+
import { i as inheritPacks } from "./packs-CY8ms8v_.js";
|
|
8
8
|
import { dirname, join } from "node:path";
|
|
9
9
|
import { copyFileSync, existsSync, mkdirSync, readFileSync, renameSync, rmSync, writeFileSync } from "node:fs";
|
|
10
10
|
import { createUserMessage } from "@deepseek-ai/dsh-llm";
|
|
@@ -2039,4 +2039,4 @@ function memoryReflector(deps) {
|
|
|
2039
2039
|
//#endregion
|
|
2040
2040
|
export { referent as _, whereabouts as a, copyPreset as c, switchPreset as d, readTimeline as f, sameWords as g, defaultBoundaries as h, reflectionStatus as i, presetStatus as l, pathTo as m, memoryReflector as n, TimelineError as o, writeTimeline as p, recordFailure as r, Timelines as s, dueReflection as t, recordPreset as u };
|
|
2041
2041
|
|
|
2042
|
-
//# sourceMappingURL=reflection-
|
|
2042
|
+
//# sourceMappingURL=reflection-CJB5s0ip.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./narration-DvFBqmqe.js";
|
|
2
|
-
import { $ as listFiles, J as PROMPTS_FOLDER, Q as languageOf, et as promptProblem, nt as shippedPromptsDirectory, q as LANGUAGE_FOLDER, tt as shippedLanguages } from "./hooks-
|
|
2
|
+
import { $ as listFiles, J as PROMPTS_FOLDER, Q as languageOf, et as promptProblem, nt as shippedPromptsDirectory, q as LANGUAGE_FOLDER, tt as shippedLanguages } from "./hooks-C8eELrni.js";
|
|
3
3
|
import { u as parseSampling } from "./child-CyCViUKa.js";
|
|
4
4
|
import { dirname, join } from "node:path";
|
|
5
5
|
import { existsSync, readFileSync, readdirSync } from "node:fs";
|
|
@@ -515,4 +515,4 @@ function mergeReports(mode, reports) {
|
|
|
515
515
|
//#endregion
|
|
516
516
|
export { readWorldPrompt as C, INTENT_TYPES as D, INTENT_STATUSES as E, listWorldPrompts as S, INTENT_HORIZONS as T, savePresetFromWorld as _, routeVerdicts as a, PROSE_PROMPTS as b, createPresetFromGuidance as c, isPresetName as d, listPresets as f, reservePreset as g, readPreset as h, noAt as i, createPresetFromShipped as l, presetDirectory as m, askYesNo as n, yesAt as o, loadPreset as p, mergeReports as r, PRESET_FILE as s, announceProblem as t, deletePreset as u, sha as v, writeWorldPrompt as w, deleteWorldPrompt as x, updatePresetInfo as y };
|
|
517
517
|
|
|
518
|
-
//# sourceMappingURL=route-
|
|
518
|
+
//# sourceMappingURL=route-C6SHz9j2.js.map
|
|
@@ -216,6 +216,8 @@ const ZH = {
|
|
|
216
216
|
"## MCP resource servers\n\nUse {tools} with one of these names as the server argument: {servers}.": "## MCP 资源服务器\n\n使用 {tools},server 参数填下列名称之一:{servers}。",
|
|
217
217
|
"{where}: the text is longer than {max} characters. A belief is not rewritten to hold what speaks against it: leave the text out and list the belief under doubt with the numbers of what speaks against it, and put what was learned as a new belief of its own": "{where}:文字超过 {max} 个字符。不要通过改写信念来容纳与之相悖的事:不要写文字,把这条信念列入 doubt 并给出与之相悖的编号;新了解到的内容另写成一条新信念",
|
|
218
218
|
"Import this card into this newly created world.": "把这张卡片导入这个新建的世界。",
|
|
219
|
+
"The character card this world was made from has a newer version, kept in this world's .import/update folder. Bring the world up to date with it. First call card_diff: it lists what changed between the two versions, which characters, places and things were made from each changed piece, and which files of the world have been edited since the import. Read the pieces you need with card_read (version current is the old card, version new is the new one). Then change only what the new card changed, with your editing tools, and keep what the person has edited since the import. What the card says about the world itself (its description, tags and opening) is changed with edit_world_info. Remove what only a dropped piece made unless the person edited it. Do not add what neither version of the card says. When the world matches the new card, call card_update_finish, then tell me briefly what you changed, what you left alone and why.": "这个世界所依据的角色卡有了新版本,放在这个世界的 .import/update 文件夹里。请让世界与它保持一致。先调用 card_diff:它会列出两个版本之间的变化、每个变化的片段生成了哪些角色、地点和物品,以及导入之后世界里哪些文件被修改过。需要时用 card_read 读取片段(version 为 current 是旧卡,为 new 是新卡)。然后用你的编辑工具只改新卡改动的部分,并保留用户在导入之后做的修改。卡片对世界本身的描述(简介、标签和开场)用 edit_world_info 修改。只由已被删除的片段生成、且用户没有改过的内容,要移除。两个版本的卡都没有写的内容,一概不要添加。世界与新卡一致后,调用 card_update_finish,再简要告诉我:你改了什么、哪些没动以及原因。",
|
|
220
|
+
"The update from the newer card is not finished. Apply the changes that remain and call card_update_finish. A change you cannot make with your tools, or one you need the person to decide, goes in your report instead; then say what is left.": "按新卡更新还没有完成。请应用剩下的改动,然后调用 card_update_finish。你的工具做不了的改动,或需要用户决定的改动,写进报告里;然后说明还剩什么。",
|
|
219
221
|
"Turn the SillyTavern lorebook I uploaded into this lorebook: call {tool} with file {file}.": "把我上传的 SillyTavern 世界书转成这本世界书:调用 {tool},文件为 {file}。",
|
|
220
222
|
"Turn the SillyTavern preset I uploaded into this preset's prompts: call {tool} with file {file}.": "把我上传的 SillyTavern 预设转成这个预设的提示词:调用 {tool},文件为 {file}。",
|
|
221
223
|
"Apply the narration preset I uploaded to this world: call {tool} with file {file}.": "把我上传的叙述预设应用到这个世界:调用 {tool},文件为 {file}。",
|
|
@@ -292,4 +294,4 @@ function withoutExtension(value) {
|
|
|
292
294
|
//#endregion
|
|
293
295
|
export { translator as i, withoutExtension as n, languageOf as r, trimCharacters as t };
|
|
294
296
|
|
|
295
|
-
//# sourceMappingURL=text-
|
|
297
|
+
//# sourceMappingURL=text-Cwl5s0j0.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dsh-agentic-roleplay/core",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.3",
|
|
4
4
|
"description": "Core plugin of the agentic roleplay bundle for DeepSeek Harness: roleplay UI, orchestration and storage.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Firefox2100",
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"@deepseek-ai/schemastery": "^3.18.5"
|
|
77
77
|
},
|
|
78
78
|
"dependencies": {
|
|
79
|
-
"@dsh-agentic-roleplay/state": "0.7.
|
|
79
|
+
"@dsh-agentic-roleplay/state": "0.7.3",
|
|
80
80
|
"@dsh-ai-providers/core": "^0.5.0"
|
|
81
81
|
},
|
|
82
82
|
"devDependencies": {
|