Preface¶
When writing long-form web novels extending to hundreds of chapters, the common challenges are no longer just about “can I generate a plot segment,” but whether the settings are still intact, whether foreshadowing is remembered, whether the outline is adhered to, and whether promises made to readers are tracked. dsh-tool-writing is a plugin for the DeepSeek Harness (DSH) long-form web novel writing engine, breaking these issues down into tool calls, ledger records, review checkpoints, and retrieval processes.
This document introduces what problems it solves, what verified capabilities it offers, and how to install and enable it.
What It Is¶
dsh-tool-writing is maintained by x2802490130-prog under the MIT license.
Its one-sentence positioning is: a long-form web novel creation system that turns “long-form consistency” into engineering—even after hundreds of chapters, it remembers settings, follows through on foreshadowing, and adheres to the outline; after each chapter is written, facts are automatically logged, and promises to readers are automatically tracked.
It provides long-form web novel writing capabilities for DSH and uses an independent DeepSeek key to handle subthreads, task distribution, multi-threaded generation and retrieval tasks. The plugin offers a novel_* toolset, with the README noting 48 tools.
Core Capabilities¶
Multi-Book Isolation¶
The plugin organizes projects by “one workspace = one book” and binds workspaces to sessions. This allows maintaining multiple books within the same host environment, reducing interference between project states.
Independent Key and Task Distribution¶
The plugin uses a DeepSeek key independent of the main Agent to handle subthreads, task distribution, multi-threaded generation and retrieval tasks.
Verified key configurations include:
- Main key:
DSH_WRITING_API_KEY, required. - Draft channel:
DSH_WRITING_DRAFT_KEY, optional, falls back to main key. - Polish channel:
DSH_WRITING_POLISH_KEY, optional, falls back to main key. - Sync/deep task channel:
DSH_WRITING_SYNC_KEY, optional, falls back to main key.
All credentials are injected via host environment variables, with no hardcoded keys in the code.
Flexible Contract System¶
The verified flexible contract system includes:
- Story promise letter
- Canon ledger
- Five-stage writing task document
- Hard checkpoints
The goal of this system is to break down “whole book promises, written facts, writing tasks, and post-writing checks” into executable steps, rather than relying solely on one-time prompts to maintain long-form consistency.
Post-Chapter Health Check and Pre-Publication Review¶
Verified review capabilities include:
- Post-chapter eight-item health check, including rhythm signals and AI flavor check.
- Dual-platform review for Qidian and Tomato.
- Pre-publication sensitive content self-check.
Retrieval and Book Library¶
Verified retrieval and book library capabilities include:
- Semantic retrieval
- Pure concept vector retrieval
- Concept index construction
- Feed area book library management: import, list, read, delete, retrieval, and deconstruction
Semantic retrieval uses DeepSeek concept index, requiring no third-party embedding key; if an effective embedApiKey is explicitly configured, dense vectors can still be used.
Installation and Enabling¶
1. Install the Plugin¶
First, execute the plugin installation command:
dsh plugin --profile web add dsh-tool-writing
After installation, restart the harness.
2. Mount to Writing Preset¶
Mount the plugin in the writing preset’s agent.cordis.yml. The following code block lists the verified configuration keys; fill in the specific model and concurrency according to the actual environment:
- id: tool-writing
name: 'dsh-tool-writing'
config:
apiKeyEnv: DSH_WRITING_API_KEY
model: <fill in available model>
deepModel: <fill in available model>
maxConcurrency: <fill in concurrency>
This step enables the writing session to call the novel_* tools provided by dsh-tool-writing.
3. Configure DeepSeek Key¶
Main key required:
DSH_WRITING_API_KEY=...
Optional split channel keys:
DSH_WRITING_DRAFT_KEY=...
DSH_WRITING_POLISH_KEY=...
DSH_WRITING_SYNC_KEY=...
If optional keys are not configured, they fall back to the main key.
4. Verify Installation¶
After entering the writing session, send:
novel_status
This tool is used to verify successful installation.
Typical Usage¶
Starting a Book¶
The basic process is as follows:
- Create a new workspace. One workspace corresponds to one book.
- Guide the book start through
novel_brief. - Use
novel_initto build the skeleton. - Use
novel_outlineto construct the outline. - Use
novel_loreto establish settings. - Use
novel_draftto write the first chapter.
Serialized Maintenance¶
After each chapter is written, you can perform the following arrangements:
- Execute
novel_syncfor automatic arrangement. - Periodically execute
novel_auditfor the eight-item health check. - Execute
novel_ledger scanto check reading retention.
Pre-Publication Review¶
Before publication, you can use:
novel_marketfor dual-platform review on Qidian and Tomato.novel_censorfor sensitive content self-check.
Retrieval and Book Library¶
You can use the plugin’s semantic retrieval, pure concept vector retrieval, and concept index construction capabilities to search the current project and feed area book library. The feed area book library supports import, list, read, delete, retrieval, and deconstruction.
Environment and Dependencies¶
The dependencies declared in package.json are as follows:
{
"engines": {
"node": ">=22.5.0"
},
"peerDependencies": {
"@deepseek-ai/cordis": "^4.0.1",
"@deepseek-ai/dsh-tools": "^0.1.0-rc.6",
"@deepseek-ai/schemastery": "^3.18.1"
}
}
Applicable Scenarios and Notes¶
Suitable usage scenarios:
- Need to write long-form web novels in DSH.
- Need to maintain multiple books simultaneously with workspace isolation.
- Need to incorporate settings, foreshadowing, outlines, and promises into a tool-based process.
- Need to perform platform review and sensitive content self-check before publication.
- Need to import existing book libraries for retrieval or deconstruction.
Notes before use:
- The plugin runs its code with the current DSH process permissions; check the source code and license before installation.
- The plugin requires a DeepSeek key independent of the main Agent; the main key is required, while other channel keys are optional and fall back to the main key.
- The repository’s
.gitignoreexcludes all project data files; content is not uploaded, and feeds are provided by plugin users themselves. - There are no hardcoded keys in the code; all credentials are injected via host environment variables.
- Semantic retrieval defaults to using the DeepSeek concept index, requiring no third-party embedding key; if an effective
embedApiKeyis explicitly configured, dense vectors can still be used. - The license is MIT.
Resources¶
GitHub repository:
https://github.com/x2802490130-prog/dsh-tool-writing
Currently verified materials do not provide a directory page URL, so no unverified directory page links are included in this document.