@agentshouse/panel-contract

中文文档
0.1.0-alpha.87385202698428发布于 2026/10/10UNLICENSEDTypeScriptES Module零依赖近 30 天下载 1.1万

What one agents.house release serves to its panel: every application-door act with its input and answer schema, every House document type with each field's value format, every Human Notification kind with its value fields, and the App runtime, adapter and

原始使用文档

@agentshouse/panel-contract

What one agents.house release serves to its panel. House generates it from its own code, and its version is derived from its content: two releases with equal contracts and recorded days carry one version.

import { contract, version } from '@agentshouse/panel-contract';

contract holds these parts, each schema a JSON Schema (2020-12):

  • acts - every application-door act by name, posted to /door/<name>, with its input schema and, once the act states one, its answer schema: the act's outcome alone.
  • refusals - every refusal code House answers, each once with the schema of its detail, the fields beside code in the answer's error. Any act may answer any of them.
  • door_answers - the answers the door gives any act that are no refusal: the credential challenge, the pending answer of a write still settling and the fault body.
  • runtime_calls - every act the App runtime's Call takes or answers in another form than the door, with the input the Call takes and the answer it completes with. attachments/upload takes the file's bytes as blob and answers the attachment its stored bytes name, with upload_failure when they were not saved, or the door's answer for a version House already holds; attachments/get answers an opened file's bytes as blob in place of the door's download; apps/upload takes each file's bytes as blob. A Blob is a schema whose contentMediaType is application/octet-stream.
  • documents - every House document type House writes, with the schema of its frontmatter fields, where it has them, and, where House writes one, its Markdown body. A list entry's word grammar is a pattern whose named groups are its words; a field that holds JSON names contentMediaType and its contentSchema.
  • room_documents - every document House reads or writes in a Room by its path rather than a House type: a Trigger and its routine and notification routes in a Room, a Routine in /private and a Site Submission in its Site's Intake Room, each with the path it lives at below its Room's root, the schema of its frontmatter fields and of its Markdown body.
  • notifications - every Human Notification kind with the value fields its house-notification document carries.
  • conversation_frames - every conversation frame the App runtime receives by its type: a turn's draft view with its plan steps, a working-note, a message, and the CLI's process, commands and options, each option a select with its values or a boolean.
  • served - the exact @agentshouse/mdruntime, @agentshouse/mdruntime-adapter and @agentshouse/app-bridge versions this release serves.

index.d.ts types contract as its literal value, so a schema can be turned into a TypeScript type at build time. contract.json holds the same value.

day.json (@agentshouse/panel-contract/day.json) is the recorded day: what House produced for a scripted day of real acts by several Users. users holds each User's House documents by path, acts each door answer with its act, User, request and status, a request string longer than 65,536 characters (an oversized upload's file content) recorded as <N characters>, frames each frame a User's App runtime received, as the worker hands it over (a turn's draft and plan frames as its draft view), with its User, and transfers each byte transfer through a grant an act answered, with its User, byte grant act, method, the grant's url, status and answer: the byte origin's JSON for a POST, and {media_type, content}, the bytes as base64, for a GET. Its instants are moved onto one fixed day, 16 October 2026, its identities are numbered from that day and no credential is kept.

版本与发布记录

@agentshouse/panel-contract 共发布 84 个版本,首次发布于 2026/10/05;过去 12 个月发布了 84 个版本。

版本发布日期距今
0.1.0-alpha.87385202698428latest2026/10/1028 天前
0.1.0-alpha.1033175811782332026/10/1028 天前
0.1.0-alpha.1303612661010122026/10/1028 天前
0.1.0-alpha.1419683475609652026/10/1028 天前
0.1.0-alpha.222988497337442026/10/1028 天前
0.1.0-alpha.1578714044277722026/10/1028 天前

关于 @agentshouse/panel-contract 的常见问题

@agentshouse/panel-contract 是什么?

What one agents.house release serves to its panel: every application-door act with its input and answer schema, every House document type with each field's value format, every Human Notification kind with its value fields, and the App runtime, adapter and

如何安装 @agentshouse/panel-contract?

在项目目录运行 npm install @agentshouse/panel-contract,或使用 pnpm add / yarn add / bun add。

@agentshouse/panel-contract 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@agentshouse/panel-contract 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@agentshouse/panel-contract 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js >=24。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@agentshouse/panel-contract 可以商用吗?

@agentshouse/panel-contract 使用 UNLICENSED 许可。作者声明为 UNLICENSED,即不授予公开使用许可(与公共领域的 Unlicense 不同)。使用前需获得作者授权。以上为概括,不构成法律意见,请以许可原文为准。

@agentshouse/panel-contract 的下载量有多少?

根据 npm 官方下载统计,@agentshouse/panel-contract 在 2026/10/05 – 2026/11/03 这 30 天内被下载 11,303 次,日均约 377 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@agentshouse/panel-contract 还在维护吗?

最新版本 0.1.0-alpha.87385202698428 发布于 2026/10/10(28 天前);至今共发布 84 个版本,其中过去 12 个月发布了 84 个;首次发布于 2026/10/05。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。