Access & Privacy settings
Navigation: WordPress Admin → WooCommerce → AI Assistant → Settings → Access & Privacy
Rate limits, message size, and retention. Analytics retention is configured on the Analytics tab and only deletes this plugin’s analytics tables, never WooCommerce orders.
Maximum message length
What it does Maximum characters in one shopper message.
Default value 1000
Available options 50–4000
Recommended configuration 1000
When to use it Lower on shared hosting if abuse is a concern.
Effect on the frontend Longer paste is rejected by REST validation.
Dependencies Also sent to the widget as limits.max_message_length.
Important notes Does not change model max output tokens.
Example 1000 for retail chat.
Messages per window, per visitor
What it does How many chat turns a visitor may send per rate-limit window.
Default value 20
Available options 1–500
Recommended configuration 20
When to use it Lower if you see token abuse.
Effect on the frontend HTTP 429 with rate-limit headers when exceeded.
Dependencies Rate limiter keyed by actor (logged-in user or guest identity). Filter aiwsa_rate_limits.
Important notes Separate from cart mutation and confirm limits.
Example 20 per 5 minutes.
Cart mutations per window
What it does Cap on cart-changing REST calls.
Default value 10
Available options 1–200
Recommended configuration 10
When to use it Anti-automation.
Effect on the frontend Add/update/remove may be refused until the window resets.
Dependencies Cart REST routes.
Important notes Does not affect the WooCommerce cart page.
Example 10
Confirmations per window
What it does Cap on confirmation redemptions (staged add-to-cart, etc.).
Default value 20
Available options 1–200
Recommended configuration 20
When to use it Abuse control.
Effect on the frontend Confirm button may fail with 429.
Dependencies Confirmation broker.
Important notes Confirm body cannot change product or quantity.
Example 20
Rate limit window (seconds)
What it does Length of the sliding window for the limits above.
Default value 300 (5 minutes)
Available options 30–3600
Recommended configuration 300
When to use it Shorter window = stricter bursts.
Effect on the frontend How quickly limits reset.
Dependencies None.
Important notes Widget config includes window_seconds and messages_per_window.
Example 300
Conversation activity TTL (seconds)
What it does Inactivity before a conversation expires.
Default value 86400 (1 day)
Available options 300–2592000 (5 minutes–30 days). Filter aiwsa_conversation_ttl (still clamped).
Recommended configuration 1 day.
When to use it Shorter for privacy-sensitive shops.
Effect on the frontend Expired chats start a new session.
Dependencies Daily cleanup cron aiwsa_daily_cleanup.
Important notes Not the same as retention (deletion of stored rows).
Example 86400
Conversation retention (days)
What it does How long conversation rows are kept before purge.
Default value 90
Available options 7–730
Recommended configuration 90 or your policy.
When to use it GDPR-style minimization.
Effect on the frontend None immediately. Old chats disappear from storage.
Dependencies Daily cleanup. Filter aiwsa_retention_days.
Important notes Floor 7 days.
Example 30 for stricter shops.
Audit retention (days)
What it does How long audit log rows are kept.
Default value 365
Available options 365–730. Floor is 365 (cannot go below one year in code).
Recommended configuration 365
When to use it Compliance artifact.
Effect on the frontend None.
Dependencies Audit repository.
Important notes Raising is allowed; lowering below 365 is not.
Example 365