@dudko.dev/agent-web 0.0.49 → 0.0.50
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 +1 -1
- package/dist/agent-web.js +155 -155
- package/dist/agent-web.js.map +1 -1
- package/dist/index.cjs +219 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +83 -47
- package/dist/index.d.ts +83 -47
- package/dist/index.js +212 -9
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1043,7 +1043,7 @@ Details: [Several tabs](docs/capabilities.md#several-tabs) ·
|
|
|
1043
1043
|
| `mcpSkills` | `{ consent: 'once-per-skill' }` | experimental: when a person is asked (`toolApproval.onRequest`, a request with `skill`) before an MCP server's skill enters the model's context, for servers whose `skills: { consent }` does not say - `'once-per-skill'`, `'ask'` (every run) or `'never'` - see [MCP skills](#mcp-skills-experimental-a-servers-instructions-as-skills) |
|
|
1044
1044
|
| `egress` | off | what the **model** may fetch (`web_fetch`): `true` = any public host over https, or `{ allow, deny, protocols, allowPrivateNetwork, fetch, ... }`; a browser can't pin DNS, so prefer an `allow` list — see [Egress](docs/capabilities.md#egress-what-the-model-may-fetch) |
|
|
1045
1045
|
| `search` | off | the model may **search the web** (`web_search`: a short list of title / url / snippet): `{ engine: fn }` - a search engine of yours, any API (it may answer `{ results, usage }`: a search through a model is charged as phase `'search'`) - or `{ provider: 'google', credentialRef, model, baseURL, maxResults, allowPrivateNetwork, readOnly, fetch }` - Google Search through Gemini grounding: one extra `generateContent` call per search on a Gemini key (default model `gemini-2.5-flash-lite`), which **spends model tokens** (`usage` phase `'search'`) and returns **Google redirect links**, not the pages' URLs. No key ships with the library and none is written in the config (`credentialRef` names it in `credentials`); the request reaches only that API; with `egress`, results the model could not fetch are left out. Recipes for Tavily / Brave / SearXNG as an `engine`, the free-tier models and what the redirect links mean — see [Search](docs/capabilities.md#search-finding-the-page-to-fetch) |
|
|
1046
|
-
| `media` | off | image generation, speech and transcription as tools, each mounted only when its model is set: `{ imageModel, speechModel, transcriptionModel, maxCalls, timeoutMs, files, folder, voice, speechFormat, transcribeAttachments }`. A model is an AI SDK image / speech / transcription model object or a `ProviderModelSpec` (key by `credentialRef`). Generated files go to the virtual file system and the model gets a path, never the bytes; attached audio is transcribed to text; calls are counted in `usage.mediaCalls` (and the other media fields) and capped per run — see [Media](docs/capabilities.md#media-images-speech-and-transcription) |
|
|
1046
|
+
| `media` | off | image generation, speech and transcription as tools, each mounted only when its model is set: `{ imageModel, imageInputs, speechModel, transcriptionModel, maxCalls, timeoutMs, files, folder, voice, speechFormat, transcribeAttachments }`. A model is an AI SDK image / speech / transcription model object or a `ProviderModelSpec` (key by `credentialRef`). Generated files go to the virtual file system and the model gets a path, never the bytes; `generate_image({ prompt, images? })` sends up to 4 reference pictures of the workspace (the person's photo, "like this") to an image model that takes them (`imageInputs`, else the model's own `supportsFileInputs`) - checked by their bytes and capped; one that takes none makes the picture from the text and the result says so; attached audio is transcribed to text; calls are counted in `usage.mediaCalls` (and the other media fields) and capped per run — see [Media](docs/capabilities.md#media-images-speech-and-transcription) |
|
|
1047
1047
|
| `decisionModel` | off | a **decision model** - answers a closed question with one option and a probability instead of writing text: `{ providerType: 'google', model: 'gemini-decision-1', credentialRef }` (the key stays in `credentials`; the request reaches only that API) or an object with `decide(question, { abortSignal })`. Where it is confident it replaces the replanner's continue / finish call and a pipeline node's route call; never consulted for tool approval or egress — see [Decision models](docs/capabilities.md#decision-models) |
|
|
1048
1048
|
| `decision` | `{}` | `{ confidenceThreshold, timeoutMs, replan, route }` (defaults 0.8, 5000 ms, on, on): below the threshold, on an error, a timeout or an answer that is not an option, the ordinary model call runs unchanged |
|
|
1049
1049
|
| `askUser` | off | the **model** may ask the person ONE closed question with buttons instead of guessing (the built-in `ask_user`: a question, 2-6 options, optionally `multiple` or `allowOther`): `{ onQuestion(req, { signal }), timeoutMs, maxPerRun }`. `onQuestion` answers `{ choice: [label] }`, `{ other: text }` or `{ declined: true }`; without it there is no tool (`true` / `{}` = the handler comes later, e.g. from `useAgent`). At most `maxPerRun` (3) per run, helpers and subagents included; each waits `timeoutMs` (300000; the step's limit stops meanwhile), a stop ends the wait. Events `user.question-asked` / `user.question-answered` (the labels picked, never the person's own words). The question and options are the model's text, cleaned: render them as plain text. See [Asking the user](docs/capabilities.md#asking-the-user-a-question-with-choices) |
|