Replace the hardcoded DeepSeek rate table with a client-fetched price book: @opencode-ai/models reads the models.dev registry once per page load, every entry is re-proved at the boundary, and a failed fetch degrades to a dash + note with backed-off automatic retries. - cost totals rekey per (provider, model); only DeepSeek splits a pricing period (peak windows at list price, all other hours half price) — every other provider bills everything at list price - provider ids resolve through a shared rename table (deepseek-official, kimi-coding, minimax-cn, zai-coding-cn) with verbatim passthrough for unmapped ids; model ids match exactly, case-insensitively, or by suffix (k3 -> kimi-k3), ambiguous matches price nothing - CNY display converts at the fixed 1 CNY = 0.15 USD; the tooltip lists per-1M rates for the models the session billed, with peak|off-peak pairs and the DeepSeek note shown on DeepSeek sessions only - stateVersion 18: cached rows refold from the log, which rebuilds the new cost keys and periods
133 lines
3.7 KiB
JSON
133 lines
3.7 KiB
JSON
{
|
|
"name": "dsh-context",
|
|
"version": "0.50.0",
|
|
"description": "A DeepSeek Harness plugin for context insight and management, with context dashboard and context command, for understanding how the context is made of, and how it evolves.",
|
|
"author": "bowenliang123",
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git+https://github.com/bowenliang123/dsh-context.git"
|
|
},
|
|
"homepage": "https://github.com/bowenliang123/dsh-context",
|
|
"bugs": {
|
|
"url": "https://github.com/bowenliang123/dsh-context/issues"
|
|
},
|
|
"type": "module",
|
|
"engines": {
|
|
"node": "^22.19.0 || >=24.0.0"
|
|
},
|
|
"main": "lib/index.js",
|
|
"types": "lib/index.d.ts",
|
|
"exports": {
|
|
".": {
|
|
"types": "./lib/index.d.ts",
|
|
"default": "./lib/index.js"
|
|
},
|
|
"./client": "./lib/client.js",
|
|
"./package.json": "./package.json"
|
|
},
|
|
"files": [
|
|
"lib/client.js",
|
|
"lib/index.js",
|
|
"lib/index.d.ts",
|
|
"cordis.patch.yml",
|
|
"README.md",
|
|
"LICENSE"
|
|
],
|
|
"scripts": {
|
|
"build": "tsdown",
|
|
"lint": "oxlint",
|
|
"lint:fix": "oxlint --fix",
|
|
"watch": "bash scripts/watch.sh",
|
|
"web": "bash scripts/web.sh",
|
|
"register": "bash scripts/register.sh",
|
|
"typecheck": "tsc --noEmit && tsc --noEmit -p tsconfig.tests.json",
|
|
"test": "pnpm run typecheck && vitest run --coverage",
|
|
"coverage": "vitest run --coverage",
|
|
"release": "bash scripts/publish.sh",
|
|
"social-preview": "node docs/social-preview/generate.ts",
|
|
"prepare": "husky"
|
|
},
|
|
"dsh": {
|
|
"bundle": {
|
|
"patch": "./cordis.patch.yml"
|
|
},
|
|
"client": {
|
|
"inject": [
|
|
"@deepseek-ai/dsh-api-remotes",
|
|
"@deepseek-ai/dsh-client-connection",
|
|
"@deepseek-ai/dsh-client-locale",
|
|
"@deepseek-ai/dsh-client-ui-conversation",
|
|
"@deepseek-ai/dsh-client-ui-settings",
|
|
"@deepseek-ai/dsh-client-ui-sidebar-right"
|
|
],
|
|
"platform": "web"
|
|
},
|
|
"compatibility": {
|
|
"dshReleases": {
|
|
"0.1.2-rc.1": "compatible",
|
|
"0.1.3-alpha.2": "compatible",
|
|
"0.1.5-rc.1": "compatible"
|
|
}
|
|
}
|
|
},
|
|
"keywords": [
|
|
"deepseek-harness",
|
|
"dsh",
|
|
"cordis",
|
|
"plugin",
|
|
"context",
|
|
"token",
|
|
"ui"
|
|
],
|
|
"license": "Apache-2.0",
|
|
"dependencies": {
|
|
"zod": "^4.4.3"
|
|
},
|
|
"peerDependencies": {
|
|
"@deepseek-ai/cordis": "^4.0.2",
|
|
"@deepseek-ai/dsh-client-ui-primitives": ">=0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-session": ">=0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-settings": ">=0.1.2-rc.1",
|
|
"@deepseek-ai/schemastery": "^3.18.2",
|
|
"react": "^18.3.1"
|
|
},
|
|
"peerDependenciesMeta": {
|
|
"@deepseek-ai/dsh-client-ui-primitives": {
|
|
"optional": true
|
|
},
|
|
"react": {
|
|
"optional": true
|
|
}
|
|
},
|
|
"devDependencies": {
|
|
"@deepseek-ai/cordis": "^4.0.2",
|
|
"@deepseek-ai/dsh-client-ui-primitives": "0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-invariants": "0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-scope": "0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-session": "0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-session-projection": "0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-settings": "0.1.2-rc.1",
|
|
"@deepseek-ai/dsh-util-workspace-path": "0.1.5-rc.1",
|
|
"@deepseek-ai/schemastery": "^3.18.2",
|
|
"@opencode-ai/models": "^0.0.72",
|
|
"@stylistic/eslint-plugin": "^5.10.0",
|
|
"@types/node": "^26.2.0",
|
|
"@types/react": "^18.3.31",
|
|
"@types/react-dom": "^18.3.7",
|
|
"@vitest/coverage-v8": "^4.1.11",
|
|
"eslint-plugin-sonarjs": "^4.2.0",
|
|
"husky": "^9.1.7",
|
|
"jsdom": "^30.0.1",
|
|
"lightningcss": "^1.33.0",
|
|
"oxlint": "1.82.0",
|
|
"oxlint-tsgolint": "7.0.2001",
|
|
"playwright-core": "^1.62.1",
|
|
"react": "^18.3.1",
|
|
"react-dom": "^18.3.1",
|
|
"tsdown": "^0.23.0",
|
|
"typescript": "^7.0.2",
|
|
"vitest": "^4.1.11",
|
|
"zod": "^4.4.3"
|
|
}
|
|
}
|