| 开发者 | devhasib |
|---|---|
| 更新时间 | 2026年8月12日 10:02 |
| PHP版本: | 8.1 及以上 |
| WordPress版本: | 7.0 |
| 版权: | GPL-2.0-or-later |
| 版权网址: | 版权信息 |
woocommerce_related_products filter — no template files modified, zero theme conflict risk.
🛒 Cart Recommendations & Mini-Cart Cross-Sells
Display smart product suggestions on the cart page and inside the mini-cart sidebar — exactly when purchase intent is highest. Products are scored in real time based on current cart contents and automatically exclude items already in the cart.
🎉 Post-Purchase Recommendations
Show a "Complete your purchase" widget on the WooCommerce order-received (thank-you) page. Seeds recommendations from the highest-value item in the completed order and automatically excludes already-purchased products. Catches customers at peak satisfaction — their most likely moment to buy again.
👁️ Recently Viewed Products
Session-based browsing history widget — fully GDPR-compliant with zero database queries. Uses browser sessionStorage (not cookies), data is never sent to the server, and clears automatically when the tab closes. Appears on product pages, the cart page, and anywhere via the [sprwoo_recently_viewed] shortcode.
⭐ Social Proof Badges
Automatically display trust signals on all recommendation cards — no manual setup needed:
sessionStorage — no cookies, no personal data stored server-side[sprwoo_recently_viewed] — Display recently viewed products anywhere.
Optional attributes:
max — Number of products to show (default: 6)columns — Grid columns (default: 4)title — Widget heading text (default: "Recently viewed")
Example: [sprwoo_recently_viewed max="4" columns="2" title="Your browsing history"].sprwoo- class names — no CSS conflictspublic/css/sprwoo-public.css from your themestorzen-ai-recommends/wp-content/plugins/storzen-ai-recommends, or install directly from the WordPress plugin screen.No. AI Product Recommendations for WooCommerce works entirely within your WordPress installation using your own WooCommerce order data. No external API, no cloud service, no subscription, and no account required — ever.
Accuracy improves directly with order volume. On stores with hundreds of orders, the co-purchase matrix produces highly relevant recommendations. On brand-new stores, the built-in taxonomy fallback uses category and tag overlap to generate useful suggestions from day one. The default hybrid mode blends both signals for the best output at every stage of store growth.
Yes. The recommendation engine works with all WooCommerce product types — simple, variable, grouped, and external. Variable products in recommendation widgets link to the product page so customers can choose their variation. The low stock urgency badge checks all available variations and shows the lowest remaining stock count.
Recently viewed products are stored exclusively in the browser's sessionStorage — a temporary, client-side mechanism that is never transmitted to the server and is automatically cleared when the browser tab closes. No personal data is written to the database. No cookies are used.
No. Recommendation scores are cached as WordPress transients with a 1-hour TTL — the AI scoring query runs at most once per hour per product, not on every page load. Social proof sales velocity data is cached for 6 hours. Frontend assets (CSS/JS) are loaded only on pages where recommendation widgets are active. The recently viewed feature triggers zero server-side queries.
AI Product Recommendations for WooCommerce uses only standard WooCommerce hooks and filters. Related products are replaced via the official woocommerce_related_products filter — no template files are modified. This makes it fully compatible with any properly built WooCommerce theme.
Use the native Gutenberg block or Elementor widget to drop recommendations anywhere without writing code. For recently viewed products specifically, use the [sprwoo_recently_viewed] shortcode.
Yes. All widget elements use prefixed .sprwoo- CSS class names to avoid conflicts. Override any style via your theme's style.css or a custom CSS plugin by targeting the .sprwoo- namespace.
Two custom tables are created on activation:
{prefix}sprwoo_copurchase — stores the co-purchase frequency matrix{prefix}sprwoo_analytics — stores impression, click, and add-to-cart events
Both tables are fully removed on plugin deletion. The analytics table auto-purges rows older than your configured data retention window.When you delete the plugin from the WordPress admin, the uninstall routine automatically drops both custom database tables, deletes all plugin options, and clears all transient cache entries. No manual database cleanup is required.
Each badge type has a configurable minimum threshold in the admin settings. For example, if the sales velocity threshold is set to 5, the "sold this month" badge only appears on products with at least 5 sales. This prevents new or low-volume products from showing misleading social proof.
The badge appears when WooCommerce stock management is enabled for a product and the remaining stock is at or below your configured threshold (default: 5). For variable products, it checks all available variations and displays the lowest stock count. Products without stock management enabled are never shown a low stock badge.
[sprwoo_on_sale] shortcode displays all products currently on sale with automatic discount-percentage badges (−30%). Powered by WooCommerce's native wc_get_product_ids_on_sale() — no custom queries. Transient-cached 2 hours, auto-busts on product save.[sprwoo_top_rated] shortcode displays highest-rated products ordered by WooCommerce average rating. Configurable minimum rating (default 4.0) and minimum review count (default 3) thresholds prevent low-data products from appearing. Cached 4 hours, busts on review approval.[sprwoo_trending] shortcode. Products scored by real sales velocity (units sold in the last 7, 14, or 30 days). Automatic bestseller fallback for new stores. Transient-cached, 2-hour TTL.[sprwoo_bestsellers] renders all-time top sellers ordered by WooCommerce total_sales. Cached 6 hours.[sprwoo_new_arrivals] renders recently published products with configurable look-back window (default 30 days). Cached 1 hour. Displays a "NEW" badge on each product card.storzen-ai-recommends, all strings wrapped and ready.