Skip to content

Auto Preferences Manager

Feature Launch Date: December 2025 For: Business Owners & Administrators

Overview

The Auto Preferences Manager automatically identifies products that customers consistently substitute out of their orders and sets those products to "NO" in their preferences. This proactive approach helps reduce future substitutions by preventing the system from offering items that customers have repeatedly rejected.

By analyzing customer behavior patterns across multiple weeks, the system can intelligently adjust preferences to better match what customers actually want, improving customer satisfaction and reducing operational complexity.

How It Works

The Smart Algorithm

The system analyzes every customer's order history and substitution patterns. A product is automatically set to "NO" in a customer's preferences when ALL of the following criteria are met:

  • Offered at least 2 times: The product was assigned to the customer in at least 2 different weeks
  • Substituted out 100% of the time: The customer replaced it with something else every single time it was offered
  • Never chosen as a substitution: The customer has never actively selected this product when swapping out a different item
  • Never purchased standalone: The customer has never added this product as an extra item to their order

This strict criteria ensures that only products the customer clearly dislikes are removed from their preferences, avoiding false positives.

Processing Limits & Customer Notifications

The system processes up to 3 products per customer per run to avoid overwhelming customers with too many preference changes at once. When preferences are updated:

  • Changes are logged in the customer's account activity
  • A notification is created that appears on the customer's next login
  • The notification explains which products were changed and why
  • Customers can review and adjust these preferences if desired

Using the Auto Preferences Manager

Accessing the Tool

Navigate to the Auto Preferences Manager in your admin panel at /kiv/auto-preferences.php or through your admin menu.

Preview Mode (Current Week)

When viewing the current week, the system operates in Preview Mode:

  1. Select Week: The current week is selected by default
  2. Optional Customer Filter: Enter a specific customer ID to test with just one customer
  3. View Preview: Click "View" to see what would happen if you run the process
  4. Review Results: The preview shows:
  5. Which customers would be affected
  6. Which products would be set to "NO" for each customer
  7. Statistics for each product (times offered, subbed out, chosen, purchased standalone)
  8. Summary counts of customers and preferences affected
  9. Run Process: If satisfied with the preview, click "Run Process for Current Week" to execute

Important: No changes are made until you click the "Run Process" button. Preview mode is completely safe to use as many times as needed.

Historical View (Previous Weeks)

When viewing previous weeks, the system shows a Historical View of notifications that were generated:

  • Customer names with links to their profiles
  • Products that were set to "NO" for each customer
  • When the notification was created
  • When the customer viewed the notification (shown_at)
  • When the customer dismissed the notification (dismissed_at)

This historical data helps you track how the feature has been working over time and verify that customers are seeing the notifications.

Best Practices

When to Run the Process

  • Before starting a new week: Run after customers have finalized their current week orders
  • After major order adjustments: If many customers made substitutions, running the process can capture those patterns
  • Weekly routine: Consider making this part of your weekly order preparation workflow
  • Don't run too frequently: Once per week is typically sufficient; running more often won't provide much benefit

Testing with Individual Customers

Before running the process for all customers, you can test with individual customers:

  1. Enter a customer ID in the "Customer ID (optional)" field
  2. Review the preview to see what would change for that customer
  3. Run the process for just that customer
  4. Check the customer's account to verify the changes
  5. Review the notification they'll see on next login

This is especially useful when you're first learning how the feature works or want to verify behavior for a specific case.

Monitoring Results

  • Check summary statistics: The summary shows how many customers and preferences were affected
  • Review historical data: Look at previous weeks to see patterns over time
  • Monitor customer feedback: Pay attention to whether customers notice and appreciate the automatic adjustments
  • Adjust criteria if needed: If you find the system is too aggressive or not aggressive enough, contact your system administrator

Understanding the Preview Results

Customer Section

Each customer in the preview shows:

  • Customer name: Linked to their full profile for easy reference
  • Products table: All products that qualify for auto-preference adjustment

Product Statistics

For each qualifying product, you'll see:

  • Product name: The product classification name
  • Times Offered: How many weeks this product was assigned to the customer
  • Times Subbed Out: How many times the customer replaced it (should be 100% for qualifying products)
  • Times Chosen: How many times the customer actively selected this as a substitution (should be 0)
  • Standalone Purchases: How many times the customer added it as an extra item (should be 0)
  • Action: "Will set to NO" label indicating the intended change

Reading the Summary

The summary at the bottom shows:

  • Customers affected: Total number of customers who will have at least one preference updated
  • Total preferences to set: Total number of product preferences that will be changed across all customers

Customer Experience

What Customers See

When preferences are automatically updated, customers will:

  1. Receive a notification on their next login to the customer portal
  2. See a list of products that were set to "NO" in their preferences
  3. Understand why the change was made (they consistently substituted out these items)
  4. Have the ability to change these preferences back if they want
  5. Experience fewer unwanted items in future orders

Customer Notification Content

The popup notification customers see includes:

  • Friendly explanation of what happened
  • List of products that were adjusted
  • Reason for the adjustment (pattern of substitutions)
  • Link to their preferences page to make changes if needed
  • Option to dismiss the notification

Common Scenarios

Scenario: Customer Consistently Dislikes a Product

Situation: Customer "Jane Smith" has been offered "Brussels Sprouts" in 3 different weeks and has substituted them out all 3 times.

What Happens: - System detects: Offered 3 times, subbed out 3 times (100%), never chosen, never purchased - All criteria met > Brussels Sprouts set to "NO" in Jane's preferences - Notification created for Jane's next login - Future weeks: Brussels Sprouts won't be assigned to Jane unless she changes her preference back

Result: Jane no longer has to substitute out Brussels Sprouts every week, improving her experience.

Scenario: Customer Sometimes Dislikes a Product

Situation: Customer "Bob Johnson" has been offered "Kale" 4 times and substituted it out 3 times, but kept it once.

What Happens: - System detects: Offered 4 times, subbed out 3 times (75%), never chosen, never purchased - Criteria NOT met (not 100% substitution rate) > No change made - Kale continues to be offered to Bob

Result: System correctly identifies that Bob sometimes wants Kale, so it remains in rotation.

Scenario: Customer Actively Chooses a Product

Situation: Customer "Mary Wilson" has been offered "Carrots" 2 times and substituted them out both times, but has selected Carrots as a substitution for other items 2 different weeks.

What Happens: - System detects: Offered 2 times, subbed out 2 times (100%), chosen 2 times, never purchased standalone - Criteria NOT met (actively chose it as substitution) > No change made - Carrots remain available as a substitution option

Result: System recognizes Mary does want Carrots sometimes (when she chooses them), just not when they're automatically assigned.

Scenario: Customer Purchases Product Standalone

Situation: Customer "Tom Davis" has been offered "Organic Honey" 2 times and substituted it out both times, but has added Organic Honey as a standalone purchase once.

What Happens: - System detects: Offered 2 times, subbed out 2 times (100%), never chosen, purchased standalone 1 time - Criteria NOT met (made standalone purchase) > No change made - Organic Honey remains in Tom's available products

Result: System correctly identifies that Tom does want the product (he bought it separately), so it stays available.

Troubleshooting

Preview Shows No Results

Possible Reasons: - No customers made substitutions in the current week - Customers who made substitutions don't have products that meet all 4 criteria - Products that were subbed out haven't been offered enough times (need minimum 2 weeks) - You're viewing a historical week with no data

Solution: This is normal and means no automatic adjustments are needed this week.

Expected Customer Not Showing Up

Possible Reasons: - Customer hasn't substituted the same product multiple times - Customer chose the product as a substitution at some point - Customer purchased the product standalone before - Product was only offered once (need minimum 2 times)

Solution: Review the customer's order history to understand their substitution patterns. The strict criteria are intentional to avoid false positives.

Too Many Preferences Being Set

Possible Reasons: - Many customers have clear dislike patterns (this is actually good data) - Product offerings haven't been well-matched to customer preferences - New customers still learning what they like

Solution: This is typically a good thing - the system is helping align offerings with preferences. Monitor customer feedback to ensure the adjustments are helpful.

Customer Complaints About Auto-Adjusted Preferences

Possible Reasons: - Customer didn't see or understand the notification - Customer's preferences changed over time - Rare edge case where the algorithm made an incorrect determination

Solution: Remind customers they can always change preferences back in their account settings. The notification includes a direct link to preferences.

Technical Details

Data Sources

The system analyzes data from: - cust_order: Customer orders and week associations - cust_order_contents: Order line items, substitutions (cust_menu_id vs menu_id), and standalone purchases (type 2) - menu: Product details and classification mappings - product_classification: Product category names - custy_likes: Customer preference storage (0 = NO, 1 = MAYBE, 2 = YES)

Database Changes

When the process runs, it: - Updates or creates records in custy_likes table - Sets pref = 0 (NO) for qualifying products - Sets system_set timestamp to track when the system made the change - Creates records in custy_preference_notifications table - Logs changes in customer activity log

Processing Constraints

  • Maximum 3 products per customer: Prevents overwhelming customers with too many changes at once
  • Only current week processing: Can only run the process for the active week; historical views are read-only
  • No duplicate notifications: System won't create multiple notifications for the same week/customer combination

FAQ

Q: Can I undo changes made by the auto-preferences process? A: Yes, preferences can be manually changed in each customer's account. The system won't override manual changes.

Q: What if a customer's tastes change over time? A: Customers can update their preferences anytime. If they start accepting a product they previously disliked, it won't be automatically set to NO again (the "never chosen" and "never purchased" criteria will fail).

Q: How often should I run this process? A: Once per week is typical, usually before starting a new order cycle. Running more frequently won't provide much additional benefit.

Q: Can I run this for just one customer? A: Yes, enter a customer ID in the optional field to preview and run for just that customer. Great for testing!

Q: What happens if I run the process multiple times in the same week? A: The system will re-analyze patterns. Products already set to NO will be skipped. New qualifying products (if any) will be processed.

Q: Do customers get an email notification? A: Currently, customers see a popup notification on their next login. Email notifications can be added if desired.

Q: Can customers opt out of automatic preference adjustments? A: Not currently, but they can always change preferences back manually. The notification makes them aware of changes.

Q: Why is there a limit of 3 products per customer? A: To avoid overwhelming customers with too many changes at once. If a customer has more than 3 qualifying products, they'll be processed in future runs.

Q: What if a product is set to NO by mistake? A: Customers can change it back in their preferences. The strict criteria (100% substitution, never chosen, never purchased) make mistakes very rare.

Q: Can I see why a specific product was set to NO? A: Yes, check the customer's activity log. Each auto-preference change includes a detailed reason with statistics.

Support

If you need assistance with this feature: - Review this documentation - Test with a single customer ID first - Check historical data to see previous runs - Review customer activity logs for specific cases - Contact your system administrator


Last Updated: December 17, 2025