Inspiration
Modern AI systems are fundamentally limited — they excel at finding correlations, but fail to answer the most important question:
Why did something happen?
Across domains like software systems, SaaS metrics, and business analytics, decisions are still made on surface-level patterns rather than true causal understanding. This gap leads to poor predictions, failed strategies, and inefficient interventions.
We were inspired by the idea of moving beyond correlation into causal intelligence, grounded in the work of Structural Causal Models (SCMs).
Our goal was to build a system that:
- Understands cause-effect relationships
- Simulates alternate realities (counterfactuals)
- And most importantly, learns from its own mistakes
That vision became LAPLACE — a platform where AI doesn’t just predict outcomes, but reasons, acts, and evolves.
What it does
LAPLACE (Logical Architecture for Predictive Learning and Autonomous Causal Evolution) is a browser-based causal intelligence engine that enables users to:
🔍 Discover Root Causes
Instead of showing correlations, LAPLACE traces causal pathways across a system to identify why a failure occurred.
🔮 Simulate Counterfactuals
Users can ask:
“What would happen if this variable changed?”
Using causal propagation, the system computes:
$$ \text{Predicted}Y = \text{Baseline}_Y + \sum_i w{i \to Y} \cdot (X_i^{new} - X_i^{baseline}) $$
⚡ Execute Interventions
The system translates insights into actionable interventions, visually updating the system in real time.
🧬 Self-Evolve Through Error
Unlike traditional AI, LAPLACE improves itself by comparing prediction vs reality:
$$ \text{Error} = |Y_{predicted} - Y_{actual}| $$
It then updates causal weights dynamically:
$$ w_{new} = w_{old} - \alpha \cdot \nabla(\text{Error}) $$
This creates a feedback loop, where the system becomes progressively more accurate.
🌐 Visualize Everything Live
All causal relationships are rendered as a dynamic graph, where:
- Nodes represent variables
- Edges represent causal influence
- Changes ripple through the system in real time
How we built it
We engineered LAPLACE as a high-performance, zero-backend system:
- Frontend: Vanilla JavaScript (ES6+), HTML5, CSS3
- Visualization: D3.js (
d3-force,d3-zoom) - AI Layer: Google Gemini 2.5 Flash API
- Deployment: Google Cloud App Engine
- Architecture: Serverless SPA with a Bring-Your-Own-Key (BYOK) model
Core System Components
Structural Causal Model Engine
A custom engine processes causal graphs using nodes and weighted edges.
Multi-Agent AI System
- Analyst Agent → finds root causes
- Counterfactual Agent → simulates “what-if”
- Intervention Agent → applies changes
- Evolution Agent → improves the model
Dynamic Graph Engine
Real-time graph updates using D3.js with smooth performance.
Secure BYOK Architecture
- API key stored only in
sessionStorage - No backend, no database
- Fully client-side execution
Challenges we ran into
Bridging Math and AI
LLMs are not naturally good at structured numerical reasoning. We solved this by:
- Handling math on the frontend
- Passing structured context to the AI
Real-Time State Management
Synchronizing:
- D3 simulation
- DOM updates
- AI responses
was complex and required careful lifecycle handling.
Avoiding Hallucination
We prevented incorrect outputs by:
- Using strict JSON structures
- Feeding only relevant causal paths
- Controlling prompt structure
Making Evolution Real
Instead of fake learning, we implemented:
- Prediction vs actual comparison
- Error-based updates
- Version-based improvement
Accomplishments that we're proud of
- Built a causal reasoning engine in the browser
- Created a self-evolving AI system
- Designed a secure zero-backend architecture
- Achieved real-time interactive visualization
- Implemented a multi-agent intelligence system
What we learned
- Causality is fundamentally different from correlation
- AI must be grounded in structure to be reliable
- System design matters more than individual features
- Real innovation comes from combining:
- Mathematics
- Engineering
- AI reasoning
- Mathematics
What's next for LAPLACE
- Integrate real-time data sources (APIs, databases)
- Expand domain templates (finance, healthcare, climate)
- Improve causal discovery algorithms
- Scale to enterprise-level datasets
- Add autonomous decision-making capabilities
Our vision:
AI that doesn’t just predict outcomes — but understands causes and improves reality.
Built With
- causal-ai
- css3
- d3.js
- google-app-engine
- google-cloud
- google-gemini-api
- html5
- javascript
- json
- multi-agent-system
- node.js
- vite



Log in or sign up for Devpost to join the conversation.