bailinghub 0.3.2-rc.1 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.en.md CHANGED
@@ -229,7 +229,7 @@ export default buildOpenApiSpec({
229
229
  - [Tool Governance](docs/TOOLS_DESIGN.en.md)
230
230
  - [AI-Friendly Tool Design](docs/AI_FRIENDLY_TOOLS.en.md)
231
231
  - [Third-Party Integration](docs/INTEGRATION.en.md)
232
- - [Latest Release Notes](docs/RELEASE_NOTES_v0.3.1.en.md)
232
+ - [Latest Release Notes](docs/RELEASE_NOTES_v0.3.3.en.md)
233
233
  - [v0.1.7 Release Notes](docs/RELEASE_NOTES_v0.1.7.en.md)
234
234
  - [v0.1.6 Release Notes](docs/RELEASE_NOTES_v0.1.6.en.md)
235
235
  - [v0.1.5 Release Notes](docs/RELEASE_NOTES_v0.1.5.en.md)
package/README.md CHANGED
@@ -227,6 +227,8 @@ BAILING_SMOKE_RUN_ROUTE=<route-key> npm run smoke
227
227
  | `docs/RELEASE_NOTES_v0.2.0.md` | `v0.2.0` 工具清单访问保护与主动核验说明 |
228
228
  | `docs/RELEASE_NOTES_v0.3.0.md` | `v0.3.0` 可组合 Core 与 Kernel Host API v1 说明 |
229
229
  | `docs/RELEASE_NOTES_v0.3.1.md` | `v0.3.1` PDF 解析安全更新说明 |
230
+ | `docs/RELEASE_NOTES_v0.3.2.md` | `v0.3.2` 受管演示数据引导说明 |
231
+ | `docs/RELEASE_NOTES_v0.3.3.md` | `v0.3.3` npm 发布来源元数据纠偏说明 |
230
232
  | `docs/RELEASE_NOTES_v0.1.0.md` | 首个公开版本的发布说明 |
231
233
  | `docs/兼容性与升级.md` | 版本发布策略:SemVer、稳定契约、数据库结构纪律、发布记录要求 |
232
234
  | `sql/` | 中枢**独立**状态库 DDL(`bz_` 前缀,按序号演进);数据库结构演进纪律见 [sql/README.md](sql/README.md) |
@@ -18,7 +18,7 @@ services:
18
18
  retries: 30
19
19
 
20
20
  demo-business:
21
- image: ${BAILING_DEMO_BUSINESS_IMAGE:-crpi-xm97pbcjrmf5in3s.cn-shanghai.personal.cr.aliyuncs.com/bailinghub/bailing-demo-business:0.3.1}
21
+ image: ${BAILING_DEMO_BUSINESS_IMAGE:-crpi-xm97pbcjrmf5in3s.cn-shanghai.personal.cr.aliyuncs.com/bailinghub/bailing-demo-business:0.3.3}
22
22
  environment:
23
23
  DEMO_HOST: 0.0.0.0
24
24
  DEMO_PORT: 19080
@@ -29,7 +29,7 @@ services:
29
29
  - "${BAILING_DEMO_PUBLIC_PORT:-19080}:19080"
30
30
 
31
31
  bailinghub:
32
- image: ${BAILINGHUB_IMAGE:-crpi-xm97pbcjrmf5in3s.cn-shanghai.personal.cr.aliyuncs.com/bailinghub/bailinghub:0.3.1}
32
+ image: ${BAILINGHUB_IMAGE:-crpi-xm97pbcjrmf5in3s.cn-shanghai.personal.cr.aliyuncs.com/bailinghub/bailinghub:0.3.3}
33
33
  depends_on:
34
34
  mysql:
35
35
  condition: service_healthy
@@ -24,6 +24,28 @@ Each public version should describe:
24
24
 
25
25
  There are no unreleased changes.
26
26
 
27
+ ## v0.3.3 - npm Publication Metadata Correction
28
+
29
+ Released on 2026-08-09.
30
+
31
+ - **Publication identity check**: publishes npm from an independent full Git clone of the exact Tag so Registry `gitHead`, the Tag commit, and public source can be checked consistently. `v0.3.2` remains immutable history and is not overwritten, moved, or republished.
32
+ - **Unchanged runtime**: `src/`, `sql/`, `web/`, `web-admin/`, `demo/`, and `sdk/` are unchanged from `v0.3.2`; the managed demo dataset capability is carried forward as-is.
33
+ - **Database schema**: there is no new migration; `054_demo_dataset_state.sql` remains the latest migration.
34
+ - **Integration impact**: Client API, Kernel Host API v1, the chat protocol, Executor Protocol, ACC, tool signatures, approval semantics, and final business authorization are unchanged.
35
+ - **Related docs**: [RELEASE_NOTES_v0.3.3.en.md](RELEASE_NOTES_v0.3.3.en.md) and the [v0.3.2 managed demo dataset notes](RELEASE_NOTES_v0.3.2.en.md).
36
+
37
+ ## v0.3.2 - Managed Demo Dataset Onboarding
38
+
39
+ Released on 2026-08-08.
40
+
41
+ - **Core-native onboarding**: adds demo dataset status, import, and clear Admin APIs together with the empty-instance console prompt. Demo targets, tool providers, routes, and clients are owned by the current tenant Core rather than an external private data layer.
42
+ - **Ownership and conflict safety**: adds a durable ownership manifest, fixed resource fingerprints, and transactional concurrency protection. Name collisions, user modifications, and external references return `409`; clearing never deletes jobs, messages, traces, or audit history.
43
+ - **Two runtime profiles**: keeps the complete Docker `full-local` demo and adds a loopback-only, stateless, read-only `stateless-readonly` profile for shared or embedded evaluation environments.
44
+ - **Database schema**: adds `054_demo_dataset_state.sql` and `bz_demo_datasets`, which store only the demo configuration set and fingerprints explicitly owned by Core. Run the official migrator before restarting the service.
45
+ - **Integration impact**: Client API, Kernel Host API v1, chat protocol, Executor Protocol, ACC, tool signatures, approval semantics, and final business authorization remain compatible. Instances without Demo Business configuration do not expose the import action.
46
+ - **Validation**: full `npm run release:check`, Docker demo coverage, npm artifact verification, and a manual candidate import, inspection, and clear flow from an empty instance.
47
+ - **Related docs**: [RELEASE_NOTES_v0.3.2.en.md](RELEASE_NOTES_v0.3.2.en.md), [Docker Demo](DEMO.en.md), [SQL migration discipline](../sql/README.en.md), and [Compatibility](COMPATIBILITY.en.md).
48
+
27
49
  ## v0.3.1 - PDF Parsing Security Update
28
50
 
29
51
  Released on 2026-08-07.
package/docs/CHANGELOG.md CHANGED
@@ -17,6 +17,28 @@
17
17
 
18
18
  当前无待发布变更。
19
19
 
20
+ ## v0.3.3 - npm 发布元数据纠偏
21
+
22
+ 发布日期:2026-08-09。
23
+
24
+ - **发布来源核对**:从精确 Tag 的独立完整 Git clone 发布 npm 包,使 Registry `gitHead`、Tag 提交与公开源码可以一致核对;`v0.3.2` 保留为不可变历史,不覆盖、不移动、不重发。
25
+ - **运行时不变**:`src/`、`sql/`、`web/`、`web-admin/`、`demo/` 与 `sdk/` 相对 `v0.3.2` 无变化,受管演示数据能力保持不变。
26
+ - **数据库结构**:没有新增迁移,最新迁移仍为 `054_demo_dataset_state.sql`。
27
+ - **对接影响**:Client API、Kernel Host API v1、聊天协议、Executor Protocol、ACC、工具签名、审批语义与最终业务授权均不变。
28
+ - **相关文档**:[RELEASE_NOTES_v0.3.3.md](RELEASE_NOTES_v0.3.3.md) 与 [v0.3.2 受管演示数据说明](RELEASE_NOTES_v0.3.2.md)。
29
+
30
+ ## v0.3.2 - 受管演示数据引导
31
+
32
+ 发布日期:2026-08-08。
33
+
34
+ - **Core 原生上手能力**:新增演示数据状态、导入与清理 Admin API,并恢复空实例的控制台引导;演示目标、工具源、路由和接入方由当前租户 Core 自己管理,不依赖外部私有数据层。
35
+ - **所有权与冲突保护**:新增持久 ownership manifest、固定资源指纹和事务级并发保护;同名占用、用户修改或外部引用均返回 `409`,清理不删除任务、消息、Trace 和审计历史。
36
+ - **双运行 profile**:保留 Docker `full-local` 完整演示,并增加只允许 loopback、无状态、只读工具的 `stateless-readonly` profile,供共享或宿主式体验环境安全复用。
37
+ - **数据库结构**:新增 `054_demo_dataset_state.sql` 和 `bz_demo_datasets`,只记录 Core 明确拥有的演示配置清单与指纹;升级先执行官方迁移器,再重启服务。
38
+ - **对接影响**:Client API、Kernel Host API v1、聊天协议、Executor Protocol、ACC、工具签名、审批语义和业务系统最终授权保持兼容;未配置 Demo Business 的实例不会显示可导入入口。
39
+ - **验证方式**:完整 `npm run release:check`、Docker demo、npm 制品检查,以及从空实例执行导入、浏览和清理的人工候选验证。
40
+ - **相关文档**:[RELEASE_NOTES_v0.3.2.md](RELEASE_NOTES_v0.3.2.md)、[Docker Demo](DEMO.md)、[SQL 迁移纪律](../sql/README.md) 与 [兼容性与升级](兼容性与升级.md)。
41
+
20
42
  ## v0.3.1 - PDF 解析安全更新
21
43
 
22
44
  发布日期:2026-08-07。
package/docs/DEMO.en.md CHANGED
@@ -33,6 +33,31 @@ Login:
33
33
  admin / bailing-demo-admin
34
34
  ```
35
35
 
36
+ ## Console Import And The Stateless Read-Only Profile
37
+
38
+ Core also provides a managed demo dataset that administrators can import from the onboarding prompt or setup page. It creates deterministic targets, tool providers, routes, and clients, but it does not fabricate jobs, approvals, costs, or audit history. A smoke run generates the runtime records through the real execution path.
39
+
40
+ The deployment supplies the demo endpoint and profile:
41
+
42
+ ```bash
43
+ DEMO_BUSINESS_URL=http://127.0.0.1:19080
44
+ DEMO_TOOL_SECRET=<independent-random-secret>
45
+ DEMO_PROFILE=stateless-readonly
46
+ ```
47
+
48
+ - `full-local` is the complete Docker demo with order lookup, ticket creation, refund approval, and failure tools.
49
+ - `stateless-readonly` is for shared or embedded evaluation environments. Demo Business must bind to loopback, exposes only order lookup and failure observation, stores no request state, uses no Hub callback, and creates no public chat entry.
50
+
51
+ Core records the exact objects it owns, together with their fingerprints, in the durable `bz_demo_datasets` manifest. Refresh and clear fail with `409` if a name is already occupied, a managed object changed, or another configuration references it. Clearing removes only unchanged, unreferenced demo configuration; jobs, messages, traces, and audit history remain intact.
52
+
53
+ The Admin API is:
54
+
55
+ - `GET /admin/api/demo-dataset/status`
56
+ - `POST /admin/api/demo-dataset/import`
57
+ - `DELETE /admin/api/demo-dataset`
58
+
59
+ Import and clear require all of `targets:write`, `tools:write`, `routes:write`, and `clients:write`. Status requires `audit:read` or the same aggregate write permissions.
60
+
36
61
  ## Smoke Test
37
62
 
38
63
  ```bash
@@ -7,7 +7,7 @@ It is not certification, a benchmark, or evidence of production adoption. Passin
7
7
  ## Scope
8
8
 
9
9
  - Target: the open-source BailingHub Docker demo;
10
- - Stable baseline: `v0.3.1`;
10
+ - Stable baseline: `v0.3.3`;
11
11
  - Data: the bundled demo orders, tickets, refunds, and failure probe;
12
12
  - Expected time: about 20 minutes after images and dependencies are available;
13
13
  - Not required: a real model key, production API, production credential, or real business data.
@@ -32,7 +32,7 @@ curl -fsSL https://www.bailinghub.com/install.sh | sh
32
32
  cd "$HOME/bailinghub"
33
33
  ```
34
34
 
35
- The installer pulls the official `v0.3.1` images by default, generates random tokens and an admin password, starts the services, and runs the smoke test. The initial administrator is created only when the administrator table is empty; restarting, upgrading, recreating containers, or reinstalling against the same persistent database does not overwrite a changed password. The optional `/metrics` endpoint remains disabled and does not affect core validation. Keep the reported version, install mode, elapsed time, and the commands printed under `常用命令`, but never include passwords or tokens in your report. After Docker is installed, the current non-root login usually still needs the printed `sudo docker compose ...` commands; Docker group membership may not take effect until the next login.
35
+ The installer pulls the official `v0.3.3` images by default, generates random tokens and an admin password, starts the services, and runs the smoke test. The initial administrator is created only when the administrator table is empty; restarting, upgrading, recreating containers, or reinstalling against the same persistent database does not overwrite a changed password. The optional `/metrics` endpoint remains disabled and does not affect core validation. Keep the reported version, install mode, elapsed time, and the commands printed under `常用命令`, but never include passwords or tokens in your report. After Docker is installed, the current non-root login usually still needs the printed `sudo docker compose ...` commands; Docker group membership may not take effect until the next login.
36
36
 
37
37
  If the default directory is already in use, choose a new empty directory instead of overwriting an existing deployment:
38
38
 
@@ -46,7 +46,7 @@ cd "$HOME/bailinghub-validation"
46
46
  ### Path B: local source reproduction
47
47
 
48
48
  ```bash
49
- git clone --depth 1 --branch v0.3.1 https://github.com/bailinghub/bailinghub.git
49
+ git clone --depth 1 --branch v0.3.3 https://github.com/bailinghub/bailinghub.git
50
50
  cd bailinghub
51
51
  git rev-parse HEAD
52
52
  export BAILING_TOKEN="$(openssl rand -hex 32)"
@@ -164,7 +164,7 @@ After the core task passes, you may continue with:
164
164
  - [Trusted rich rendering and chat reliability](RELEASE_NOTES_v0.1.15.en.md).
165
165
  - [Bounded tool runtime and resilient semantic retrieval](RELEASE_NOTES_v0.1.16.en.md).
166
166
  - [Composable Core and Kernel Host API v1](RELEASE_NOTES_v0.3.0.en.md).
167
- - [PDF parsing security update](RELEASE_NOTES_v0.3.1.en.md).
167
+ - [Current stable release notes](RELEASE_NOTES_v0.3.3.en.md).
168
168
 
169
169
  Select the relevant track in the same Issue form and disclose whether you received direct maintainer assistance.
170
170
 
@@ -7,7 +7,7 @@
7
7
  ## 验证范围
8
8
 
9
9
  - 验证对象:BailingHub 开源版 Docker demo;
10
- - 稳定基线:`v0.3.1`;
10
+ - 稳定基线:`v0.3.3`;
11
11
  - 数据范围:仓库自带的 demo 订单、工单、退款和故障工具;
12
12
  - 预计用时:镜像和依赖下载完成后约 20 分钟;
13
13
  - 不需要:真实大模型 Key、生产 API、生产凭据或真实业务数据。
@@ -32,7 +32,7 @@ curl -fsSL https://www.bailinghub.com/install.sh | sh
32
32
  cd "$HOME/bailinghub"
33
33
  ```
34
34
 
35
- 脚本默认拉取 `v0.3.1` 官方镜像,生成随机 Token 与后台密码,启动服务并自动运行基础体检。首次管理员只在数据库管理员表为空时创建;对同一持久化数据库进行重启、升级、容器重建或重新安装,不会覆盖已经修改的管理员密码。可选 `/metrics` 端点默认关闭,不影响基础验证。请保留终端输出中的版本、安装模式、耗时和“常用命令”,但不要把密码或 Token 写入反馈。新安装 Docker 后,当前非 root 会话通常仍需使用脚本打印的 `sudo docker compose ...` 命令;重新登录后 Docker 组权限才可能生效。
35
+ 脚本默认拉取 `v0.3.3` 官方镜像,生成随机 Token 与后台密码,启动服务并自动运行基础体检。首次管理员只在数据库管理员表为空时创建;对同一持久化数据库进行重启、升级、容器重建或重新安装,不会覆盖已经修改的管理员密码。可选 `/metrics` 端点默认关闭,不影响基础验证。请保留终端输出中的版本、安装模式、耗时和“常用命令”,但不要把密码或 Token 写入反馈。新安装 Docker 后,当前非 root 会话通常仍需使用脚本打印的 `sudo docker compose ...` 命令;重新登录后 Docker 组权限才可能生效。
36
36
 
37
37
  如果默认目录已被占用,请使用一个新的空目录,不要覆盖现有部署:
38
38
 
@@ -46,7 +46,7 @@ cd "$HOME/bailinghub-validation"
46
46
  ### 路径 B:本地源码复现
47
47
 
48
48
  ```bash
49
- git clone --depth 1 --branch v0.3.1 https://github.com/bailinghub/bailinghub.git
49
+ git clone --depth 1 --branch v0.3.3 https://github.com/bailinghub/bailinghub.git
50
50
  cd bailinghub
51
51
  git rev-parse HEAD
52
52
  export BAILING_TOKEN="$(openssl rand -hex 32)"
@@ -164,7 +164,7 @@ docker compose exec -T bailinghub npm run demo:e2e
164
164
  - [可信富内容渲染与聊天可靠性](RELEASE_NOTES_v0.1.15.md)。
165
165
  - [工具运行时收敛与语义检索韧性](RELEASE_NOTES_v0.1.16.md)。
166
166
  - [可组合 Core 与 Kernel Host API v1](RELEASE_NOTES_v0.3.0.md)。
167
- - [PDF 解析安全更新](RELEASE_NOTES_v0.3.1.md)。
167
+ - [当前稳定版发布说明](RELEASE_NOTES_v0.3.3.md)。
168
168
 
169
169
  扩展验证请在同一 Issue 模板中选择对应路径,并说明是否获得过维护者的直接帮助。
170
170
 
package/docs/README.en.md CHANGED
@@ -93,6 +93,10 @@ This directory contains public documentation for the open-source BailingHub proj
93
93
  | [RELEASE_NOTES_v0.3.0.md](RELEASE_NOTES_v0.3.0.md) | Chinese `v0.3.0` release notes. |
94
94
  | [RELEASE_NOTES_v0.3.1.en.md](RELEASE_NOTES_v0.3.1.en.md) | `v0.3.1` PDF parsing security update. |
95
95
  | [RELEASE_NOTES_v0.3.1.md](RELEASE_NOTES_v0.3.1.md) | Chinese `v0.3.1` release notes. |
96
+ | [RELEASE_NOTES_v0.3.2.en.md](RELEASE_NOTES_v0.3.2.en.md) | `v0.3.2` managed demo dataset onboarding. |
97
+ | [RELEASE_NOTES_v0.3.2.md](RELEASE_NOTES_v0.3.2.md) | Chinese `v0.3.2` release notes. |
98
+ | [RELEASE_NOTES_v0.3.3.en.md](RELEASE_NOTES_v0.3.3.en.md) | `v0.3.3` npm publication provenance-metadata correction. |
99
+ | [RELEASE_NOTES_v0.3.3.md](RELEASE_NOTES_v0.3.3.md) | Chinese `v0.3.3` release notes. |
96
100
  | [RELEASE_NOTES_v0.1.0.en.md](RELEASE_NOTES_v0.1.0.en.md) | First public release notes. |
97
101
  | [CHANGELOG.en.md](CHANGELOG.en.md) | Public changelog format and current release summary. |
98
102
  | [COMPATIBILITY.en.md](COMPATIBILITY.en.md) | Versioning, compatibility, migration, and schema discipline. |
package/docs/README.md CHANGED
@@ -106,6 +106,10 @@
106
106
  | [RELEASE_NOTES_v0.3.0.en.md](RELEASE_NOTES_v0.3.0.en.md) | English `v0.3.0` composable Core and Kernel Host API v1 release notes. |
107
107
  | [RELEASE_NOTES_v0.3.1.md](RELEASE_NOTES_v0.3.1.md) | `v0.3.1` PDF 解析安全更新说明。 |
108
108
  | [RELEASE_NOTES_v0.3.1.en.md](RELEASE_NOTES_v0.3.1.en.md) | English `v0.3.1` PDF parsing security update. |
109
+ | [RELEASE_NOTES_v0.3.2.md](RELEASE_NOTES_v0.3.2.md) | `v0.3.2` 受管演示数据引导说明。 |
110
+ | [RELEASE_NOTES_v0.3.2.en.md](RELEASE_NOTES_v0.3.2.en.md) | English `v0.3.2` managed demo dataset onboarding. |
111
+ | [RELEASE_NOTES_v0.3.3.md](RELEASE_NOTES_v0.3.3.md) | `v0.3.3` npm 发布来源元数据纠偏说明。 |
112
+ | [RELEASE_NOTES_v0.3.3.en.md](RELEASE_NOTES_v0.3.3.en.md) | English `v0.3.3` npm publication provenance-metadata correction. |
109
113
  | [RELEASE_NOTES_v0.1.0.md](RELEASE_NOTES_v0.1.0.md) | 首个公开版本的 GitHub Release 草稿。 |
110
114
  | [RELEASE_NOTES_v0.1.0.en.md](RELEASE_NOTES_v0.1.0.en.md) | English release notes. |
111
115
  | [CHANGELOG.md](CHANGELOG.md) | 公开发布后的对外变更记录。 |
@@ -0,0 +1,57 @@
1
+ # BailingHub v0.3.2: Managed Demo Dataset Onboarding
2
+
3
+ `v0.3.2` makes empty-instance demo import a Core-owned onboarding capability. Administrators can import a deterministic set of targets, tool providers, routes, and clients from the console, inspect or exercise them through a real smoke run, and later clear only the configuration that Core can still prove it owns. No external data fork or hidden initialization path is required.
4
+
5
+ ## Who should upgrade
6
+
7
+ - Deployments that want new users to understand targets, tool providers, routes, and clients from an empty instance;
8
+ - self-hosted environments that need repeatable import, refresh, and clear operations for the official demo configuration;
9
+ - Kernel Host API consumers that want the same onboarding model in each isolated Core.
10
+
11
+ Existing instances do not import anything automatically. The console shows the action only when Demo Business is configured and the current principal has the aggregate write permissions.
12
+
13
+ ## What changed
14
+
15
+ - Adds `GET /admin/api/demo-dataset/status`, `POST /admin/api/demo-dataset/import`, and `DELETE /admin/api/demo-dataset`.
16
+ - Adds an empty-instance console prompt plus import, refresh, and clear actions on the setup page.
17
+ - Core stores a durable ownership manifest and fixed fingerprints for the demo objects it creates. Existing names, user modifications, or external references return `409`; the service never guesses ownership or overwrites user configuration.
18
+ - Import and clear run inside a transaction and a dataset-level advisory lock. First creation uses conflict-closed inserts so concurrent requests cannot replace same-name objects.
19
+ - Clear removes only demo configuration that the manifest still proves is owned, unchanged, and unreferenced. Jobs, messages, traces, and audit entries are real runtime history and remain intact.
20
+ - `demo-business` now has two explicit profiles:
21
+ - `full-local` retains the Docker demo for order lookup, ticket creation, refund approval, and failure diagnosis;
22
+ - `stateless-readonly` requires loopback binding and exposes only signed order lookup and a failure probe, with no mutable state, business writes, or approval callbacks.
23
+
24
+ ## Database and upgrade
25
+
26
+ Migration `054_demo_dataset_state.sql` adds `bz_demo_datasets`. It stores only the dataset version, owned-resource manifest and fingerprints, and timestamps. Run the official migrator before restarting:
27
+
28
+ ```bash
29
+ npm run db:init
30
+ ```
31
+
32
+ Hosts that compose Core through Kernel Host API v1 should keep using their existing explicit migration and drain workflow.
33
+
34
+ ## Configuration
35
+
36
+ To enable console import, provide:
37
+
38
+ ```bash
39
+ DEMO_BUSINESS_URL=http://127.0.0.1:19080
40
+ DEMO_TOOL_SECRET=<independent-random-secret>
41
+ DEMO_PROFILE=stateless-readonly
42
+ ```
43
+
44
+ Shared or embedded environments must use `stateless-readonly`, a loopback URL, and independent random signing material. The value is stored in each tenant's demo tool provider and can be revealed by a tenant administrator with the relevant management permission, so it must never be reused as a platform, tenant, or real business secret.
45
+
46
+ ## Compatibility and validation
47
+
48
+ - Client API, Kernel Host API v1, the chat protocol, Executor Protocol, ACC, tool signatures, approval semantics, and final business authorization remain compatible.
49
+ - Production instances without Demo Business configuration keep their existing behavior: demo status is unavailable and the console does not expose the import action.
50
+ - Release validation covers the full `npm run release:check`, Docker demo, npm tarball inspection, concurrency and conflict tests, and a manual import, inspection, and clear flow from an empty instance.
51
+
52
+ ## Related documentation
53
+
54
+ - [Docker Demo](DEMO.en.md)
55
+ - [SQL migration discipline](../sql/README.en.md)
56
+ - [Compatibility](COMPATIBILITY.en.md)
57
+ - [中文发布说明](RELEASE_NOTES_v0.3.2.md)
@@ -0,0 +1,57 @@
1
+ # BailingHub v0.3.2:受管演示数据引导
2
+
3
+ `v0.3.2` 将空实例的演示数据导入正式收敛为 BailingHub Core 自己拥有的上手能力。管理员可以从控制台导入一组确定性的目标、工具源、路由和接入方,完成浏览或真实 smoke 后再精确清理,而不需要依赖某个外部数据分叉或隐藏的初始化脚本。
4
+
5
+ ## 谁适合升级
6
+
7
+ - 希望新用户在空实例中快速理解目标、工具源、路由和接入方关系的部署;
8
+ - 需要从控制台重复导入、刷新或清理官方演示配置的自托管环境;
9
+ - 通过 Kernel Host API 承载多个隔离 Core,并希望为每个租户提供相同上手心智的宿主。
10
+
11
+ 已有实例不会自动导入任何演示对象。只有配置了 Demo Business、且当前账号具备聚合写权限时,控制台才会显示导入入口。
12
+
13
+ ## 主要变化
14
+
15
+ - 新增 `GET /admin/api/demo-dataset/status`、`POST /admin/api/demo-dataset/import` 和 `DELETE /admin/api/demo-dataset`。
16
+ - 空实例首次进入控制台时可以看到导入提示;设置页提供导入、刷新和清理操作。
17
+ - Core 使用持久 ownership manifest 与固定资源指纹记录自己创建的演示对象。名称已被占用、对象已被用户修改或已被外部配置引用时返回 `409`,不会猜测所有权或覆盖用户配置。
18
+ - 导入和清理运行在事务与演示数据集互斥锁内;首次创建使用冲突关闭式写入,避免并发请求覆盖同名对象。
19
+ - 清理只删除仍由 manifest 证明拥有、且未被修改和引用的演示配置。任务、消息、Trace 与审计是实际运行历史,不随配置清理删除。
20
+ - `demo-business` 支持两个明确 profile:
21
+ - `full-local` 保留 Docker demo 的查单、工单、退款审批和故障演示;
22
+ - `stateless-readonly` 只允许 loopback 监听,只提供签名查单与故障探针,不保存请求状态、不提供业务写入或审批回调。
23
+
24
+ ## 数据库与升级
25
+
26
+ 新增迁移 `054_demo_dataset_state.sql`,创建 `bz_demo_datasets`,只保存 Core 明确拥有的演示数据集版本、资源 manifest、指纹与时间。升级时先执行官方迁移器:
27
+
28
+ ```bash
29
+ npm run db:init
30
+ ```
31
+
32
+ 迁移成功后再按现有方式重启服务。通过 Kernel Host API 组合 Core 的宿主继续使用既有显式 migration 与排空流程。
33
+
34
+ ## 配置
35
+
36
+ 需要控制台导入能力时,由部署环境提供:
37
+
38
+ ```bash
39
+ DEMO_BUSINESS_URL=http://127.0.0.1:19080
40
+ DEMO_TOOL_SECRET=<independent-random-secret>
41
+ DEMO_PROFILE=stateless-readonly
42
+ ```
43
+
44
+ 共享或宿主式环境必须使用 `stateless-readonly`、回环地址和独立随机签名材料。该签名材料会进入租户自己的演示工具源,具备相应管理权限的租户管理员可以显式读取,因此不能与平台、租户或真实业务密钥复用。
45
+
46
+ ## 兼容性与验证
47
+
48
+ - Client API、Kernel Host API v1、聊天协议、Executor Protocol、ACC、工具签名、审批语义和业务系统最终授权保持兼容。
49
+ - 未配置 Demo Business 的生产实例行为不变,演示数据状态返回不可用,控制台不会展示导入动作。
50
+ - 发布验证覆盖完整 `npm run release:check`、Docker demo、npm tarball、并发与冲突测试,以及空实例的人工导入、浏览和清理。
51
+
52
+ ## 相关文档
53
+
54
+ - [Docker Demo](DEMO.md)
55
+ - [SQL 迁移纪律](../sql/README.md)
56
+ - [兼容性与升级](兼容性与升级.md)
57
+ - [English release notes](RELEASE_NOTES_v0.3.2.en.md)
@@ -0,0 +1,28 @@
1
+ # BailingHub v0.3.3: npm Publication Metadata Correction
2
+
3
+ `v0.3.3` is a publication-metadata-only correction to `v0.3.2`. The `v0.3.2` npm artifact contents and integrity checks were valid, but npm Registry did not contain the `gitHead` field used by BailingHub's release gate to match the package to public source. That immutable version remains part of the release history; it was not overwritten, moved, or republished.
4
+
5
+ ## What this corrects
6
+
7
+ - Publishes the npm package from the exact Tag in an independent full Git clone so Registry `gitHead`, the Git Tag commit, and public source can be checked consistently.
8
+ - Aligns the default installer, image tags, independent-validation baseline, and current release notes on `v0.3.3`.
9
+ - Carries forward the managed demo dataset import, refresh, and clear capability introduced in `v0.3.2` without changing runtime behavior.
10
+
11
+ ## Compatibility and upgrade
12
+
13
+ - Runtime content under `src/`, `sql/`, `web/`, `web-admin/`, `demo/`, and `sdk/` is unchanged from `v0.3.2`.
14
+ - There is no new database migration; `054_demo_dataset_state.sql` remains the latest migration.
15
+ - Client API, Kernel Host API v1, the chat protocol, Executor Protocol, ACC, tool signatures, approval semantics, and final business authorization are unchanged.
16
+ - Deployments already on `v0.3.2` can upgrade as a normal patch release; new deployments should use `v0.3.3` directly.
17
+
18
+ ## Validation
19
+
20
+ This release repeats the complete `npm run release:check` gate and then verifies the npm Registry version, integrity, tarball, and exact Git commit. The GitHub Release and public installation distribution are created only after every readiness check passes.
21
+
22
+ ## Related documentation
23
+
24
+ - [v0.3.2 managed demo dataset onboarding](RELEASE_NOTES_v0.3.2.en.md)
25
+ - [Docker Demo](DEMO.en.md)
26
+ - [SQL migration discipline](../sql/README.en.md)
27
+ - [Compatibility](COMPATIBILITY.en.md)
28
+ - [中文发布说明](RELEASE_NOTES_v0.3.3.md)
@@ -0,0 +1,28 @@
1
+ # BailingHub v0.3.3:npm 发布元数据纠偏
2
+
3
+ `v0.3.3` 是 `v0.3.2` 的仅发布元数据修正版。`v0.3.2` 的 npm 制品内容与完整性校验均正常,但 npm Registry 缺少用于核对源码提交的 `gitHead` 字段,因此没有通过 BailingHub 的完整发布就绪门禁。该不可变版本保留为历史事实;维护者没有覆盖、移动或重新发布它。
4
+
5
+ ## 这次修正了什么
6
+
7
+ - 从独立完整 Git clone 的精确 Tag 目录发布 npm 包,使 Registry 中的 `gitHead`、Git Tag 提交与公开源码可以被一致核对。
8
+ - 将默认安装器、镜像标签、独立验证基线和当前发布说明统一到 `v0.3.3`。
9
+ - 保留 `v0.3.2` 引入的受管演示数据导入、刷新和清理能力,不改变运行时行为。
10
+
11
+ ## 兼容性与升级
12
+
13
+ - `src/`、`sql/`、`web/`、`web-admin/`、`demo/` 与 `sdk/` 的运行时内容相对 `v0.3.2` 没有变化。
14
+ - 不新增数据库迁移;最新迁移仍为 `054_demo_dataset_state.sql`。
15
+ - Client API、Kernel Host API v1、聊天协议、Executor Protocol、ACC、工具签名、审批语义和业务系统最终授权保持不变。
16
+ - 正在使用 `v0.3.2` 的部署可以按普通补丁版本升级到 `v0.3.3`;新部署应直接使用 `v0.3.3`。
17
+
18
+ ## 验证
19
+
20
+ 本版本继续执行完整 `npm run release:check`,并在发布后核对 npm Registry 的版本、完整性摘要、Tarball 与精确 Git 提交。只有发布就绪门禁全部通过后,才创建 GitHub Release 并同步公开安装分发。
21
+
22
+ ## 相关文档
23
+
24
+ - [v0.3.2 受管演示数据引导](RELEASE_NOTES_v0.3.2.md)
25
+ - [Docker Demo](DEMO.md)
26
+ - [SQL 迁移纪律](../sql/README.md)
27
+ - [兼容性与升级](兼容性与升级.md)
28
+ - [English release notes](RELEASE_NOTES_v0.3.3.en.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bailinghub",
3
- "version": "0.3.2-rc.1",
3
+ "version": "0.3.3",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "Open-source ACC runtime and agent control plane for existing business systems.",
@@ -47,7 +47,7 @@
47
47
  "node": ">=22"
48
48
  },
49
49
  "publishConfig": {
50
- "tag": "next"
50
+ "tag": "latest"
51
51
  },
52
52
  "scripts": {
53
53
  "start": "tsx src/server.ts",
@@ -98,6 +98,8 @@ const englishCompanions = {
98
98
  'docs/RELEASE_NOTES_v0.2.0.md': 'docs/RELEASE_NOTES_v0.2.0.en.md',
99
99
  'docs/RELEASE_NOTES_v0.3.0.md': 'docs/RELEASE_NOTES_v0.3.0.en.md',
100
100
  'docs/RELEASE_NOTES_v0.3.1.md': 'docs/RELEASE_NOTES_v0.3.1.en.md',
101
+ 'docs/RELEASE_NOTES_v0.3.2.md': 'docs/RELEASE_NOTES_v0.3.2.en.md',
102
+ 'docs/RELEASE_NOTES_v0.3.3.md': 'docs/RELEASE_NOTES_v0.3.3.en.md',
101
103
  'docs/TOOLS_DESIGN.md': 'docs/TOOLS_DESIGN.en.md',
102
104
  'docs/TOOLS_MODEL.md': 'docs/TOOLS_MODEL.en.md',
103
105
  'docs/AI友好工具设计指南.md': 'docs/AI_FRIENDLY_TOOLS.en.md',
@@ -9,7 +9,7 @@ REGISTRY="${BAILING_IMAGE_REGISTRY:-$DEFAULT_REGISTRY}"
9
9
  NAMESPACE="${BAILING_IMAGE_NAMESPACE:-$DEFAULT_NAMESPACE}"
10
10
  PACKAGE_VERSION="$(sed -n 's/.*"version"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' package.json | head -1)"
11
11
  TAG="${BAILING_IMAGE_TAG:-$PACKAGE_VERSION}"
12
- [ -n "$TAG" ] || TAG="0.3.1"
12
+ [ -n "$TAG" ] || TAG="0.3.3"
13
13
  MYSQL_TAG="${BAILING_MYSQL_IMAGE_TAG:-8.4}"
14
14
  MYSQL_IMAGE="${BAILING_MYSQL_IMAGE:-$REGISTRY/$NAMESPACE/bailing-mysql:$MYSQL_TAG}"
15
15
  PLATFORM="${BAILING_IMAGE_PLATFORM:-linux/amd64}"
@@ -38,9 +38,9 @@ function updateJson(root, relativePath, update) {
38
38
  test('current release surface is internally consistent', () => {
39
39
  const result = checkReleaseConsistency({ root: repoRoot });
40
40
  assert.deepEqual(result.findings, []);
41
- assert.equal(result.version, '0.3.2-rc.1');
42
- assert.equal(result.stableVersion, '0.3.1');
43
- assert.equal(result.publishTag, 'next');
41
+ assert.equal(result.version, '0.3.3');
42
+ assert.equal(result.stableVersion, '0.3.3');
43
+ assert.equal(result.publishTag, 'latest');
44
44
  });
45
45
 
46
46
  for (const [label, tag] of [
@@ -51,9 +51,14 @@ for (const [label, tag] of [
51
51
  const root = createFixture();
52
52
  try {
53
53
  updateJson(root, 'package.json', (pkg) => {
54
+ pkg.version = '0.3.3-rc.1';
54
55
  if (tag === undefined) delete pkg.publishConfig;
55
56
  else pkg.publishConfig = { tag };
56
57
  });
58
+ updateJson(root, 'package-lock.json', (lock) => {
59
+ lock.version = '0.3.3-rc.1';
60
+ lock.packages[''].version = '0.3.3-rc.1';
61
+ });
57
62
 
58
63
  const result = checkReleaseConsistency({ root });
59
64
  assert.ok(
@@ -275,7 +275,7 @@ write_env() {
275
275
  TOOL_SECRET="${DEMO_TOOL_SECRET:-$(secret)}"
276
276
  CLIENT_TOKEN="${DEMO_CLIENT_TOKEN:-$(secret)}"
277
277
  IMAGE_TAG="${BAILING_IMAGE_TAG:-$(sed -n 's/.*"version"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' "$APP_DIR/package.json" | head -1)}"
278
- [ -n "$IMAGE_TAG" ] || IMAGE_TAG="0.3.1"
278
+ [ -n "$IMAGE_TAG" ] || IMAGE_TAG="0.3.3"
279
279
  IMAGE_REGISTRY="${BAILING_IMAGE_REGISTRY:-$DEFAULT_IMAGE_REGISTRY}"
280
280
  IMAGE_NAMESPACE="${BAILING_IMAGE_NAMESPACE:-$DEFAULT_IMAGE_NAMESPACE}"
281
281
  cat > "$ENV_FILE" <<EOF
@@ -9,7 +9,7 @@ REGISTRY="${BAILING_IMAGE_REGISTRY:-$DEFAULT_REGISTRY}"
9
9
  NAMESPACE="${BAILING_IMAGE_NAMESPACE:-$DEFAULT_NAMESPACE}"
10
10
  PACKAGE_VERSION="$(sed -n 's/.*"version"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' package.json | head -1)"
11
11
  TAG="${BAILING_IMAGE_TAG:-$PACKAGE_VERSION}"
12
- [ -n "$TAG" ] || TAG="0.3.1"
12
+ [ -n "$TAG" ] || TAG="0.3.3"
13
13
  NODE_IMAGE="${BAILING_NODE_IMAGE:-node:22-bookworm-slim}"
14
14
  PLATFORM="${BAILING_IMAGE_PLATFORM:-linux/amd64}"
15
15
  PUSH="${BAILING_PUSH_IMAGES:-0}"
@@ -29,7 +29,8 @@ const requiredRepoFiles = [
29
29
  'docs/RELEASE_NOTES_v0.1.16.md',
30
30
  'docs/RELEASE_NOTES_v0.2.0.md',
31
31
  'docs/RELEASE_NOTES_v0.3.0.md',
32
- 'docs/RELEASE_NOTES_v0.3.1.md',
32
+ 'docs/RELEASE_NOTES_v0.3.2.md',
33
+ 'docs/RELEASE_NOTES_v0.3.3.md',
33
34
  'docs/CHANGELOG.md',
34
35
  'docs/CLIENT_API.md',
35
36
  'config.example.json',
@@ -121,7 +121,8 @@ const requiredFiles = [
121
121
  'docs/RELEASE_NOTES_v0.1.16.md',
122
122
  'docs/RELEASE_NOTES_v0.2.0.md',
123
123
  'docs/RELEASE_NOTES_v0.3.0.md',
124
- 'docs/RELEASE_NOTES_v0.3.1.md',
124
+ 'docs/RELEASE_NOTES_v0.3.2.md',
125
+ 'docs/RELEASE_NOTES_v0.3.3.md',
125
126
  'docs/CHANGELOG.md',
126
127
  ];
127
128
  for (const file of requiredFiles) requireFile(file);