DSH Tool Writing: A DSH Plugin for Engineering Consistency in Long-Form Web Articles

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:

  1. Create a new workspace. One workspace corresponds to one book.
  2. Guide the book start through novel_brief.
  3. Use novel_init to build the skeleton.
  4. Use novel_outline to construct the outline.
  5. Use novel_lore to establish settings.
  6. Use novel_draft to write the first chapter.

Serialized Maintenance

After each chapter is written, you can perform the following arrangements:

  1. Execute novel_sync for automatic arrangement.
  2. Periodically execute novel_audit for the eight-item health check.
  3. Execute novel_ledger scan to check reading retention.

Pre-Publication Review

Before publication, you can use:

  1. novel_market for dual-platform review on Qidian and Tomato.
  2. novel_censor for 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 .gitignore excludes 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 embedApiKey is 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.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye