Preface¶
DeepSeek Harness (DSH) is primarily used for local agent development. During development, it is often necessary to answer DSH’s prompts on a mobile phone or view real-time session output. Direct forwarding via SSH or a browser is not intuitive and can easily lead to context loss.
dsh-mobile-mirror is a DSH plugin that deploys an independent HTTPS service within the local network, allowing mobile browsers or native apps to mirror DSH sessions. The desktop behavior remains completely unchanged; the plugin does not alter the layout or inject UI into the desktop interface.
Plugin Introduction¶
- Name: dsh-mobile-mirror
- Maintainer: ImHaoYuan
- Category: Networking Tools
- License: MIT
The plugin provides services via an independent port (19388), supporting session list viewing, real-time character-by-character output, sending messages, stopping the current turn, creating new sessions, switching models and modes, and directly answering DSH’s questions on the mobile phone.
Environment Requirements¶
Before starting, please ensure your environment meets the following conditions:
- DSH (Desktop): Only supports Windows Desktop 0.2.0-rc.2. Installation on other versions is theoretically possible but unverified.
- Mobile Phone: Connected to the computer on the same Local Area Network (LAN).
- Node.js: The host environment requires Node.js >= 20.
- HyperOS: Notification and “Super Island” features are tested and verified only on Xiaomi HyperOS 3.
Installation and Activation¶
To install this plugin, you need to clone the repository first, then import it via DSH’s plugin manager or by manually linking it.
- Clone the Repository
git clone https://github.com/ImHaoYuan/dsh-mobile-mirror.git
- Install via Plugin Manager
The plugin manager will automatically handle dependency linking and hot-apply the configuration.
plugin_manager install_bundle target = link:<absolute_path_you_cloned_to>
(Please replace <absolute_path_you_cloned_to> with the actual absolute path, e.g., link:D:/plugins/dsh-mobile-mirror)
- Confirm Installation
After installation, open the DSH settings panel; you should see a “Mobile Mirror” page. The desktop logs should displaylistening on 0.0.0.0:19388.
Initial Configuration: Account & Password¶
By default, the plugin is in “Login Denied” mode. Initial setup must be performed on the computer side for first-time use.
- Open
https://127.0.0.1:19388/setup. - Enter an account and password (at least 6 characters) and click Save.
- The browser will warn that the self-signed certificate is not secure; click “Continue” or “Proceed” to visit.
You can also directly edit the configuration file $DSH_HOME/mobile-mirror.json to insert a plaintext password, which the plugin will automatically convert to a hash upon startup.
Mobile Access¶
After configuration, access the following address in your mobile browser:
https://<computer_LAN_IP>:19388/
The first visit will trigger a self-signed certificate error; this is expected:
- iOS Safari: Click “Details” → “Visit this website”.
- Android Chrome: Click “Advanced” → “Continue to
To eliminate the warning, you can download cert.pem from the /setup page on your computer and install it into your phone’s system certificate list.
Client Solutions¶
The plugin provides three access methods, all sharing the same core data source:
| Method | Description | Package Name | Features |
|---|---|---|---|
| Web Client | Direct access via mobile browser | — | Zero installation, full functionality, Markdown support |
| WebView APK | Encapsulates the web page into an App | dsh.mirror |
Includes notification and Super Island support, small size (78 KB) |
| Native Client | Rewritten using Kotlin + Compose | dsh.mirror.client |
Larger size (23.8 MB), native feel, support for three font size levels |
Recommendation: Install only one of the apps at a time. The Native Client is a superset of the WebView version, and its use is recommended.
Core Features¶
The plugin supports the following operations:
- Session Management: View session list (supports grouping and collapsing by workspace), create new sessions, long-press to archive empty sessions.
- Real-time Interaction: Supports SSE character-by-character output (automatically backfills when returning from background), stop current turn (with secondary confirmation), send messages (idempotent and throttled).
- Model Control: Switch session models (including reasoning levels) and modes (Standard/PTC/Minimal/Creative, etc.).
- Answering Questions: Whoever answers first (mobile or desktop) takes effect. In time-limited question mode, the mobile side takes over the waiting state, preventing disconnection due to switching to the background.
- Content Display: Supports Markdown rendering, no truncation for long content (body limit 100,000 characters), and file downloads.
- Native Exclusive: The Native Client provides a “Sent Messages” list, multi-line input expansion, and three levels of font settings (Interface/Body/Monospace).
Security and Port Design¶
DSH’s built-in Web service only listens on 127.0.0.1. Changing DSH’s port directly to 0.0.0.0 would expose the entire desktop GUI and API to the local network.
The design philosophy of dsh-mobile-mirror is:
1. Launch an independent HTTPS service on a default port of 19388.
2. Self-issue a self-signed certificate without relying on third-party packages.
3. Only provide the read-only interfaces and message sending interfaces required for mobile mirroring, without exposing DSH’s original Web Server.
Notes¶
- Version Compatibility: This document is tested based on DSH Windows 0.2.0-rc.2 and Xiaomi HyperOS 3. Other DSH versions, Android ROMs, or device models are unverified.
- Certificate Trust: Due to the use of self-signed certificates, iOS requires additional steps in “Certificate Trust Settings” to enable full trust; Android requires manual installation of the CA certificate.
- Font Files: Of the Native Client’s 23.8 MB size, approximately 20 MB is due to built-in font files (Smiley Sans, Source Han Sans, JetBrains Mono).