taskflow 0.3.0-beta.1.2 · Trusted Effects beta

声明 effect。验证路径。让一个 authority 负责提交。

taskflow 把 coding-agent 工作变成可验证的运行时:显式任务图、类型化 effect 声明、隔离执行、受 resources 控制的文件提交,以及覆盖六个宿主的 ledger-backed 解释。

Trusted Effects Bench

一份合同,四个检查点。

声明、准入、事务、解释。

Declare
EffectIR / PathRef
Admit
labels · overlap
Authorize
principal · capability
Stage
snapshot · intent
Commit
or restore + reject
Ledger
durable evidence
Explain
why-effect
Evidence 回传verify
finalOutput
已声明的报告写入

PathRef 已准入。Resource intent 已提交。why-effect 可以解释 principal、capability、lifecycle 与 generation。

准入
effect
fs.write
PathRef
已解析
labels
通过
重叠
已检查
提交
snapshot
durable
intent
已记账
lifecycle
commit | restore
authority
resources
解释
why-effect
只读
principal
已推导
capability
已绑定
status
committed

0.3.0-beta.1.2 宿主安装;请显式选择 beta channel。

pi install npm:pi-taskflow@beta
指南

Runtime contract

这是修改边界,不是 prompt 承诺。

candidate 把副作用显式化,但不声称不存在的 sandbox。

声明

EffectIR 写出阶段 effect 的 kind、target、purpose、confidentiality 与 integrity。

准入

Resource transaction 继续前,先检查 PathRef 解析、标签流与 mutating-path 重叠。

解释

Durable ledger 支撑 why-authorized、why-context 与 why-effect,不消耗模型 token。

Release ledger

0.3 是 Trusted Effects 转身。

0.2 运行时仍是图引擎;candidate 在声明的文件 effect 周围增加类型化、可检查的边界。

EffectIR

让 effect 成为数据

封闭 effect kind、类型化 ref 与 labels 贯穿校验、FlowIR、哈希与运行时准入。

Resources

只有一个修改权威

Snapshot、lease、intent、stage、commit;事务不能完成时就 restore and reject。

why-*

Evidence 可以查询

why-effect 从 durable resource records 解释授权与生命周期,而不是复述模型 prose。

Boundary

安全声明保持窄

MVP 路径保护已声明目标;未声明写入与 OS-level sandbox 不在声明范围内。

0.3-C

Control Plane 在后面

ControlHost 目前是脚手架;store、receipt、审批与 WebUI 属于后续 0.3-C 阶段,还不是已发布的 0.3 GA 表面。

Hosts

六个宿主 · 一份 flow 合同

Pi、Codex、Claude Code、OpenCode、Grok、Hermes 共用 taskflow runtime,同时保留宿主策略差异。

Authoring surface

同一运行时,三种合同表面。

JSON 用于传输。TypeScript 用于编写。FlowIR 与 EffectIR 用于编译合同。

1{
2 "name": "review-changes",
3 "budget": { "maxUSD": 2 },
4 "phases": [
5 {
6 "id": "discover",
7 "type": "agent",
8 "agent": "scout",
9 "task": "List changed files as a JSON array of {path} objects",
10 "output": "json",
11 "expect": {
12 "type": "array",
13 "items": {
14 "type": "object",
15 "properties": { "path": { "type": "string" } },
16 "required": ["path"]
17 }
18 }
19 },
20 {
21 "id": "review",
22 "type": "map",
23 "over": "{steps.discover.json}",
24 "agent": "reviewer",
25 "task": "Review {item.path}",
26 "dependsOn": ["discover"]
27 },
28 {
29 "id": "report",
30 "type": "reduce",
31 "from": ["review"],
32 "task": "Prioritized risk summary",
33 "dependsOn": ["review"],
34 "final": true
35 }
36 ]
37}

Difference ledger

当 effect 成为数据,事情会怎么变。

不是 sandbox 宣言,而是运行边界。

taskflowad-hoc
authority
一个 resource finalizer
ambient command writes
target
typed PathRef + admission
隐式 path string
failure
restore + reject
partial mutation
evidence
ledger-backed why-effect
model explanation

taskflow 0.3 · candidate

把副作用写进合同。

声明目标,验证边界,让一个 authority 负责提交,并诚实地写出安全边界。