← Back to home@RickT34

dsh-just-enough-tools

Nearly half the agent cost, with accuracy intact. Just enough tools is a DeepSeek Harness plugin that uses Jev to reveal tools and skills progressively. The main model starts with a clean planning step. Jev then selects which capabilities to add as the task unfolds.

Stars
1
Language
TypeScript
Created
Sep 22, 2026
Updated
Sep 28, 2026
GitHub repo

Introduction

Just enough tools

Think first. Bring in tools and skills when they matter.

简体中文 · Install · Contributing

Our goal: nearly half the agent cost, with accuracy intact.

Just enough tools is a DeepSeek Harness plugin for progressive tool and skill selection, powered by Jev, with an optional OpenAI-compatible scorer.

Agents often receive more capabilities than a task needs:

  • Extra input cost: unused tool and skill schemas and descriptions consume tokens on repeated requests.
  • Overuse: unnecessary tool and skill invocations add steps, latency and cost.

The plugin puts tools and skills in one candidate pool and exposes only the capabilities selected for the task. Each agent has its own enabled set.

How it works

How Just enough tools works: Agent thinks, Jev scores, the plugin opens capabilities, and Agent acts.

Example scores illustrate progressive selection; they are not benchmark results. Editable TikZ source.

The diagram uses blue for tools and purple for skills. Jev receives the task, the latest final Agent text, summaries of remaining candidates, the enabled capability set, and any active skill instructions. Execution parameter schemas are omitted.

Scoring runs when the final Agent text contains REQUEST_CAPABILITIES or a supported spelling variant anywhere. The Agent is prompted to describe the missing operation or workflow. agent_response contains only that round's final text; tool calls, tool results and hidden reasoning are excluded. Tools and skills above the shared threshold are enabled and remain available. Later requests score only remaining candidates; skill dependencies are scored separately.

Detection ignores case and tolerates full-width characters, spaces, hyphens and omitted separators. Brackets, position and Markdown formatting do not matter: bare keywords, quoted text and code blocks also match.

Without the marker, the answer ends the turn immediately, including the first response: no Jev call and no extra Agent call. After an explicit request, the Agent continues with the routing result. If no capability is admitted, it answers with current capabilities or explains the limitation, without repeating the same request.

Example

For “Fix the login error and run the tests,” with a threshold of 0.50:

StageAgent response or actionJev / plugin decision
Think[REQUEST_CAPABILITIES] + newline + “I need to inspect the login flow.”read 0.94 and login-debug 0.88 are enabled; edit 0.32 and bash 0.21 stay hidden.
InspectAgent reads the code using the debug workflow, then requests: [REQUEST_CAPABILITIES] + newline + “Bug found. I need to edit and run tests.”Only remaining candidates are scored: edit 0.97 and bash 0.93 are added. Previously enabled capabilities stay available.
FinishAgent edits the code, runs tests, and replies: “Fixed; tests passed.”No marker: no Jev call; the turn ends.

Scores and outcomes are illustrative. A writing task may need only a style skill, or no external capabilities at all.

Install

Requires Node.js 22.19+, DeepSeek Harness 0.1.7-alpha.1, and Cordis 4.0.3.

Build from the repository:

npm ci
npm pack

Install the package and start dsh:

npx @deepseek-ai/dsh@0.1.7-alpha.1 plugin --profile web add /absolute/path/to/dsh-just-enough-tools-0.5.8.tgz
npx @deepseek-ai/dsh@0.1.7-alpha.1 web
  1. Open Plugins → dsh-just-enough-tools.
  2. Choose a provider protocol, configure credentials and model, and save.
  3. Start a new conversation in Just enough tools mode.

The acting model remains the one configured in dsh. The mode includes file, search and terminal tools, and discovers model-invocable skills through dsh.

Providers and settings

ProtocolDefault base URLModelKey environment variable
System One / TypeSafehttps://api.typesafe.ai/v1jev-latestTYPESAFE_API_KEY
Vercel AI Gateway (Evaluation)https://ai-gateway.vercel.sh/v4/aitypesafe-ai/jevAI_GATEWAY_API_KEY
OpenAI-compatible / LM Studiohttp://127.0.0.1:1234/v1Required: provider model IDOPENAI_API_KEY

Custom compatible base URLs and full endpoints are supported. Credentials are resolved in this order: saved key → JEV_API_KEY → provider environment variable. Reset a saved key to use an environment variable. Unauthenticated local chat servers may leave the key blank. dsh reads .env at startup; restart it after changing that file.

System One and Vercel return native decision probabilities. OpenAI-compatible scoring requires a generative model that returns JSON scores; these are model estimates, not calibrated decision probabilities. Encoder-only models require a separate decision service. There is no automatic fallback between protocols.

SettingDefault
Tool / skill threshold0.5
Maximum steps per user turn12
Routing operation timeout60000 ms
Terminal routing diagnosticsEnabled

Provider settings and diagnostics apply immediately; start a new conversation after changing routing limits. Diagnostics show per-capability scores, threshold and admission results in the dsh terminal. Scoring or registration failures stop execution with an explicit error.

Add a skill

Create .dsh/skills/login-debug/SKILL.md (or use dsh's other configured skill directories):

---
name: login-debug
description: Diagnose login and session failures before changing authentication code.
---
Reproduce the failure, inspect the relevant code, make a focused fix, and run the affected tests.

The scorer initially sees the summary; the Agent receives full instructions only after selection. Capability selection controls availability and instruction injection, not filesystem permissions.

Contribute

Help improve capability selection, provider support, thresholds and examples. See CONTRIBUTING.md, design, and integration details.

Independent community project · MIT license.