An interactive, zero-backend Cognitive Wargaming tool designed for analysts, strategists, and decision-makers. The engine simulates non-linear future scenarios (2nd and 3rd-order consequences) using Large Language Models (Gemini 3.5 Flash Lite) anchored in a Directed Acyclic Graph (DAG) architecture.
Traditional forecasting often suffers from linear bias. The Bayesian AI Simulator forces users to explore probabilistic branches, unexpected trade-offs, and systemic sectorial impacts across customizable timelines.
It does not serve as a financial oracle, but as a Strategic Stress-Testing Tool to evaluate "What If" scenarios under strict probabilistic boundaries.
- BYOK Architecture (Bring Your Own Key): 100% Client-Side execution. Your Google Gemini API key is stored exclusively in your browser's Local Storage. No external database or intermediate backend.
- Timeline Alignment: Dynamic spatial calculation anchoring scenarios to an absolute year coordinate, allowing precise parallel branch inspection.
- Probabilistic Confidence Metrics:
- Relative Confidence: Independent probability of occurrence based purely on the immediate parent scenario.
- Absolute Confidence: Cumulative path-dependent probability calculated from Node 0 (Genesis).
- Multi-Branching Parallel Realities: Generate up to 3 mutually exclusive scenarios for the same target year in a single inference call.
- Target Year Override: Force projections to a specific future year while strictly preventing temporal paradoxes (past-year traversal).
- Incremental Deep Dive: Expand specific node insights without polluting the DAG layout.
- Data Lifecycle Management: Export and Import your entire simulation tree via standard
.jsonformat. - Multi-Language Support: Fully operational in Italian, English, Spanish, and French.
- Frontend: Vanilla HTML5, CSS3 (Glassmorphism UI), JavaScript (ES6+).
- Graph Engine: Vis-Network (Hierarchical Directed Layout).
- AI Model: Google Gemini 3.5 Flash Lite via REST API.
- Persistence: HTML5 Web Storage API (
localStorage).
- Clone this repository or download the source files.
- Open
index.htmlin any modern web browser (Chrome, Safari, Firefox). - Click on the 📖 Guida / Guide or Inizializza Motore button.
- Provide your Google Gemini API Key (Get one at Google AI Studio).
Since the application is purely static and backend-less:
- Import this repository into Vercel or Netlify.
- Click Deploy (No environment variables or build settings required).
This application does not collect, track, or proxy any user data. All API calls are routed directly from your browser to Google's official endpoints (generativelanguage.googleapis.com).
This project is open-source and available under the MIT License.