docs(wechat): 合入扫码账号渠道简化
Some checks failed
Electron E2E / Electron E2E (macos-latest) (push) Has been cancelled
Electron E2E / Electron E2E (ubuntu-latest) (push) Has been cancelled
Electron E2E / Electron E2E (windows-latest) (push) Has been cancelled

This commit is contained in:
2026-09-14 12:18:05 +08:00
parent 21e707d9c4
commit 9c79eeca25
6 changed files with 77 additions and 7 deletions

View File

@@ -27,9 +27,9 @@ Accepted / implemented,2026-09-11 集成。产品范围、三端分工、创
## Personal WeChat Publication(2026-09-13 accepted / implemented)
- Published cloud agents expose a native personal WeChat panel: create/adopt account, local QR rendering, login verification, direct use by the scanning owner, contact invitations, access revocation, enable/pause, route switch, disconnect, safe activity and failed-file retry. Creator self-pairing codes are removed, including stale recovery presentation; invited contacts still receive a complete invitation command.
- The native Channels page owns account creation, local QR rendering, login verification, direct use by the scanning account, enable/pause, route switch, disconnect, safe activity and failed-file retry. Agent publication provides a linked-account summary. Pairing codes, contact invitations, audience configuration and caller management are removed.
- Renderer uses typed Host operations. Main owns credentials, network, per-account durable original operations and file saving. Verification codes never enter the recovery journal; uncertain mutations require explicit recovery.
- QR payloads are encoded locally. Account or Provider-generation changes clear transient state. Enable confirmation shows the actual published version, audience and task/daily budget, including zero.
- QR payloads are encoded locally. Account or Provider-generation changes clear transient state. Each selected account exposes its connection and current target; budgets remain the existing Agent policy.
- Own WeChat conversations use dedicated Yuxi session endpoints for approval, stop/new session, complete history pagination and automatically refreshed deliverables. The creator cannot browse invited callers' content.
- The scanning owner's first message establishes their history and available notification conversation. Scheduled result notification requires an explicitly selected self target. Execution completion and WeChat delivery status remain distinct; retrying a failed file part does not run the model again.
@@ -39,13 +39,23 @@ Source `2e710db0fb512f276fda8ae8a3939d366b34a972`, [source task](../30-worklog/t
- 用户在 MakeLore 的“渠道 > 微信”统一管理多个个人微信账号;账号可以先创建、扫码连接,再选择自己已发布的智能体。每个账号只有一个可选当前目标,多个账号可路由到同一智能体。
- AgentBus Core 的 ChannelAccount 继续拥有账号、当前路由、代次和操作回执;无目标创建默认停用,请求体不增加 `enabled` 字段。清空目标必须停用,切换或清空路由保留微信登录凭据与 Provider generation。
- Yuxi 提供用户级 `/api/makelore/channel-accounts` 与按操作 ID 恢复的接口。已有 Agent binding 仅索引当前路由,历史 caller/session 保留;旧渠道与无目标账号均按 Core 账号清单呈现。多个账号分别保留通知目标和权限范围。
- MakeLore Main 继续拥有凭据、请求与持久恢复,Renderer 只消费 typed Host API。智能体发布页改为关联渠道摘要与跳转;权限、活动记录及本人会话定位到明确选中的账号。
- Yuxi 提供用户级 `/api/makelore/channel-accounts` 与按操作 ID 恢复的接口。已有 Agent binding 仅索引当前路由,历史 caller/session 保留;旧渠道与无目标账号均按 Core 账号清单呈现。多个账号分别保留通知目标和会话隔离。
- MakeLore Main 继续拥有凭据、请求与持久恢复,Renderer 只消费 typed Host API。智能体发布页改为关联渠道摘要与跳转;活动记录及微信对话定位到明确选中的账号。
- 已完成操作优先读取既有回执,再处理首次操作才需要的发布/归档及 Worker 条件;恢复不能重放旧路由或重新调用模型。账号与目标始终限定在可信创建者身份内;原创建者计费、受邀调用者内容隔离及扫码本人免配对规则保持。
- 本节取代此前将创建、连接与路由都放在智能体发布页的入口设计。先更新 AgentBus Core 与 Yuxi API/worker,再使用新版客户端;本批没有新环境变量、数据库迁移,也不要求修改 Works Square 或微信 Adapter。
源提交 `b7d8b1298f02e4b10b6d0089594d48720efc03e7`,见[已审查源任务](../30-worklog/tasks/20260913-user-channels-ml-8d61e4a9.md)。独立 Reviewer 最终 Standards/Spec PASS;本地测试证据与线上验收分开,真实微信、生产部署及收费模型未因这次合并视为通过。
## Scan-Bound WeChat Accounts(2026-09-14 accepted / implemented)
- 谁扫码就绑定谁。一个账号只接受经过 Adapter/Core 验证的扫码身份;其他微信通过各自扫码连接,可分别选择同一个已发布智能体。
- 移除使用范围、邀请码、邀请兑换和单个调用者管理。账号级连接、路由、启停/解绑、活动、微信对话、文件和既有控制流程保留;Main 仍拥有凭据与恢复,创建者继续付款。
- 历史 invited caller/session 不更改内容归属,不允许新的入站、内部恢复或待发结果继续交付;旧邀请码回执取消。服务端保留历史表,不需要新增 schema 迁移。
- MakeLore 已删除相应 typed Host 操作与界面;旧恢复记录只能在本机显式丢弃,不请求已删除 API、不阻塞其他账号。定时通知仍从隔离的扫码账号会话选择目标。
- 本节取代上述旧章节中的邀请、受众配置和单 caller 撤销规则;历史源任务与已发生的集成记录保留。部署需配套更新 MakeLore 与 Yuxi API/worker,本批不修改 AgentBus/Works Square,不新增环境变量。
源 `21e707d`,见[源任务](../30-worklog/tasks/20260914-wechat-scan-owner-ml-b4169ea9.md)。独立 Reviewer Standards/Spec PASS,测试与生产边界以源记录为准;真实微信与收费模型仍需发布环境验收。
## Evidence And Limits
The creator no-code change explicitly replaces the earlier pairing step. See [reviewed source task](../30-worklog/tasks/20260913-wechat-auto-self-ml-3679bce2.md): 64 focused tests, typecheck, build, scoped lint and an inspected Electron scenario passed; independent review passed. Main remains the network boundary and Yuxi/AgentBus establish identity. Compatible backend and client deployment is required; historical connections missing scanning identity need one reconnect. No real WeChat acceptance or installer was produced by this change.

View File

@@ -2,7 +2,7 @@
## Active Decisions
- [个人云智能体与微信渠道](ADR-2026-09-11-personal-cloud-agents.md):2026-09-14 amended / implemented;用户级多微信账号、可选已发布智能体路由、先连接后选目标、切换保留登录。共享身份、创建者计费与调用者隐私不变;真实渠道部署验收待执行。
- [个人云智能体与微信渠道](ADR-2026-09-11-personal-cloud-agents.md):2026-09-14 amended / implemented;每个微信账号独立扫码、选择已发布智能体;只接受扫码身份,移除邀请/使用范围/调用者管理。多账号路由、创建者计费及历史内容隔离保留;真实部署验收待执行。
- [官方模型能力与原生思考选项](ADR-2026-09-12-official-model-capabilities.md):2026-09-12 accepted / implemented;one-api 官方事实、Works v2 授权投影、受管模型图片输入与 Main-owned reasoningChoice,取代受管模型的静态推测与 Pi 枚举映射。