← 返回 Skills 市场
cchenwei

Lark Multi Agent Factory

作者 Cchenwei · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ 安全检测通过
86
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install lark-multi-agent-factory
功能描述
针对 @larksuite/openclaw-lark 官方插件的多 agent 批量配置工具。当用户说「添加 agent」「新建 agent」「配置飞书」「批量创建 agent」「添加新机器人」,且系统安装的是 @larksuite/openclaw-lark 插件时触发。支持 threadSession、re...
使用说明 (SKILL.md)

Lark Multi-Agent Factory

针对 @larksuite/openclaw-lark(≥ 2026.4.0) 的多 agent 批量配置向导。

feishu-multi-agent-factory 的区别

  • 专为官方 @larksuite/openclaw-lark 插件设计(内置插件 @openclaw/feishu 用另一个)
  • 支持 threadSessionreplyModeblockStreaming 等官方插件专属字段
  • 创建前自动检查插件是否已安装

核心脚本

~/.openclaw/workspace/skills/lark-multi-agent-factory/scripts/setup_agents.py

官方插件专属字段说明

字段 级别 类型 说明
threadSession channel boolean 开启后每个飞书话题为独立会话(推荐 true
replyMode channel / account auto | static | streaming 回复渲染方式:auto 自动选择,streaming 流式输出,static 纯文本
blockStreaming channel boolean 是否合并流式块(减少更新频率)
blockStreamingCoalesce channel object 流式合并策略(高级配置)

对话示例

批量创建 agents

用户:

帮我用官方飞书插件创建 2 个 agent:
1. id: analyst,数据分析师📊,AppId: cli_xxx1,Secret: yyy1
2. id: writer,内容创作者✍️,AppId: cli_xxx2,Secret: yyy2
用 streaming 模式,开启 threadSession

助手回应(先 dry-run 确认):

python3 ~/.openclaw/workspace/skills/lark-multi-agent-factory/scripts/setup_agents.py \
  --dry-run \
  --config '{
    "channel": {"threadSession": true, "replyMode": "streaming"},
    "agents": [
      {"id": "analyst", "name": "数据分析师", "emoji": "📊",
       "feishu_app_id": "cli_xxx1", "feishu_app_secret": "yyy1"},
      {"id": "writer", "name": "内容创作者", "emoji": "✍️",
       "feishu_app_id": "cli_xxx2", "feishu_app_secret": "yyy2"}
    ]
  }'

确认后执行:

python3 ~/.openclaw/workspace/skills/lark-multi-agent-factory/scripts/setup_agents.py \
  --config '...' --restart

调整 channel 级别参数

# 切换 replyMode(无需重新创建 agents)
python3 ~/.../setup_agents.py --set-channel --reply-mode streaming --restart

# 开启 threadSession
python3 ~/.../setup_agents.py --set-channel --thread-session true

# 关闭 blockStreaming
python3 ~/.../setup_agents.py --set-channel --block-streaming false

操作流程

第一步:收集信息

用户说想添加 agent 时,引导收集:

我需要以下信息:

1. **Agent ID**(英文小写,如 `analyst`)
2. **名称**(如「数据分析师」)
3. **Emoji**
4. **飞书 App ID**(格式:cli_xxxxxxxx)
5. **飞书 App Secret**
6. **replyMode**(可选,默认继承 channel 设置)
   - `auto` — 自动选择(推荐)
   - `streaming` — 流式输出,打字机效果
   - `static` — 纯文本,兼容性最佳

可同时提供多个 agent。

第二步:dry-run 预览

python3 ~/.openclaw/workspace/skills/lark-multi-agent-factory/scripts/setup_agents.py \
  --dry-run --config '\x3CJSON>'

第三步:确认并创建

python3 ~/.openclaw/workspace/skills/lark-multi-agent-factory/scripts/setup_agents.py \
  --config '\x3CJSON>' --restart

JSON 格式

{
  "channel": {
    "threadSession": true,
    "replyMode": "auto",
    "blockStreaming": false
  },
  "agents": [
    {
      "id": "analyst",
      "name": "数据分析师",
      "emoji": "📊",
      "description": "负责数据分析与报表",
      "feishu_app_id": "cli_xxxxxxxx",
      "feishu_app_secret": "xxxxxxxx",
      "feishu_domain": "feishu",
      "reply_mode": "streaming"
    }
  ]
}

channel 字段可选,第一次运行时写入 channels.feishu(已有值不覆盖)。
reply_mode 为 per-agent 覆盖,仅当与 channel 级别不同时才写入账号配置。


其他命令

# 查看现有 agents 及 channel 配置
python3 ~/.../setup_agents.py --list

# 删除 agent(仅移除配置,不删目录)
python3 ~/.../setup_agents.py --remove \x3Cid>

# 跳过插件检查(调试用)
python3 ~/.../setup_agents.py --skip-plugin-check --config '...'

前置条件

  1. 安装官方插件:

    openclaw plugins install @larksuite/openclaw-lark
    
  2. 禁用内置插件(若已安装,两者不可同时运行):

    openclaw plugins disable feishu
    
  3. 通过 openclaw channels add 配置顶层主账号(channels.feishu.appId/appSecret)。

  4. 重启 gateway 激活插件:

    openclaw gateway restart
    

自动完成的事项

步骤 内容
✅ 插件检查 验证 @larksuite/openclaw-lark 已安装
✅ workspace 目录 ~/.openclaw/workspace-{id}/ + 基础文件
✅ agentDir ~/.openclaw/agents/{id}/agent/ + defaults.json
✅ agents.list 写入 openclaw.json
✅ feishu accounts 写入 channels.feishu.accounts(含 name 字段)
✅ channel 字段 threadSession / replyMode 等首次写入
✅ bindings agent ↔ feishu account
✅ agentToAgent.allow 加入协作白名单
✅ session.dmScope 自动设置多账号会话隔离

安全说明

  • App Secret 脱敏输出(仅显示前 4 位)
  • 凭据只写入本地 ~/.openclaw/openclaw.json
  • agent id 严格校验,防止路径穿越攻击
安全使用建议
This tool is a local configuration helper: it will create directories under ~/.openclaw and write agent/account entries (including Feishu AppId/AppSecret) to ~/.openclaw/openclaw.json. Before running: (1) confirm you trust the author because the script will store full app secrets locally; (2) back up your existing ~/.openclaw/openclaw.json; (3) ensure the 'openclaw' CLI on your system is the expected official tool (the script invokes it to check plugins); (4) if you want secrets stored elsewhere, modify the script or manage secrets outside of this helper. If you only want a dry-run first, use the --dry-run option shown in the examples.
功能分析
Type: OpenClaw Skill Name: lark-multi-agent-factory Version: 1.0.0 The lark-multi-agent-factory skill is a legitimate configuration utility designed to batch-create and manage Lark (Feishu) agents for the OpenClaw platform. The Python script (setup_agents.py) performs standard configuration tasks such as modifying the local openclaw.json file, creating workspace directories, and managing agent bindings. It includes security best practices such as validating agent IDs to prevent path traversal and masking sensitive App Secrets in console output. No evidence of data exfiltration, unauthorized remote execution, or malicious prompt injection was found.
能力评估
Purpose & Capability
The name/description describe batch-creating/configuring Lark/Feishu agents for the @larksuite/openclaw-lark plugin. The included Python script exclusively manipulates ~/.openclaw configuration, creates workspace/agent directories, and checks whether the plugin is installed — all consistent with the stated purpose.
Instruction Scope
SKILL.md and the script limit actions to collecting agent metadata, validating ids/reply modes, writing to ~/.openclaw/openclaw.json, creating workspace/agent files under ~/.openclaw, and optionally calling the local 'openclaw' CLI to check installed plugins. There are no instructions to read unrelated system files, transmit data to external endpoints, or gather extraneous secrets.
Install Mechanism
There is no install spec; this is instruction + local script only, so nothing is downloaded or executed from remote URLs. The script uses standard local filesystem operations and subprocess calls to the 'openclaw' CLI (expected for managing OpenClaw plugins).
Credentials
The skill declares no required environment variables or credentials. It asks the user to provide Feishu/App credentials (AppId and AppSecret) as part of agent creation, and writes those into ~/.openclaw/openclaw.json — this is proportional to its function. The README notes secrets are masked in output; the full secret is stored locally (as expected for account configuration).
Persistence & Privilege
always is false and the skill does not request system-wide privileges. It writes only to its own OpenClaw config area (~/.openclaw) and creates workspace/agent directories under that path. It does not modify other skills' configs or enable persistent/hidden remote access.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install lark-multi-agent-factory
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /lark-multi-agent-factory 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release: Multi-agent batch configuration for the official @larksuite/openclaw-lark plugin. - Guides users to batch add or configure Feishu (Lark) agents with fields exclusive to the official plugin (threadSession, replyMode, blockStreaming, etc.). - Auto-checks @larksuite/openclaw-lark plugin installation before operation. - Supports dry-run preview and interactive information gathering. - Separate per-agent and channel-level options, with clear JSON structure and command-line workflows. - Ensures plugin safety: agentId validation, local credential storage, app secret masking.
元数据
Slug lark-multi-agent-factory
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Lark Multi Agent Factory 是什么?

针对 @larksuite/openclaw-lark 官方插件的多 agent 批量配置工具。当用户说「添加 agent」「新建 agent」「配置飞书」「批量创建 agent」「添加新机器人」,且系统安装的是 @larksuite/openclaw-lark 插件时触发。支持 threadSession、re... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 86 次。

如何安装 Lark Multi Agent Factory?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install lark-multi-agent-factory」即可一键安装,无需额外配置。

Lark Multi Agent Factory 是免费的吗?

是的,Lark Multi Agent Factory 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Lark Multi Agent Factory 支持哪些平台?

Lark Multi Agent Factory 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Lark Multi Agent Factory?

由 Cchenwei(@cchenwei)开发并维护,当前版本 v1.0.0。

💬 留言讨论