Skip to content

Add opt-in Parallel documentation search to WebToolProvider - #109

Open
georgeatparallel wants to merge 1 commit into
ArtificialAnalysis:mainfrom
georgeatparallel:george/parallel-mcp-stirrup-1d2c10a8
Open

georgeatparallel wants to merge 1 commit into
ArtificialAnalysis:mainfrom
georgeatparallel:george/parallel-mcp-stirrup-1d2c10a8

Conversation

@georgeatparallel

Copy link
Copy Markdown

For attended documentation lookups, a host may approve one literal public search phrase before the agent runs. WebToolProvider currently exposes a model-authored Brave query, and generic MCP registration forwards the model's tool arguments, so preserving that approval requires a custom wrapper.

This adds explicit search_provider="parallel" and a required parallel_public_query to WebToolProvider. The model receives an argument-free web_search; extra arguments fail validation before dispatch. One provider instance permits one attempt, including failures and cancellation, and sends the exact approved phrase to Unified MCP with a fixed documentation objective. Original source URLs and excerpts return to the next agent turn. Brave remains the default, and default tools and Slack registration retain their existing behavior. The documentation explains host approval, public-only input, and one attended operation per provider. The MCP extra minimum becomes the already locked and tested 1.23.3, which supplies the transport hook and structured results used here.

Validation at commit b564e25495edd40e902a7d9109037df402c59d80:

  • 129 tests passed across the Parallel, Brave search, web fetch, Agent and existing MCP image suites. Local HTTP/model fixtures cover exact forwarding, argument rejection before dispatch, original URL and fact citation, absent opt-in, repeated attempts and provider re-entry, empty/structured results, tool errors, unavailable service, timeout and cancellation.
  • Full-repository ruff format, ruff lint and ty checks passed with locked all-extras/dev dependencies. Documentation and package builds passed.
  • A separate live anonymous Unified MCP check ran through the normal Agent session with a deterministic local LLMClient fixture. It sent one search for Python 3.13 tomllib TOMLDecodeError, observed Stirrup/0.2.1 (Parallel MCP) on actual HTTP requests, and carried the original Python 3.13 documentation URL into both the tool response and cited final answer. Retrieval was live; the model was a local fixture.
  • Fresh independent automated review was CLEAN on the unchanged exact commit and independently repeated the 129 tests plus repository format, lint and type checks.

Setup: Parallel MCP setup.

This is a Parallel DevRel contribution prepared with AI assistance and independently reviewed by an automated reviewer.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant