dsh-novel-generator 0.1.37 → 0.1.38

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.
Files changed (2) hide show
  1. package/index.js +10 -8
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -1499,7 +1499,7 @@ async function bootstrap(ctx, root) {
1499
1499
  }
1500
1500
  }
1501
1501
  return {
1502
- revision: '2026-10-28.10',
1502
+ revision: '2026-10-29.1',
1503
1503
  projects,
1504
1504
  models: {
1505
1505
  default: modelCatalog.default || null,
@@ -2017,7 +2017,6 @@ async function updatePreset(ctx, root, body) {
2017
2017
  * the four numbers the outline records, all measured from this one chapter.
2018
2018
  */
2019
2019
  function syncOutlinePrompt(project, chapter, prose) {
2020
- const span = chapterWindow(project, chapter);
2021
2020
  const chars = wordCount(prose);
2022
2021
  const lines = [];
2023
2022
  lines.push('你是这部小说的编辑。作者已经写完了下面这一章,请据此同步它的章节大纲。');
@@ -2026,13 +2025,17 @@ function syncOutlinePrompt(project, chapter, prose) {
2026
2025
  lines.push('');
2027
2026
  lines.push('各项含义:');
2028
2027
  lines.push('- synopsis:这一章的故事梗概,写清起因、经过、转折、结果,供后续章节与世界观使用;300 字以内,纯文本。');
2029
- lines.push(`- durationDays:这段剧情在故事里覆盖的天数,整数 1–365。当前记为第 ${span.start}→${span.end} 天(共 ${span.end - span.start} 天),按正文实际推进判断是否需要改。`);
2028
+ lines.push('- durationDays:这段剧情在故事内部推进了几天,整数 1–365。');
2029
+ lines.push(' 只看正文里的时间线索(清晨到入夜、翌日、过了三日、雨下到第几天……)来数;');
2030
+ lines.push(' 正文没有时间线索时按事件密度估计:一场连续场景通常算 1 天,跨几次昼夜就往上加;');
2031
+ lines.push(' 大多数章节在 1–7 天之间,只有正文明确跨越更久时才写更大的数。');
2032
+ lines.push(' 不要参考任何已有设定或历史记录,完全按这段正文判断,不要沿用「原来记了多少天」。');
2030
2033
  lines.push(`- minWords / maxWords:这一章应有的字数下限与上限,整数;本章正文实际 ${chars} 字,范围应当把 ${chars} 包在里面。`);
2031
2034
  lines.push('- synopsisMinChars:上面这段梗概算「合格」的最低字数,整数 20–400,取梗概长度的八成左右。');
2032
2035
  lines.push('');
2033
- const prelude = preludeBlock(project);
2034
- if (prelude !== '') lines.push(prelude);
2035
- lines.push(`【本章】第 ${chapter.index + 1} 章 ${chapter.title || ''}(第 ${span.start}→${span.end} 天)`);
2036
+ // No time span and no preface here: this is a measurement of the text, and
2037
+ // either would hand the model the answer it is supposed to derive.
2038
+ lines.push(`【本章】第 ${chapter.index + 1} 章 ${chapter.title || ''}`);
2036
2039
  lines.push(`【正文】(共 ${chars} 字,不含空白)`);
2037
2040
  lines.push(prose);
2038
2041
  return lines.join('\n');
@@ -2454,7 +2457,6 @@ const STYLE_MIN_CHARS = 300;
2454
2457
  const STYLE_MAX_CHARS = 600;
2455
2458
 
2456
2459
  function styleExtractPrompt(project, chapter, prose) {
2457
- const span = chapterWindow(project, chapter);
2458
2460
  const lines = [];
2459
2461
  lines.push('你是这部小说的文字编辑。请从下面这段正文里提取这篇小说的行文风格,写成可以直接当作「写作约束」使用的条目。');
2460
2462
  lines.push('');
@@ -2471,7 +2473,7 @@ function styleExtractPrompt(project, chapter, prose) {
2471
2473
  lines.push('- 不要出现「这段文字」「作者」之类的话,也不要评价好坏;');
2472
2474
  lines.push(`- 全文不超过 ${STYLE_MAX_CHARS} 字,宁可少写几条也要写得可执行。`);
2473
2475
  lines.push('');
2474
- lines.push(`【本章】第 ${chapter.index + 1} 章 ${chapter.title || ''}(第 ${span.start}→${span.end} 天)`);
2476
+ lines.push(`【本章】第 ${chapter.index + 1} 章 ${chapter.title || ''}`);
2475
2477
  lines.push('【正文】');
2476
2478
  lines.push(prose);
2477
2479
  return lines.join('\n');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-novel-generator",
3
- "version": "0.1.37",
3
+ "version": "0.1.38",
4
4
  "type": "module",
5
5
  "description": "Novel studio for DeepSeek Harness: a draggable story timeline, world snapshots, chapter outlines, and chapters written by the work's own agent.",
6
6
  "license": "MIT",