@dudko.dev/agent-web 0.0.46 → 0.0.48
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 +12 -2
- package/dist/agent-web.js +124 -124
- package/dist/agent-web.js.map +1 -1
- package/dist/{chunk-Y6CD3WOK.js → chunk-6D4RB3H5.js} +11 -213
- package/dist/chunk-6D4RB3H5.js.map +1 -0
- package/dist/{chunk-PTJA7V23.js → chunk-6XHCPSZE.js} +5 -3
- package/dist/{chunk-PTJA7V23.js.map → chunk-6XHCPSZE.js.map} +1 -1
- package/dist/{chunk-Y4MIIBPB.js → chunk-7D2CJQB2.js} +1 -100
- package/dist/chunk-7D2CJQB2.js.map +1 -0
- package/dist/chunk-7Y5UC6L7.js +52 -0
- package/dist/chunk-7Y5UC6L7.js.map +1 -0
- package/dist/chunk-IT77BVAD.js +99 -0
- package/dist/chunk-IT77BVAD.js.map +1 -0
- package/dist/chunk-JTZEUPIG.js +217 -0
- package/dist/chunk-JTZEUPIG.js.map +1 -0
- package/dist/index.cjs +45 -26
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +25 -74
- package/dist/index.d.ts +25 -74
- package/dist/index.js +47 -70
- package/dist/index.js.map +1 -1
- package/dist/mcp.cjs +28 -20
- package/dist/mcp.cjs.map +1 -1
- package/dist/mcp.d.cts +4 -3
- package/dist/mcp.d.ts +4 -3
- package/dist/mcp.js +9 -5
- package/dist/mcp.js.map +1 -1
- package/dist/{sandbox-ZXWD5IWZ.js → sandbox-IGTCMOOX.js} +4 -3
- package/dist/{sandbox-ZXWD5IWZ.js.map → sandbox-IGTCMOOX.js.map} +1 -1
- package/dist/secrets.cjs +329 -0
- package/dist/secrets.cjs.map +1 -0
- package/dist/secrets.d.cts +63 -0
- package/dist/secrets.d.ts +63 -0
- package/dist/secrets.js +20 -0
- package/dist/secrets.js.map +1 -0
- package/dist/{vault-Mar2CY0J.d.ts → skills-ufoyTJ-B.d.cts} +2 -36
- package/dist/{vault-Mar2CY0J.d.cts → skills-ufoyTJ-B.d.ts} +2 -36
- package/dist/vault-BBGybouF.d.cts +35 -0
- package/dist/vault-BBGybouF.d.ts +35 -0
- package/package.json +11 -1
- package/dist/chunk-Y4MIIBPB.js.map +0 -1
- package/dist/chunk-Y6CD3WOK.js.map +0 -1
package/README.md
CHANGED
|
@@ -107,7 +107,8 @@ import {
|
|
|
107
107
|
} from '@dudko.dev/agent-web'
|
|
108
108
|
import { z } from 'zod'
|
|
109
109
|
|
|
110
|
-
// 1. Store the user's key once (e.g. from a settings form). Encrypted at rest.
|
|
110
|
+
// 1. Store the user's key once (e.g. from a settings form). Encrypted at rest. (A settings page
|
|
111
|
+
// that only stores keys can import it from '@dudko.dev/agent-web/secrets': no agent loaded.)
|
|
111
112
|
const credentials = new VaultCredentialStore()
|
|
112
113
|
await credentials.setApiKey('openai', userProvidedKey)
|
|
113
114
|
|
|
@@ -995,7 +996,8 @@ await watch.stop()
|
|
|
995
996
|
- **Change notices** (`credentials`, `oauth`, `files`, `session`, `runs`, `skills`, and the React
|
|
996
997
|
package's `chats`): one channel per database name, sent after the transaction completed, never for
|
|
997
998
|
a failed write, never heard by the tab that wrote. A store of your own posts with
|
|
998
|
-
`postStorageChange
|
|
999
|
+
`postStorageChange` (kind `host` for one that keeps none of those: which store, which record -
|
|
1000
|
+
names only). `agent.reloadLearnedSkills()` re-reads the notebook after a `skills` notice.
|
|
999
1001
|
- **`sessionLock`** (`'wait'` default, `'fail'`, `'off'`): the session's Web Lock for the run's whole
|
|
1000
1002
|
duration, released however it ends (and by the browser when the tab closes). Subagents that share
|
|
1001
1003
|
the session run under the parent's hold; helpers and pipeline nodes have sessions of their own.
|
|
@@ -1009,6 +1011,14 @@ await watch.stop()
|
|
|
1009
1011
|
- **`watchSession`**: the run's events (clipped), its state (`running`, `ended: 'done' | 'stopped' |
|
|
1010
1012
|
'gone'`), a replay for a tab that joins late, `send` and `stop`. Tool approvals never cross: they
|
|
1011
1013
|
are answered in the tab that runs the tool.
|
|
1014
|
+
- **A deletion or an upgrade in another tab is never held up**: the one connection per database
|
|
1015
|
+
closes on `versionchange`; the next use opens a new, empty database after a deletion (the vault
|
|
1016
|
+
makes a new key there), and fails with a `VersionError` after an upgrade by a newer copy, until a
|
|
1017
|
+
reload.
|
|
1018
|
+
- **The vault without the agent**: `@dudko.dev/agent-web/secrets` (`IndexedDBVault`,
|
|
1019
|
+
`VaultCredentialStore`, `MemoryCredentialStore`, `getOrCreateVaultKey`, `encryptJSON`,
|
|
1020
|
+
`decryptJSON`) loads `idb` and the vault only - for a page that stores or lists keys before (or
|
|
1021
|
+
without) the agent. The same objects as the main entry's.
|
|
1012
1022
|
|
|
1013
1023
|
Details: [Several tabs](docs/capabilities.md#several-tabs) ·
|
|
1014
1024
|
[what crosses, and who can post](docs/security.md#several-tabs-what-crosses-and-who-can-post) ·
|