@burtson-labs/agent-adapters-web 1.0.4 → 1.0.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.
Files changed (2) hide show
  1. package/README.md +49 -0
  2. package/package.json +2 -2
package/README.md ADDED
@@ -0,0 +1,49 @@
1
+ <div align="center">
2
+ <a href="https://burtson.ai">
3
+ <picture>
4
+ <img src="https://cdn.burtson.ai/logos/bandit-stealth.png" alt="Bandit Stealth" width="150" style="width: 150px !important; max-width: 150px !important; height: auto; display: inline-block;" />
5
+ </picture>
6
+ </a>
7
+
8
+ # @burtson-labs/agent-adapters-web
9
+
10
+ **Browser host adapter for the Bandit Agent Framework.**
11
+
12
+ Run an [`@burtson-labs/agent-core`](https://www.npmjs.com/package/@burtson-labs/agent-core) runtime in the browser — agent events are dispatched through a configurable `EventTarget` so any host (a React app, a webview, a worker) can subscribe with normal DOM event listeners.
13
+ </div>
14
+
15
+ ---
16
+
17
+ ## <img src="https://api.iconify.design/lucide/package.svg?color=%23a60ee5&width=22" align="absmiddle"> Install
18
+
19
+ ```bash
20
+ pnpm add @burtson-labs/agent-adapters-web @burtson-labs/agent-core
21
+ ```
22
+
23
+ ## <img src="https://api.iconify.design/lucide/puzzle.svg?color=%23a60ee5&width=22" align="absmiddle"> What's inside
24
+
25
+ - `WebAdapter` — wraps an `AgentRuntime` with `plan` / `execute` / `report` plus a `subscribe(listener)` returning an unsubscribe function
26
+ - `WebAdapterOptions` — extends `CreateAgentRuntimeOptions` with `target` (custom `EventTarget`) and `eventName` for the dispatched event type
27
+ - `MinimalEventTarget` — structural type for hosts that ship a partial event target (workers, custom impls)
28
+
29
+ ## <img src="https://api.iconify.design/lucide/zap.svg?color=%23a60ee5&width=22" align="absmiddle"> Quick example
30
+
31
+ ```ts
32
+ import { createWebAdapter } from "@burtson-labs/agent-adapters-web";
33
+
34
+ const adapter = createWebAdapter({
35
+ target: window,
36
+ eventName: "bandit-agent-event"
37
+ });
38
+
39
+ const unsubscribe = adapter.subscribe((event) => {
40
+ console.log(event.type, event.payload);
41
+ });
42
+
43
+ await adapter.plan("Summarize the current page");
44
+ unsubscribe();
45
+ ```
46
+
47
+ ## License
48
+
49
+ [Apache License 2.0](LICENSE) — Copyright 2026 Burtson Labs.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burtson-labs/agent-adapters-web",
3
- "version": "1.0.4",
3
+ "version": "1.0.5",
4
4
  "description": "Web adapter for the Bandit Agent Framework.",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -18,7 +18,7 @@
18
18
  ],
19
19
  "license": "Apache-2.0",
20
20
  "dependencies": {
21
- "@burtson-labs/agent-core": "1.6.13"
21
+ "@burtson-labs/agent-core": "1.6.14"
22
22
  },
23
23
  "scripts": {
24
24
  "prebuild": "pnpm -C ../../.. --filter @burtson-labs/agent-core build",