hovclaw 0.1.3 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -33,15 +33,17 @@ HOVClaw is built on a simple principle: **run your own AI agent infrastructure,
33
33
  - **Policy layer** - `dmPolicy`, `groupPolicy`, per-group/per-topic overrides, pairing flow
34
34
  - **Native Telegram commands** - Auto-registered slash command menu (including skill aliases)
35
35
  - **Thinking controls** - `/think <level> <task>` plus persisted default via `commands.defaultThinkingLevel`
36
+ - **Exec chat approvals** - `/bash <cmd>` requests approval and `/approve <id> allow-once|allow-always|deny` resolves
36
37
 
37
38
  ### Gateway & Control Plane
38
39
 
39
- - **WebSocket protocol v3** - Request/response/event frames with 21 methods
40
+ - **WebSocket protocol v3** - Request/response/event frames with 25 methods
40
41
  - **Built-in web UI** - Connection, health, channels, sessions, and chat in one page
41
42
  - **Fail-closed auth defaults** - Gateway auth is required unless explicitly opting into insecure mode
42
43
  - **Origin-aware WS policy** - Browser `Origin` headers must be same-origin or allowlisted
43
44
  - **LaunchAgent integration** - `hovclaw gateway install/start/stop` for macOS background service
44
45
  - **Programmatic access** - `hovclaw gateway call <method>` for scripting
46
+ - **Approval APIs** - `exec.approval.request|resolve` and `exec.approvals.get|set`
45
47
 
46
48
  ### Agent Runtime
47
49
 
@@ -49,7 +51,9 @@ HOVClaw is built on a simple principle: **run your own AI agent infrastructure,
49
51
  - **Multi-provider models** - Anthropic, Google, OpenAI, OpenRouter via `@mariozechner/pi-ai`
50
52
  - **Model routing** - Per-target model slots (interactive, discord, cron) with fallback policy
51
53
  - **Workspace-first tools** - Relative file tool paths resolve from agent workspace
52
- - **Least-privilege tools** - Bash tool disabled by default (`runtime.tools.bashEnabled=false`)
54
+ - **Exec approvals model** - deny/allowlist/full + `off|on-miss|always` ask modes with persistent allowlists
55
+ - **Least-privilege defaults** - exec disabled by default (`runtime.tools.exec.enabled=false`)
56
+ - **Read-only diagnostics** - built-in `diagnose_device` tool (`profile=core`)
53
57
  - **Session persistence** - SQLite-backed sessions, messages, agent state, and usage tracking
54
58
 
55
59
  ### Scheduling & Automation
@@ -106,7 +110,7 @@ and agent configuration. All settings are saved to `~/.hovclaw/config.json`.
106
110
  Security defaults in this release are intentionally strict:
107
111
  - gateway start fails if `gateway.enabled=true` and neither `gateway.auth.token` nor `gateway.auth.password` is set (unless `gateway.auth.allowUnauthenticated=true`)
108
112
  - Telegram webhook mode requires a non-empty webhook secret
109
- - bash runtime tool is opt-in only via `runtime.tools.bashEnabled=true`
113
+ - exec runtime tool is opt-in via `runtime.tools.exec.enabled=true` (legacy `runtime.tools.bashEnabled=true` still maps to exec enabled)
110
114
 
111
115
  Agent and skill definitions are loaded from:
112
116
  - `~/.hovclaw/agents/<name>/agent.json` (`CLAUDE.md`, `cron.json`)
@@ -187,7 +191,7 @@ Environment overrides are supported for most fields. See [docs/config-reference.
187
191
  │ │
188
192
  │ ┌────────────────────────────────────────────────────────┐ │
189
193
  │ │ Gateway (ws + http) │ │
190
- │ │ WebSocket v3 protocol • Web UI • 21 methods │ │
194
+ │ │ WebSocket v3 protocol • Web UI • 25 methods │ │
191
195
  │ └────────────────────────────────────────────────────────┘ │
192
196
  │ │
193
197
  │ ┌────────────────────────────────────────────────────────┐ │
@@ -205,7 +209,7 @@ Environment overrides are supported for most fields. See [docs/config-reference.
205
209
  | **Agent Manager** | Per-session agent lifecycle, state persistence, model resolution |
206
210
  | **Router** | Binding-based inbound routing with peer/guild/account/channel cascade |
207
211
  | **Scheduler** | Cron job loading, execution, and channel notifications |
208
- | **Gateway** | WebSocket v3 server with 21 methods, 5 event types, built-in web UI |
212
+ | **Gateway** | WebSocket v3 server with 25 methods, 7 event types, built-in web UI |
209
213
  | **Skill Loader** | SKILL.md frontmatter parsing and dependency checking |
210
214
  | **Channels** | Telegram (multi-account, policy, pairing) and Discord adapters |
211
215
 
@@ -264,8 +268,10 @@ hovclaw daemon install|uninstall|start|stop|restart|status|logs
264
268
  | `chat.history` / `chat.send` / `chat.abort` | Chat session interaction |
265
269
  | `cron.list` / `cron.status` | Scheduled job listing and status |
266
270
  | `logs.tail` | Recent audit events |
271
+ | `exec.approval.request` / `exec.approval.resolve` | Create and resolve pending exec approvals |
272
+ | `exec.approvals.get` / `exec.approvals.set` | Read/write persisted exec defaults and per-agent allowlists |
267
273
 
268
- Events: `tick`, `health`, `agent`, `chat`, `shutdown`
274
+ Events: `tick`, `health`, `agent`, `chat`, `shutdown`, `exec.approval.requested`, `exec.approval.resolved`
269
275
 
270
276
  ## Development
271
277
 
@@ -1,4 +1,4 @@
1
- import { A as ensureConfigFromLegacyEnv, F as hasConfigFile, H as saveCredentials, I as hasCredentialsFile, L as loadConfig, M as getCredentialsPath, P as getHovclawHome, R as loadCredentials, V as saveConfigFile, j as getConfigPath, k as detectLegacyEnvConfig, z as loadFileConfig } from "./hovclaw.js";
1
+ import { B as loadCredentials, I as getHovclawHome, L as hasConfigFile, M as ensureConfigFromLegacyEnv, N as getConfigPath, P as getCredentialsPath, R as hasCredentialsFile, U as saveConfigFile, V as loadFileConfig, W as saveCredentials, j as detectLegacyEnvConfig, z as loadConfig } from "./hovclaw.js";
2
2
  import fs from "node:fs";
3
3
  import path from "node:path";
4
4
  import { fileURLToPath } from "node:url";
@@ -36,7 +36,7 @@
36
36
  <input
37
37
  id="gateway-url"
38
38
  type="text"
39
- placeholder="ws://127.0.0.1:18789"
39
+ placeholder="ws://127.0.0.1:18889"
40
40
  spellcheck="false"
41
41
  />
42
42
  </label>