---
id: CS-001
title: "Reading a production lender's interest engine, and a latent defect caught in the read"
url: https://mxto.ai/case-studies/cs-001
product: mxto
vendor: Ontology Labs, Inc.
capability_tags: [comprehension, spec-generation, defect-discovery, offline, no-sdk]
audience_tags: [cto, architect, risk, cfo, product-owner]
client_descriptor: a South African consumer-lending platform (debt consolidation)
date: 2026-06-26
status: published (final figures; some domain-intent specifics under SME confirmation, omitted here)
metrics:
  modules: 77
  entities: 992
  associations: 1209
  enumerations: 264
  microflows: 3444
  pages: 745
  extraction_seconds: 112
  extraction_mode: mpr-direct, fully offline, no Mendix SDK
  round_trip: re-extracted with zero differences
  interest_engine_entities: 5
  interest_engine_flow_cascade: ~11 microflows
  interest_strategies: 3 (configurable)
  latent_defect: 1 (verified against the raw model; dormant until year 2100)
---

# Reading a production lender's interest engine, and a latent defect caught in the read

> mxto read a South African consumer-lending platform's entire production Mendix™ application (77 modules, ~990 entities, ~3,400 microflows, 745 pages) fully offline in 112 seconds, with no Mendix SDK, and a 100% zero-difference round-trip. It produced an auditable specification of the interest-accrual engine and, while rendering the logic legibly, surfaced a dormant leap-year defect verified against the raw model.

## 1. Situation

A South African consumer-lending platform runs its entire debt-consolidation business on a large, mature Mendix™ application (**77 modules, ~990 entities, ~3,400 microflows, 745 pages**), evolved over years. The financial heart of the product is its **interest-accrual engine**: every month, for every active loan, it re-derives interest from the account's transaction history and an effective-dated rate schedule. Logic of that importance, buried in thousands of microflows, becomes *institutional risk*: only a handful of people understand it, and no one can easily prove it still does what the business thinks it does.

The goal: **understand the interest engine well enough to maintain it safely**, and produce a durable, auditable specification of it, without a lengthy manual code-reading exercise.

## 2. What mxto did

Pointed at the application's model file, mxto **extracted the entire application in 112 seconds, fully offline, with no access to Mendix™'s own SDK.** It then re-extracted and compared: a **100% round-trip with zero differences**, establishing a trustworthy "before" picture.

From there it produced a human-readable rendering of the interest logic and an **auditable domain-rule specification** of the accrual engine: the five governing entities, the full trigger-to-posting cascade (daily scheduled event → per-account interest posting → recompute → instalment generation), the effective-dated rate-segment logic, and the interest formula, including the day-count convention and how accrued interest compounds.

It surfaced a first-order design fact a casual read would miss: **interest is computed by one of three configurable strategies**, selected by a global settings record, so "the interest calculation" is not one algorithm but three, and any change has to account for that.

## 3. The standout moment

While transcribing the leap-year day-count, mxto's rendering made the logic legible enough to notice that **the century-year rule was inverted**: years divisible by 400 were being treated as 365-day years (they are leap years, 366) and years divisible by 100-but-not-400 as 366-day years (they are not). The finding was then **verified against the raw model expression**: confirmed real, not a reading artifact.

The defect is **dormant**: no live loan's interest-year basis lands on a century year before **2100**, so it has never mispriced a single account. But it is a genuine latent correctness bug that had sat in production, unseen, for years, found in the course of simply *reading* the model, and triaged with a "log it for the next time this engine is touched" note rather than a false alarm.

## 4. Outcome & value

- **Comprehension risk retired.** A money-critical engine that lived in a few people's heads is now a written, reviewable specification: the durable asset every future interest-logic change is validated against.
- **A latent defect caught early, proportionately.** Found, verified, and correctly triaged as non-urgent: the kind of quiet correctness issue that audits and manual reviews routinely miss.
- **Speed and reach.** Whole-application understanding in minutes, offline, with no SDK licensing and no runtime, turning "we'd need weeks to safely touch this" into a same-day exercise.
- **A reusable method.** The same read-and-specify pass applies to any module of the app, and to any Mendix™ application.

## 5. Evidence & metrics

| Fact | Measure |
|------|---------|
| Application scale | 77 modules · 992 entities · 1,209 associations · 264 enumerations · 3,444 microflows · 745 pages |
| Full extraction | **112 seconds**, mpr-direct, fully offline, **no Mendix™ SDK** |
| Fidelity of the read | re-extracted with **zero differences** (verified round-trip) |
| Interest engine specified | 5 governing entities, ~11-flow cascade, **3 configurable strategies** |
| Finding | **1 verified latent defect** (leap-year century inversion), dormant until 2100 |

Extraction, fidelity, and the defect finding are final and verified. Some domain-intent specifics raised by the spec (e.g. which of the three strategies is live in production, the intended rounding convention) are under confirmation with the platform's domain experts and are deliberately omitted here.

## 6. Talk to us

How much of your most important business logic exists only in someone's head? mxto turns it into a spec, offline, in minutes, on any Mendix™ application, with the read proven by a zero-difference round-trip. Bring your own AI agent; mxto is the toolchain it drives.

- Request a demo: hello@ontologylabs.ai
- Product: https://mxto.ai
- Platform: https://ayios.ai (AYIOS, by Ontology Labs)

---

*mxto.ai is a product of Ontology Labs, Inc., powered by AYIOS. Mendix™ is a trademark of Siemens Digital Industries Software; mxto.ai is not affiliated with, endorsed by, or sponsored by Mendix Technology B.V. or Siemens AG. This case study is anonymized; all figures are measured on the client's production model.*
