Preface

When using DeepSeek Harness (DSH), most providers’ /v1/models endpoints return only model IDs and lack key capability fields such as name, contextWindow, maxTokens, reasoningEfforts, and input. This results in incomplete model list views and increases the burden of manual configuration. This plugin aims to address this pain point by reading the locally cached models.dev catalog and automatically filling in the missing fields.

Introduction

dsh-model-parameters is a DSH plugin that detects and fills missing model metadata when settings are written (including model synchronization). It is maintained by fonlan and is licensed under the MIT License.

Core Features

  • Automatic metadata completion: Automatically fetches from the models.dev catalog and populates display name, context window, maximum output tokens, reasoning effort levels, and input modalities.
  • Smart triggering mechanism: Listens to the settings/updated namespace. Any settings change (such as syncing a new provider, editing a provider card, or manually editing settings.yaml) triggers a reconcile. On plugin startup, it also performs a full backfill for the existing configuration.
  • Deterministic matching logic: Supports provider mapping (providerMap), exact ID matching, and official provider priority (officialProviders). For bare IDs, it supports case-insensitive matching on the final path segment.
  • Fill-only updates: Only missing fields are filled; existing values are never overwritten. The reconcile process is inherently fill-only and does not create write loops.
  • Settings card and refresh: Provides a visual configuration interface, including a master toggle, per-field toggles, TTL configuration, a catalog refresh button, and a completion report.

Matching Logic

When matching models.dev catalog entries, the plugin follows this priority:
1. Provider mapping: Prefer an explicit providerMap, then fall back to same-ID matching.
2. Full ID exact match: A DSH model ID already prefixed with vendor/ matches the identical models.dev key.
3. Official provider priority: In case of conflicts, prefer entries from officialProviders (such as deepseek, openai, anthropic, etc.).
4. Completeness: Entries with both limits known are preferred over partially known entries.
5. Provider ID alphabetical order: Used as a stable fallback strategy.
Bare IDs (such as qwen3.7-max) perform case-insensitive matching on the final path segment (such as Qwen/Qwen3.7-Max).

Completed Fields

The plugin maps the following models.dev fields to DSH model configuration:
* name: Maps to the name field in models.dev.
* contextWindow: Maps to limit.context.
* maxTokens: Maps to limit.output.
* reasoningEfforts: Maps to reasoning_options[type=effort].values, filtered to an identity dictionary (such as {high:"high", max:"max"}).
* input: Maps to modalities.input, filtered to text or image.

Catalog Cache and Updates

  • Cache location: ~/.dsh/model-parameters/catalog.json (about 4 MB).
  • Update mechanism: The default cache TTL is 7 days. After the TTL expires, the next reconcile performs a lazy refresh.
  • Fault tolerance: If a fetch fails, the last successful cache is retained. If there is no cache at all, the plugin does not perform completion until a refresh succeeds.
  • Manual refresh: The settings card provides an “Update catalog now and populate” button, which can force a refresh and display the last update time and freshness.

Installation and Enablement

Install it using the dsh plugin command (replace --profile web with your actual profile name):

dsh plugin --profile web add @fonlan/dsh-model-parameters

After installation, go to DSH Settings → Plugins → Plugin Configuration, and expand the “Model Parameters Completion / Model Parameters” card to configure it.

Use Cases and Notes

  • Use cases: Scenarios where provider lists are incomplete and you need to rely on the models.dev catalog to obtain metadata.
  • Permission note: The plugin runs with the permissions of the current DSH process. It is recommended to review the source code and license (MIT) before installation.
  • Behavior note: Completion is fill-only and does not overwrite existing values. Models with no catalog match (such as local gateway models) remain unchanged and are listed as unmatched in the completion report.

Conclusion

By automating metadata completion, this plugin lowers the configuration barrier for agent development. For more details and source code, see the GitHub repository.