Enables connection to Databricks SQL warehouses with secure credential management, allowing users to browse catalogs, schemas, and tables, execute queries, and create visualizations from Databricks data using natural language.
Provides local database support with CSV import capabilities, interactive database browsing, table management, and the ability to query and visualize data stored in DuckDB databases.
Powers the generation of interactive HTML charts and visualizations including bar, line, scatter, pie, histogram, box plots, heatmaps, and area charts from database query results.
šÆ MCP Data Visualization Server
Transform natural language into beautiful, interactive data visualizations using Claude Desktop with DuckDB and Databricks support - one-command installation!
⨠Features
š One-Command Installation -
pip install mcp-visualization-duckdbš§ Automatic Configuration - Automatically sets up Claude Desktop
š£ļø Natural Language Interface - Chat with Claude to create visualizations
š Interactive Charts - Plotly-powered HTML widgets
š¢ Databricks Integration - Connect to Databricks SQL warehouses with secure credential management
šļø DuckDB Support - Local database with CSV import and interactive browser
š Multi-Database - Seamlessly switch between DuckDB and Databricks
š§ Rule-Based Analysis - Smart chart suggestions without external LLM dependencies
š Multiple Chart Types - Bar, line, scatter, pie, histogram, box plots, heatmaps, and area charts
š Smart Insights - Automatic statistical analysis and pattern detection
š”ļø Security First - SQL injection protection, encrypted credential storage
ā” No External Dependencies - Works entirely offline with Claude Desktop
š Quick Installation
Option A: DuckDB (Local Database)
That's it! No manual configuration needed.
Note: DuckDB and all other dependencies are automatically installed with the package. No separate database installation required!
Option B: Databricks (Enterprise Data Warehouse)
For Databricks, you'll need:
Databricks workspace hostname (e.g.,
your-company.cloud.databricks.com)SQL warehouse HTTP path (e.g.,
/sql/1.0/warehouses/abc123)Personal access token (generated in Databricks User Settings > Developer > Access Tokens)
š Security: Credentials are stored securely using your system keyring or encrypted files. Tokens are never stored in plain text or command history.
What the installer does automatically:
ā Detects your platform (Windows/Mac/Linux)
ā Finds Claude Desktop config automatically
ā Auto-detects database type (DuckDB or Databricks)
ā Sets up database with sample data (DuckDB)
ā Securely stores credentials (Databricks)
ā Configures paths correctly
ā Creates backups of existing config
ā Validates setup to ensure it works
š After Installation
Once installed, you'll see detailed instructions with:
Next steps for your chosen database type
Quick start commands
Sample database links
Example queries to try
Run mcp-viz-setup anytime to see the post-installation guide again!
š Ongoing Usage (After Setup)
ā One-Time Setup Only
š Daily Usage - No Reconfiguration Needed
š Check Status Anytime
š When You Need to Reconfigure
ā Token expires (personal access tokens can have expiration dates)
ā Change workspaces (different Databricks instance)
ā Change SQL warehouses (different HTTP path)
ā Credential issues (run
mcp-viz databricks removethen reconfigure)
š¾ Secure Credential Storage
š Encrypted on disk or in system keyring
š Automatically loaded when Claude Desktop starts
ā” No repeated authentication needed
š Note: After initial setup, you should be able to use Claude Desktop normally without any additional configuration steps!
š® Usage with Claude Desktop
After installation, simply chat with Claude using natural language:
Data Analysis
"What tables are available?" - List database tables
"What Databricks catalogs are available?" - Browse Databricks catalogs
"Show me schemas in the sales catalog" - List schemas
"Analyze the sales table" - Get table information
"Show me the top 10 products by revenue" - Query data
Creating Visualizations
"Create a bar chart of sales by region" - Generate charts
"Show me the correlation between price and quantity" - Scatter plots
"Make a pie chart of customer segments" - Category breakdowns
"Visualize sales trends over time" - Time series analysis
Database Management
DuckDB:
"Browse databases in my Downloads folder" - Interactive database browser
"Connect to C:/path/to/mydata.duckdb" - Switch databases
"Load CSV from Downloads/sales.csv as table 'sales'" - Import data
Databricks:
"Switch to the marketing catalog" - Navigate catalogs
"List schemas in the sales catalog" - Browse schemas
"What database am I connected to?" - Connection info
š§ CLI Commands
The package includes a powerful CLI:
š Supported Chart Types
Chart Type | Use Case | Example Request |
Bar | Compare categories | "Show sales by region" |
Line | Show trends over time | "Plot revenue over months" |
Scatter | Explore relationships | "Price vs quantity relationship" |
Pie | Show proportions | "Customer segment breakdown" |
Histogram | Analyze distributions | "Distribution of order values" |
Box | Compare distributions | "Price ranges by category" |
Heatmap | Show correlations | "Correlation matrix of metrics" |
Area | Cumulative trends | "Cumulative sales over time" |
š ļø Troubleshooting
"Server not found" in Claude Desktop
"Unknown tool" errors
Database issues
š§ Advanced Configuration
Custom Database Path
The installer will prompt you for a database location, or you can specify it:
Multiple Databases
You can easily switch between databases using Claude Desktop:
"Browse databases in Documents folder"
"Connect to /path/to/another/database.duckdb"
"What database am I currently connected to?"
š¾ Sample Data
šÆ Built-in Sample Data
The package automatically creates sample data including:
Sales Data - 365 days of sales across regions and products
Customer Data - 1000 customer records with demographics
Product Data - 100 products with categories and pricing
š Additional Sample Databases
Want more data to explore? Check out these high-quality sample databases:
TimeStored Sample DuckDB Databases
Available datasets include:
Financial Data - Stock prices, trading data, market analysis
NYC Taxi - Real NYC taxi trip records with geospatial data
TPC-H Benchmark - Standard database performance testing data
E-commerce - Product catalogs, orders, customer behavior
IoT Sensor Data - Time-series sensor readings and telemetry
Simply download any .duckdb file and load it:
Perfect for testing, learning, and demonstrating data visualization capabilities!
šļø Development Setup
For developers who want to contribute:
See Development Guide for detailed instructions.
ā Frequently Asked Questions
Q: Do I need to run
A: No! You only run it once during initial setup. After that:
ā Credentials are stored securely and auto-loaded
ā Just open Claude Desktop and start chatting
ā No repeated authentication needed
Q: How do I know if my Databricks is still connected?
A: Check anytime with:
Q: When do I need to reconfigure?
A: Only when:
Your access token expires
You change Databricks workspaces
You switch to a different SQL warehouse
Credentials get corrupted (rare)
Q: Are my credentials safe?
A: Yes! Credentials are:
š Encrypted on disk or stored in system keyring
š« Never stored in plain text or command history
ā” Automatically loaded when needed
Q: Can I use both DuckDB and Databricks?
A: Yes! The server auto-detects which database type to use:
Configure Databricks:
mcp-viz databricks configureConfigure DuckDB:
mcp-viz configureServer automatically uses the appropriate one
š¦ Package Information
Repository: https://github.com/your-github-username/mcp-visualization-duckdb
License: MIT
š¤ Contributing
We welcome contributions! The package is structured for easy development:
Fork the repository
Create a feature branch
Make your changes
Run tests:
python test_package.pySubmit a pull request
š Acknowledgments
Model Context Protocol by Anthropic
DuckDB for fast analytical processing
Plotly for interactive visualizations
Claude Desktop for the amazing AI interface
Ready to transform your data analysis with Claude Desktop?
š That's it! Start chatting with Claude about your data!