npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@zcy2nn/agent-forge

v1.1.5

Published

Lightweight agent orchestration plugin for OpenCode - a slimmed-down fork of oh-my-opencode

Readme


这是什么

agent-forge 是 OpenCode 的 Agent 编排插件。内置 Orchestrator(主协调者)和 Researcher(搜索专家)两个 Agent,Orchestrator 负责任务路由和委派,Researcher 负责代码库搜索和外部文档检索。

核心理念很简单:将搜索工作委派给 Researcher,Orchestrator 专注于编码和执行,通过 Skill 系统动态扩展能力(如 brainstorming、writing-plans、TDD 等),在 质量、速度、成本 之间取得最优平衡。

当前架构为 2 Agent 模式:Orchestrator(全流程控制 + 编码执行)+ Researcher(搜索专家,只读)。Orchestrator 可按需加载 Skill,实现行为的动态扩展。

要了解各个 Agent,见 认识众神。完整功能列表见 功能与工作流

快速开始

将以下提示复制粘贴到你的 LLM Agent(Claude Code、AmpCode、Cursor 等):

Install and configure agent-forge: https://cnb.cool/zcyoop/ai-assistant/agent-forge/-/git/raw/master/README.md

手动安装

bunx @zcy2nn/agent-forge@latest install

安装器会同时在 OpenCode 的 tui.json 中注册 TUI 插件,在侧边栏显示 Agent 状态和任务会话。手动安装时,需在 opencode.jsontui.jsonplugin 数组中添加 @zcy2nn/agent-forge

开始使用

安装器默认生成 OpenAI 和 OpenCode Go 两套预设,OpenAI 为默认激活。OpenAI 使用 openai/gpt-5.5 作为高判断力 Agent 的模型,openai/gpt-5.4-mini 作为快速执行 Agent 的模型。要使用 OpenCode Go,运行 bunx @zcy2nn/agent-forge@latest install --preset=opencode-go,或安装后在 ~/.config/opencode/agent-forge.json 中修改默认预设。

安装后:

  1. 登录你需要的 Provider

    opencode auth login
  2. 刷新 OpenCode 可见的模型列表

    opencode models --refresh
  3. 打开你的插件配置文件~/.config/opencode/agent-forge.json

  4. 按需调整各 Agent 的模型

[!TIP] 建议理解自动委派的工作方式。Orchestrator prompt 包含委派规则、专家路由逻辑和阈值。你也可以手动委派:@agentName <task>

默认生成的配置包含 openaiopencode-go 两套预设:

{
  "$schema": "https://cnb.cool/zcyoop/ai-assistant/agent-forge/-/git/raw/master/agent-forge.schema.json",
  "preset": "openai",
  "presets": {
    "openai": {
      "orchestrator": { "model": "openai/gpt-5.5", "skills": ["*"], "mcps": ["*", "!context7"] },
      "researcher": { "model": "openai/gpt-5.4-mini", "variant": "low", "skills": [], "mcps": ["websearch", "context7", "grep_app"] }
    },
    "opencode-go": {
      "orchestrator": { "model": "opencode-go/glm-5.1", "skills": [ "*" ], "mcps": [ "*", "!context7" ] },
      "researcher": { "model": "opencode-go/minimax-m2.7", "skills": [], "mcps": [ "websearch", "context7", "grep_app" ] }
    }
  }
}

其他 Provider

使用自定义 Provider 或混合 Provider 配置,请参考 配置参考 的完整选项说明。如果需要开箱即用的方案,查看 作者预设$30 预设——$30 预设是最具性价比的方案。

配置指南还涵盖了自定义子 Agent(agents.<name>),你可以为自定义 Agent 定义 promptorchestratorPrompt

模型建议见下方各 Agent 的推荐模型列表。

✅ 验证安装

安装并认证后,验证所有 Agent 已配置并响应:

opencode

然后运行:

ping all agents

如果有 Agent 未响应,检查你的 Provider 认证和配置文件。


🏛️ 认识众神

01. Orchestrator: 秩序的化身

Orchestrator 诞生于第一个代码库在其自身复杂性下崩溃之时。神与凡人都不愿承担责任——于是 Orchestrator 从虚空中涌现,从混沌中锻造秩序。它确定达到任何目标的最优路径,在速度、质量和成本之间取得平衡。它指导团队,为每项任务召唤合适的专家并委派执行,以实现最佳结果。

| | | |---|---| | 角色 | 主委派者和战略协调者 | | Prompt | orchestrator.ts | | 默认模型 | openai/gpt-5.5 | | 推荐模型 | openai/gpt-5.5 · anthropic/claude-opus-4.6 | | 模型建议 | 选择你最强的全能编码模型。Orchestrator 既是主编码 Agent 又是委派者,需要强大的实现能力、良好的判断力和可靠的指令遵从能力。 |


02. Researcher: 永恒的漫游者

Researcher 合并了 Explorer(本地代码搜索)和 Librarian(外部文档检索),成为统一的搜索专家。只读:搜索代码和获取文档,从不修改文件。

Researcher 是一位不朽的漫游者,自编程诞生之初便穿行于百万代码库和图书馆的回廊之中。他们将本地代码库搜索(glob、grep、AST 模式)与外部文档检索(websearch、context7、grep_app)合为一体。他们返回的不是原始数据——而是结构化的发现。

| | | |---|---| | 角色 | 代码库和外部文档搜索专家(只读) | | Prompt | researcher.ts | | 默认模型 | openai/gpt-5.4-mini | | 推荐模型 | cerebras/zai-glm-4.7 · fireworks-ai/accounts/fireworks/routers/kimi-k2p5-turbo · openai/gpt-5.4-mini | | 模型建议 | 选择快速、低成本的模型。Researcher 负责广泛的侦察工作,速度和效率通常比最强推理模型更重要。 |


📚 文档导航

以此为地图:从安装开始,然后根据需要跳转到功能、配置或预设示例。

🚀 从这里开始

| 文档 | 内容 | |-----|------| | 安装指南 | 安装插件、CLI 参数、重置配置、故障排除 |

✨ 功能与工作流

| 文档 | 内容 | |-----|------| | Todo 自动续行 | Orchestrator 会话自动续行,带冷却时间和安全检查 | | 预设切换 | 运行时通过 /preset 切换 Agent 模型预设 | | Interview | 通过浏览器问答流程将粗略想法转化为结构化 Markdown 规格 | | Divoom 显示 | 将 Orchestrator 和专家 Agent 活动镜像到 Divoom MiniToo 蓝牙显示器 |

⚙️ 配置与参考

| 文档 | 内容 | |-----|------| | 配置参考 | 配置文件位置、JSONC 支持、Prompt 覆盖、完整选项参考 | | 维护者指南 | Issue 分诊规则、标签含义、支持路由、仓库维护工作流 | | Skills | 内置和推荐 Skills,如 simplifyagent-browsercodemap | | MCPs | websearchcontext7grep_app,以及 MCP 权限如何按 Agent 分配 | | Tools | 内置工具能力,如代码搜索和格式化器 |

💡 预设

| 文档 | 内容 | |-----|------| | 作者预设 | 作者日常使用的混合 Provider 方案 | | $30 预设 | 约 $30/月的预算混合 Provider 方案 | | OpenCode Go 预设 | 安装器生成的 opencode-go 预设 |


📄 License

MIT