Skip to main content
Glama

novel_delete_book

Preview and delete a selected book's chapters, settings, and linked materials, then restore from Trash or purge permanently.

Instructions

按书删除/清理(含回收站):删掉一本书的正文、创作资料、设定库条目与关联资料(伏笔/设定表/摘要/必用词表/风格基线/分析缓存/改稿与审计报告/风格画像/语义索引,以及旧版本遗留的平铺伏笔表)。默认只预览(列出将清理的位置与体积,不动磁盘),action:"apply" 才执行;keys 可只清理其中几处(例如只清报告历史与缓存、正文留着)。默认移入回收站(数据目录下 trash/,可用 action=restore 原样恢复,action=purge 才彻底删除)。只处理所选书籍:全局词表、插件设置、事件日志与其他书的文件一律不动。

Input Schema

NameRequiredDescriptionDefault
bookNo书名(与 novels/ 下的目录名一致;preview/apply 必填)。
keysNo可选。只清理这些位置(取自 preview 返回的 targets[].key,例如只清 data:audits 与 data:style-reports 就是「只删报告历史」)。省略=全选,即删整本书。apply 时生效。
rootNo章节库根目录(含 novels 子目录)。
actionNopreview=预览将清理的内容(默认,不写盘);apply=执行删除(移入回收站);list=列出回收站条目;restore=从回收站恢复(需 trashId);purge=彻底删除某个回收站条目(需 trashId,不可恢复)。
trashIdNo回收站条目 id(restore/purge 必填,取自 preview/apply 返回的 trashId 或 action=list)。

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv6.9.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does: it discloses that deletion is a two-step preview/apply flow, that data goes to trash/ under the data directory by default, that restore returns it intact, that purge is irreversible, and precisely which directories are untouched. This is exactly the safety context an agent needs before a destructive call.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the default-preview warning and the apply gate, which are the highest-risk facts. The long parenthetical enumeration of artifact types (伏笔/设定表/摘要/必用词表/...) is somewhat dense but does earn its place by telling the agent what data loss to expect.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive multi-mode tool with no annotations and no output schema, the description covers modes, defaults, partial-selection semantics, trash lifecycle, and scope exclusions. Nothing material for correct invocation is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3; the description adds real value by explaining that omitted `keys` means 'select all, i.e. delete the whole book' and that keys come from preview's targets[].key, which the schema only hints at. The action enum semantics are largely duplicated from the schema, keeping this below a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (delete/clean up by book) and enumerates exactly what is removed: body text, creation materials, setting-library entries, and associated artifacts. It also scopes the deletion to a single book, explicitly excluding global word lists, plugin settings, event logs, and other books' files, which no sibling tool does.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states the default mode (preview, no disk writes) and the condition for real deletion (action:"apply"), plus the partial-cleanup path via `keys` with a concrete example (only clearing reports and cache while keeping the body text). It also names the restore/purge alternatives and their irreversibility, leaving nothing to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.