@antprofuse/saddle-skill 0.1.2 → 0.1.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/SKILL.md +21 -17
- package/agents/openai.yaml +3 -3
- package/assets/v1-business/Cargo.lock +1932 -0
- package/assets/v1-business/Cargo.toml +12 -0
- package/assets/v1-business/schema.sql +18 -0
- package/assets/v1-business/src/main.rs +42 -0
- package/assets/v1-business/src/order.rs +118 -0
- package/assets/v1-business/src/user.rs +54 -0
- package/package.json +5 -3
- package/references/db-0.1.1.md +96 -0
- package/references/gates-0.1.1.md +77 -0
- package/references/observability-0.1.1.md +69 -0
- package/references/overview-0.1.1.md +73 -0
- package/references/runtime-0.1.1.md +54 -0
- package/references/service-0.1.1.md +73 -112
- package/references/validation-0.1.1.md +50 -0
- package/scripts/check-business-boundaries.sh +5 -0
- package/scripts/check_business_boundaries.py +356 -0
package/SKILL.md
CHANGED
|
@@ -1,26 +1,30 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: saddle-service
|
|
3
|
-
description: 基于已发布的
|
|
3
|
+
description: 基于已发布的 `saddle-framework = "=0.1.1"` 构建和审查 Saddle V1 Rust 业务应用。当 AI Coding 需要创建单进程业务大库、Service 契约与内部调用、HTTP/JSON 入口、托管数据库查询与写入、单层事务、稳定错误、领域事件,或检查线程、运行时、Web、DB 和日志旁路时使用。
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# Saddle
|
|
6
|
+
# Saddle V1 研发契约
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
只将针对 crates.io `saddle-framework = "=0.1.1"` 编译通过的用法视为可用能力。
|
|
9
9
|
|
|
10
|
-
##
|
|
10
|
+
## 执行顺序
|
|
11
11
|
|
|
12
|
-
1.
|
|
13
|
-
2.
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
12
|
+
1. 阅读 [总览](references/overview-0.1.1.md),确定大库、模块和进程边界。
|
|
13
|
+
2. 按任务读取对应参考:
|
|
14
|
+
- Service 定义、注册、对外入口或内部调用:读 [Service](references/service-0.1.1.md)。
|
|
15
|
+
- 启动、异步执行或关闭边界:读 [Runtime](references/runtime-0.1.1.md)。
|
|
16
|
+
- 查询、写入、行解码或事务:读 [DB 与事务](references/db-0.1.1.md)。
|
|
17
|
+
- 稳定错误、Trace 上下文或领域事件:读 [Observability](references/observability-0.1.1.md)。
|
|
18
|
+
- 新增依赖或交付前检查:读 [门禁](references/gates-0.1.1.md)。
|
|
19
|
+
3. 新建应用时复制 `assets/v1-business`,再按领域修改;不要重新装配中间件。
|
|
20
|
+
4. 业务 crate 只直接依赖精确版本的 Saddle 门面和必要的纯计算/序列化依赖。
|
|
21
|
+
5. 完成后执行 [验证](references/validation-0.1.1.md) 中的编译、依赖和边界检查。
|
|
18
22
|
|
|
19
|
-
##
|
|
23
|
+
## 不可突破的边界
|
|
20
24
|
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
24
|
-
-
|
|
25
|
-
-
|
|
26
|
-
-
|
|
25
|
+
- 不读取、复制或修改 Saddle 中间件实现。
|
|
26
|
+
- 不创建线程、async runtime、脱离 Saddle 管理的 task、Web Server、路由器、连接池、底层事务或日志 subscriber。
|
|
27
|
+
- 不绕过 `ServiceClient` 调用其他业务模块,不绕过 `Database` 执行数据库 I/O。
|
|
28
|
+
- 不记录完整请求、响应、SQL 参数、凭据或任意敏感对象。
|
|
29
|
+
- 不使用设计文档中的目标替代已发布 API;编译失败时保留最小复现并提交控制 workspace。
|
|
30
|
+
- 不声称 0.1.1 支持定时任务、后台任务、消息消费、外部 HTTP/RPC、文件 I/O、多数据源、嵌套/分布式事务、Metrics 或跨进程调用。
|
package/agents/openai.yaml
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
interface:
|
|
2
|
-
display_name: "Saddle
|
|
3
|
-
short_description: "
|
|
4
|
-
default_prompt: "使用 $saddle-service
|
|
2
|
+
display_name: "Saddle V1 研发契约"
|
|
3
|
+
short_description: "使用已发布 API 构建完整 Saddle V1 业务应用"
|
|
4
|
+
default_prompt: "使用 $saddle-service 按 Saddle V1 契约实现并验证业务模块。"
|