mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-18 07:23:20 +08:00
重构主控编排与运行时预热链路,统一工作区提示词/专家调度协议并补齐 wiki 记忆注入与写回闭环。
同时收敛启动与运维脚本默认行为(含 wiki worker)、更新 Admin 可观测性与相关测试,降低首轮时延并提高运行稳定性。 Made-with: Cursor
This commit is contained in:
parent
4a23b715a2
commit
dbbe3add6a
14438 changed files with 2693620 additions and 2546 deletions
197
openclaw/skills/discord/SKILL.md
Normal file
197
openclaw/skills/discord/SKILL.md
Normal file
|
|
@ -0,0 +1,197 @@
|
|||
---
|
||||
name: discord
|
||||
description: "Discord ops via the message tool (channel=discord)."
|
||||
metadata: { "openclaw": { "emoji": "🎮", "requires": { "config": ["channels.discord.token"] } } }
|
||||
allowed-tools: ["message"]
|
||||
---
|
||||
|
||||
# Discord (Via `message`)
|
||||
|
||||
Use the `message` tool. No provider-specific `discord` tool exposed to the agent.
|
||||
|
||||
## Musts
|
||||
|
||||
- Always: `channel: "discord"`.
|
||||
- Respect gating: `channels.discord.actions.*` (some default off: `roles`, `moderation`, `presence`, `channels`).
|
||||
- Prefer explicit ids: `guildId`, `channelId`, `messageId`, `userId`.
|
||||
- Multi-account: optional `accountId`.
|
||||
|
||||
## Guidelines
|
||||
|
||||
- Avoid Markdown tables in outbound Discord messages.
|
||||
- Mention users as `<@USER_ID>`.
|
||||
- Prefer Discord components v2 (`components`) for rich UI; use legacy `embeds` only when you must.
|
||||
|
||||
## Targets
|
||||
|
||||
- Send-like actions: `to: "channel:<id>"` or `to: "user:<id>"`.
|
||||
- Message-specific actions: `channelId: "<id>"` (or `to`) + `messageId: "<id>"`.
|
||||
|
||||
## Common Actions (Examples)
|
||||
|
||||
Send message:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "send",
|
||||
"channel": "discord",
|
||||
"to": "channel:123",
|
||||
"message": "hello",
|
||||
"silent": true
|
||||
}
|
||||
```
|
||||
|
||||
Send with media:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "send",
|
||||
"channel": "discord",
|
||||
"to": "channel:123",
|
||||
"message": "see attachment",
|
||||
"media": "file:///tmp/example.png"
|
||||
}
|
||||
```
|
||||
|
||||
- Optional `silent: true` to suppress Discord notifications.
|
||||
|
||||
Send with components v2 (recommended for rich UI):
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "send",
|
||||
"channel": "discord",
|
||||
"to": "channel:123",
|
||||
"message": "Status update",
|
||||
"components": "[Carbon v2 components]"
|
||||
}
|
||||
```
|
||||
|
||||
- `components` expects Carbon component instances (Container, TextDisplay, etc.) from JS/TS integrations.
|
||||
- Do not combine `components` with `embeds` (Discord rejects v2 + embeds).
|
||||
|
||||
Legacy embeds (not recommended):
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "send",
|
||||
"channel": "discord",
|
||||
"to": "channel:123",
|
||||
"message": "Status update",
|
||||
"embeds": [{ "title": "Legacy", "description": "Embeds are legacy." }]
|
||||
}
|
||||
```
|
||||
|
||||
- `embeds` are ignored when components v2 are present.
|
||||
|
||||
React:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "react",
|
||||
"channel": "discord",
|
||||
"channelId": "123",
|
||||
"messageId": "456",
|
||||
"emoji": "✅"
|
||||
}
|
||||
```
|
||||
|
||||
Read:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "read",
|
||||
"channel": "discord",
|
||||
"to": "channel:123",
|
||||
"limit": 20
|
||||
}
|
||||
```
|
||||
|
||||
Edit / delete:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "edit",
|
||||
"channel": "discord",
|
||||
"channelId": "123",
|
||||
"messageId": "456",
|
||||
"message": "fixed typo"
|
||||
}
|
||||
```
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "delete",
|
||||
"channel": "discord",
|
||||
"channelId": "123",
|
||||
"messageId": "456"
|
||||
}
|
||||
```
|
||||
|
||||
Poll:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "poll",
|
||||
"channel": "discord",
|
||||
"to": "channel:123",
|
||||
"pollQuestion": "Lunch?",
|
||||
"pollOption": ["Pizza", "Sushi", "Salad"],
|
||||
"pollMulti": false,
|
||||
"pollDurationHours": 24
|
||||
}
|
||||
```
|
||||
|
||||
Pins:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "pin",
|
||||
"channel": "discord",
|
||||
"channelId": "123",
|
||||
"messageId": "456"
|
||||
}
|
||||
```
|
||||
|
||||
Threads:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "thread-create",
|
||||
"channel": "discord",
|
||||
"channelId": "123",
|
||||
"messageId": "456",
|
||||
"threadName": "bug triage"
|
||||
}
|
||||
```
|
||||
|
||||
Search:
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "search",
|
||||
"channel": "discord",
|
||||
"guildId": "999",
|
||||
"query": "release notes",
|
||||
"channelIds": ["123", "456"],
|
||||
"limit": 10
|
||||
}
|
||||
```
|
||||
|
||||
Presence (often gated):
|
||||
|
||||
```json
|
||||
{
|
||||
"action": "set-presence",
|
||||
"channel": "discord",
|
||||
"activityType": "playing",
|
||||
"activityName": "with fire",
|
||||
"status": "online"
|
||||
}
|
||||
```
|
||||
|
||||
## Writing Style (Discord)
|
||||
|
||||
- Short, conversational, low ceremony.
|
||||
- No markdown tables.
|
||||
- Mention users as `<@USER_ID>`.
|
||||
Loading…
Add table
Add a link
Reference in a new issue