ユーザ用ツール

サイト用ツール


ai:agent

文書の過去の版を表示しています。


Agent の設定

OpenClaw のコンテキストは Agent 毎に管理されています。 デフォルトでは “main” だけですが、別の Agent を追加することもできます。

例えば Slack と Discord で別の独立した Agent として使い分けることもできます。

(1) Agent の追加

  1. openclaw agents add AGENTNAME
    • 例「openclaw agents add slackagent
  2. Workspace directory: デフォルトのまま
  3. Copy auth profiles from “main”?: Yes
  4. Configure model/auth for this agent now?: No
    • もし Agent 毎に異なる Model や Provider を使いたい場合は Yes にします
  5. Configure chat channels now?: No

追加したら openclaw agents list で確認できます。

(2) Channel 毎の割当

  1. ~/.openclaw/openclaw.json を編集して bindings を追加します
  2. 編集したら「openclaw gateway restart」で Gateway を再起動します

以下は ~/.openclaw/openclaw.json の “bindings” の設定の例です。 slack にデフォルトの “main” とは異なる専用の Agent (“slackagent”) を割り当てています。 discord の方はデフォルトの “main” のままにしています。

{
  ~
 
  "bindings": [
    {
      "agentId": "slackagent",
      "match": {
        "channel": "slack"
      }
    },
    {
      "agentId": "main",
      "match": {
        "channel": "discord"
      }
    }
  ],
 
  ~
}
ai/agent.1770122051.txt.gz · 最終更新: by oga

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki