# How serving behaves

> Fail-closed guarantees, the 24-hour freshness window, and automatic stock repair for live kits.

Serving is fail-closed end to end: if a surface isn't published, a term isn't live, or
anything errors, shoppers get your native experience — never a degraded or fabricated
one.

## What makes a kit serve

A live kit serves on one of two triggers (see [Agentic Kits](./agentic-kits.md) for setup):

- a **search term** the shopper typed, matched against your live terms; or
- a **category page** whose URL matches a pattern you configured (for example
  `https://www.apotea.se/halsont*`).

Either way the same fail-closed gate applies: a typed search always takes precedence over a
category match, and a page that matches no live trigger serves your native experience with
no band.

## Verified before live

Your assistant serves shoppers only the configuration that has **passed verification**.
Each time we learn your store, we run the proposed setup through a real shopping journey
and judge it; only a passing run is promoted to the live serving layer. Until a store has
a passing result, shoppers get the safe native experience and your dashboard shows the
store as still learning — never an unverified setup quietly going live.

If a re-learn produces a setup that does **not** pass, the previous passing configuration
keeps serving (or, for a brand-new store with nothing verified yet, the assistant stays
in the safe not-ready state). A failed run can never replace or downgrade a configuration
that already passed.

Every version that passes is kept immutably as its own promoted bundle, and serving
always points at the latest passing one. Because earlier good versions are never
overwritten, reverting to a previous passing configuration is instant and exact.

## Freshness

Served kits come from a fast serving layer, and every product in a live kit is
re-verified against your live store within 24 hours; a kit is never served past that
freshness window.

## Stock repair

When a product goes out of stock, the kit is automatically repaired — fitting replacement
products are selected from your catalog while the kit's copy stays untouched and is
safety-re-checked — or pulled from serving if no fit exists, with the change surfaced in
your Review queue.

## Dashboard actions

Dashboard actions (go live, pause, approve) take effect immediately.
