dsh-imessage:爲 DeepSeek Harness 增加 Photon 託管 iMessage 通道

前言

做 DeepSeek Harness(DSH)會話時,一個具體問題是:瀏覽器裏已經有 DSH 會話,但希望把 iMessage 文本變成 DSH prompt,並把最終助手回答通過 iMessage 發回來,同時還要能控制會話和當前 turn。

DSH 的理念是「一切皆插件」。下面介紹的 dsh-imessage 面向這個場景,給 DSH 的 web profile 增加 Photon 託管 iMessage transport 和配置頁。

這是什麼

dsh-imessage 是一個 DSH 插件,描述爲 Photon-hosted iMessage transport and configuration UI for DeepSeek Harness

它做的事情可以概括爲三步:

  1. Settings → iMessage 頁面完成 Photon 設備碼授權。
  2. 保存一個發送方 E.164 號碼,並獲取一個 hosted iMessage 號碼。
  3. 之後,來自該路線的 iMessage 文本會進入 DSH prompt,DSH 的最終助手回答會經 iMessage 返回。

資料中可確認的信息如下:

  • 倉庫名:photon-hq/dsh-imessage
  • 許可證:MIT
  • 包版本:0.2.0
  • 初始兼容目標:DeepSeek Harness 0.1.0-rc.6
  • Spectrum:12.7.x,當前鎖定 12.7.0
  • Node.js:22.19+24+

資料沒有單獨確認 owner 字段,這裏只按倉庫名陳述維護入口。

核心功能

先做通道和配置,再做消息路由。已覈實的能力包括:

  • Photon-hosted iMessage transport
  • Settings → iMessage 配置頁
  • Photon device-code authorization over HTTPS
  • Configure an E.164 sender number and obtain a hosted iMessage number
  • Queues inbound iMessage text as DSH prompts
  • Sends final DSH assistant answers back over iMessage
  • Provides /help, /new, /sessions, /switch, /status, /stop, /cancel, /approve, /deny, and /answer commands
  • Filters messages by platform, inbound direction, direct message, configured sender, and hosted-line route
  • Converts final answers from markdown to plain text and splits long answers
  • Stores non-secret configuration in dsh-imessage settings and one opaque credential at DSH_IMESSAGE_PHOTON_CREDENTIALS

邊界也需要看清楚:

  • 只投遞 final assistant answer。
  • Intermediate reasoning、tool activity 和 partial output 仍留在 DSH 中。
  • Approval delivery failure、unhealthy listener、cancellation 或 timeout 會 fail closed。

安裝與啓用

先安裝插件,再在目標工作區啓動 DSH。資料給出的安裝命令是:

dsh plugin --profile web add dsh-imessage

這一步把 dsh-imessage 添加到 DSH 的 web profile 中。

接下來啓動 DSH:

dsh web

這一步會啓動 DSH,使剛纔安裝的 web profile 插件生效。

典型用法

啓動後打開 Settings → iMessage,按頁面卡片完成配置:

  1. 選擇 Authorize
  2. 輸入你準備發送消息的 E.164 號碼,例如 +14155552671,然後保存。
  3. 複製或短信發給對方的 hosted iMessage 號碼。

完成之後,普通文本會被入隊爲 DSH prompt。如果一個 prompt 本身確實以 / 開頭,使用 // 前綴。例如:

//review this route

資料列出的會話與 turn 控制命令包括:

/help
/new
/sessions
/switch
/status
/stop
/cancel
/approve
/deny
/answer

這些命令用於會話和 turn 控制。如果當前已有排隊或運行中的 prompt,或者存在待處理的人工交互,/new/switch 可能失敗;可先使用 /stop

適用場景與注意

適合以下情況:

  • 希望把 iMessage 文本作爲 DSH prompt。
  • 希望通過 iMessage 接收 DSH 的最終助手回答。
  • 需要 /new/switch/approve/deny/answer 這類會話或 turn 控制命令。
  • 不希望消息內容、原始電話號碼、設備碼、訪問令牌或項目密鑰出現在日誌中。

注意事項:

  • 插件以當前 dsh 進程權限運行;安裝前應檢查源碼、依賴和許可證。
  • 該插件許可證爲 MIT。
  • 它只投遞最終助手回答,不會把中間推理、工具活動或部分輸出經 iMessage 發回。
  • 未授權消息會被忽略且沒有回覆。
  • 插件不記錄 message content、raw phone numbers、device codes、access tokens 或 project secrets。
  • 自動開通會創建一個 shared Spectrum user,並禁用邀請。
  • 如果 shared capacity 不可用,設置會以 shared-line-unavailable 停止。
  • 資料說明它使用 Photon CLI compatibility 的 client_id=photon-cli,並把這個共享 client ID 視爲 intentional exception。

小結

dsh-imessage 給 DSH 增加 Photon-hosted iMessage transport 和 Settings → iMessage 配置頁。適合希望用 iMessage 文本觸發 DSH prompt、接收最終回答,並保留會話與審批控制的使用者。

相關鏈接:

  • GitHub:https://github.com/photon-hq/dsh-imessage
  • 資料提供的目錄頁:https://www.skillhub.cn/plugins/photon-hq/dsh-imessage

社區目錄是獨立站點,不等於 DeepSeek / 幻方的官方應用商店。

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

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

小夜