@dsh-agentic-roleplay/core 0.1.0 → 0.2.1
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/{notes-CJzbN_-E.js → activity-t7OBgHlc.js} +267 -47
- package/lib/authoring.js +295 -14
- package/lib/client.js +2599 -648
- package/lib/client.js.map +1 -1
- package/lib/compaction.js +1 -1
- package/lib/{documents-BBq88wXP.js → documents-Bu5uYRZB.js} +54 -33
- package/lib/{gallery-CjG9_4Sz.js → gallery-DUeBMHQX.js} +2 -2
- package/lib/{generator-pxZS-pu-.js → generator-HPifO3Kk.js} +211 -15
- package/lib/images.js +3 -3
- package/lib/index.js +849 -20
- package/lib/{narration-tYy6Rkfr.js → narration-BRyHU0H2.js} +28 -5
- package/lib/orchestration.js +803 -233
- package/lib/packs-ByP1J-zj.js +1334 -0
- package/lib/{presenter-agent-DbZALurg.js → presenter-agent-G43ODV8I.js} +3 -3
- package/package.json +5 -3
- package/prompts/en/roleplay/ask-answerer.md +3 -0
- package/prompts/en/roleplay/ask-question.md +2 -0
- package/prompts/en/roleplay/character-decide.md +1 -1
- package/prompts/en/roleplay/character-lookup.md +1 -1
- package/prompts/en/roleplay/faction-strategist.md +5 -0
- package/prompts/en/roleplay/game-master.md +5 -1
- package/prompts/en/roleplay/ooc-empty.md +1 -1
- package/prompts/en/roleplay/trigger-judge.md +3 -0
- package/prompts/en/world/procedure.md +1 -1
- package/prompts/zh/roleplay/ask-answerer.md +3 -0
- package/prompts/zh/roleplay/ask-question.md +2 -0
- package/prompts/zh/roleplay/character-decide.md +1 -1
- package/prompts/zh/roleplay/character-lookup.md +1 -1
- package/prompts/zh/roleplay/faction-strategist.md +5 -0
- package/prompts/zh/roleplay/game-master.md +5 -1
- package/prompts/zh/roleplay/ooc-empty.md +1 -1
- package/prompts/zh/roleplay/trigger-judge.md +3 -0
- package/prompts/zh/world/procedure.md +1 -1
- package/starter-worlds/blackwater-observatory/characters/arthur-moore/character.json +65 -0
- package/starter-worlds/blackwater-observatory/characters/clara-whitlock/character.json +87 -0
- package/starter-worlds/blackwater-observatory/characters/eleanor-graves/character.json +80 -0
- package/starter-worlds/blackwater-observatory/characters/marcus-reed/character.json +73 -0
- package/starter-worlds/blackwater-observatory/items/anonymous-letter/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/brass-laboratory-key/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/claras-gossip-notebook/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/harlans-notebook/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/investigators-coat/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/investigators-notebook/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/locked-filing-cabinet/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/marcus-calibration-notes/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/mayors-administrative-seal/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/municipal-lockbox/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/pocket-revolver/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/room-7-cash-receipt/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/rusting-mine-cart/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/signal-recording-strip/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/silver-pocket-watch/item.json +9 -0
- package/starter-worlds/blackwater-observatory/items/survey-archive-cabinet/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/surveyors-map/item.json +10 -0
- package/starter-worlds/blackwater-observatory/items/unknown-visitors-note-fragment/item.json +10 -0
- package/starter-worlds/blackwater-observatory/locations/blackwater-ridge/location.json +5 -0
- package/starter-worlds/blackwater-observatory/locations/iron-stag-bar/location.json +30 -0
- package/starter-worlds/blackwater-observatory/locations/iron-stag-room-7/location.json +18 -0
- package/starter-worlds/blackwater-observatory/locations/north-forest-cabin/location.json +18 -0
- package/starter-worlds/blackwater-observatory/locations/observatory-directors-office/location.json +20 -0
- package/starter-worlds/blackwater-observatory/locations/observatory-telescope-chamber/location.json +25 -0
- package/starter-worlds/blackwater-observatory/locations/old-mine-entrance/location.json +27 -0
- package/starter-worlds/blackwater-observatory/locations/old-mine-main-tunnel/location.json +13 -0
- package/starter-worlds/blackwater-observatory/locations/town-hall-mayors-office/location.json +25 -0
- package/starter-worlds/blackwater-observatory/locations/town-hall-records-room/location.json +13 -0
- package/starter-worlds/blackwater-observatory/locations/town-square/location.json +30 -0
- package/starter-worlds/blackwater-observatory/triggers.json +20 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/map.html +12 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/map.js +40 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/notebook.html +29 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/notebook.js +45 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/pack.json +31 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/skin.css +16 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/strip.html +11 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/strip.js +12 -0
- package/starter-worlds/blackwater-observatory/ui/notebook/style.css +23 -0
- package/starter-worlds/blackwater-observatory/variables.json +39 -0
- package/starter-worlds/blackwater-observatory/world.json +27 -0
- package/lib/worlds-Bj-EGS_i.js +0 -478
|
@@ -54,9 +54,12 @@ const SETTINGS_SPEC = {
|
|
|
54
54
|
flaky: flag(true),
|
|
55
55
|
recall: integer(1, 30, 12),
|
|
56
56
|
lookup: flag(true),
|
|
57
|
+
lookupCalls: integer(1, 20, 5),
|
|
57
58
|
verify: flag(true),
|
|
58
59
|
backlogRounds: integer(1, 100, 6),
|
|
59
|
-
overRetrieve: integer(1, 10, 4)
|
|
60
|
+
overRetrieve: integer(1, 10, 4),
|
|
61
|
+
associate: integer(0, 10, 2),
|
|
62
|
+
diversity: ratio(0, 1, .3)
|
|
60
63
|
},
|
|
61
64
|
context: {
|
|
62
65
|
limitTokens: integer(0, 1e6, 0),
|
|
@@ -77,28 +80,45 @@ const SETTINGS_SPEC = {
|
|
|
77
80
|
roundSeconds: integer(0, 3600, 30),
|
|
78
81
|
maxSkipDays: integer(1, 3650, 30)
|
|
79
82
|
},
|
|
83
|
+
diagnostics: { keepRuns: flag(false) },
|
|
80
84
|
offstage: {
|
|
81
85
|
perTurn: integer(0, 5, 2),
|
|
82
86
|
perCharacter: integer(1, 3, 1),
|
|
87
|
+
joint: flag(true),
|
|
83
88
|
summary: flag(true)
|
|
84
89
|
},
|
|
85
90
|
sampling: {
|
|
86
91
|
master: ratio(0, 2, .7),
|
|
87
92
|
characters: ratio(0, 2, .8),
|
|
88
|
-
suggestions: ratio(0, 2, .
|
|
93
|
+
suggestions: ratio(0, 2, .2),
|
|
89
94
|
authoring: ratio(0, 2, .4),
|
|
90
95
|
records: ratio(0, 2, .1),
|
|
91
96
|
tools: choice(["auto", "required"], "required"),
|
|
92
|
-
maxTokens: integer(256, 64e3, 8e3)
|
|
97
|
+
maxTokens: integer(256, 64e3, 8e3),
|
|
98
|
+
shortMaxTokens: integer(256, 64e3, 2e3),
|
|
99
|
+
headroom: ratio(1, 10, 2)
|
|
93
100
|
},
|
|
94
101
|
prompts: { language: text(8, "en") },
|
|
95
102
|
reasoning: { children: text(40, "") },
|
|
103
|
+
factions: {
|
|
104
|
+
perTurn: integer(0, 3, 1),
|
|
105
|
+
everyDays: integer(1, 365, 3)
|
|
106
|
+
},
|
|
107
|
+
models: {
|
|
108
|
+
characters: text(200, ""),
|
|
109
|
+
background: text(200, ""),
|
|
110
|
+
records: text(200, ""),
|
|
111
|
+
suggestions: text(200, ""),
|
|
112
|
+
authoring: text(200, "")
|
|
113
|
+
},
|
|
96
114
|
triggers: {
|
|
97
115
|
enabled: flag(true),
|
|
98
116
|
maxFires: integer(1, 10, 3),
|
|
99
117
|
beatTurns: integer(1, 20, 3),
|
|
100
|
-
cueTurns: integer(1, 20, 2)
|
|
118
|
+
cueTurns: integer(1, 20, 2),
|
|
119
|
+
judgedPerTurn: integer(0, 5, 2)
|
|
101
120
|
},
|
|
121
|
+
interface: { pack: text(60, "") },
|
|
102
122
|
rewind: { keepSnapshots: integer(0, 500, 30) },
|
|
103
123
|
rules: { own: text(MAX_OWN_RULES, "") },
|
|
104
124
|
preview: { enabled: flag(true) },
|
|
@@ -137,6 +157,8 @@ function isTimeZone(zone) {
|
|
|
137
157
|
return false;
|
|
138
158
|
}
|
|
139
159
|
}
|
|
160
|
+
/** A model as `provider/model`: both parts present, no spaces. */
|
|
161
|
+
const MODEL_NAME = /^[^\s/]+\/\S+$/;
|
|
140
162
|
const OPTION_NAME = /^[A-Za-z][A-Za-z0-9_]{0,39}$/;
|
|
141
163
|
/** The options, or what is wrong with them. */
|
|
142
164
|
function parseOptions(value, name) {
|
|
@@ -188,6 +210,7 @@ function parseSettings(value) {
|
|
|
188
210
|
const parsed = parseLevel(SETTINGS_SPEC, value, "", problems);
|
|
189
211
|
const zone = parsed["clock"]?.timeZone;
|
|
190
212
|
if (typeof zone === "string" && zone !== "" && !isTimeZone(zone)) problems.push(`"clock.timeZone" is not a time zone this system knows: write it like Europe/London or UTC`);
|
|
213
|
+
for (const [kind, name] of Object.entries(parsed["models"] ?? {})) if (typeof name === "string" && name !== "" && !MODEL_NAME.test(name)) problems.push(`"models.${kind}" must be written provider/model, for example localai/qwen`);
|
|
191
214
|
return problems.length > 0 ? {
|
|
192
215
|
ok: false,
|
|
193
216
|
problems
|
|
@@ -332,4 +355,4 @@ function decodeOutput(text) {
|
|
|
332
355
|
//#endregion
|
|
333
356
|
export { liveSettings as a, writeSettings as c, parseSettings as d, WORLD_RULES_KEY as f, InvalidSettingsError as i, DEFAULT_SETTINGS as l, encodeOutput as n, readSettings as o, rulesOf as p, encodePreview as r, useChildReasoning as s, decodeOutput as t, SETTINGS_SPEC as u };
|
|
334
357
|
|
|
335
|
-
//# sourceMappingURL=narration-
|
|
358
|
+
//# sourceMappingURL=narration-BRyHU0H2.js.map
|