SmartBrain

In-Stock-Only Recommendations: Never Sell What You Don't Have

2026-06-22 · inventory-aware recommendations, ecommerce automation, conversational commerce, product recommendations, stock managemen

What Are In-Stock-Only Recommendations?

An in-stock-only recommendation is a product suggestion that is filtered, in real time, against your live inventory before it is ever shown to a customer. If a product is out of stock — or below a safety threshold — it is excluded from the recommendation pool entirely. The customer only ever sees products you can actually ship.

This sounds obvious. In practice, most recommendation engines ignore it.

Why Most Recommendation Engines Get This Wrong

Traditional product recommendation tools are trained on historical behavior: what customers clicked, what they bought, what they viewed together. That training data is a snapshot of the past. Your inventory is a moving target in the present.

The result is a well-known ecommerce failure mode: a customer clicks a recommended product, adds it to their cart, and discovers at checkout — or worse, after payment — that the item is unavailable. According to Baymard Institute research, unexpected inventory issues at checkout are among the top reasons customers abandon and do not return.

For DM automation in particular, the problem is amplified. When a Messenger or Instagram flow recommends a product to a customer who has just expressed purchase intent, that conversation is live. The customer is ready to buy right now. Pointing them at a sold-out item does not just lose one sale — it erodes the credibility of your entire automated channel.

How Does Real-Time Inventory Filtering Work?

The architecture that makes in-stock-only recommendations reliable separates two distinct jobs:

This division of responsibility is the core principle behind SmartBrain. The server holds the business logic and the inventory truth; the AI handles language. Neither role bleeds into the other. The AI cannot hallucinate a product into existence because it never had the power to select one in the first place.

What Counts as "In Stock"? Setting Your Own Rules

Raw stock level is rarely the right filter on its own. A more robust in-stock definition typically includes:

Defining these rules clearly in your commerce engine — and enforcing them at query time rather than display time — is what separates inventory-aware recommendations from ones that merely look inventory-aware.

In-Stock Filtering vs. Popularity-Based Recommendations: A Direct Comparison

Most ecommerce platforms ship with popularity-based recommendations out of the box. Here is how the two approaches differ in practice:

The two approaches are not mutually exclusive. You can use popularity signals to rank candidates within an already-filtered, in-stock pool — combining recency of inventory truth with wisdom from historical behavior.

Concrete Example: A DM Flow Gone Right

A customer sends a message to your Instagram account: "I'm looking for a waterproof backpack under $80."

With a naive system, the automation might surface the three most popular waterproof backpacks in that price range — two of which have been out of stock for a week. The customer clicks, gets frustrated, and leaves.

With SmartBrain, the flow works differently. The moment the customer's intent is parsed, a server-side query runs against your live Shopify catalog: category = backpack, waterproof = true, price ≤ $80, stock ≥ 3 units, variant size = N/A. The system returns only products that meet every criterion. The AI then writes a short, helpful message about the top result — a product the customer can actually buy and you can actually ship.

The entire exchange takes under two seconds. The customer sees one confident recommendation, clicks, and converts. No dead ends.

Why This Matters More in Automated Channels Than on Your Website

On a product page, a customer who hits an out-of-stock item can browse alternatives themselves. In a DM conversation, there is no browsing. The customer asked a question and got an answer. If that answer is wrong, the conversation is over — and so is the sale.

This is why inventory awareness is table stakes for any commerce automation running over Messenger, Instagram DMs, WhatsApp, or SMS. The channel is direct; the expectation is that you know what you are talking about. SmartBrain enforces this by making inventory the first filter applied, not an afterthought appended at display time.

FAQ

Does in-stock filtering slow down my recommendation response time?

No, not meaningfully. A live inventory query against a properly indexed Shopify catalog typically resolves in under 100 milliseconds. The language model step that follows takes longer. Net response time to the customer is unchanged from a naive recommendation system.

What happens if every product in a category is out of stock?

The system should fall back to an adjacent category, a broader price range, or a graceful "nothing available right now" message rather than surfacing an out-of-stock product. Defining these fallback rules explicitly is part of the setup process for any inventory-aware recommendation engine.

Can I recommend pre-order products through this system?

Yes, if you configure your system to treat pre-order stock as a valid inventory state. The key is intentionality: explicitly include pre-order products as a recommendation-eligible category with their own copy rules, rather than letting them slip through an inventory filter by accident.

Does this work with multi-location inventory on Shopify?

Yes. Shopify's inventory API exposes stock levels per location. A server-side query can filter by the location relevant to the customer — either based on their shipping address or a default fulfillment center — before returning candidate products.

Is in-stock filtering the same as real-time sync?

They are related but not identical. Real-time sync keeps a local cache updated as inventory changes. In-stock filtering queries that cache (or the source directly) at the moment a recommendation is requested. You can have sync without filtering, but filtering without reliable sync produces stale results. Both are necessary for a trustworthy system.

Try SmartBrain free on your store — watch it qualify a shopper and recommend the exact in-stock product, in minutes. Free plan, instant setup, no rebuild.

Start free →