@hybridaione/hybridclaw 0.1.20 → 0.1.22
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/CHANGELOG.md +38 -0
- package/README.md +44 -8
- package/config.example.json +3 -0
- package/container/package-lock.json +2 -2
- package/container/package.json +1 -1
- package/container/src/browser-tools.ts +594 -9
- package/container/src/index.ts +93 -2
- package/container/src/tools.ts +23 -3
- package/container/src/types.ts +7 -0
- package/container/src/web-fetch.ts +98 -7
- package/dist/audit-events.d.ts.map +1 -1
- package/dist/audit-events.js +24 -1
- package/dist/audit-events.js.map +1 -1
- package/dist/container-runner.d.ts.map +1 -1
- package/dist/container-runner.js +50 -0
- package/dist/container-runner.js.map +1 -1
- package/dist/discord.d.ts +3 -3
- package/dist/discord.d.ts.map +1 -1
- package/dist/discord.js +4 -4
- package/dist/discord.js.map +1 -1
- package/dist/gateway-service.d.ts +7 -3
- package/dist/gateway-service.d.ts.map +1 -1
- package/dist/gateway-service.js +28 -3
- package/dist/gateway-service.js.map +1 -1
- package/dist/gateway-types.d.ts +5 -0
- package/dist/gateway-types.d.ts.map +1 -1
- package/dist/gateway-types.js.map +1 -1
- package/dist/gateway.js +41 -12
- package/dist/gateway.js.map +1 -1
- package/dist/heartbeat.d.ts.map +1 -1
- package/dist/heartbeat.js +4 -0
- package/dist/heartbeat.js.map +1 -1
- package/dist/prompt-hooks.d.ts.map +1 -1
- package/dist/prompt-hooks.js +17 -0
- package/dist/prompt-hooks.js.map +1 -1
- package/dist/runtime-config.d.ts +3 -0
- package/dist/runtime-config.d.ts.map +1 -1
- package/dist/runtime-config.js +17 -1
- package/dist/runtime-config.js.map +1 -1
- package/dist/scheduled-task-runner.d.ts +8 -1
- package/dist/scheduled-task-runner.d.ts.map +1 -1
- package/dist/scheduled-task-runner.js +4 -1
- package/dist/scheduled-task-runner.js.map +1 -1
- package/dist/skills-guard.d.ts +36 -0
- package/dist/skills-guard.d.ts.map +1 -0
- package/dist/skills-guard.js +607 -0
- package/dist/skills-guard.js.map +1 -0
- package/dist/skills.d.ts +13 -2
- package/dist/skills.d.ts.map +1 -1
- package/dist/skills.js +494 -59
- package/dist/skills.js.map +1 -1
- package/dist/types.d.ts +6 -0
- package/dist/types.d.ts.map +1 -1
- package/docs/index.html +3 -3
- package/package.json +1 -1
- package/src/container-runner.ts +51 -1
- package/src/discord.ts +8 -5
- package/src/gateway-service.ts +50 -8
- package/src/gateway-types.ts +5 -0
- package/src/gateway.ts +61 -12
- package/src/heartbeat.ts +4 -0
- package/src/prompt-hooks.ts +11 -0
- package/src/runtime-config.ts +18 -1
- package/src/scheduled-task-runner.ts +8 -2
- package/src/skills-guard.ts +736 -0
- package/src/skills.ts +570 -61
- package/src/types.ts +7 -0
- package/.hybridclaw/container-image-state.json +0 -5
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,44 @@
|
|
|
8
8
|
|
|
9
9
|
### Fixed
|
|
10
10
|
|
|
11
|
+
## [0.1.22](https://github.com/HybridAIOne/hybridclaw/tree/v0.1.22)
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- **Skills trust scanner**: Added `src/skills-guard.ts` with Hermes-derived regex threat detection (exfiltration, prompt injection, destructive ops, persistence, reverse shells, obfuscation, supply chain, credential exposure), structural checks (file count/size limits, binary blocking, symlink escape checks), and invisible-unicode detection.
|
|
16
|
+
- **Skill scan cache**: Added mtime-signature + content-hash scanner caching to skip re-scan on unchanged skills.
|
|
17
|
+
- **Extended SKILL frontmatter**: Added support for `always`, `requires.bins`, `requires.env`, and `metadata.hybridclaw.{tags,related_skills}` while preserving backward compatibility for existing fields.
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- **Skill discovery tiers**: Expanded skill discovery precedence to `extra < bundled < codex < claude < agents-personal < agents-project < workspace`, including `config.skills.extraDirs[]` and `.agents/skills` interop paths.
|
|
22
|
+
- **Skill prompt embedding modes**: Implemented Always/Summary/Hidden behavior via frontmatter flags (`always`, `disable-model-invocation`) with `maxAlwaysChars=10000`, `maxSkillsPromptChars=30000`, and `maxSkillsInPrompt=150`.
|
|
23
|
+
- **Skill eligibility gating**: Skills with unmet `requires` are now silently excluded from both prompt availability and slash-command resolution.
|
|
24
|
+
- **Skill slash commands**: Added command-name sanitization (32-char max), reserved built-in command blocking, and deterministic collision deduplication (`-2`, `-3`, ...), while keeping `/skill name`, `/skill:name`, and `/<name>` invocation compatibility.
|
|
25
|
+
- **Web tool routing guidance**: Tool descriptions and runtime prompt guidance now include explicit `web_fetch` vs browser decision rules, concrete SPA/auth/app categories, and quantified cost asymmetry.
|
|
26
|
+
- **web_fetch escalation signaling**: `web_fetch` now emits structured escalation hints (`javascript_required`, `spa_shell_only`, `empty_extraction`, `boilerplate_only`, `bot_blocked`) and surfaces them in tool output for browser fallback routing.
|
|
27
|
+
- **Browser extraction steering**: `browser_navigate` responses now include text preview metadata and explicit next-step hints (`browser_snapshot` with `mode="full"`), and docs/prompts now clarify that `browser_pdf` is export-only (not text extraction).
|
|
28
|
+
|
|
29
|
+
### Fixed
|
|
30
|
+
|
|
31
|
+
## [0.1.21](https://github.com/HybridAIOne/hybridclaw/tree/v0.1.21)
|
|
32
|
+
|
|
33
|
+
### Added
|
|
34
|
+
|
|
35
|
+
- **Browser tool expansion**: Added `browser_vision`, `browser_get_images`, `browser_console`, and `browser_network` to the container browser toolset and subagent allowlists.
|
|
36
|
+
- **Frame-aware browser interactions**: Added optional `frame` targeting to browser interaction tools and exposed iframe metadata in browser snapshots.
|
|
37
|
+
- **Discord artifact delivery path**: Added proactive/delegation artifact propagation so generated screenshot/PDF outputs can be attached to Discord messages.
|
|
38
|
+
|
|
39
|
+
### Changed
|
|
40
|
+
|
|
41
|
+
- **Vision request payload policy**: Browser vision requests now always send a single-message payload with `enable_rag: false` and include required active request context (`baseUrl`, `apiKey`, `model`, `chatbot_id`).
|
|
42
|
+
- **Browser snapshot modes**: Added explicit snapshot `mode` support (`default`, `interactive`, `full`) for tighter interactive-only dumps.
|
|
43
|
+
|
|
44
|
+
### Fixed
|
|
45
|
+
|
|
46
|
+
- **Delegation attachment gap**: Resolved delegated/scheduled tool-result path that previously posted text-only proactive responses while omitting generated artifacts.
|
|
47
|
+
- **Bot-detection signaling**: Browser navigation responses now emit structured warning hints when known anti-bot/verification titles are detected.
|
|
48
|
+
|
|
11
49
|
## [0.1.20](https://github.com/HybridAIOne/hybridclaw/tree/v0.1.20)
|
|
12
50
|
|
|
13
51
|
### Added
|
package/README.md
CHANGED
|
@@ -87,6 +87,7 @@ HybridClaw uses typed runtime config in `config.json` (auto-created on first run
|
|
|
87
87
|
|
|
88
88
|
- Start from `config.example.json` (reference)
|
|
89
89
|
- Runtime watches `config.json` and hot-reloads most settings (model defaults, heartbeat, prompt hooks, limits, etc.)
|
|
90
|
+
- `skills.extraDirs` adds additional enterprise/shared skill roots (lowest precedence tier)
|
|
90
91
|
- `proactive.*` controls autonomous behavior (`activeHours`, `delegation`, `autoRetry`)
|
|
91
92
|
- `observability.*` controls push ingest into HybridAI (`events:batch` endpoint, batching, identity metadata)
|
|
92
93
|
- Some settings require restart to fully apply (for example HTTP bind host/port)
|
|
@@ -178,13 +179,25 @@ HybridClaw supports `SKILL.md`-based skills (`<skill-name>/SKILL.md`).
|
|
|
178
179
|
|
|
179
180
|
You can place skills in:
|
|
180
181
|
|
|
181
|
-
-
|
|
182
|
-
- `<
|
|
183
|
-
- `$CODEX_HOME/skills/<skill-name>/SKILL.md
|
|
182
|
+
- any directory listed in `config.skills.extraDirs[]` (enterprise/shared)
|
|
183
|
+
- bundled package skills (`<hybridclaw install>/skills/<skill-name>/SKILL.md`)
|
|
184
|
+
- `$CODEX_HOME/skills/<skill-name>/SKILL.md` or `~/.codex/skills/<skill-name>/SKILL.md`
|
|
185
|
+
- `~/.claude/skills/<skill-name>/SKILL.md`
|
|
186
|
+
- `~/.agents/skills/<skill-name>/SKILL.md`
|
|
187
|
+
- `./.agents/skills/<skill-name>/SKILL.md` (project)
|
|
188
|
+
- `./skills/<skill-name>/SKILL.md` (workspace)
|
|
184
189
|
|
|
185
190
|
Load precedence is:
|
|
186
191
|
|
|
187
|
-
-
|
|
192
|
+
- `extra < bundled < codex < claude < agents-personal < agents-project < workspace`
|
|
193
|
+
- skills are merged by `name`; higher-precedence sources override lower-precedence ones
|
|
194
|
+
|
|
195
|
+
Security scanning is trust-aware:
|
|
196
|
+
|
|
197
|
+
- `bundled` sources are treated as `builtin` and not scanned
|
|
198
|
+
- `workspace` sources (`./skills/`, `./.agents/skills/`) are scanned; `caution` is allowed, `dangerous` is blocked
|
|
199
|
+
- `personal` sources (`~/.codex/skills/`, `~/.claude/skills/`, `~/.agents/skills/`) are scanned and blocked on `caution`/`dangerous`
|
|
200
|
+
- scanner includes Hermes-derived regex checks, structural limits (50 files, 1MB total, 256KB/file, binary/symlink checks), invisible-unicode detection, and mtime+content-hash cache reuse
|
|
188
201
|
|
|
189
202
|
### Required format
|
|
190
203
|
|
|
@@ -196,6 +209,14 @@ name: repo-orientation
|
|
|
196
209
|
description: Quickly map an unfamiliar repository and identify where a requested feature should be implemented.
|
|
197
210
|
user-invocable: true
|
|
198
211
|
disable-model-invocation: false
|
|
212
|
+
always: false
|
|
213
|
+
requires:
|
|
214
|
+
bins: [docker, git]
|
|
215
|
+
env: [GITHUB_TOKEN]
|
|
216
|
+
metadata:
|
|
217
|
+
hybridclaw:
|
|
218
|
+
tags: [devops, docker]
|
|
219
|
+
related_skills: [kubernetes]
|
|
199
220
|
---
|
|
200
221
|
|
|
201
222
|
# Repo Orientation
|
|
@@ -208,16 +229,25 @@ Supported frontmatter keys:
|
|
|
208
229
|
- `description` (required)
|
|
209
230
|
- `user-invocable` (optional, default `true`)
|
|
210
231
|
- `disable-model-invocation` (optional, default `false`)
|
|
232
|
+
- `always` (optional, default `false`; embeds full skill body in the system prompt up to `maxAlwaysChars=10000`, then demotes to summary)
|
|
233
|
+
- `requires.bins` / `requires.env` (optional; skill is excluded unless requirements are met)
|
|
234
|
+
- `metadata.hybridclaw.tags` / `metadata.hybridclaw.related_skills` (optional metadata namespace)
|
|
211
235
|
|
|
212
236
|
### Using skills
|
|
213
237
|
|
|
214
|
-
Skills are listed to the model as metadata (`name`, `description`, `location`), and the model reads `SKILL.md` on demand with the `read` tool.
|
|
238
|
+
Skills are listed to the model as metadata (`name`, `description`, `location`), and the model reads `SKILL.md` on demand with the `read` tool. Skills with `always: true` are embedded directly in the system prompt.
|
|
239
|
+
|
|
240
|
+
Prompt embedding modes:
|
|
241
|
+
|
|
242
|
+
- `Always`: `always: true` embeds full body in `<skill_always ...>` (budgeted by `maxAlwaysChars=10000`)
|
|
243
|
+
- `Summary`: default mode, emits only XML metadata under `<available_skills>`
|
|
244
|
+
- `Hidden`: `disable-model-invocation: true` excludes the skill from model prompt metadata (still invocable by slash command when `user-invocable: true`)
|
|
215
245
|
|
|
216
246
|
Explicit invocation is supported via:
|
|
217
247
|
|
|
218
248
|
- `/skill <name> [input]`
|
|
219
249
|
- `/skill:<name> [input]`
|
|
220
|
-
- `/<name> [input]` (when `user-invocable: true`)
|
|
250
|
+
- `/<name> [input]` (when `user-invocable: true`; command names are sanitized to lowercase `a-z0-9-`, max 32 chars, with `-2`/`-3` dedup and built-in command-name blocking)
|
|
221
251
|
|
|
222
252
|
Example skill in this repo:
|
|
223
253
|
|
|
@@ -233,8 +263,8 @@ The agent has access to these sandboxed tools inside the container:
|
|
|
233
263
|
- `memory` — durable memory files (`MEMORY.md`, `USER.md`, `memory/YYYY-MM-DD.md`)
|
|
234
264
|
- `session_search` — search/summarize historical sessions from transcript archives
|
|
235
265
|
- `delegate` — push-based background subagent tasks (`single`, `parallel`, `chain`) with auto-announced completion (no polling)
|
|
236
|
-
- `web_fetch` — fetch
|
|
237
|
-
- `browser_*` (optional) —
|
|
266
|
+
- `web_fetch` — plain HTTP fetch + extraction for static/read-only content (docs, articles, READMEs, JSON/text APIs, direct files)
|
|
267
|
+
- `browser_*` (optional) — full browser automation for JS-rendered or interactive pages (`navigate`, `snapshot`, `click`, `type`, `press`, `scroll`, `back`, `screenshot`, `pdf`, `close`)
|
|
238
268
|
|
|
239
269
|
`delegate` mode examples:
|
|
240
270
|
|
|
@@ -244,6 +274,12 @@ The agent has access to these sandboxed tools inside the container:
|
|
|
244
274
|
|
|
245
275
|
Browser tooling notes:
|
|
246
276
|
|
|
277
|
+
- Routing default: prefer `web_fetch` first for read-only retrieval.
|
|
278
|
+
- Use browser tools for SPAs/web apps/auth flows/interaction tasks, or when `web_fetch` returns escalation hints (`javascript_required`, `spa_shell_only`, `empty_extraction`, `boilerplate_only`, `bot_blocked`).
|
|
279
|
+
- Cost profile: browser calls are typically ~10-100x slower/more expensive than `web_fetch`.
|
|
280
|
+
- Browser read flow: after `browser_navigate`, use `browser_snapshot` with `mode="full"` to extract content, then `browser_scroll` + `browser_snapshot` for additional lazy-loaded sections.
|
|
281
|
+
- `browser_pdf` is for export artifacts, not text extraction.
|
|
282
|
+
|
|
247
283
|
- The shipped container image preinstalls `agent-browser` and Chromium (Playwright).
|
|
248
284
|
- You can override the binary via `AGENT_BROWSER_BIN` if needed.
|
|
249
285
|
- User-directed authenticated browser-flow testing is supported (including filling/submitting login forms on the requested site).
|
package/config.example.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hybridclaw-agent",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.22",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "hybridclaw-agent",
|
|
9
|
-
"version": "0.1.
|
|
9
|
+
"version": "0.1.22",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@mozilla/readability": "^0.6.0",
|
|
12
12
|
"agent-browser": "^0.15.1",
|