Files
deepseek-harness/package.json
Tianyi Cui ef45ca823a Fix schema-DSL findings from the second Codex review
InferArgs now produces genuinely optional keys: required/optional
properties are split at the key level (RequiredKeys + mapped `?`), so
{ limit: { type: 'number' } } infers as { limit?: number } and callers
can omit it — previously the key stayed required with `| undefined`.
Array item inference recurses (arrays of objects infer their element
shape instead of Record<string, unknown>), matching the generated
JSON Schema.

Tool execution error reporting handles non-Error throws again:
`throw { message: 'denied' }` reports the message instead of
"[object Object]" (errorMessage helper).

The new schema tests now actually typecheck: schema literals use
`satisfies SchemaSpec` (the standalone-literal widening made
schemaSpecToJsonSchema reject the suite's own examples), and the
ToolSchema probe cast goes through unknown. Tests-and-examples
typechecking is now part of `yarn typecheck` via the new
tsconfig.typecheck.json (resolves vendor packages by their built
declarations, so vendor's relaxed-strictness source stays out of
scope) — vitest never typechecks, so this gate is what catches such
breakage. +4 regression tests (typed omission, array-of-objects
inference both type- and runtime-level, non-Error throw message).
2026-06-11 13:46:01 +08:00

29 lines
695 B
JSON

{
"name": "@deepseek-ai/dsh-root",
"version": "0.0.1",
"private": true,
"type": "module",
"packageManager": "yarn@4.14.1",
"engines": {
"node": ">=24"
},
"workspaces": [
"vendor/*",
"packages/*"
],
"scripts": {
"build": "tsc -b tsconfig.build.json && tsx scripts/build.ts",
"typecheck": "tsc -b tsconfig.build.json && tsc -p tsconfig.typecheck.json",
"test": "vitest run",
"demo": "node --expose-internals --import tsx examples/echo-agent/start.ts"
},
"devDependencies": {
"@types/node": "^25.3.5",
"dumble": "^0.2.3",
"tsx": "^4.22.4",
"typescript": "^6.0.3",
"vite-tsconfig-paths": "^6.1.1",
"vitest": "^4.1.8"
}
}