Unpacking the architecture, the logic, and the "why" behind the Factory for Verifiable Data.
CausalFoundry is built to bridge the gap between "realistic looking" data and "mathematically correct" data. Its primary goals are:
Autophagy happens when Model B is trained on the statistical output of Model A. Because most generators are "mimics," they smooth out the diversity of data, eventually causing the model to collapse into a bland average.
CausalFoundry prevents this by using Invariants as Anchors. Instead of just mimicking the shape of your data, it anchors every generated row to a Causal Graph. Even if the sample data is biased or small, the generated data is held in place by the "laws" of your business logic, preventing the divergence that leads to model collapse.
We use a three-layer enforcement system:
A high-performance Rust memory map that tracks every entity's balance and state in real-time.
If a random generator picks an "illegal" value, the engine dynamically constrains it to the legal range.
Custom SQL invariants defined in YAML that act as the laws of physics for the generator.
It's better described as Causal AI. Standard ML (like Neural Networks) is a "Black Box"—it guesses. CausalFoundry is a "Glass Box."
It uses Statistical Inference to "shadow" the frequencies of your production traffic, but it uses Symbolic Logic to ensure that every record is valid. It doesn't "guess" the rules; it follows the rules you give it, while learning the distribution of those rules from your live data.
This is the process of forcing the engine into the "Long Tail" of distribution. In your configuration, you set a rate for specific scenarios.
When the engine "hits" that rate, it overrides its normal shadowed distribution to generate a rare event (like a $1,000,000 withdrawal). Crucially, the engine then Drills Down through the causal graph to ensure the rest of the database makes sense (e.g., creating a High Net Worth account for that transaction) so that the event isn't just a "floating" outlier, but a logically consistent part of the stream.
CausalFoundry is built in high-performance Rust, capable of generating and processing 10,000+ records per second with full invariant enforcement. For a standard 1,000,000 record task spread over an hour, the engine consumes minimal resources, often running as a background service with sub-millisecond latency.
"1 million records in an hour? CausalFoundry handles that with 95% of its capacity to spare."
It's powerful, but it requires careful calibration. If you train a fraud detection model on data where 80% of transactions are $1,000,000 fraud cases, the model becomes "paranoid." It may learn that large transfers never need authorization, leading to catastrophic security failures in production.
CausalFoundry isn't just a generator; it's a Factory. It enforces the "Laws of Physics" for your business logic to ensure that even forced rare events fit perfectly into the surrounding context, preventing the creation of nonsensical outliers that confuse your AI.
In Shadow Mode, CausalFoundry constantly watches the frequency of events in your production database. As your schema evolves—new columns, changed table structures—the engine auto-introspects these changes, ensuring your seed data never "rots." It learns the distribution of real data and shadow-calibrates itself to keep the synthetic stream in sync with reality.
CausalFoundry includes a specific crate called cf_verify. This acts like a "Spectrometer" for your data stream. For every 10,000 records, it can output a report scoring the stream for quality, ensuring that the "Causal Entropy" remains within expected bounds.
Our multi-tier architecture allows you to balance performance with semantic realism:
"A 100% statistical match is a security failure, not a product feature."
If your synthetic data is a perfect statistical mirror of your production data, an attacker can use Model Inversion Attacks to reverse-engineer sensitive production secrets. We advocate for Intentional Reality via the 80/15/5 rule:
This approach gives your models the "entropy" they need to be robust without exposing the exact statistical fingerprints of your customers.
| Feature | Manual "Dummy" Data | CausalFoundry Injection |
|---|---|---|
| Implementation | Manual SQL `INSERT` statements | Define `rate` (e.g., 0.1) in YAML |
| Integrity | Often rejected by FK constraints | Fits schema & ripples correctly |
| Result | Model finds it "too fake" | 100% "real" to model logic |
Join the limited beta to start enforcing causal integrity in your ML pipelines.