{"_id":"@argszero/cordis-plugin-subagent-effort","_rev":"2-fc0665acc68a35a50548948e1ced8b5c","name":"@argszero/cordis-plugin-subagent-effort","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@argszero/cordis-plugin-subagent-effort","version":"0.1.0","keywords":["cordis","deepseek-harness","dsh","plugin","subagent","reasoning-effort"],"license":"MIT","_id":"@argszero/cordis-plugin-subagent-effort@0.1.0","maintainers":[{"name":"argszero","email":"argszero.reg@gmail.com"}],"dsh":{"bundle":{"patch":"./cordis.patch.yml"}},"dist":{"shasum":"1be30634a80e1d75bbcf74597a8fd34c8d8965ed","tarball":"https://registry.npmjs.org/@argszero/cordis-plugin-subagent-effort/-/cordis-plugin-subagent-effort-0.1.0.tgz","fileCount":5,"integrity":"sha512-5ZtSHKnrbpybE4YKSzqGF9mtOt7Y2fBEeTZT/x1BmcxoNhYqlUUfaP3gE1vihIPvk7SAmn3f/1Sap/BbHKsbIA==","signatures":[{"sig":"MEQCIEhIzkxmwDaFEFRHT2NMdMcuM+l4e37+9KvZ2vmALsPBAiB4xdzehh4jyiiWu91tk60NNt5p49YoSmrNfrHLB4iifQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":15909},"main":"lib/index.js","type":"module","types":"lib/types/index.d.ts","exports":{".":{"types":"./lib/types/index.d.ts","default":"./lib/index.js"},"./src/*":"./src/*","./package.json":"./package.json"},"gitHead":"3476651d8bd57b38b215e85c84bf6ab7089fab65","scripts":{"build":"tsc","prepublishOnly":"tsc"},"_npmUser":{"name":"argszero","email":"argszero.reg@gmail.com"},"_npmVersion":"11.17.0","description":"Per-delegation reasoning effort for dsh subagents: makes AgentOptions.reasoningEffort reach child requests (the agent loop silently ignored it) and adds a subagent_effort tool that accepts reasoning_effort and model per call","directories":{},"_nodeVersion":"26.5.0","dependencies":{"@deepseek-ai/dsh-llm":"^0.1.1-rc.2","@deepseek-ai/dsh-agent":"^0.1.1-rc.2","@deepseek-ai/dsh-tools":"^0.1.1-rc.2","@deepseek-ai/dsh-session":"^0.1.1-rc.2","@deepseek-ai/schemastery":"^3.18.1","@deepseek-ai/dsh-subagent":"^0.1.1-rc.2"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.5.0","@deepseek-ai/cordis":"^4.0.1","@deepseek-ai/dsh-system-prompt":"^0.1.1-rc.2"},"peerDependencies":{"@deepseek-ai/cordis":"^4.0.1"},"_npmOperationalInternal":{"tmp":"tmp/cordis-plugin-subagent-effort_0.1.0_1787831380596_0.46879859712459027","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"_id":"@argszero/cordis-plugin-subagent-effort@0.1.1","dsh":{"bundle":{"patch":"./cordis.patch.yml"}},"dist":{"shasum":"3de883743f8ed1aabca064c7fdcb4d6543a17c0c","tarball":"https://registry.npmjs.org/@argszero/cordis-plugin-subagent-effort/-/cordis-plugin-subagent-effort-0.1.1.tgz","fileCount":5,"integrity":"sha512-mCdh00MDX9eT0mdU6yX0Nr68Z1MjGWQADCyUXki0NygHz901XDyM0EKXppYO09hda5h3tgxcgJp6VV9izttWiw==","signatures":[{"sig":"MEUCIQCwp/HA/7wdrSPERHVwYxwLphddmBCX/vkKE6a48H5joQIgN0nN/M+NdVj61LxrTcpL7zHlEEUP2KaV/1Tf9lketB0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIGHz0Se7i2O0ygQm9tCsLzW/D5C+e39+Btg/VWoHYEOOAiBYg5H/6o5Sb3JjjmYrsSOWXGSlAezUuPci/sfbbLJXrg=="}],"unpackedSize":18384},"main":"lib/index.js","name":"@argszero/cordis-plugin-subagent-effort","type":"module","types":"lib/types/index.d.ts","exports":{".":{"types":"./lib/types/index.d.ts","default":"./lib/index.js"},"./src/*":"./src/*","./package.json":"./package.json"},"gitHead":"b781df1058b4679e29df9118ebe6c4f498613aed","license":"MIT","scripts":{"test":"tsc && node --test \"test/*.spec.mjs\"","build":"tsc","prepublishOnly":"tsc"},"version":"0.1.1","_npmUser":{"name":"argszero","email":"argszero.reg@gmail.com"},"keywords":["cordis","deepseek-harness","dsh","plugin","subagent","reasoning-effort"],"_npmVersion":"11.17.0","description":"Per-delegation reasoning effort for dsh subagents: makes AgentOptions.reasoningEffort reach child requests (the agent loop silently ignored it) and adds a subagent_effort tool that accepts reasoning_effort and model per call","directories":{},"maintainers":[{"name":"argszero","email":"argszero.reg@gmail.com"}],"_nodeVersion":"26.5.0","dependencies":{"@deepseek-ai/schemastery":"^3.18.1"},"_hasShrinkwrap":false,"devDependencies":{"semver":"^7.6.0","typescript":"^5.5.0","@deepseek-ai/cordis":"^4.0.1","@deepseek-ai/dsh-llm":"0.1.1-rc.2","@deepseek-ai/dsh-agent":"0.1.1-rc.2","@deepseek-ai/dsh-tools":"0.1.1-rc.2","@deepseek-ai/dsh-session":"0.1.1-rc.2","@deepseek-ai/dsh-subagent":"0.1.1-rc.2","@deepseek-ai/dsh-system-prompt":"0.1.1-rc.2"},"peerDependencies":{"@deepseek-ai/cordis":"^4.0.1","@deepseek-ai/dsh-llm":">=0.1.1-rc.2 <0.1.2","@deepseek-ai/dsh-agent":">=0.1.1-rc.2 <0.1.2","@deepseek-ai/dsh-tools":">=0.1.1-rc.2 <0.1.2","@deepseek-ai/dsh-session":">=0.1.1-rc.2 <0.1.2","@deepseek-ai/dsh-subagent":">=0.1.1-rc.2 <0.1.2"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/cordis-plugin-subagent-effort_0.1.1_1789715853467_0.8409582538881164"}}},"time":{"created":"2026-08-27T11:49:40.406Z","modified":"2026-09-18T07:17:33.716Z","0.1.0":"2026-08-27T11:49:40.762Z","0.1.1":"2026-09-18T07:17:33.555Z"},"license":"MIT","keywords":["cordis","deepseek-harness","dsh","plugin","subagent","reasoning-effort"],"description":"Per-delegation reasoning effort for dsh subagents: makes AgentOptions.reasoningEffort reach child requests (the agent loop silently ignored it) and adds a subagent_effort tool that accepts reasoning_effort and model per call","maintainers":[{"name":"argszero","email":"argszero.reg@gmail.com"}],"readme":"# @argszero/cordis-plugin-subagent-effort\n\nPer-delegation reasoning effort for [deepseek-harness](https://github.com/deepseek-ai/deepseek-harness) (`dsh`) subagents.\n\n> ## ⚠️ Superseded upstream (0.1.2-alpha.1, 2026-08-28)\n>\n> deepseek-harness **0.1.2-alpha.1 fixed this gap natively**: `AgentOptions` now\n> carries `reasoningEffort` (consumed by the agent-loop request builder), and\n> `dsh-tool-subagent` exposes a per-call `reasoning_effort` parameter plus\n> background/continuable delegation. This plugin is **not needed on\n> ≥ 0.1.2-alpha.1** and is kept for users pinned to `0.1.1-rc.2`, where the\n> silent-drop gap still exists. See\n> [discussion #4666](https://github.com/deepseek-ai/deepseek-harness/discussions/4666)\n> for the maintainer-confirmed root cause and the upstream fix.\n\nCloses one gap end to end: `@deepseek-ai/dsh-tool-subagent` accepts config-level\n`agentOptions` and forwards them into the child's `AgentOptions`, but the agent\nloop's request builder only reads `provider` / `model` / `maxTokens` from\n`AgentOptions` — a `reasoningEffort` declared there was **silently ignored**\n(the model never saw it, no error). This plugin fixes the consumption side and\nadds a per-call effort tool.\n\n## What it does\n\n1. **Effort plumbing** — extends the merge-extensible `AgentOptions` interface\n   with `reasoningEffort` and injects it into every request of that agent via\n   the `agent/request` waterfall. Config-declared effort (e.g. `tool-subagent`'s\n   `agentOptions.reasoningEffort`) now actually reaches the adapter.\n2. **Per-call tool** — registers `subagent_effort` (configurable), a foreground\n   subagent tool accepting `reasoning_effort` (`off` | `low` | `high` | `max`,\n   the DeepSeek adapter vocabulary) and an optional `model` override per call,\n   forwarded as child `agentOptions`.\n\n## Install\n\n```sh\n# add to your dsh profile (the dsh.bundle declaration mounts it as a profile layer)\npnpm add @argszero/cordis-plugin-subagent-effort\n```\n\nSet the provider in your profile's `cordis.patch.yml` (last write wins per row):\n\n```yaml\n- set:\n    - id: subagent-effort\n      config:\n        provider: spawn          # your ctx.subagents provider name\n        # toolName: subagent_effort\n        # defaultReasoningEffort: high\n```\n\n## Config\n\n| key | type | default | meaning |\n|-----|------|---------|---------|\n| `provider` | string | — (required) | the `ctx.subagents` provider name to delegate on (e.g. `spawn`, `fork`, `acp`) |\n| `toolName` | string | `subagent_effort` | model-facing tool name |\n| `defaultReasoningEffort` | `'off' \\| 'low' \\| 'high' \\| 'max'` | provider default | effort applied when a call omits `reasoning_effort` |\n\n## Usage\n\n### Config-level effort (fixes the silent drop)\n\nWith `@deepseek-ai/dsh-tool-subagent` configured with `agentOptions`, the\neffort now reaches the child's requests:\n\n```yaml\n- set:\n    - id: subagent\n      config:\n        provider: spawn\n        agentOptions:\n          reasoningEffort: high\n```\n\nWithout this plugin that value was accepted and silently ignored.\n\n### Per-call effort (new tool)\n\nThe `subagent_effort` tool lets the model vary the thinking budget per\ndelegation:\n\n```\n{\n  \"description\": \"verify the proof\",\n  \"prompt\": \"Check the induction step carefully…\",\n  \"reasoning_effort\": \"max\"\n}\n```\n\nOptional `model` overrides the child's model for that delegation.\n\n## Design notes\n\n- The tool mirrors `@deepseek-ai/dsh-tool-subagent`'s provider lifecycle: it\n  registers when the configured provider appears and unregisters when it leaves.\n- The `agent/request` listener is conservative: only agents whose options\n  explicitly carry `reasoningEffort` are touched; every other request passes\n  through unchanged.\n- Foreground-only by design — background/continuable delegation is available\n  from the built-in `subagent` tool; this plugin is about effort control.\n\n## Peer range\n\nThis plugin targets one dsh line, and declares every harness package it reads as\na **peer** rather than a dependency:\n\n```\n>=0.1.1-rc.2 <0.1.2\n```\n\ndeclared identically on `@deepseek-ai/dsh-agent`, `@deepseek-ai/dsh-llm`,\n`@deepseek-ai/dsh-session`, `@deepseek-ai/dsh-subagent` and\n`@deepseek-ai/dsh-tools`. It admits exactly `0.1.1-rc.2`.\n\nThe narrow scope is deliberate: upstream closed this gap natively in\n**0.1.2-alpha.1** (`AgentOptions.reasoningEffort` is consumed from there), so the\nplugin is only meaningful on the line where the silent drop still exists.\n\nThe *declaration* was the bug. v0.1.0 shipped these five as `dependencies` at\n`^0.1.1-rc.2`, and a caret on a prerelease admits only its own tuple — so no\nnewer tree could satisfy it, and npm resolves an unsatisfiable *dependency* by\nnesting its own copy. Installing the published 0.1.0 into a project running dsh\n`0.1.6-alpha.2` produced:\n\n```\nnode_modules/@argszero/cordis-plugin-subagent-effort/node_modules/@deepseek-ai/dsh-tools   (=0.1.1-rc.2)\nnode_modules/@deepseek-ai/dsh-tools                                                        (=0.1.6-alpha.2)\n```\n\nTwo copies of the harness runtime in one process, with no warning at all. As a\n**peer** the same narrow scope produces the correct outcome instead: npm refuses\nthe install with `ERESOLVE`, which tells a user on a newer line that this plugin\nis not for them.\n\n`test/peer-range.spec.mjs` asserts the admitted set exactly, asserts that no\nharness package appears in `dependencies`, and asserts that this README quotes\nthe manifest range verbatim.\n\n## Development\n\n```sh\nnpm install\nnpm run build        # tsc → lib/\nnpm test             # tsc + node --test (peer-range / declaration guard)\n```\n\n## License\n\nMIT\n","readmeFilename":"README.md"}