Skip to content

feat(ai-pair): add dual-model review UI plugin 0.4.8 - #199

Open
JustinChia wants to merge 1 commit into
zai-org:mainfrom
JustinChia:feat/ai-pair
Open

JustinChia wants to merge 1 commit into
zai-org:mainfrom
JustinChia:feat/ai-pair

Conversation

@JustinChia

@JustinChia JustinChia commented Nov 18, 2026 •

Copy link
Copy Markdown

Plugin type (required) / 插件类型(必填)

  • UI Plugin / 是 UI 插件 — provides MCP Apps interactive pages / 提供 MCP Apps 交互页面
  • Standard plugin / 普通插件(非 UI)
  • Not applicable / 不适用

Affected plugin name(s) / 涉及的插件名称:ai-pair

What / 改动内容

新增社区贡献 UI 插件 ai-pair 0.4.8(external_plugins/ai-pair,按维护者指引放置,publisherType: community):

主对话完成代码修改或内容创作后,把成果送 两个异构模型 并行评审,报告在会话侧栏「AI Pair 评审」面板(ui.surfaces,session 可用)分级展示。

  • 评审由插件 MCP server(dist/server.mjs)直连用户在 ZCode「管理模型」已配置的渠道执行,复用已有密钥,插件不需单独填 API Key
  • 两个评审位固定分工:评审模型 1 = 正确性把关,评审模型 2 = 设计与可维护性;支持 OpenAI chat/completions 与 Anthropic messages 协议(自动识别),建议两槽异构厂商
  • MCP 工具:request_review / get_review / list_reviews / delete_review / open_panel / list_models / configure_reviewers
  • 隐私:评审内容发送到用户自己配置的模型渠道;评审记录仅存本机插件数据目录;API Key 只在服务端内存,不落盘、不下发面板(README 已写明)
  • 致谢与出处:改编自 axtonliu/ai-pair(MIT),本插件同为 MIT;icon 为原创设计(矢量源 ui-plugins/ai-pair/icon.svg),已登记 assets/icon-sources.json

版本与注册 / Version & registration

  • .zcode-plugin/plugin.json 与 marketplace.json 均为 0.4.8(首次发布版本,无历史版本占用)
  • category: developer-tools;description_i18n 含 en + zh-CN
  • 图标:assets/ai-pair/icon.png(sha256 已登记 icon-sources.json)
  • 目录布局遵循仓库约定:安装目录 external_plugins/ai-pair,构建源 ui-plugins/ai-pair

测试与验证 / Testing

  • python scripts/validate.py:OK: 57 plugin(s) validated(56 上游条目含 unlisted openpencil + ai-pair)
  • pnpm --filter @zcode/plugin-ai-pair test:11/11 通过(panel markdown 渲染单测)
  • pnpm lint:0 errors
  • ai-pair 单包构建(与根构建器同参):panel bundle 1,285,870 bytes,dist/build-info.json = {name: ai-pair, version: 0.4.8},server 入口存在
  • 已在 ZCode 桌面端通过 dist/local-marketplace 真实安装并日常使用(面板、双模型评审、渠道级联配置均实际运行)
  • 说明:本机(Windows, Node 23)无法完整复现 pnpm build 全仓构建——9 个 Craft 插件需要 Rust wasm 工具链(CI 以 CRAFT_TOOLCHAIN_INSTALL=1 自动处理);ai-pair 不依赖该工具链
  • 面板截图/录屏可按 reviewer 要求补充

Self-check / 自查清单

  • Plugin name is unique kebab-case; new community plugin directory is external_plugins/ai-pair/
  • Usage category is set independently of publisher ownership(developer-tools)
  • Plugin type and affected names are declared above(UI Plugin / ai-pair)
  • version synced in BOTH plugin.json and marketplace.json(0.4.8,首次发布)
  • README.md (EN) and README_CN.md (中文) both present and equivalent
  • description_i18n has both en and zh-CN
  • No secrets, machine-specific paths, or private dependencies(已扫描源码确认)
  • Model/API/network dependencies documented(README:模型渠道直连、OpenCode Go 网关注意事项)
  • python3 scripts/validate.py passes locally;build_dist.py 全量构建依赖 CI 的 Rust 工具链(见上)

@panda920

Copy link
Copy Markdown
Collaborator

Thanks for the contribution! This PR changes files that are maintained by the ZCode team and cannot be taken from external contributions: .gitignore. Please drop those changes (plugin content, marketplace.json and docs are welcome) and push again; it will be picked up automatically.

🤖 Copy this prompt into Claude Code / Codex to fix it
You are updating my pull request #199 to github.com/zai-org/zcode-plugins (the ZCode plugin marketplace).
The maintainers' automated intake reported: the PR touches maintainer-owned files

Remove my changes to: .gitignore

Fix it in this repository:
- New external plugins belong under external_plugins/<my-plugin>/; keep existing plugins in their current directory;
  never modify .github/, scripts/, tests/, .gitignore, .gitattributes or AGENTS.md.
- Follow CONTRIBUTING.md and AGENTS.md: the manifest lives at <plugin-directory>/.zcode-plugin/plugin.json,
  its name/version must match marketplace.json, names are kebab-case, keep the required i18n fields.
- Fetch the latest main of zai-org/zcode-plugins and rebase onto it; if marketplace.json conflicts,
  keep every existing entry and re-add mine.
- Run `python scripts/validate.py` until it passes, then force-push my PR branch.

Register ai-pair: after the main conversation finishes code or content
work, it sends the result to two heterogeneous reviewers (reusing ZCode
Manage-Models channels) in parallel and shows graded reports in the
session side pane.

- external_plugins/ai-pair: manifest, bilingual READMEs, review skill, MIT license
- ui-plugins/ai-pair: MCP server, panel UI, build script, unit tests
- marketplace.json + assets/icon-sources.json: register entry and icon
@panda920

Copy link
Copy Markdown
Collaborator

❌ Internal validation failed:

ai-pair: external submissions must use ./external_plugins/ai-pair

Please fix it and push again; the check re-runs automatically.

🤖 Copy this prompt into Claude Code / Codex to fix it
You are updating my pull request #199 to github.com/zai-org/zcode-plugins (the ZCode plugin marketplace).
The maintainers' automated intake reported: `python scripts/validate.py` failed

Validator output:
ai-pair: external submissions must use ./external_plugins/ai-pair

Fix it in this repository:
- New external plugins belong under external_plugins/<my-plugin>/; keep existing plugins in their current directory;
  never modify .github/, scripts/, tests/, .gitignore, .gitattributes or AGENTS.md.
- Follow CONTRIBUTING.md and AGENTS.md: the manifest lives at <plugin-directory>/.zcode-plugin/plugin.json,
  its name/version must match marketplace.json, names are kebab-case, keep the required i18n fields.
- Fetch the latest main of zai-org/zcode-plugins and rebase onto it; if marketplace.json conflicts,
  keep every existing entry and re-add mine.
- Run `python scripts/validate.py` until it passes, then force-push my PR branch.

@JustinChia

JustinChia commented Nov 18, 2026 •

Copy link
Copy Markdown
Author

Done — removed the .gitignore change and moved the plugin to external_plugins/ai-pair/. Force-pushed as 43d9b76, python scripts/validate.py passes (57 plugins incl. the unlisted one). Ready for re-review.

@panda920

Copy link
Copy Markdown
Collaborator

✅ Internal validation passed. A ZCode maintainer will review the change next; after acceptance, release checks run separately and this PR is closed automatically.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants