Skip to content

Various questions & feedback #237

Description

@jakearchibald

Noting this all down in one place ahead of a meeting. I only read through the spec and explainers on a plane, so apologies if this is stuff that's already been discussed. If anything isn't a quick answer, I can create a separate issue.

Also see #236.


Browsing context required: As tool calls are handled in JavaScript, a browser tab or a webview must be opened to provide a visible interface and browser context. In other words, there is no support for agents or assistive tools to call tools in a headless state.

Why? Headless browsers have a browsing context right?


WebMCP is only available in origin-isolated documents. This ensures that the document's origin remains stable throughout the tool's lifetime.

Why? Not saying it's wrong, just don't understand. postMessage doesn't have this limitation.


Can tools provide progress? Seems like a job for a stream/observable!


How does document.modelContext access work across origin for exposed tools? (document access will be blocked right?)


Why is inputSchema stringified? Seems a bit weird.


The browser agent, on the other hand, does not run JavaScript on the page.

I guess you're already on top of this, but the same should happen for executing tools.


Using JSON schema seems a bit… WebSQL. Is the format frozen? What if it's changed in future? I assume there's no actual casting/validation of the format?


Do we need an output schema? So, if the function returns an object, the agent can understand how the various keys can be used.


Should an observation be required before attempting to call a tool? In case things have changed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions