Inspiration

Japan has highly organized waste-disposal systems, but the rules differ between municipalities. The same object may be classified differently depending on the city, quantity, size, material, or safety risk.

People also rarely use exact official category names. They say things like:

“I have ten of those transparent things sold at convenience stores for rainy days, something I put on the floor to sleep on, and a portable battery for charging my phone.”

An AI agent can understand what the user probably means, but it should not invent municipal rules or automatically complete a potentially unsafe action.

GomiMCP separates those responsibilities:

  • The municipality declares the rules.
  • The agent interprets the user’s language.
  • The human makes the final decision.

What it does

GomiMCP is a static WebMCP-powered interface that exposes structured municipal waste rules directly from a webpage.

The page registers three WebMCP tools:

  • resolve_item converts ordinary or indirect wording into a canonical waste item.
  • get_disposal_rule returns the municipality’s declared rule for that item.
  • prepare_bulky_pickup prepares an eligible bulky-waste request without finalizing it.

In the demo, the agent interprets one indirect Japanese request as ten umbrellas, one futon, and one mobile power bank. It makes eight real WebMCP calls:

  • resolve_item ×3
  • get_disposal_rule ×3
  • prepare_bulky_pickup ×2

Under Aoba City’s fictional test rules, ten umbrellas and the futon are classified as bulky waste. GomiMCP prepares both requests and displays a Human Confirmation Gate totaling 800 yen.

The mobile power bank is classified as high-risk. Automated preparation is refused, and the result is marked manual_review_required.

The agent can prepare eligible requests, but it cannot press the final confirmation button. Nothing is booked until a human explicitly confirms it.

How we built it

GomiMCP is a static JavaScript application deployed with GitHub Pages.

Its tools are registered using document.modelContext.registerTool(). Each tool provides a name, natural-language description, JSON input schema, execution logic, and safety annotations.

The implementation separates:

  • Item aliases and canonical identifiers
  • Municipality-specific classifications
  • Conditional rules such as quantity thresholds
  • Fees and reservation requirements
  • Risk levels and automation permissions
  • Human-confirmation requirements
  • Rule provenance and version information

The LIVE WEBMCP TRACE displays only actual tool calls made through the page, making the interaction visible and auditable.

No backend, database, authentication system, payment integration, or real municipality booking is used.

Challenges we ran into

The hardest problem was deciding where language interpretation should end and authoritative decision-making should begin.

Natural language is flexible, while municipal rules must be precise. Allowing a language model to invent a disposal category would be unsafe. Passing an entire ambiguous sentence directly into a rule engine would also be unreliable.

We solved this with a staged flow:

  1. The agent interprets each description as one ordinary item concept.
  2. GomiMCP resolves that concept to a canonical item.
  3. The page applies the selected municipality’s declared rules.
  4. Risk policies determine whether automation must stop.
  5. Consequential actions stop at a visible Human Confirmation Gate.

Another challenge was proving that the tools were actually called. The LIVE WEBMCP TRACE records real page-level tool activity rather than displaying a simulated agent response.

Accomplishments that we're proud of

We successfully demonstrated:

  • Semantic interpretation of indirect Japanese descriptions
  • Eight real WebMCP tool calls
  • Deterministic results based on municipality and quantity
  • Automatic refusal for a high-risk mobile battery
  • Preparation of two eligible bulky-waste requests
  • A mandatory human-confirmation boundary
  • A visible and auditable trace of every tool call
  • A complete product experience running as a static website

We are especially proud that the demo shows a useful division of responsibility: the agent understands the user, the page owns the rules, and the human retains control of the final action.

What we learned

AI does not need to own every decision to be useful.

The model is best used for understanding human intent. The authoritative source should still own the rule, the safety constraint, and the final action boundary.

WebMCP makes this division practical. It allows an ordinary webpage to expose structured capabilities to an agent while preserving the page’s existing logic, state, and user interface.

We also learned that observability matters. Showing the real tool-call trace makes the system easier to test, explain, and trust.

What's next for GomiMCP

The current version uses fictional municipalities and test rules derived from official municipal open-data structures. It must not be used as real-world disposal advice.

Future work includes:

  • Importing and validating real municipality-maintained rules
  • Expanding rule provenance and version tracking
  • Supporting more item conditions, such as dimensions and remaining contents
  • Adding multilingual municipality-maintained descriptions
  • Providing reusable schemas for additional municipalities
  • Exploring Remote MCP and SDK integrations
  • Testing the same contracts across more WebMCP-aware agents and browsers

Our longer-term goal is simple: municipalities should be able to declare their rules once and make them safely usable by people, websites, and AI agents.

Built With

Share this project:

Updates

Submission history