Skip to main content

// decision log

Every row a reason. Every move reversible.

The decision log records every catalog change Magistry makes, with its trigger, its evidence and who applied it. In the last 30 days (measured 17 Oct 2026) that was 1,785 catalog writes applied to Shopify. Ad network changes and Brain actions are recorded the same way. Anatomy below.

Live A trigger on every row Catalog changes reversible Approvals recorded
catalog changes · example
#84193  DISCOUNT_TEST  SKU-LIN-228 (-15%)
        ACTIVE → ON_DISCOUNT       ✓ APPLIED

#84194  DRAFT          SKU-CER-019
        ON_DISCOUNT → DRAFTED      ✓ APPLIED

#84195  OPTIMIZE_LOSER SKU-WOO-441
        ACTIVE → OPTIMIZING        ✓ APPLIED

#84196  REVIVE_SEASONAL SKU-LIN-007
        SEASONAL_VAULT → PUBLISHED ⏸ WAITING
        trigger: SEASONAL_REVIVE
        reason: kill switch on since 09:14

cycle 2026-05-25T09:00Z

// anatomy

Read a row, understand the day.

Nine fields, the same on every row. The example below is a discount test for a single product, with the trigger, the evidence and the way back in one row.
catalog change · row #84193, example
row_id            : 84193
product_id        : p_88421
sku               : SKU-LIN-228-SND-L

from_state        : ACTIVE
to_state          : ON_DISCOUNT
trigger           : OPTIMIZE_CYCLE_FAILED

evidence          : {
  action            : discount_test
  performance_tier  : LOSER
  optimize_attempts : 1
  cost_tier         : A    (cost verified)
  margin_pct        : 41
  reasoning         : "loser, optimised once
                       already, margin OK →
                       last-chance discount"
}

revert            : restore price to 89.00;
                      stamps reverted_at / reverted_by

applied_to_shopify: true
applied_at        : 2026-05-25T08:02:14Z
approved_by       : operator, with biometric

status            : APPLIED
audit_chain       : signal → plan → approve → execute → log
↶ revert availablekept on record

product_id

uuid

The product the row pertains to. A variant id is added when the change is per variant.

p_88421

from_state

lifecycle_state

Where the product was before the change.

ACTIVE

to_state

lifecycle_state

Where it lands. A move outside the allowed lifecycle transitions is refused.

ON_DISCOUNT

trigger

Trigger enum

Why the change was proposed. One of a fixed list, never freeform text.

OPTIMIZE_CYCLE_FAILED

evidence

json

The move and the numbers behind it: performance tier, margin, cost tier, complaint signal, earlier attempts and the written reasoning.

{action: discount_test, cost_tier: A}

applied_to_shopify

bool

Whether the change reached Shopify. A call that changed nothing is not counted as a write.

true

applied_at

timestamptz

When the executor wrote the change.

2026-05-25T08:02Z

approved_by

user

Who approved it, and whether they confirmed with Face ID or fingerprint in the mobile app.

operator, with biometric

reverted_at

timestamptz

When the change was reverted, and by whom. The original row stays on record.

null

// triggers

Why a row exists.

Every decision row carries a trigger: the reason the engine emitted the action. Triggers are enumerated; no row gets a freeform 'because we felt like it'.

AUDIT_CLASSIFICATION

Each pass classifies a product by performance tier, margin and complaint signal, and the result proposes a move.

OPTIMIZE_CYCLE_FAILED

A product rewritten once without lift goes to a discount test when its margin allows, and is drafted when it does not.

DISCOUNT_CYCLE_FAILED

A product still losing after its discount test is drafted.

COMPETITOR_REPRICE

A tracked competitor sells the same product for less. A discount test is proposed above the store's margin floor.

PROMOTION_APPLY

A promotion started and set the product's sale price. When it ends, the price is put back and recorded as PROMOTION_REVERT.

SHOPIFY_STATE_RECONCILE

Someone changed the product in Shopify directly. The change is recorded so the history matches the store.

MANUAL_OVERRIDE

A person made the change. Logged the same way as an agent's move, in the same shape.

// evidence

The evidence behind the move.

The evidence field changes shape per action type. For a catalog lifecycle move it holds the move, the numbers that chose it and the reasoning in a sentence.

// the move

  • actionthe lifecycle move, from a fixed list
  • current_statethe product's state when it was read

// the product

  • performance_tierwinner, mid or loser on this store
  • margin_pctmargin at the current price
  • cost_tierhow well the product cost is known (A to C)

// the history

  • optimize_attemptsearlier copy rewrites for this product
  • complaint_signalcomplaints from the helpdesk about it

// the reasoning

  • reasoningthe engine's reasons, in order
evidence · example
{
  "action":            "discount_test",
  "current_state":     "ACTIVE",
  "performance_tier":  "LOSER",
  "margin_pct":        41,
  "cost_tier":         "A",
  "optimize_attempts": 1,
  "complaint_signal":  null,
  "reasoning": [
    "loser, optimised once already,
     margin OK → last-chance discount"
  ]
}

// reversal model

Revert writes the old value back.

Reverting a change writes the previous value back to Shopify and stamps the original row with when it was reverted and by whom. A revert takes the same store lock and respects the same kill switch as the original write.
// original
row #84193
  action      : discount_test
  delta       : -15%
  before      : 89.00
  status      : APPLIED
  applied_at  : 2026-05-25T08:02Z
// after revert (same row)
row #84193
  action      : discount_test
  price       : restored to 89.00
  reverted_at : 2026-05-25T11:32Z
  reverted_by : operator (jane@store.com)

the original row stays on record

// why it is kept

A history you can read back.

A change has one owner.

One owner per change, and every catalog change can be reverted. While an agent holds a field, no other agent can write over it.

A revert keeps the original.

Revert a change and the original row stays, stamped with when it was reverted and by whom.

A kept history makes audits cheap.

When finance asks 'what did the agent do on the 14th', the answer is a SELECT. Not a reconstruction.

// decision log

A history you can defend.

Every catalog change is a row with its trigger and its evidence, and each one can be reverted.

One owner per change · Catalog changes reversible · Built to be read