Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions declarative-api-explainer.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ interface SubmitEvent : Event {
};
```

**`toolactivated` and `toolcanceled` events**
**`toolactivated` and `toolcancel` events**

We introduce these events that get fired at the `ModelContext` object when a WebMCP tool is run, and when
its invocation is canceled.
Expand All @@ -183,7 +183,7 @@ form to the user's attention, once a declarative tool is filled out but before i
JavaScript equivalent of the [`:tool-form-active` pseudo-class](#pseudo-classes).

When the agent cancels a tool call (perhaps because a user has instigated another turn of the
conversation, obviating the need for the pending tool), the `toolcanceled` event is fired. Note that
conversation, obviating the need for the pending tool), the `toolcancel` event is fired. Note that
this event does not fire when the site itself cancels the tool, due to removing the form element or
changing its name or description.

Expand All @@ -195,7 +195,7 @@ Some open questions:
> that](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/script_tools/model_context.cc;l=265-274;drc=2af6413cf36d701fdaffb09188f2ab2a5be37f4f).

> [!WARNING]
> For declarative, should they be fired at `Window` or at the `<form>` that registered the tool in
> For declarative, should they be fired at `ModelContext` or at the `<form>` that registered the tool in
> the first place, and bubble up to the document that way? See
> https://github.com/webmachinelearning/webmcp/issues/126.

Expand Down
2 changes: 1 addition & 1 deletion security-privacy-questionnaire.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Yes, origin-supplied tools can influence the user agent's UI in the following wa

- A tool's [`title`](https://webmachinelearning.github.io/webmcp/#dom-modelcontexttool-title) is displayed by the user agent when referencing the tool in its UI.
- Tool responses (the return value of [`execute`](https://webmachinelearning.github.io/webmcp/#dom-modelcontexttool-execute)) may be shown in, or influence, the user agent's UI.
- [Tool annotations](https://webmachinelearning.github.io/webmcp/#dom-modelcontexttoolannotations) can indirectly influence how an agent presents a tool invocation (e.g., a `readOnlyHint` may cause the agent to skip a confirmation step).
- [Tool annotations](https://webmachinelearning.github.io/webmcp/#dictdef-toolannotations) can indirectly influence how an agent presents a tool invocation (e.g., a `readOnlyHint` may cause the agent to skip a confirmation step).

There is also discussion of `requestUserInput` in [Issue #165](https://github.com/webmachinelearning/webmcp/issues/165).

Expand Down
Loading