Introduction¶
DeepSeek Harness (DSH) provides a basic agent loop, tool calling, and model routing, but it still lacks an adaptive intelligence layer (such as persistent memory, reusable skills, and RL trajectory collection). Traditional implementations often rely on Python or an additional Hermes installation, increasing environment complexity and process overhead.
The dsh-hermes-bridge plugin integrates Hermes’ adaptive intelligence layer directly into DSH with a native JavaScript implementation. It requires no Python dependencies and does not communicate through subprocesses; instead, it interacts directly with DSH via shared memory and the file system.
Core Features¶
The plugin provides the following capabilities:
* Persistent memory: Generates MEMORY.md and USER.md via hermes_memory, together with a frozen system prompt snapshot.
* Reusable skills: Provides SKILL.md directory management, supporting viewing the skill list, viewing skill details, and managing skills.
* Skill authoring: Creates and updates skills through the /hermes-learn command.
* Trajectory collection and compression: Captures conversation trajectories via hermes_trajectory_save and compresses trajectories within a token budget via hermes_trajectory_compress (preserving first and last turns), for generating SFT/DPO data.
* Diagnostics: Checks capability status through hermes_status.
* Optional enhancements: Supports background memory/skill review (backgroundReview) and curator (curator) features.
Installation & Configuration¶
Run the following command in a terminal to install the plugin:
dsh plugin --profile web add github:aalvsz/dsh-hermes-bridge
After installation, you need to override the package’s configuration in the profile’s cordis.patch.yml. The default configuration is as follows:
- id: dsh/hermes-bridge
config:
enabled: true
namespace: hermes
backgroundReview: false
curator: false
memoryCharLimit: 2200
userCharLimit: 1375
memoryNudgeInterval: 10
skillNudgeInterval: 10
saveTrajectories: false
model: null
trajectoryTargetMaxTokens: 15250
trajectorySummaryTargetTokens: 750
Typical Usage¶
- Trajectory compression: When
saveTrajectories: trueis enabled, a trajectory file in ShareGPT format is automatically generated at the end of the conversation.hermes_trajectory_compresscompresses intermediate turns to save tokens while preserving the integrity of the initial and final turns (System, Human, Assistant tool-call pairs). - Skill management: Use
hermes_skills_listto browse the skill library,hermes_skill_viewto view a specific skill, andhermes_skill_manageto perform management operations. - Development verification: The plugin includes standard Node.js test scripts; run
npm testornpm run verifylocally to verify it.
Notes¶
- Version requirement: Requires Node.js
^22.19.0or>=24.0.0. - Default state:
backgroundReview,curator, andsaveTrajectoriesare disabled by default and must be explicitly enabled in the configuration. - File permissions: Generated memory and skill files use
0600permissions, while directories use0700. - Namespace: All tools are prefixed with
hermes_to avoid conflicts with DSH native tools. - No Python dependency: This is a pure JavaScript native rewrite for v0.2.0 and no longer depends on Python or Hermes.
Summary¶
The plugin fills DSH’s gap in adaptive intelligence and RL data generation. For developers who need to build highly complex agents, manage long-term memory, or generate fine-tuning data, this is a lightweight solution that avoids introducing an additional Python environment.