dsh-cc/dsh-cc--packages-core-tool-structured-output ↗★ 1

@dsh-cc/tool-structured-output

StructuredOutput 工具,按调用方 JSON schema 校验并原样返回输入。 适合需模型输出结构化 JSON 的开发者;需提供 schema。

套件
@dsh-cc/tool-structured-output
相容性
待驗證
Harness 依賴範圍
>=0.1.5-rc.1
Cordis 依賴範圍
>=0.1.5-rc.1
版本
0.7.1
授權
Apache-2.0
最近更新
2026年9月16日

安裝

此插件尚未提供可驗證的 bundle,或相容性檢查未通過。請先閱讀倉庫說明。 閱讀完整 README ↗

Usage

const tool = createStructuredOutputTool({
  type: 'object',
  additionalProperties: false,
  properties: {
    title: { type: 'string' },
    count: { type: 'integer' },
  },
  required: ['title', 'count'],
})
ctx.tools.register(tool)