Preface¶
DeepSeek Harness (DSH) extends its capabilities through a plugin architecture. When dealing with complex codebases, standard agents often lack IDE-level symbol navigation capabilities, such as finding references to specific symbols, renaming variables, or viewing project symbol overviews. The dsh-serena plugin bridges this gap for every agent by introducing the Serena MCP server, enabling structured code analysis.
Plugin Positioning¶
dsh-serena is a utility plugin for DeepSeek Harness, maintained by akash-digitavision. It integrates Serena’s symbolic code intelligence capabilities into the DSH ecosystem via the MCP protocol, solving the issue of agents being unable to perform deep symbolic operations within codebases.
Core Features¶
The plugin primarily provides the following capabilities:
- Symbolic Code Intelligence: Provides tools such as
find_symbol,find_referencing_symbols,rename_symbol,replace_symbol_body, andget_symbols_overview. - MCP Server Integration: Launches the Serena server via stdio to provide functions like symbol search, reference lookup, renaming, and diagnostics.
- Session Hook Management: Runs session hooks to manage project activation and tool usage, ensuring agents correctly invoke Serena tools.
- Local Storage: Reads or writes only to the active workspace, with memory stored in the
.serena/directory.
Installation and Enablement¶
Installation Command
dsh plugin --profile web add github:akash-digitavision/dsh-serena
Prerequisites
1. Serena CLI: The Serena command-line tool must be installed.
uv tool install serena-agent
- Hooks File: The
~/.dsh/hooks.jsonfile needs to be configured. This file defines the logic for session start, reminders before tool usage, and cleanup at session end.
Service Restart
After installation, DeepSeek Harness must be restarted to load the plugin.
Typical Usage¶
Starting a Session
It is recommended to start the session using the --project-from-cwd parameter to automatically activate the current directory as a Serena project:
dsh --context claude-code --project-from-cwd
Verifying Activation
Once in the session, you can ask the agent:
activate this project with serena
The agent will verify if the project was successfully activated and begin using the symbolic tools provided by Serena to perform operations.
Use Cases and Notes¶
Execution Permissions
- The plugin runs with the permissions of the current DSH process and involves no accounts, API keys, or telemetry.
- All operations are limited to the local process, with no external service dependencies.
Compatibility and Performance
- Compatibility: Requires DeepSeek Harness version 0.2.0-rc.2 or higher.
- Dependency Version: The dependency version is locked to @deepseek-ai/dsh-hooks-claude-code 0.2.0-rc.2; please ensure the DSH runtime version matches.
- First Query: The first symbol query in a new project requires downloading the server for the corresponding language, which may be slow.
Summary¶
dsh-serena brings Serena’s symbolic capabilities into the DSH ecosystem via the standardized MCP protocol. It does not rely on external APIs and runs entirely locally, making it suitable for agent workflows that require deep analysis of code structure in a local environment.