JohnXu22786/model-catalog0

model-catalog

dsh 插件:模型目录自动发现 —— 从 OpenAI 兼容 API 主机自动拉取模型列表、定价与能力,归一化后生成可直接使用的配置。

包名
model-catalog
版本
1.0.0
许可证
MIT
最近更新
2026年8月16日

安装

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:JohnXu22786/model-catalog

Configuration

Config file catalog.config.json (in the plugin root; overridable with --config FILE; all fields optional):

{
  "baseUrl": "https://api.deepseek.com",
  "apiKeyEnv": "DEEPSEEK_API_KEY",
  "probe": "auto",
  "externalUrl": "https://example.com/mirror.json",
  "outputDir": "out",
  "cacheDir": "var",
  "httpTimeoutMs": 10000
}
FieldDefaultDescription
baseUrlnoneHost address; also --base-url on the CLI
apiKeyEnvautoKey environment variable name; auto-detects MODELCAT_API_KEY / DEEPSEEK_API_KEY / OPENAI_API_KEY
kindHintnoneForce host type (bare/augmented/quota/flag/ollama/vllm)
probeautoCapability probe mode
catalogTtlSec900Catalog freshness (reused by the plugin list tool)
probeTtlSec86400Probe result cache TTL
detectTtlSec3600Host classification cache TTL
externalUrlnoneExternal price mirror URL (structure in data/mirror.example.json)
outputDir / cacheDirout / varOutput and cache directories
concurrency4Fetch concurrency (e.g. Ollama /api/show)
httpTimeoutMs10000HTTP timeout

Keys are only passed via environment variables (--api-key is for transient CLI use only); no artifact file ever contains a plaintext key.