refactor: remove turn tools, rename discord tools, rewrite installer

- Remove turn management tools (turn-status/advance/reset) — internal only,
  accessible via /dirigent slash commands
- Rename discord tools: dirigent_discord_channel_create,
  dirigent_discord_channel_update, dirigent_discord_member_list
- Rewrite install script:
  - Dynamic OpenClaw dir resolution (OPENCLAW_DIR env → openclaw CLI → ~/.openclaw)
  - Plugin installed to $(openclaw_dir)/plugins/dirigent
  - New --update mode: git pull from latest branch + reinstall
  - Cleaner uninstall: removes installed plugin files
- Update docs (FEAT.md, README.md, CHANGELOG.md, TASKLIST.md)
This commit is contained in:
zhi
2026-03-07 17:24:36 +00:00
parent 7b93db3ed9
commit e4454bfc1a
7 changed files with 214 additions and 168 deletions

26
FEAT.md
View File

@@ -66,22 +66,23 @@ All implemented features across all versions.
- Sends handoff messages to trigger next speaker's turn
## Individual Tools *(v0.3.0)*
Nine standalone tools (split from former monolithic `dirigent_tools`):
Six standalone tools (split from former monolithic `dirigent_tools`):
### Discord Control
- **`dirigent_channel_create`** — Create private Discord channel with user/role permissions
- **`dirigent_channel_update`** — Update permissions on existing private channel
- **`dirigent_member_list`** — List guild members with pagination and field projection
- **`dirigent_discord_channel_create`** — Create private Discord channel with user/role permissions
- **`dirigent_discord_channel_update`** — Update permissions on existing private channel
- **`dirigent_discord_member_list`** — List guild members with pagination and field projection
### Policy Management
- **`dirigent_policy_get`** — Get all channel policies
- **`dirigent_policy_set`** — Set/update a channel policy (listMode, humanList, agentList, endSymbols)
- **`dirigent_policy_delete`** — Delete a channel policy
### Turn Management
- **`dirigent_turn_status`** — Show turn state (order, current speaker, dormant status, override info)
- **`dirigent_turn_advance`** — Manually advance to next speaker
- **`dirigent_turn_reset`** — Reset turn order (go dormant, clear overrides)
### Turn Management (internal only — not exposed as tools)
Turn management is handled entirely by the plugin. Manual control via slash commands:
- `/dirigent turn-status` — Show turn state
- `/dirigent turn-advance` — Manually advance to next speaker
- `/dirigent turn-reset` — Reset turn order (go dormant, clear overrides)
## Slash Command: `/dirigent`
- `status` — Show all channel policies
@@ -93,12 +94,15 @@ Nine standalone tools (split from former monolithic `dirigent_tools`):
- All plugin ids, tool names, config keys, file paths, docs updated
- Legacy `whispergate` config key still supported as fallback
## Installer Script
## Installer Script *(updated v0.3.0)*
- `scripts/install-dirigent-openclaw.mjs`
- `--install` / `--uninstall` with delta-tracking
- `--install` / `--uninstall` / `--update` modes
- **Dynamic OpenClaw dir resolution**: `$OPENCLAW_DIR``openclaw config get dataDir``~/.openclaw`
- Builds dist and copies to `$(openclaw_dir)/plugins/dirigent`
- `--update`: pulls latest from git `latest` branch, then reinstalls
- Auto-reinstall (uninstall + install) if already installed
- Backup before changes, rollback on failure
- Records stored in `~/.openclaw/dirigent-install-records/`
- Records stored in `$(openclaw_dir)/dirigent-install-records/`
## Discord Control API (Sidecar)
- Private channel create/update with permission overwrites