JD962 / dsh-model-reasoning-intensity

목록에 있음

This plugin complements DeepSeek Harness by fixing the problem where third-party platforms are unable to select the model's reasoning intensity.

main모델 소스 보기

설치

npx -y @deepseek-ai/dsh plugin --profile web add github:JD962/dsh-model-reasoning-intensity

이 설치 명령은 GitHub 저장소 주소에서 생성된 확인되지 않은 시작점입니다.

README

유지 관리자가 작성한 문서 스냅샷입니다.

GitHub에서 보기 ↗
커밋 f4af514동기화 2026. 8. 18.

최근 디렉터리 동기화에서 이 README 스냅샷을 새로 고치지 못했습니다.

Reasoning Effort Bridge / 思考强度桥

A DeepSeek Harness (DSH) host plugin that gives third-party (llm-pi-ai) models a selectable thinking-effort row in the composer's model menu — Off / Low / Medium / High / Xhigh / Max — the same experience official DeepSeek models already have.

一个 DeepSeek Harness(DSH)宿主插件:为第三方(llm-pi-ai)模型在输入框的 模型菜单中补齐思考强度选择(Off/Low/Medium/High/Xhigh/Max),与官方模型 体验一致。

How it works / 工作原理

DSH only renders the effort row when a model reports reasoning metadata. Official llm-deepseek models carry a built-in level table; third-party llm-pi-ai models report levels only when their profile entry declares reasoningEfforts — which hand-added gateway routes never do. The bridge watches the llm-pi-ai settings namespace and fills the default six-level map into every model that currently reports no reasoning metadata (probed via llm.resolveModelInfo — the exact condition under which the menu hides the row):

DSH 只在模型上报 reasoning 元数据时渲染强度行。官方模型内置档位表;第三方 模型只有显式声明 reasoningEfforts 才会上报——手工添加的网关路由没有该 字段。本插件监听 llm-pi-ai 设置命名空间,对当前完全没有 reasoning 元数据的模型(以 llm.resolveModelInfo 探测,与菜单隐藏强度行同判据) 补写默认六档表:

reasoningEfforts:
  off: none      # the wire spelling; same as pi-ai's own gpt-5.1+ catalog
  low: low
  medium: medium
  high: high
  xhigh: xhigh
  max: max

Selecting a level dispatches a real request parameter (reasoning.effort on openai-responses, reasoning_effort on openai-completions); unsupported levels keep being refused before any network I/O. There is no fake UI.

选择档位后真实分发到网络请求;不支持的档位依旧在发起请求前被拒绝——不存 在假 UI。

Guarantees / 保证

  • Only fills absent fields: user-declared maps and reasoningEfforts: false opt-outs are never overwritten; models whose pi-ai catalog entry already carries its own levels are untouched (the catalog stays authoritative). 只填缺失字段:用户已声明的档位表与显式 false 退出一律不覆盖;目录自带 档位的模型不补。
  • Writes only the user layer through settings.update() with an expectedRevision optimistic lock — concurrent edits win over the bridge. 只写用户层,带乐观锁;并发用户编辑优先。
  • Idempotent and loop-free: its own write re-triggers the watcher, which finds nothing left to fill. 幂等无循环。
  • Bridged protocols: openai-responses, openai-completions, azure-openai-responses, openai-codex-responses, anthropic-messages. Others are intentionally skipped. 其余协议有意跳过。

Install / 安装

powershell -ExecutionPolicy Bypass -File .\install.ps1
# then restart `dsh web` and hard-refresh the browser (Ctrl+Shift+R)

Uninstall / 卸载

powershell -ExecutionPolicy Bypass -File .\uninstall.ps1

The maps already written into settings.yaml are user data and stay; set reasoningEfforts: false on a model to stop offering levels for it.

See BUILD-INSTALL.md for details and troubleshooting.

License

MIT

프로젝트 파일 및 신호

표시된 항목은 디렉터리 스냅샷에서 감지된 공개 저장소 신호입니다.

테스트감지됨

저장소 정보

언어
JavaScript
라이선스
MIT
마지막 업데이트
2026. 8. 18. AM 6:00

신중하게 설치하기

소스 코드, 권한, 수명 주기 스크립트, 의존성 및 네트워크 접근을 검토하고 신뢰하지 않는 플러그인은 격리 환경에서 테스트하세요.