Compare and sync your database schemas across environments — safely, visually, and fast.
TheAndb Core is the high-performance engine powering the entire Andb ecosystem. Optimized for the AI-First Era (2026), it provides the bridge between natural language reasoning and reliable database schema management.
This engine doesn't just "compare text"; it understands intent through AST (Abstract Syntax Tree) analysis, protecting your production environments from destructive operations and providing human-level semantic insights.
- 🧠 The Advisor (Safety Engine): Full AST-based SQL analysis. Detects destructive operations (DROP, TRUNCATE) and "Metadata Lock" hazards (Full Table Rebuilds) with high precision.
- 📝 Semantic Diffing: Goes beyond SQL code to provide human-readable descriptions of changes (e.g., "Column type changed: VARCHAR -> ENUM").
- 🤖 AI-Agent Ready (MCP): Native support for the Model Context Protocol. AI agents (Cursor, Claude, GPT) can now reason about your DB schema via standardized, normalized SQL views.
- 🏗️ Professional Orchestration: Single API for comparison, migration, export, and secure user management across multiple environments.
- 💎 Premium Intelligence: Advanced comparison for Tables, Views, Procedures, Functions, Triggers, and Events.
- 📊 Normalized SQL: Generates standardized DDLs, making it easier for both humans and AI to identify structural drift.
- 🛡️ Session Hygiene: Automatic handling of foreign key checks and safe session modes for zero-downtime migrations.
- 🔌 Pluggable Drivers: High-performance MySQL and Dump (offline storage) drivers.
- Node.js >= 18
- macOS (Windows support coming soon)
- MySQL 5.7+ or 8.0+
# Clone the repository
git clone https://github.com/The-Andb/andb-core.git
cd andb-core
npm installThe new core provides the andb binary directly:
# Generate npm scripts for your project
npx ts-node src/cli/main.ts generate -e DEV,PROD
# Show usage and helper information
npx ts-node src/cli/main.ts helperOnce installed globally or linked:
andb helper
andb generatecore/
├── src/
│ ├── common/ # Interfaces and shared types
│ ├── modules/ # Core logic
│ │ ├── comparator/# Schema comparison & Semantic Diff
│ │ ├── driver/ # Database drivers (MySQL, Dump)
│ │ ├── migrator/ # SQL generation & Safety Guards
│ │ ├── safety/ # AST-based Impact Analysis (The Advisor)
│ │ └── parser/ # SQL/DDL parsing and AST logic
│ └── index.ts # Public API entry point
We are currently in Phase 4.5 of our master plan. Our goal is 100% parity with the legacy @the-andb/core package before a full switchover.
- Core Infrastructure (Framework + TypeScript)
- MySQL Driver & Dump Driver
- Schema Comparison (Tables, Views, Routines, Triggers)
- CLI Parity (
generate,helper)
TheAndb Desktop and TheAndb Core are free to download and use for internal business operations including production use. A commercial license is required only if you redistribute, white-label, or resell the software as a competing product.
Keep Going. Keep Syncing.
Made with ❤️ by TheAndb Team