# Kopilotti WebMCP **The agent can propose. It cannot approve itself. Deterministic policy decides. The receipt proves it.** Kopilotti WebMCP is an open-source challenge build for the [WebMCP Challenge 2026](https://webmcp.devpost.com/). The live page presents **Kopilotti Sales** as the fictional storefront and identifies this repository as the open challenge implementation, not the private production engine. It explores how a person and a browser agent can share one visible automotive-shopping workspace without delegating commercial authority to the model. The browser agent can: - search a fictional six-vehicle inventory; - compare factual vehicle fields; - display versioned vehicle-condition facts; - prepare a local, non-binding price-discussion draft for the user's review; and - request deterministic evaluation of that exact draft only after page-native human approval. It cannot approve itself, set or override pricing policy, submit an offer, contact a dealer, create a transaction, access production data, or use the private Kopilotti Sales decision engine. ## Why WebMCP Normal browser automation has to infer controls from a visual interface. This build exposes five narrowly scoped, described and schema-constrained tools through `document.modelContext.registerTool()`. Tool calls update the same page the user sees, making the agent's work observable and correctable. ```mermaid flowchart LR A[Browser agent] -->|structured call| W[WebMCP tools] W --> S[Shared visible workspace] S --> H{Human approval} H -->|stop or revise| A H -->|approved draft| D[Deterministic demo policy] ``` ## Tools | Tool | Side effect | Boundary | |---|---|---| | `search_vehicles` | Read only | Fictional public demo data only | | `compare_vehicles` | Read only | Factual comparison; no suitability ranking | | `get_vehicle_condition` | Read only | Versioned facts must be shown before drafting | | `prepare_price_discussion` | Local UI draft | Pending, reversible and unevaluated | | `evaluate_price_discussion` | Local policy result and receipt | Blocked unless the exact draft has page-native human approval | Tool descriptions state their actual behavior. Inputs are bounded with JSON Schema, read-only tools carry `readOnlyHint: true`, execution supports cancellation, and no tool accepts personal data. Human approval is intentionally absent from the WebMCP manifest. ## Run locally Requirements: a recent Node.js release for tests and any static HTTP server for the page. ```bash npm test npm run serve ``` Open `http://localhost:4173`. In a browser without WebMCP support, the numbered manual fallback controls call the same application functions and label their invocation source as manual. To invoke the registered tools, use ChatGPT's in-app browser or Chrome with WebMCP testing enabled. Live demo: ## Example agent request > Find performance sedans under €100,000. Compare KS-001 and KS-002, show the condition facts for KS-001, then prepare a non-binding €90,000 price-discussion draft. Do not claim to approve it for me. ## Safety and IP boundary This repository is a standalone MIT-licensed competition implementation. All inventory is fictional. It contains no production endpoints, credentials, customer data, dealer data, private pricing rules, price floors, decision thresholds or source code from the proprietary Kopilotti Sales transaction engine. Development was AI-assisted with OpenAI Codex. The product scope, trust boundary, implementation decisions, reviews and submission remain human-directed. The guiding product principle remains: > AI handles the conversation. Dealer-controlled deterministic rules make the commercial decision. ## License [MIT](LICENSE) © 2026 Mikko Tarkiainen ## Submission materials - [Devpost submission draft](docs/DEVPOST_SUBMISSION.md) - [Demo script](docs/DEMO_SCRIPT.md) - [Submission checklist](docs/SUBMISSION_CHECKLIST.md)