rea
morluto
Reverse engineer anything with agents, from app behavior down to native binaries.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:lcf2212dev/dsh-claude-delegate
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
Bundle package: @dsh-burn-plugins/dsh-claude-delegate. License: MIT.
Standalone DeepSeek Harness plugin that exposes one tool, claude_delegate:
it delegates a task to a fresh, unattended Claude Code session, with
model and effort chosen per call.
It also keeps the host Claude Code CLI on the newest build at every DSH
start, so alias-to-model mappings (for example fable → Fable 5.2, which needs
Claude Code 2.1.321 or later) never come from a stale launcher.
It does not depend on the official @deepseek-ai/dsh-subagent-claude-code bundle,
on any fixed subagent instance, or on any pinned SDK. It talks directly to the
host's Claude Code launcher (claude -p), whose version it refreshes
automatically on DSH start (see below) — so there is no SDK version to track.
Each call becomes one process:
claude -p <task> --model <opus|sonnet|haiku|fable> --effort <low|medium|high|xhigh|max> \
--dangerously-skip-permissions --output-format stream-json --verbose --no-session-persistence
readOnly: true the child runs with
--permission-mode plan instead of --dangerously-skip-permissions
(no edits, no commands that require approval).model and effort per call; defaults come from the row config.ANTHROPIC_API_KEY,
ANTHROPIC_AUTH_TOKEN, CLAUDE_CODE_OAUTH_TOKEN, CLAUDE_CODE_API_KEY) are
removed so the native OAuth login wins. Turn this off with
isolateCredentials: false and pass the key in env if you want to use an API key.CLAUDE_CODE_TMPDIR (default ~/.cache/claude-delegate), avoiding
the problem of /tmp/claude-$UID belonging to another user.cwd); cancellation tears down the
process tree (SIGTERM → SIGKILL after 3s).stream-json; the
wrapper collects the result events and returns the one that answers the task.
A background task that finishes after the agent already answered makes the CLI
append an extra turn and a second result event that only acknowledges the
notification — returning it (what --output-format json does, as it prints the
last result) lost two worker reports in the 2026-11-11 Bits mission. The
selection lives in result.js.Every DSH start refreshes the host Claude Code build before and in parallel with the session:
command symlink, e.g.
~/.local/share/claude/versions) and points that stable launcher symlink at
the newest build already on disk. A launcher left on an older build — for
example after a channel switch or a partial update — is fixed without
network access.<command> install <updateChannel> in the background and repairs the
launcher again. Failures (offline, registry error, timeout) are logged and
never block DSH startup or the delegate tool.Every maintenance outcome is appended to latest.log under the plugin's cache
directory (tmpDir, default ~/.cache/claude-delegate), so the last automatic
refresh stays inspectable after a restart.
Only the native installer layout is managed: when command is a plain file or a
wrapper (not the stable launcher symlink into .../versions/<build>), the plugin
leaves it untouched and skips the refresh. Set keepLatest: false to opt out,
or updateChannel: stable to follow the stable channel instead of latest.
node test/result.test.mjs
The suite replays a trimmed capture of a real background-notification run
(test/fixtures/background-notification.stream.jsonl): the report must win over
the notification acknowledgement, including when JSON lines are split across
arbitrary chunks.
Link the package in the profile (e.g. ~/.dsh/profiles/desktop/package.json):
"@dsh-burn-plugins/dsh-claude-delegate": "link:/path/to/dsh-claude-delegate"
Add @dsh-burn-plugins/dsh-claude-delegate to dsh.profile.bundles.
Run the profile's pnpm install (creates the symlink under node_modules/@local).
HMR recomposes the profile and the tool appears on the next model request.
claude-delegate)| field | default | meaning |
|---|---|---|
command |
claude |
stable Claude Code launcher (use an absolute path if the Host PATH has wrappers) |
model |
opus |
alias used when the call omits model |
effort |
high |
effort used when the call omits effort |
tmpDir |
"" → ~/.cache/claude-delegate |
exported as CLAUDE_CODE_TMPDIR |
env |
{} |
extra env layered over the host environment |
timeoutMs |
0 |
declarative per-call limit; 0 does not cap |
isolateCredentials |
true |
removes ambient credentials so the subscription is used |
keepLatest |
true |
repair/refresh the native Claude Code launcher at DSH start |
updateChannel |
latest |
startup refresh channel: latest, stable, or off |
versionsDir |
"" |
native version store when it cannot be derived from command |
updateTimeoutMs |
300000 |
upper bound for one startup refresh |
The package ships no machine-specific value: without an override, every field
uses the default above. To customize it, override the row in your profile patch
(e.g. ~/.dsh/profiles/desktop/cordis.patch.yml), without editing this
repository:
- id: claude-delegate
name: "@dsh-burn-plugins/dsh-claude-delegate"
config:
command: /absolute/path/to/claude
model: sonnet
effort: medium
The override config replaces the row's config entirely; omitted fields fall
back to the defaults.
task (required) — self-contained task; the child does not see the conversation.model — opus | sonnet | haiku | fable (each alias resolves to the latest build).
fable is the most capable and most expensive model: it resolves to Fable 5.2 on
Claude Code 2.1.321 or later (earlier builds resolve it to an older Fable) and,
depending on the plan, bills usage credits — claude -p never asks before billing them.
fable requires this package at 0.1.1 or later; an older build rejects the alias.effort — low | medium | high | xhigh | max (the model may clamp
a level it does not support).cwd — absolute directory; omitted = session workspace.readOnly — boolean, default false. When true, it swaps
--dangerously-skip-permissions for --permission-mode plan (read-only/planning
only; the child neither edits files nor runs commands that require approval).claude installed and logged in on the host (subscription) or a credential in env.@deepseek-ai subagent package installed.claude update changes the flags used (--effort,
--output-format stream-json, --verbose, --no-session-persistence), adjust
the array in index.js.result event per
finished turn and marks notification turns with origin.kind === "task-notification" (Claude Code 2.1.32x). A future CLI that stops marking
them falls back to the last result, as before.CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: deepseek-harness。