🫐 CACIS

Warith Harchaoui

CACIS – geometry of regret for classification

Putting errors into geometry

In many industrial systems, a classifier is not just a “predictor”: it is a decision module. Its outputs trigger irreversible actions with asymmetric economic consequences. In fraud detection, missing a €50,000 fraud is fundamentally different from missing a €10 one.

Yet, models are still often trained with cross-entropy, which lives in a “flat” geometry: all errors look alike, and labels are treated as equidistant symbols. Thresholds, reweighting, and post-hoc heuristics are then used to compensate. But these fixes do not change how the model learns — they only change the final decision rule.

CACIS (Cost-Aware Classification with Informative Selection) proposes a different approach: injecting the cost of errors directly into the geometry of the output distribution. The goal is no longer just to be probabilistically correct, but to be decision-aligned.

Three ways to handle costs

🧊 Flat
one error = one error
Cross-entropy Excellent for probability estimation, but blind to the economic value of errors.
🎚️ Patch
after the fact
Thresholds / reweighting Improves the decision policy, but leaves learning unchanged: representations remain “average”.
📏 Geometric
cost becomes distance
CACIS Regret becomes a transport cost on the probability simplex: learning focuses on high-impact errors.

How does it work?

CACIS is built on a simple idea: if errors do not have the same severity, then moving probability mass from one label to another should not have the same “price”.

1️⃣ Regret is the currency we lose
We specify a cost matrix \(\mathbf{C}\) (often instance-dependent: amount, context, segment). It encodes how costly it is to take action \(j\) when the true outcome is \(i\).

2️⃣ Optimal Transport (OT): the geometry
This regret is treated as a ground cost between labels, and an entropically-regularized OT divergence induces a geometry of caution on the probability simplex.

3️⃣ Informative Selection: a softmax with relief
Instead of the standard softmax (KL geometry), CACIS produces an “informative” distribution \(q(\mathbf{z})\) compatible with costs: gradients focus on errors that truly matter. This distribution is computed stably on the simplex using a Frank–Wolfe inner loop.

Why it matters in industry

CACIS is designed for settings where:

The result is not an “average” model optimized for the dominant case, but a representation that internalizes a geometry of precaution in high-stakes regions.

Want to explore?

If you are working on a system where error is not a scalar but a cost, and where learning must be aligned with value, let’s talk. CACIS is not a threshold trick — it is a loss that reshapes the landscape.

CACIS
Pitch (Guy Kawasaki style)

⚠️ Problem / Opportunity

  • In production, not all errors are equal — some are extremely costly.
  • Cross-entropy is decision-agnostic and learns in a flat geometry.
  • Post-hoc fixes do not change what the model learns.

💎 Value proposition

  • Align training with business value by minimizing expected regret.
  • Internalize a geometry of caution for high-stakes cases.
  • Preserve probabilistic properties (calibration) while improving decisions.

🧪 Secret sauce

  • A Fenchel–Young loss induced by entropic Optimal Transport.
  • Regret \(\mathbf{C}\) becomes the ground cost that warps the simplex geometry.
  • Stable computation of informative distributions via a Frank–Wolfe inner loop.

💰 Business model

  • Workshops to formalize regret matrices (finance / product / data).
  • PoCs benchmarking regret vs standard metrics (temporal protocols).
  • Integration: training, regret monitoring, shadow windows, cost audits.

📣 Marketing

  • Storytelling: “Putting errors into geometry”.
  • Demos: same model, same data, different loss → different regret.
  • Posts: “cross-entropy is correct… but not profitable”.

🦅 Competition

  • Threshold tuning and post-hoc heuristics.
  • Manual cost-sensitive weighting (unstable, poorly calibrated).
  • Unrolled OT losses (expensive, numerically fragile).

⭐️ Let’s build it together

🇫🇷
⭐️ Contact