@akagilnc/pi-workflow-roles 0.1.3737 → 0.1.3744

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.md CHANGED
@@ -59,13 +59,11 @@ ak-role config unset-engine judge
59
59
  ak-role config set-host judge grok-build
60
60
  ak-role config unset-host judge
61
61
  ak-role config set-auto-resume-limit 3
62
- ak-role config set-provider-alias xai hermes xai-oauth
63
- ak-role config unset-provider-alias xai hermes
64
62
  ```
65
63
 
66
64
  **Host axis (invocation-insensible after default):** `--host` is a global public option on every callable role and on `resume`. Resolution is invocation `--host` → persistent seat host (`config set-host`) → package default (`pi`). After `config set-host <seat> <name>`, the same command face used with Pi runs that seat on the named host with zero extra flags and zero caller-side changes; bare `resume` follows the same table. All public callable roles and their institutional sub-legs (soul audit, doctor audit, navigator, reviewer evidence children) are host-neutral on the shared in-process institutional session seam.
67
65
 
68
- **Provider host alias (#778):** seat rows keep one provider name; `config set-provider-alias <provider> <host> <alias>` registers an owner map so the same row hands the host the name it recognizes. Unregistered pairs pass the seat provider through unchanged — the package never invents pairs.
66
+ **Host providers (#788):** seat rows keep one provider name. Owner edits `~/.ak-roles/host-providers.json` (`{ "hermes": { "xai": "xai-oauth" } }`); code only reads it. Missing table entries ask the host directory (hermes this ticket): unique match wins, zero or many fail loud. Priority is table > unique > fail — no package discretion. `config show` prints the table as written.
69
67
 
70
68
  For Gate officers (`gatekeeper` / `inspector` / `notary`) resolution is officer pin → province (`gatekeeper`) pin → inherit parent session; an explicit selection that fails is loud and does not fall back. Configuration usage and refusal text are owned by `ak-role config` / `ak-role help config`. The persistent file is machine-wide and shared across CLI builds: seat keys this build does not know are skipped on read (not an error); unknown field-level keys on known seats keep their existing tolerance.
71
69
 
@@ -78,7 +76,7 @@ Gate submission gate: on DONE-side submissions (`completed` / `partially_complet
78
76
  The examples below are usage sketches; option identity, aliases, requiredness, and mode faces are owned by `ak-role help <command>`, not by a second flag contract here.
79
77
 
80
78
  ```bash
81
- # countersign — ticket-court review before work starts; resume continues the exact session
79
+ # countersign — ticket-court review before work starts; admission runs the ticket's diarist first (#742, caller-transparent); resume continues the exact session
82
80
  ak-role countersign --attach ./ticket.md "裁:本票 #582 是否足以开工。"
83
81
 
84
82
  # gleaner-left — unanchored pre-merge memorials; resume continues the exact session; --base required; instruction may be empty; callers must not pass directional instruction
@@ -118,10 +116,10 @@ ak-role gatekeeper --attach ./submission.json "审:这批材料该谁审?"
118
116
  # navigator — direct route advice (ordered next-role candidates); automatic attendance unchanged
119
117
  ak-role navigator "刚完成 coder apply 收敛,下一步?"
120
118
 
121
- # diarist — gather and organize this case's decision basis into its per-ticket 起居录
119
+ # diarist — gather and organize this case's decision basis into its per-ticket 起居录 (LLM resolves the ticket itself, no mechanical verification since #779; countersign admission runs it automatically, other stations summon it explicitly)
122
120
  ak-role diarist "整理 #708 的本案依据。"
123
121
 
124
- # countersign — ticket-court five questions; ticket recognition via instruction
122
+ # countersign — ticket-court five questions; ticket recognition via instruction; admission runs the ticket's diarist first (#742)
125
123
  ak-role countersign --attach ./ticket.md "裁:本票 #582 是否足以开工。"
126
124
 
127
125
  # analyst — deterministic metrics; bare call = whole book
package/README.zh-CN.md CHANGED
@@ -59,13 +59,11 @@ ak-role config unset-engine judge
59
59
  ak-role config set-host judge grok-build
60
60
  ak-role config unset-host judge
61
61
  ak-role config set-auto-resume-limit 3
62
- ak-role config set-provider-alias xai hermes xai-oauth
63
- ak-role config unset-provider-alias xai hermes
64
62
  ```
65
63
 
66
64
  **宿主轴(配置默认 host 后调用无感):** `--host` 为全局公开旗,全部可调用角色与 `resume` 受理。解析序为调用 `--host` → 席位持久 host(`config set-host`)→ 包默认(`pi`)。`config set-host <seat> <name>` 之后,与 Pi 完全相同的命令面即可在该席跑命名宿主——零额外旗、零调用侧改动;裸 `resume` 同序取表。全部 public callable 角色及其机构子腿(审刑审计、太医审计、游奕使、御史台证据子腿)在共享进程内机构子会话接缝上均为宿主中立。
67
65
 
68
- **Provider 宿主别名(#778):** 席位行只写一份 provider 名;`config set-provider-alias <provider> <host> <alias>` 由 owner 在席位表登记映射,使同一行在指定宿主下交出该宿主认得的名。未登记的 (provider, host) 原样透传——包内不内置任何对照。
66
+ **宿主 provider 表(#788):** 席位行只写一份 provider 名。owner 手改 `~/.ak-roles/host-providers.json`(形如 `{ "hermes": { "xai": "xai-oauth" } }`);代码只读。表里没有的问宿主目录(本票 hermes):唯一即用,零个或多个响亮失败。优先级:表 > 唯一 > 失败,代码无裁量。`config show` 原样打印该表。
69
67
 
70
68
  门下省官席解析顺序:官自钉 → 省钉(`gatekeeper`)→ 继承父 session;显式指定失败响亮、不回退。配置用法与拒绝文案以 `ak-role config`/`ak-role help config` 为准。持久配置是全机共享单文件、多 CLI 版本同读:本构建不认识的席位键读时跳过(不报错);已知席位上的未知字段沿用现行容忍。
71
69
 
@@ -112,7 +110,7 @@ ak-role gatekeeper --attach ./submission.json "审:这批材料该谁审?"
112
110
  # 游奕使——直调路线建议(有序的下一步角色候选);自动出席不变
113
111
  ak-role navigator "刚完成 coder apply 收敛,下一步?"
114
112
 
115
- # 给事中——票庭五问;票号经由 instruction 识别
113
+ # 给事中——票庭五问;票号经由 instruction 识别;受理内先自动起居郎再本席(#742,调用者无感)
116
114
  ak-role countersign --attach ./ticket.md "裁:本票 #582 是否足以开工。"
117
115
 
118
116
  # 左拾遗——合并前无锚定风闻;可 resume 续同一 session;--base 必填;instruction 可空;调用者不得传方向性 instruction
@@ -139,14 +137,14 @@ ak-role resume <runId> "<裁定>"
139
137
  | **大理寺** | judge | **审理定谳。** 承接各方意见与材料,依照既定规则逐项判断,辨明是非曲直。可以准行、退回或请示更高决定,但自身不参与建设与修改。 |
140
138
  | **审刑院** | judge-auditor/doctor-auditor(无 CLI,共享内部接缝;御史台侧闸已退役) | **复核成案。** 不重新争论事情本身,而是检查整个办理过程是否合乎规矩。关注是否有人越过职责、是否遗漏必要步骤、是否以错误方式得出正确结果。直属陛下,不入门下省编制。 |
141
139
  | **门下省** | gatekeeper(交卷闸不再自动出席;可 `ak-role gatekeeper` 独立直调) | **审署诏敕与质量保证的省。** 交卷闸按受审物直接传召察院/符宝郎,本省不介入选席;调用者仍可独立传召本省作 dispatch/pass;给事中票庭由调用者开工前传召;左拾遗由调用者合并前传召;省内政,不是外层编排器。规范见 [ADR 0067](docs/adr/0067-menxia-province-founding-jishizhong-fubaolang.md)、[ADR 0072](docs/adr/0072-menxia-pre-pr-submission-hooks.md)、[ADR 0074](docs/adr/0074-gate-province-reorg-jishizhong-chaiyuan-split.md)、[ADR 0079](docs/adr/0079-direct-officer-summons-ticket-memory-pointer-input.md)。 |
142
- | **给事中** | countersign(无交卷闸派发;开工前由调用者传召) | **票庭审读五问。** 制度符合/授权真实(以起居录为据)/文书符意/退回重议/发布资格;读码取证是本职,实现细节不上票面。起居录由起居郎(独立角色)修,先后归调用者;交卷闸出席符宝郎。署=放行开工,封驳=退票重议,上呈=陛下裁决。规范见 [ADR 0074](docs/adr/0074-gate-province-reorg-jishizhong-chaiyuan-split.md)、[ADR 0075](docs/adr/0075-ticket-provenance-diarist-pipeline.md)。 |
140
+ | **给事中** | countersign(无交卷闸派发;开工前由调用者传召) | **票庭审读五问。** 制度符合/授权真实(以起居录为据)/文书符意/退回重议/发布资格;读码取证是本职,实现细节不上票面。受理内自动先起居郎再本席(#742,调用者无感);其余衙门前的起居郎由调用者传召;交卷闸出席符宝郎。署=放行开工,封驳=退票重议,上呈=陛下裁决。规范见 [ADR 0074](docs/adr/0074-gate-province-reorg-jishizhong-chaiyuan-split.md)、[ADR 0075](docs/adr/0075-ticket-provenance-diarist-pipeline.md)。 |
143
141
  | **左拾遗** | gleaner-left(无交卷闸派发;合并前由调用者传召) | **合并前无锚定风闻。** 对全幅合并候选作冷眼评审;只上弹章、不封驳不裁决。规范见 [ADR 0067](docs/adr/0067-menxia-province-founding-jishizhong-fubaolang.md) 修正案。 |
144
142
  | **察院** | inspector | **事后察举:复杂度与测试质量两轴。** 受审物是将作监/修内司完成侧交卷;封驳=当场打回重写,不是本局失败。可被门下省派发,也可 `ak-role inspector` 单独调。原给事中,ADR 0074 分立。 |
145
143
  | **符宝郎** | notary | **首责唯一:核实实际授权出处**(防乱编乱扩)。行事两步:读该票起居录→以录核旨;引语真伪与票面对齐为手段。受审物是大理寺拟判与给事中署章;可被门下省派发,也可 `ak-role notary` 单独调。规范见 [ADR 0075](docs/adr/0075-ticket-provenance-diarist-pipeline.md)。 |
146
144
  | **通进司** | collector | **承接百议/收证。** 门下省下的收证衙门:收集外部 GitHub PR 材料与意见,只收不审、不替人裁决。canonical 键仍为 `collector`。 |
147
145
  | **校书郎** | merger | **雠校异文。** 面对不同来源的修改,负责整理、校合与调和。保留双方有价值的部分,解决彼此冲突;遇到无法自行决定之处,则留待重新裁量。 |
148
146
  | **游奕使** | navigator(自动出席,亦可 `ak-role navigator` 直调) | **巡行问路。** 不掌具体事务,而是观察全局变化,结合当前局面提醒下一步方向。它提供建议与路径参考,但最终选择仍由执掌之人决定。 |
149
- | **起居郎** | diarist(`ak-role diarist` 单独传召) | **修起居录。** 为本票搜集、整理决策依据,写进每票起居录;LLM 语义收集是它自己的 turn,机械保全带(来源枚举、逐字反验、幂等落盘、水印)为其工具门禁。只记录已作出的决定,不立法、不批准设计、不指挥施工。规范见 [ADR 0075](docs/adr/0075-ticket-provenance-diarist-pipeline.md) `diarist-is-role`、[ADR 0081](docs/adr/0081-diarist-case-context-and-delivery.md)。 |
147
+ | **起居郎** | diarist(`ak-role diarist` 单独传召;给事中受理内自动先起,#742) | **修起居录。** 为本票搜集、整理决策依据,写进每票起居录;LLM 自行搜集、整理、认票(#779 后无机械验真,机械只做 IO;起居录供符宝郎读录核旨)。只记录已作出的决定,不立法、不批准设计、不指挥施工。规范见 [ADR 0075](docs/adr/0075-ticket-provenance-diarist-pipeline.md) `diarist-is-role`、[ADR 0081](docs/adr/0081-diarist-case-context-and-delivery.md)。 |
150
148
 
151
149
  其余席位:
152
150