Manual upsells are a second full-time job
Every WooCommerce product has an "Upsells" field — a list of product IDs that show as "you may also like" on the product page. Populating it well across a 400-SKU catalog requires deep knowledge of each product, each price bracket, and each customer's mental model. Most stores either leave it empty (losing the cross-sell) or fill it with whatever's in the same category (random, not strategic).
What most people do instead
A better way: AI, grounded in the actual product
Run ai suggest upsell -product_id=247. The command gives AI the product's real name, real price, and real category list. AI returns 1–2 upsell ideas with a one-line reason each. You review, pick the ones that match SKUs you actually stock, and drop those into WooCommerce's upsell field.
AI doesn't know your actual stock. The output may suggest products that sound right but aren't in your catalog. This is intentional — the goal is to inspire upsells, not auto-assign them. Review each suggestion against your real inventory before updating the WooCommerce upsell field. For auto-assignment, wrap it in a macro with a product-lookup step.
How it works
WooCommerce is required. The handler validates -product_id is a real product, extracts name, price, currency, and category list via WooCommerce's own methods. It builds a prompt: "You are an AI product assistant for a WooCommerce store. Suggest 1–2 realistic and valuable upsell product ideas. Include a short reason. Product: {name} | Price: {currency} {price} | Categories: {list}." AI responds in a structured Suggested upsell: <name> – <reason> format.
| Parameter | Value |
|---|---|
-product_id(required) | WooCommerce product ID — must exist and be a valid product |
| Context sent to AI | Product name, price, currency, category list |
| Output | 1–2 upsell suggestions with one-line reasons, in Suggested upsell: <name> – <reason> format |
| Requires | WooCommerce — returns error when plugin is deactivated |
| Can be used in |
Real example
You launched 20 new oil products last quarter. None have upsell fields populated. Instead of spending an afternoon manually pairing them, you run filter product -category=oils -created_after=2026-01-01 into a macro that iterates each with ai suggest upsell, captures the output, and emails the list to yourself as a CSV.
You review the 40 suggestions over coffee on Monday. 24 of them map cleanly to products you already carry (balsamics, linen towels, olive-wood boards). Those go into WooCommerce's upsell fields. The other 16 are SKUs AI invented — you ignore them, or use them as a "should we stock this?" brainstorm for the product team.
Goes further with TrueCommander
update post meta writes the product ID into WooCommerce's _upsell_ids meta.