AK-blank/dsh-codex-bridge ↗★ 0

dsh-codex-bridge

管理Codex配额并自动切换模型运行任务 适合使用Codex CLI且需要根据剩余额度自动降级模型以节省开销的用户。

包名
dsh-codex-bridge
兼容性
待验证
版本
1.1.1
许可证
MIT
最近更新
2026年10月20日

同名包的其他仓库

安装

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:AK-blank/dsh-codex-bridge

Configuration

Override the row in the profile's cordis.patch.yml:

- id: codex-bridge
  name: dsh-codex-bridge
  config:
    minModel: gpt-5.6-sol
    defaultModel: gpt-6.1-sol
    expensiveModel: gpt-6-astra
    minEffort: medium
    defaultEffort: high
    reservePercent: 10
    stopPercent: 95
    statusCacheSeconds: 30
    defaultSandbox: read-only
    ephemeral: true
    maxTimeoutSeconds: 1800
    maxOutputChars: 16000
    codexCommand: codex
    codexHome: ''
KeyDefaultMeaning
minModelgpt-5.6-solmodel floor and reserve fallback
defaultModelgpt-6.1-solnormal default (may be configured even when not listed by the CLI)
expensiveModelgpt-6-astraexplicit opt-in only
minEffortmediumlowest reasoning level ever used
defaultEfforthighreasoning level for ordinary and hard work
reservePercent10fall back when either window has this much or less left
stopPercent95block ordinary runs at this used percentage
statusCacheSeconds30quota snapshot cache
defaultSandboxread-onlyCodex sandbox unless the caller overrides it
ephemeraltruedo not persist each delegation under ~/.codex/sessions
maxTimeoutSeconds1800hard wall-clock limit per delegation
maxOutputChars16000answer characters returned to the model
codexCommandcodexexecutable name or absolute path
codexHomeemptyempty inherits the host environment

Usage

Ask the agent:

Check the Codex quota, then delegate this hard problem to Codex with the right model and effort.

The agent calls codex_status, picks a complexity (or passes explicit model / reasoning_effort), then calls codex_delegate. The task must be self-contained: Codex cannot see the DSH conversation, so include absolute paths, symptoms, constraints, and the exact deliverable.

Default sandbox is read-only. Pass sandbox: "workspace-write" and a cwd only when Codex must edit files.