@wegent/wegent-openclaw
v0.1.5
Published
OpenClaw Wegent local executor plugin
Readme
openclaw-wegent
OpenClaw plugin for Wegent local executor integration.
Config
Set values in channels["wegent-openclaw"].*:
{
"channels": {
"wegent-openclaw": {
"backendUrl": "http://127.0.0.1:8000",
"websocketUrl": "ws://127.0.0.1:8000/local-executor",
"token": "wg-xxx",
"deviceId": "f2b11392-7c7f-47f0-83f8-4fb812857e44",
"deviceType": "local",
"executorVersion": "1.0.0"
}
}
}Defaults used internally (not shown in config form):
wsNamespace:/local-executorsocketPath:/socket.iodeviceId: auto-generated UUID by default, configurabledeviceName:macOS-OpenClaw-Device-<last-segment-of-deviceId>bindShell: fixedopenclaw(emitted asbind_shell)deviceType:localby default, configurable (emitted asdevice_type)capabilities:["cpu"]executorVersion:1.0.0(可通过配置覆盖)heartbeatIntervalMs:30000ackTimeoutMs:10000autoReconnect:truereconnectDelayMs:2000reconnectDelayMaxMs:10000
Behavior
- Connects to Socket.IO namespace
/local-executor - Registers device via
device:register - Sends heartbeat via
device:heartbeatwithrunning_task_ids - Handles backend events:
task:executetask:canceltask:close-session
- Emits result events:
response.output_text.deltaresponse.completedresponse.incompleteerror
Logging
Default logs always enabled:
wegent_message_type_received(only message type + task ids)wegent_first_char_latency(first character latency)
Other logs are disabled by default, and can be enabled with environment variables:
OPENCLAW_WEGENT_LOG_SOCKET=1OPENCLAW_WEGENT_LOG_SERVICE=1OPENCLAW_WEGENT_LOG_TASK=1OPENCLAW_WEGENT_LOG_GATEWAY=1OPENCLAW_WEGENT_LOG_ALL=1(enable all of the above)
Development
npm install
npm run ci:check