sql-analyst-agent

vk4868/sql-analyst-agent
★ 0 stars Python Database Updated 5d ago
LangGraph agent that answers business questions in SQL over an MCP tool server, with three independent layers of read-only enforcement.
View on GitHub → 🔍 Audit Wallet Slippage →

Quick Install

Copy the config for your editor. Some servers may need additional setup — check the README.

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "sql-analyst-agent": {
      "command": "uvx",
      "args": [
        "sql-analyst-agent"
      ]
    }
  }
}

Or install with pip: pip install sql-analyst-agent

README Excerpt

Ask *"which city made the most revenue last quarter?"* in plain English and get a sentence with the number in it. The agent inspects the real database schema, writes its own SQL, runs it, reads the error if it fails, corrects it once, and explains the result. The database is read-only by **three independent layers of code** — a parser-level allowlist, a SQLite authorizer and a read-only file handle — each sufficient on its own to stop a write. **43 offline tests** fire nine known bypass attempts

Tools (1)

VACUUM
📊
Working with market or time-series data?
The Polymarket Historical Dataset — 18.5M+ price snapshots across 18,600+ prediction markets (CSV + SQLite). Built for backtesting & ML.
View dataset →