dbt LLM Agent
LLM based AI Agent to automate Data Analysis for dbt projects with remote MCP server
What is dbt LLM Agent?
dbt LLM Agent is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to llm based ai agent to automate data analysis for dbt projects with remote mcp server
LLM based AI Agent to automate Data Analysis for dbt projects with remote MCP server
This server falls under the Data Science & ML category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- LLM based AI Agent to automate Data Analysis for dbt project
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx dbt-llm-agentConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use dbt LLM Agent
Ragstar (formerly dbt-llm-agent) is a self-hosted AI data analyst platform that connects to your dbt projects, learns your data models through semantic indexing, and exposes an MCP server so AI clients can answer business questions in natural language, generate SQL, and retrieve detailed model metadata. It supports text-to-SQL workflows across dbt projects connected to any major data warehouse, and can be queried through a web dashboard, a Slack `/ask` command, or directly through MCP-compatible clients like Claude. Engineers and data teams use it to make dbt documentation interactive and to let stakeholders explore data without writing SQL.
Prerequisites
- Docker and Docker Compose installed
- A dbt project connected to a data warehouse (BigQuery, Snowflake, Redshift, etc.)
- An LLM provider API key: OpenAI (`LLM_OPENAI_API_KEY`), Anthropic (`LLM_ANTHROPIC_API_KEY`), or Google (`LLM_GOOGLE_API_KEY`)
- An MCP-compatible client such as Claude Desktop or Claude Code
- Git access to clone the Ragstar repository
Clone the repository and create your .env file
Clone the Ragstar repository and copy the example environment file. Open `.env` in your editor and fill in the required values.
git clone https://github.com/pragunbhutani/ragstar.git && cd ragstar
cp .env.example .envSet required environment variables in .env
The minimum required variables are the NextAuth secret and URLs. Add your LLM API key for the provider you want to use.
NEXTAUTH_SECRET=your-random-secret # openssl rand -base64 32
NEXTAUTH_URL=http://localhost:3000
NEXT_PUBLIC_API_URL=http://localhost:8000
LLM_OPENAI_API_KEY=sk-your-openai-keyStart the stack with Docker Compose
Bring up all services (frontend, Django backend, Celery worker, Postgres, Redis) and run database migrations.
docker compose up --build -d
docker compose exec backend-django uv run python manage.py migrateConnect your dbt project through the web UI
Navigate to http://localhost:3000, create an account, and use the onboarding flow to connect your dbt project. Ragstar will ingest and semantically index your dbt models.
Configure the MCP server connection
Set the MCP environment variables so the server knows where to connect, then add it to your MCP client config.
MCP_AUTHORIZATION_BASE_URL=http://localhost:8000
DJANGO_BACKEND_URL=http://localhost:8000
ALLOWED_ORIGINS=*dbt LLM Agent Examples
Client configuration
Claude Desktop config block for the Ragstar MCP server running locally via Docker.
{
"mcpServers": {
"ragstar": {
"command": "npx",
"args": ["-y", "dbt-llm-agent"],
"env": {
"MCP_AUTHORIZATION_BASE_URL": "http://localhost:8000",
"DJANGO_BACKEND_URL": "http://localhost:8000"
}
}
}
}Prompts to try
Example queries that use Ragstar's dbt model knowledge and text-to-SQL capabilities.
- "List all dbt models in my project"
- "Search for models related to customer revenue"
- "Show me the SQL and lineage for the customer_metrics model"
- "What tables feed into the orders_daily model?"
- "Write a SQL query to find the top 10 customers by revenue last quarter"Troubleshooting dbt LLM Agent
Docker Compose startup fails with database connection errors
Wait a few seconds for the Postgres container to become ready, then re-run `docker compose up -d`. The migration command can also fail if run too quickly after startup — retry `docker compose exec backend-django uv run python manage.py migrate` after Postgres is healthy.
MCP tools return empty results for model searches
Ensure you have completed the onboarding flow and connected a dbt project in the web UI at http://localhost:3000. The semantic index must be built before search works — check the Celery task monitor at http://localhost:5555 to confirm indexing has finished.
LLM API calls fail with authentication errors
Verify your LLM API key is correctly set in `.env` under `LLM_OPENAI_API_KEY`, `LLM_ANTHROPIC_API_KEY`, or `LLM_GOOGLE_API_KEY`, and that the Docker containers were restarted after the change with `docker compose restart`.
Frequently Asked Questions about dbt LLM Agent
What is dbt LLM Agent?
dbt LLM Agent is a Model Context Protocol (MCP) server that llm based ai agent to automate data analysis for dbt projects with remote mcp server It connects AI assistants to external tools and data sources through a standardized interface.
How do I install dbt LLM Agent?
Follow the installation instructions on the dbt LLM Agent GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with dbt LLM Agent?
dbt LLM Agent works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is dbt LLM Agent free to use?
Yes, dbt LLM Agent is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
dbt LLM Agent Alternatives — Similar Data Science & ML Servers
Looking for alternatives to dbt LLM Agent? Here are other popular data science & ml servers you can use with Claude, Cursor, and VS Code.
Ultrarag
★ 5.6kA Low-Code MCP Framework for Building Complex and Innovative RAG Pipelines
RocketRide
★ 3.1k📇 🏠 - MCP server that exposes RocketRide AI pipelines as t
Aix Db
★ 2.1kAix-DB 基于 LangChain/LangGraph 框架,结合 MCP Skills 多智能体协作架构,实现自然语言到数据洞察的端到端转换。
NeMo Data Designer
★ 1.9k🎨 NeMo Data Designer: Generate high-quality synthetic data from scratch or from seed data.
PaperBanana
★ 1.7kOpen source implementation and extension of Google Research’s PaperBanana for automated academic figures, diagrams, and research visuals, expanded to new domains like slide generation.
MiniMax
★ 1.5kBridges MiniMax AI capabilities to the Model Context Protocol, enabling AI agents to perform image understanding, text-to-image generation, and speech synthesis. It provides a standardized interface for accessing MiniMax's core tools via JSON-RPC.
Browse More Data Science & ML MCP Servers
Explore all data science & ml servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up dbt LLM Agent in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use dbt LLM Agent?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.