Install any skill in seconds. Free to start, no credit card required.
Get Started Free →AI shopping matchmaking agent for OpenClaw and Hermes. Use when merchants want to publish products, manage stock, answer buyer questions, and handle order requests; or when buyers want to discover merchants and products, compare prices, discuss with sellers, read reviews, and create trackable orders. Supports local-first transaction tracking and registry-backed PSP custody records.
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-04 | ✗→✓ | ▲ Improved | 128% | 0% |
| case-05 | ✗→✓ | ▲ Improved | 42% | 0% |
| case-06 | ✗→✓ | ▲ Improved | 71% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 51% | 0% |
| case-08 | ✗→✓ | ▲ Improved | 43% | 0% |
Mai helps buyers and merchants complete shopping matchmaking through an AI agent. It keeps deterministic marketplace state in scripts/mai.py while the host model handles natural language, negotiation, summaries, and risk explanations.
Mai can run local-only or registry-backed. Use local-only for one agent's private catalog. Use registry-backed discovery when buyers and merchants are on different machines or agent profiles.
message add before forming or updating an order.Use the CLI helper for deterministic state:
bashpython3 scripts/mai.py merchant create --id seller-a --name "West Lake Tea" --city Hangzhou --contact "wechat:westlake" --tags "tea,gift" python3 scripts/mai.py product add --merchant seller-a --sku tea-a --title "Longjing Gift Box" --price 88 --stock 5 --category tea --tags "longjing,gift" python3 scripts/mai.py search products --query "longjing tea" --format json python3 scripts/mai.py compare --skus tea-a,tea-b --format json python3 scripts/mai.py order create --buyer alice --merchant seller-a --sku tea-a --quantity 2 --offer-price 86
Default data path: ~/.local/share/mai/mai.json. Use --data /path/to/mai.json for a project-local or test database.
Install the published OpenClaw pair:
bashclawhub --workdir ~/.openclaw/workspace --dir skills install mai openclaw plugins install clawhub:mai-plugin
mai is the skill. mai-plugin is an optional lightweight OpenClaw native bridge for tools and /mai command support.
Local checkout install:
bashcd /Users/jianghaidong/coding/mai bash scripts/install.sh --both
Install only one ecosystem:
bashbash scripts/install.sh --openclaw bash scripts/install.sh --hermes
The installer creates symlinks:
~/.openclaw/workspace/skills/mai~/.hermes/skills/commerce/maiAfter installation, restart the host agent if it does not refresh skills automatically. Hermes can preload Mai with hermes -s mai.
Run a registry marketplace:
bashpython3 scripts/mai_registry.py issue-key --data ./mai-registry.json --token admin-token --role admin --subject ops-admin python3 scripts/mai_registry.py issue-key --data ./mai-registry.json --token seller-token --role merchant --subject seller-a --merchant-id seller-a python3 scripts/mai_registry.py issue-key --data ./mai-registry.json --token buyer-token --role buyer --subject alice --buyer-id alice python3 scripts/mai_registry.py serve --data ./mai-registry.json --host 127.0.0.1 --port 8765 --rate-limit-per-minute 60
Merchant agents publish local supply:
bashpython3 scripts/mai.py --data ./seller.json registry push --url http://127.0.0.1:8765 --api-key seller-token
Buyer agents discover supply and create demand:
bashpython3 scripts/mai.py --data ./buyer.json registry search-products --url http://127.0.0.1:8765 --query "longjing tea" --format json python3 scripts/mai.py --data ./buyer.json registry message --url http://127.0.0.1:8765 --api-key buyer-token --buyer alice --merchant seller-a --sku tea-a --text "Can this ship today?" python3 scripts/mai.py --data ./buyer.json registry order --url http://127.0.0.1:8765 --api-key buyer-token --buyer alice --merchant seller-a --sku tea-a --quantity 2 --offer-price 86 python3 scripts/mai.py --data ./buyer.json registry payment-hold --url http://127.0.0.1:8765 --api-key buyer-token --buyer alice --order ORD-0001
Merchant agents pull buyer messages and draft orders:
bashpython3 scripts/mai.py --data ./seller.json registry pull --url http://127.0.0.1:8765 --api-key seller-token --merchant seller-a
Read references/registry-api.md before changing registry integrations.
pending_review; do not show them in search until an admin approves them.registry payment-hold only as PSP-backed custody tracking. The bundled demo provider is not real money movement.registry payment-release and registry payment-refund.python3 scripts/mai.py merchant create --id ID --name NAME --city CITY --contact CONTACT --tags "A,B"
python3 scripts/mai.py product add --merchant ID --sku SKU --title TITLE --price N --stock N
python3 scripts/mai.py product stock --sku SKU --merchant ID --adjust N --reason "restock or correction"
python3 scripts/mai.py message add --buyer BUYER --merchant ID --sku SKU --sender merchant --text "..."
python3 scripts/mai.py order quote ... python3 scripts/mai.py order update --order ORD-0001 --status confirmed --actor merchant
python3 scripts/mai.py search merchants --query "tea hangzhou" --format json
python3 scripts/mai.py search products --query "longjing gift" --max-price 100 --format json
python3 scripts/mai.py compare --skus sku-a,sku-b --format json
python3 scripts/mai.py review list --merchant ID --format json
python3 scripts/mai.py message add --buyer BUYER --merchant ID --sku SKU --text "..."
python3 scripts/mai.py order create --buyer BUYER --merchant ID --sku SKU --quantity N
Mai tracks transactions without custody:
draft -> quoted -> confirmed -> payment_pending -> paid_external -> fulfilled -> completed
Disputes can move through:
disputed -> resolved/refunded/cancelled
Stock is reserved when an order becomes confirmed. Local-only payments are recorded as payment_url and payment_reference. Registry payments are PSP custody records; the agent must say the bundled demo provider is not real escrow or money movement.
Read references/transaction-model.md when handling non-happy-path order, refund, dispute, or payment questions. Read references/data-schema.md when integrating Mai with a future hosted marketplace or sync service.
For product discovery, answer with:
For merchant operations, answer with:
For order updates, answer with:
Before claiming the package is ready:
python3 scripts/mai.py --helppython3 scripts/mai_registry.py --helpbash scripts/install.sh --both --dry-runpython3 -m unittest discover -s testsbash scripts/verify.shSKILL.md has no scaffold placeholders.README.md, package.json, clawhub.json, plugins/mai-plugin/openclaw.plugin.json, and agents/openai.yaml use the mai and mai-plugin names consistently.| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | fail→fail | 16,170 | 14,009 | -13% | 1 | 1 | 0% | 2,737 | 4,824 | +76% | 0 | 0 | — |
case-02 | fail→fail | 10,396 | 5,107 | -51% | 1 | 1 | 0% | 1,876 | 2,508 | +34% | 0 | 0 | — |
case-03 | fail→fail | 11,041 | 5,285 | -52% | 1 | 1 | 0% | 1,971 | 2,493 | +26% | 0 | 0 | — |
case-04 | fail→pass | 6,197 | 3,387 | -45% | 1 | 1 | 0% | 1,282 | 2,918 | +128% | 0 | 0 | — |
case-05 | fail→pass | 9,025 | 2,424 | -73% | 1 | 1 | 0% | 1,911 | 2,717 | +42% | 0 | 0 | — |
case-06 | fail→pass | 7,721 | 3,780 | -51% | 1 | 1 | 0% | 1,711 | 2,919 | +71% | 0 | 0 | — |
case-07 | fail→pass | 9,931 | 3,810 | -62% | 1 | 1 | 0% | 1,946 | 2,947 | +51% | 0 | 0 | — |
case-08 | fail→pass | 13,052 | 2,403 | -82% | 1 | 1 | 0% | 1,892 | 2,698 | +43% | 0 | 0 | — |
case-09 | fail→pass | 7,807 | 1,922 | -75% | 1 | 1 | 0% | 1,606 | 2,588 | +61% | 0 | 0 | — |
case-10 | fail→pass | 12,945 | 2,814 | -78% | 1 | 1 | 0% | 2,454 | 2,744 | +12% | 0 | 0 | — |
case-11 | fail→pass | 16,553 | 2,201 | -87% | 1 | 1 | 0% | 3,271 | 2,722 | -17% | 0 | 0 | — |
case-12 | fail→pass | 13,538 | 2,416 | -82% | 1 | 1 | 0% | 2,299 | 2,749 | +20% | 0 | 0 | — |
case-13 | fail→pass | 11,853 | 3,190 | -73% | 1 | 1 | 0% | 1,933 | 2,695 | +39% | 0 | 0 | — |
case-14 | fail→pass | 7,148 | 1,951 | -73% | 1 | 1 | 0% | 1,205 | 2,528 | +110% | 0 | 0 | — |
case-15 | fail→pass | 10,152 | 3,411 | -66% | 1 | 1 | 0% | 1,923 | 2,808 | +46% | 0 | 0 | — |
case-16 | pass→pass | 12,370 | 3,016 | -76% | 1 | 1 | 0% | 1,969 | 2,690 | +37% | 0 | 0 | — |
case-17 | fail→pass | 6,643 | 2,128 | -68% | 1 | 1 | 0% | 1,220 | 2,565 | +110% | 0 | 0 | — |
case-18 | fail→fail | 5,522 | 1,926 | -65% | 1 | 1 | 0% | 839 | 2,516 | +200% | 0 | 0 | — |
case-19 | fail→pass | 3,986 | 1,763 | -56% | 1 | 1 | 0% | 763 | 2,496 | +227% | 0 | 0 | — |
case-20 | fail→fail | 7,968 | 6,955 | -13% | 1 | 1 | 0% | 1,288 | 3,250 | +152% | 0 | 0 | — |
case-21 | fail→fail | 11,535 | 13,811 | +20% | 1 | 1 | 0% | 2,368 | 4,957 | +109% | 0 | 0 | — |
case-22 | fail→fail | 14,193 | 12,322 | -13% | 1 | 1 | 0% | 3,236 | 5,000 | +55% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted, and 20 counted toward the lift figure. The other 2 produced results that are not comparable between the two arms, so they are excluded from the headline rather than averaged into it. The headline lift of +64 percentage points is the difference between those two pass rates over the 20 comparable cases. 2 cases got worse with the skill loaded, and they are included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.