Prompt
Our current recommendation engine keeps surfacing out-of-stock items
Latest observation
Understood. That usually means the recommender is optimizing for relevance without a hard availability filter.
Quick fixes:
-
Filter out-of-stock items at serving time
Apply a hard constraint before ranking or display. -
Use real-time inventory in the feature set
If stock changes frequently, ensure recommendations use the latest stock signal, not a stale batch snapshot. -
Add stock status as a ranking feature or penalty
Down-rank low-stock or unavailable items instead of only filtering. -
Separate candidate generation from eligibility
Generate broadly, then remove items that are unavailable before final ranking. -
Monitor freshness and cache TTLs
If inventory is cached too long, recommendations will drift out of sync. -
Add guardrail metrics
Track:- % of recommended items out of stock
- click-through on in-stock vs out-of-stock
- conversion loss due to stock issues
If you want, I can help you design a simple architecture for inventory-aware recommendations or draft the exact ranking/filtering logic.