Production Ready Library

Query your database
in plain English

Sequelize AI translates Natural Language into secure built-in ORM queries, executes them in a V8 sandbox, and returns clean JSON. Zero raw SQL access required.

app.js
const result = await ai.ask("get the 5 cheapest available products");

console.log(result);
/*
{
  model: "Product",
  method: "findAll",
  data: [
    { id: 1, name: "Mouse", price: "20.00", stock: 15 },
    ...
  ]
}
*/
Features

Why Sequelize AI?

No SQL Injection

Forces all queries through Sequelize ORM attributes to prevent destructive raw SQL actions.

Sandboxed V8 Engine

LLM code executes inside an isolated Node.js VM with zero fs/net access and strict CPU timeouts.

Multi-provider

Supports OpenAI, Gemini, Claude, Groq, DeepSeek, Together and custom LLMs out-of-the-box.

AI Column Hints

Add `aiDescription` directly on models to aid the LLM in understanding complex business logic.

Multi-Query Sync

Compound questions ("How many users and total sales?") are executed in parallel efficiently.

Computed Columns

Leverage mathematics natively inside the ORM via automatic `.literal()` evaluation strings.

About The Architecture

How it works safely

1

Natural Language

Provide a plain English string.

2

LLM Translation

AI leverages Schema context to output ORM JS objects.

3

VM Sandbox

Resolves queries autonomously in a 128MB isolated thread.

Ready to simplify your backend?

Drop `sequelize-ai` into your codebase today to instantly empower your users or your admin dashboards.

Read Documentation