Lorebook Diagnostics
Appearance
Lorebook 诊断页面
[edit | edit source]这个页面用于诊断 Lorebook 系统的问题。
1. 检查扩展
[edit | edit source]访问 Special:Version 查看是否安装了:
- ✓ Scribunto
- ✓ Semantic MediaWiki
2. 检查属性
[edit | edit source]以下属性应该存在:
- Property:Belongs to world
- Property:Parent concept
- Property:Plist
- Property:AliChat
- Property:Primary keys
- Property:Secondary keys
- Property:Key mode
- Property:Logic
- Property:Placement
- Property:Non-recursable
3. 查询概念数量
[edit | edit source]3 个概念已创建
4. 查询 Farlandia 的概念
[edit | edit source]Plist | Primary keys | Key mode | |
---|---|---|---|
Farlandia:Monsters | [Farlandia's monsters: slimes, dragons] | monsters | constant |
Mossford | [Mossford(The town of Moss): town, mossy buildings, moss used for(magic, power), has(tavern, bank, inn, castle), kind people, wealthy] | Mossford,town,moss | conditional |
Slime | [slime: enemy, slimeball, made of gelatin, bounces to move, annoyance] | slime,slimes | conditional |
5. 测试模块调用
[edit | edit source]Test 1: 无参数调用
[edit | edit source]Raw SMW data (first row):
Raw row[1]: Farlandia:Monsters (type: string) Raw row.primary: monsters (type: string) Raw row['Primary keys']: nil (type: nil) All keys in row: [1] = Farlandia:Monsters (type: string) [placement] = after-character (type: string) [mode] = constant (type: string) [primary] = monsters (type: string) [logic] = ANY (type: string) [plist] = [Farlandia's monsters: slimes, dragons] (type: string)
Found concepts:
- Farlandia:Monsters (mode: constant, primary: monsters (type: string))
- Mossford (mode: conditional, primary: Mossford,town,moss (type: string))
- Slime (mode: conditional, primary: slime,slimes (type: string))
Injected concepts:
=== Output ===
[Farlandia's monsters: slimes, dragons] [slime: enemy, slimeball, made of gelatin, bounces to move, annoyance] {{user}}: Slime? {{char}}: "Oh... Those things." She blushes, remembering their first battle.
Test 2: 指定世界但无上下文
[edit | edit source]Raw SMW data (first row):
Raw row[1]: Farlandia:Monsters (type: string) Raw row.primary: monsters (type: string) Raw row['Primary keys']: nil (type: nil) All keys in row: [1] = Farlandia:Monsters (type: string) [placement] = after-character (type: string) [mode] = constant (type: string) [primary] = monsters (type: string) [logic] = ANY (type: string) [plist] = [Farlandia's monsters: slimes, dragons] (type: string)
Found concepts:
- Farlandia:Monsters (mode: constant, primary: monsters (type: string))
- Mossford (mode: conditional, primary: Mossford,town,moss (type: string))
- Slime (mode: conditional, primary: slime,slimes (type: string))
Injected concepts:
=== Output ===
[Farlandia's monsters: slimes, dragons] [slime: enemy, slimeball, made of gelatin, bounces to move, annoyance] {{user}}: Slime? {{char}}: "Oh... Those things." She blushes, remembering their first battle.
Test 3: 指定世界和上下文
[edit | edit source]Raw SMW data (first row):
Raw row[1]: Farlandia:Monsters (type: string) Raw row.primary: monsters (type: string) Raw row['Primary keys']: nil (type: nil) All keys in row: [1] = Farlandia:Monsters (type: string) [placement] = after-character (type: string) [mode] = constant (type: string) [primary] = monsters (type: string) [logic] = ANY (type: string) [plist] = [Farlandia's monsters: slimes, dragons] (type: string)
Found concepts:
- Farlandia:Monsters (mode: constant, primary: monsters (type: string))
- Mossford (mode: conditional, primary: Mossford,town,moss (type: string))
- Slime (mode: conditional, primary: slime,slimes (type: string))
Injected concepts:
=== Output ===
[slime: enemy, slimeball, made of gelatin, bounces to move, annoyance] [Farlandia's monsters: slimes, dragons] {{user}}: Slime? {{char}}: "Oh... Those things." She blushes, remembering their first battle.
Test 4: 完整测试
[edit | edit source]Raw SMW data (first row):
Raw row[1]: Farlandia:Monsters (type: string) Raw row.primary: monsters (type: string) Raw row['Primary keys']: nil (type: nil) All keys in row: [1] = Farlandia:Monsters (type: string) [placement] = after-character (type: string) [mode] = constant (type: string) [primary] = monsters (type: string) [logic] = ANY (type: string) [plist] = [Farlandia's monsters: slimes, dragons] (type: string)
Found concepts:
- Farlandia:Monsters (mode: constant, primary: monsters (type: string))
- Mossford (mode: conditional, primary: Mossford,town,moss (type: string))
- Slime (mode: conditional, primary: slime,slimes (type: string))
Injected concepts:
=== Output ===
[slime: enemy, slimeball, made of gelatin, bounces to move, annoyance] [Mossford(The town of Moss): town, mossy buildings, moss used for(magic, power), has(tavern, bank, inn, castle), kind people, wealthy] [Farlandia's monsters: slimes, dragons] {{user}}: Slime? {{char}}: "Oh... Those things." She blushes, remembering their first battle.
Test 5: 导出 JSON
[edit | edit source]{{#invoke:Lorebook|export|world=Farlandia}}
6. 检查错误
[edit | edit source]✓ 没有错误
7. 列出所有概念页面
[edit | edit source]8. 检查世界页面
[edit | edit source]诊断建议
[edit | edit source]如果上述测试失败,请按以下顺序排查:
- 检查扩展: 确保 Scribunto 和 SMW 已安装
- 创建属性: 手动创建所有必需的 Property 页面
- 重新保存页面: 访问每个概念页面,点击编辑并保存(不修改内容)
- 清除缓存: 在页面 URL 后添加
?action=purge
- 查看日志: 检查 MediaWiki 错误日志
详细说明请参考项目中的 DEBUG_GUIDE.md
文件。