Ripple Cube
RIPPLE v1.0
FalkorDB GraphBLAS + Architectural AI

Never let your AI coding agent edit code in the dark.

When AI agents alter a shared utility or interface, consumers 4 hops away silently break. Ripple pairs FalkorDB's sub-5ms graph traversals with an architectural safe planner over MCP.

code Explore GitHub
Ripple 3D Cube Logo

Multidimensional Safety

Like a Rubik's cube, every code change affects interconnected layers. Ripple solves the whole puzzle.

⚡ ZERO MANUAL SETUP

1-Click Agent Setup Prompt

Paste this prompt directly into your AI coding assistant (Cursor, Claude Desktop, or Antigravity). The agent will autonomously spin up FalkorDB, install Ripple, index your project, and enforce graph-safety automatically:

Please install and set up Ripple for this workspace by performing the following steps:

1. Check FalkorDB availability:
   - Check if FalkorDB is reachable on localhost:6379.
   - If not reachable, check if Docker is installed and running (`docker ps`).
   - If Docker is running, start FalkorDB:
     docker run -d --name falkordb --restart unless-stopped -p 6379:6379 -p 3000:3000 falkordb/falkordb:latest
   - If Docker or FalkorDB is NOT installed on this machine, inform the user:
     "Neither Docker nor FalkorDB was detected locally. You have two instant options:
      Option A (Zero-install Cloud - Recommended): Create a free database in 30 seconds at https://app.falkordb.cloud (no Docker required). Share your Host, Port, and Password, and I will configure .env automatically!
      Option B (Local): Install Docker Desktop (https://www.docker.com) or install FalkorDB natively (`brew install falkordb/tap/falkordb` or `curl -fsSL https://www.falkordb.com/install.sh | bash`)."

2. Clone and build Ripple into a local helper folder:
   git clone https://github.com/trivikramkalagi91-commits/Ripple.git .ripple
   cd .ripple && npm install && npm run build && cd ..

3. Configure environment:
   In `.ripple/.env`, set:
   SARVAM_API_KEY=<your_sarvam_api_key>
   FALKOR_HOST=localhost (or your FalkorDB Cloud host)
   FALKOR_PORT=6379 (or your FalkorDB Cloud port)

4. Index this repository into FalkorDB:
   node .ripple/dist/cli.js index .

5. Add the following rule to your instructions:
   "Before modifying, renaming, or refactoring any exported function, type, or component, you MUST consult Ripple's generate_safe_plan tool (or run `node .ripple/dist/cli.js plan <file> -c '<change>'`) to inspect the multi-hop blast radius and apply all edits in topological safe order so nothing breaks."

Confirm when setup and indexing are complete!
hub Architectural Dependency Graph
target: src/types/api.ts#UserProfile · FalkorDB traversal (4ms)
Root Target Node

src/types/api.ts

export interface UserProfile

Hop 1 · Direct Consumer

src/services/auth.ts

authenticateSession()

Hop 2 · UI Consumer

components/UserProfileCard.tsx

<UserProfileCard user={...} />

Hop 3 · Page View

src/pages/Dashboard.tsx

<DashboardPage />

Hop 4 · App Shell

src/App.tsx

Root Application Container

Topological Sequencing Ready • Sub-5ms GraphBLAS Query
Architectural Zero-Regression Execution Guaranteed
SYSTEM ARCHITECTURE / PIPELINE SPEC REV 2.0

From code change to architectural understanding.

How Ripple combines compiler AST analysis, FalkorDB GraphBLAS sparse matrices, and deep architectural reasoning to guarantee zero-regression code refactorings.

01 / REPOSITORY

Target Code

Source files, tsconfig path aliases (@/*), and barrel re-exports.

Raw Filesystem
02 / PARSER

ts-morph AST

Extracts concrete AST trees, export tables, and static import edges.

Compiler Visitors
03 / GRAPH ENGINE

FalkorDB

Sparse-matrix GraphBLAS traversal calculating multi-hop blast radiuses in 4ms.

Sub-5ms Cypher
04 / REASONING

AI Architect

MoE reasoning models analyze affected files and output topological patch plans.

Architectural LLM
05 / AGENT MCP

AI Coding Agent

Cursor, Claude, or Antigravity executes edits file-by-file without regressions.

Zero Regressions

Why Flat Text Search and Linters Fail

Traditional Grep & Vector RAG

Standard search is syntactically blind to barrel files (export * from './...') and tsconfig path aliases. A generic identifier like id generates thousands of false positives, while indirect dependencies 2 to 4 hops away are completely missed.

Ripple Deterministic Graph

FalkorDB stores the true, resolved property graph. Paths are traversed using matrix multiplications, discovering transitive dependencies with mathematical certainty and sorting them into a clean topological execution order.

PROTOCOL SPECIFICATION 5 NATIVE PRIMITIVES

The MCP Tool Suite

Ripple exposes 5 high-leverage tools over the standard Model Context Protocol. AI coding assistants call these before generating code modifications.

01 / FLAGSHIP REFACTORING

generate_safe_plan

Combines FalkorDB graph traversal with architectural AI reasoning to generate a complete visual blast radius diagram and an exact step-by-step code modification plan in safe topological order.

Inputs: path: string, proposedChange: string
// generate_safe_plan response snippet
{
  "totalAffected": 4,
  "safePlan": [
    { "step": 1, "file": "src/types/api.ts", "action": "Update UserProfile" },
    { "step": 2, "file": "src/services/auth.ts", "action": "Update call sites" },
    { "step": 3, "file": "src/components/UserProfileCard.tsx", "action": "Update props" }
  ],
  "compile_guarantee": true
}
02 / AUDITING

blast_radius

Calculates all files that transitively import the target file up to N hops away. Returns structured dependency counts and an in-chat visual Mermaid diagram.

Inputs: path: string, maxHops?: number (default 4)
// blast_radius response snippet
{
  "target": "src/types/api.ts",
  "totalDependents": 4,
  "byDistance": {
    "1": ["src/services/auth.ts"],
    "2": ["src/components/UserProfileCard.tsx"],
    "3": ["src/pages/Dashboard.tsx"],
    "4": ["src/App.tsx"]
  }
}
03 / PROVENANCE

why_affected

Finds the shortest import chain between two distant files, explaining why modifying file "to" will break file "from".

Inputs: from: string, to: string
// why_affected response snippet
{
  "from": "src/App.tsx",
  "to": "src/types/api.ts",
  "affected": true,
  "hops": 4,
  "chain": ["src/App.tsx", "src/pages/Dashboard.tsx", "src/components/UserProfileCard.tsx", "src/services/auth.ts", "src/types/api.ts"]
}
04 / ARCHITECTURAL HEALTH

risk_hotspots

Identifies architectural single points of failure in the repository using in-degree centrality, highlighting files with the most incoming dependents.

Inputs: limit?: number (default 10)
// risk_hotspots response snippet
[
  { "path": "src/types/api.ts", "inDegree": 4 },
  { "path": "src/services/auth.ts", "inDegree": 3 }
]
05 / SCHEDULING

safe_edit_order

Sorts affected files into an acyclic topological sequence by distance from target (0 to N) so changes can be applied without deadlocks or broken builds.

Inputs: path: string
// safe_edit_order response snippet
[
  { "step": 1, "distanceFromTarget": 0, "path": "src/types/api.ts" },
  { "step": 2, "distanceFromTarget": 1, "path": "src/services/auth.ts" },
  { "step": 3, "distanceFromTarget": 2, "path": "src/components/UserProfileCard.tsx" }
]
GET STARTED IN 3 MINUTES SETUP GUIDE

Install and run Ripple.

Follow these simple steps to set up FalkorDB, build Ripple, and connect it to your AI coding agent.

1

Start FalkorDB

Run FalkorDB locally in Docker with the interactive visual studio enabled:

docker run -d --name falkordb -p 6379:6379 -p 3000:3000 falkordb/falkordb:latest
2

Clone & Build Ripple

Clone the repository and compile the TypeScript project:

git clone https://github.com/trivikramkalagi91-commits/Ripple.git
cd Ripple && npm install && npm run build
3

Index Your Project

Point the indexer to your TypeScript/JavaScript codebase:

node dist/cli.js index /path/to/your/project
4

Connect to Cursor / Claude Desktop

Add Ripple to your MCP configuration (claude_desktop_config.json or Cursor MCP settings):

{
  "mcpServers": {
    "ripple": {
      "command": "node",
      "args": ["/absolute/path/to/Ripple/dist/server.js"],
      "env": {
        "SARVAM_API_KEY": "your_sarvam_api_key",
        "SARVAM_MOCK": "false"
      }
    }
  }
}