删除旧的事件驱动章节(流水账),并同步文档到人物主线
- 移除 output/volumes/v1/chapters/001-1-9.md 与 002-10-19.md(仅普通提交,git 历史保留) - 移除被取代的写作规范 prompts/chronicler.md 与旧的按年代切章模块 - README 全面改写为人物主线流程、参数位置与踩坑记录 - scripts/dfannals 启动器:自动挑一个装了 defusedxml 的解释器
This commit is contained in:
+5
-3
@@ -135,8 +135,10 @@ def _bio_prompt(world: World, rows: list[CastRow], events: list[Event]) -> str:
|
||||
lines = [BIO_INSTRUCTIONS, "", "材料:"]
|
||||
for row in rows[:BIO_LIMIT]:
|
||||
facts = [
|
||||
f"{row.name}({row.race or '种族不详'},{row.span},本卷出场 {row.appearances} 次,"
|
||||
f"身份:{row.identity or '不详'},在故事里是{row.role})"
|
||||
(
|
||||
f"{row.name}({row.race or '种族不详'},{row.span},本卷出场 {row.appearances} 次,"
|
||||
f"身份:{row.identity or '不详'},在故事里是{row.role})"
|
||||
)
|
||||
]
|
||||
for e in events:
|
||||
if row.fid not in e.figure_ids():
|
||||
@@ -159,7 +161,7 @@ def _parse_bios(raw: str) -> dict[str, str]:
|
||||
except json.JSONDecodeError as exc:
|
||||
raise ValueError(f"小传 JSON 无法解析:{exc}|原文:{raw[:200]}") from None
|
||||
if not isinstance(data, dict):
|
||||
raise ValueError("小传返回的不是对象")
|
||||
raise TypeError("小传返回的不是对象")
|
||||
return {str(k): str(v) for k, v in data.items()}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user