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

dsh-codex-bridge

Quota-aware Codex CLI bridge for DSH: reads the 5-hour and weekly ChatGPT-plan windows, defaults to gpt-6.1-sol/high, falls back to gpt-5.6-sol at 10% left, and runs codex exec tasks. 适合使用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.