vizro-mcp 0.1.1__tar.gz → 0.1.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- vizro_mcp-0.1.3/.dockerignore +10 -0
- vizro_mcp-0.1.3/.readthedocs.yaml +19 -0
- vizro_mcp-0.1.3/CHANGELOG.md +50 -0
- vizro_mcp-0.1.3/Dockerfile +10 -0
- vizro_mcp-0.1.3/PKG-INFO +201 -0
- vizro_mcp-0.1.3/README.md +182 -0
- vizro_mcp-0.1.3/docs/assets/images/chart-context-copy.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/claude_prompt.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/claude_working.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial1.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial2.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial3.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial4.5.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial4.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial5.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/cursor-tutorial6.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/favicon.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/install-vizro-mcp-cursor-docker.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/install-vizro-mcp-cursor-uv.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/pycafe-usage.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/save-pycafe.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/share-vizro-project-options.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/song-decades-iteration1.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/song-decades-iteration2.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/song-decades-iteration3.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/song-top-10-iteration1.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/two-chart-dashboard-iteration1.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/two-chart-dashboard-iteration2.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/use-cursor-prompt-template.png +0 -0
- vizro_mcp-0.1.3/docs/assets/images/vizro-mcp-templates-in-claude.png +0 -0
- {vizro_mcp-0.1.1/assets → vizro_mcp-0.1.3/docs/assets/images}/vizro-mcp.gif +0 -0
- vizro_mcp-0.1.3/docs/index.md +35 -0
- vizro_mcp-0.1.3/docs/pages/API-reference/API-reference.md +16 -0
- vizro_mcp-0.1.3/docs/pages/explanation/contribute.md +33 -0
- vizro_mcp-0.1.3/docs/pages/explanation/disclaimers.md +53 -0
- vizro_mcp-0.1.3/docs/pages/explanation/faqs.md +21 -0
- vizro_mcp-0.1.3/docs/pages/guides/create-charts-only.md +11 -0
- vizro_mcp-0.1.3/docs/pages/guides/get-live-preview.md +7 -0
- vizro_mcp-0.1.3/docs/pages/guides/set-up-vizro-mcp-basics.md +84 -0
- vizro_mcp-0.1.3/docs/pages/guides/set-up-vizro-mcp-with-claude.md +98 -0
- vizro_mcp-0.1.3/docs/pages/guides/set-up-vizro-mcp-with-cursor.md +83 -0
- vizro_mcp-0.1.3/docs/pages/guides/set-up-vizro-mcp-with-vscode.md +51 -0
- vizro_mcp-0.1.3/docs/pages/guides/use-data.md +19 -0
- vizro_mcp-0.1.3/docs/pages/guides/use-prompt-templates.md +23 -0
- vizro_mcp-0.1.3/docs/pages/tutorials/claude-desktop-tutorial.md +272 -0
- vizro_mcp-0.1.3/docs/pages/tutorials/cursor-tutorial.md +371 -0
- vizro_mcp-0.1.3/docs/pages/tutorials/first-dashboard-tutorial.md +95 -0
- vizro_mcp-0.1.3/docs/stylesheets/extra.css +47 -0
- vizro_mcp-0.1.3/hatch.toml +87 -0
- vizro_mcp-0.1.3/mkdocs.yml +121 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/pyproject.toml +1 -1
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/src/vizro_mcp/__init__.py +1 -1
- vizro_mcp-0.1.3/src/vizro_mcp/_schemas/__init__.py +13 -0
- vizro_mcp-0.1.3/src/vizro_mcp/_schemas/schemas.py +230 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/src/vizro_mcp/_utils/__init__.py +26 -5
- vizro_mcp-0.1.3/src/vizro_mcp/_utils/configs.py +142 -0
- vizro_mcp-0.1.3/src/vizro_mcp/_utils/prompts.py +229 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/src/vizro_mcp/_utils/utils.py +66 -146
- vizro_mcp-0.1.3/src/vizro_mcp/server.py +378 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/tests/unit/vizro_mcp/test_server.py +143 -65
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/uv.lock +735 -743
- vizro_mcp-0.1.1/CHANGELOG.md +0 -18
- vizro_mcp-0.1.1/PKG-INFO +0 -300
- vizro_mcp-0.1.1/README.md +0 -281
- vizro_mcp-0.1.1/assets/claude_prompt.png +0 -0
- vizro_mcp-0.1.1/assets/claude_working.png +0 -0
- vizro_mcp-0.1.1/assets/cursor_working.png +0 -0
- vizro_mcp-0.1.1/hatch.toml +0 -45
- vizro_mcp-0.1.1/src/vizro_mcp/_schemas/__init__.py +0 -29
- vizro_mcp-0.1.1/src/vizro_mcp/_schemas/schemas.py +0 -297
- vizro_mcp-0.1.1/src/vizro_mcp/server.py +0 -400
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/.gitignore +0 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/LICENSE.txt +0 -0
- /vizro_mcp-0.1.1/changelog.d/20250515_115815_lingyi_zhang_0_1_1.md → /vizro_mcp-0.1.3/changelog.d/20250929_131634_maximilian_schulz_0_1_3.md +0 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/changelog.d/new_fragment.md.j2 +0 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/changelog.d/scriv.ini +0 -0
- {vizro_mcp-0.1.1/assets → vizro_mcp-0.1.3/docs/assets/images}/claude_validate.png +0 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/glama.json +0 -0
- {vizro_mcp-0.1.1 → vizro_mcp-0.1.3}/src/vizro_mcp/py.typed +0 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Read the Docs configuration file for MkDocs projects
|
|
2
|
+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
|
|
3
|
+
|
|
4
|
+
# Required
|
|
5
|
+
version: 2
|
|
6
|
+
|
|
7
|
+
# Set the version of Python and other tools you might need
|
|
8
|
+
build:
|
|
9
|
+
os: ubuntu-22.04
|
|
10
|
+
tools:
|
|
11
|
+
python: "3.12"
|
|
12
|
+
commands:
|
|
13
|
+
# Remove the `click` installation constraint once the
|
|
14
|
+
# https://github.com/pypa/hatch/issues/2050 is resolved.
|
|
15
|
+
- pip install hatch "click<8.3.0"
|
|
16
|
+
- cd vizro-mcp/ && hatch run docs:pip tree
|
|
17
|
+
- cd vizro-mcp/ && hatch run docs:build
|
|
18
|
+
- mkdir --parents $READTHEDOCS_OUTPUT
|
|
19
|
+
- mv vizro-mcp/site/ $READTHEDOCS_OUTPUT/html
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
<a id='changelog-0.1.3'></a>
|
|
2
|
+
|
|
3
|
+
# 0.1.3 — 2025-09-29
|
|
4
|
+
|
|
5
|
+
## Added
|
|
6
|
+
|
|
7
|
+
- Added ability to use KPI cards in `Figure`. ([#1392](https://github.com/mckinsey/vizro/pull/1392))
|
|
8
|
+
|
|
9
|
+
## Changed
|
|
10
|
+
|
|
11
|
+
- Updated Layout prompting for better Layout performance of the MCP server. ([#1405](https://github.com/mckinsey/vizro/pull/1405))
|
|
12
|
+
|
|
13
|
+
- Updated Vizro version to >=0.1.46. ([#1423](https://github.com/mckinsey/vizro/pull/1423))
|
|
14
|
+
|
|
15
|
+
## Fixed
|
|
16
|
+
|
|
17
|
+
- Added tool parameter descriptions to Field definition instead of docstring so that they display properly in hosts like Cursor. ([#1374](https://github.com/mckinsey/vizro/pull/1374)) <a id='changelog-0.1.2'></a>
|
|
18
|
+
|
|
19
|
+
# 0.1.2 — 2025-06-30
|
|
20
|
+
|
|
21
|
+
## Added
|
|
22
|
+
|
|
23
|
+
- Add Dockerfile for Vizro MCP server to enable containerized local setup. ([#1184](https://github.com/mckinsey/vizro/pull/1184))
|
|
24
|
+
|
|
25
|
+
- Add capability to create custom charts (beyond Plotly Express) with Vizro-MCP. ([#1227](https://github.com/mckinsey/vizro/pull/1227))
|
|
26
|
+
|
|
27
|
+
## Changed
|
|
28
|
+
|
|
29
|
+
- Update Vizro version to `>=0.1.42`. ([#1227](https://github.com/mckinsey/vizro/pull/1227))
|
|
30
|
+
|
|
31
|
+
- Improve usability of MCP server in IDE environments like Cursor. ([#1227](https://github.com/mckinsey/vizro/pull/1227))
|
|
32
|
+
|
|
33
|
+
<a id='changelog-0.1.1'></a>
|
|
34
|
+
|
|
35
|
+
# 0.1.1 — 2025-05-15
|
|
36
|
+
|
|
37
|
+
### Fixed
|
|
38
|
+
|
|
39
|
+
- Fix name conflict with `langchain` by avoiding use of conflicting parameter names in tools. ([#1177](https://github.com/mckinsey/vizro/pull/1177))
|
|
40
|
+
|
|
41
|
+
<a id='changelog-0.1.0'></a>
|
|
42
|
+
|
|
43
|
+
# 0.1.0 — 2025-05-06
|
|
44
|
+
|
|
45
|
+
## Added
|
|
46
|
+
|
|
47
|
+
- Initial release of the Vizro MCP server. ([#1125](https://github.com/mckinsey/vizro/pull/1125))
|
|
48
|
+
- still experimental, please provide feedback via [github issues](https://github.com/mckinsey/vizro/issues)
|
|
49
|
+
- pinned `vizro` version to `0.1.38`
|
|
50
|
+
- published with 6 tools and 3 prompt templates
|
vizro_mcp-0.1.3/PKG-INFO
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: vizro-mcp
|
|
3
|
+
Version: 0.1.3
|
|
4
|
+
Summary: MCP server to help create Vizro dashboards and charts
|
|
5
|
+
Author: Vizro Team
|
|
6
|
+
License-File: LICENSE.txt
|
|
7
|
+
Classifier: Programming Language :: Python
|
|
8
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
9
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
10
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
12
|
+
Requires-Python: >=3.10
|
|
13
|
+
Requires-Dist: click>=8.1.7
|
|
14
|
+
Requires-Dist: httpx>=0.28.1
|
|
15
|
+
Requires-Dist: mcp[cli]>=1.6.0
|
|
16
|
+
Requires-Dist: pandas[excel,html,parquet]
|
|
17
|
+
Requires-Dist: vizro>=0.1.46
|
|
18
|
+
Description-Content-Type: text/markdown
|
|
19
|
+
|
|
20
|
+
<!-- <a href="https://glama.ai/mcp/servers/@mckinsey/vizro">
|
|
21
|
+
<img width="380" height="200" src="https://glama.ai/mcp/servers/@mckinsey/vizro/badge" />
|
|
22
|
+
</a> -->
|
|
23
|
+
|
|
24
|
+
# Vizro-MCP
|
|
25
|
+
|
|
26
|
+
Vizro-MCP is a [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server, which works alongside an LLM to help you create Vizro dashboards and charts.
|
|
27
|
+
|
|
28
|
+
<img src="docs/assets/images/vizro-mcp.gif" width="600" alt="Vizro-MCP Demo">
|
|
29
|
+
|
|
30
|
+
To find out more, consult the [Vizro-MCP documentation](https://vizro.readthedocs.io/projects/vizro-mcp/).
|
|
31
|
+
|
|
32
|
+
## Set up Vizro-MCP
|
|
33
|
+
|
|
34
|
+
Vizro-MCP is best used with Claude Desktop, Cursor or VS Code. However, it can be used with most LLM products that enable configuration of MCP server usage.
|
|
35
|
+
|
|
36
|
+
> 💡 Tip: For best performance, we recommend using the `claude-4-sonnet` model, or another high-performing model of your choice. Using the often offered `auto` setting may lead to inconsistent or unexpected results.
|
|
37
|
+
|
|
38
|
+
Our documentation offers separate, detailed steps for [Claude Desktop](https://vizro.readthedocs.io/projects/vizro-mcp/en/latest/pages/guides/set-up-vizro-mcp-with-claude/), [Cursor](https://vizro.readthedocs.io/projects/vizro-mcp/en/latest/pages/guides/set-up-vizro-mcp-with-cursor/) and [VS Code](https://vizro.readthedocs.io/projects/vizro-mcp/en/latest/pages/guides/set-up-vizro-mcp-with-vscode/).
|
|
39
|
+
|
|
40
|
+
### Basic configuration
|
|
41
|
+
|
|
42
|
+
The following is for those familiar with MCP server setup who are comfortable with basic configuration settings. You must have downloaded and installed the LLM app you want to configure and use as a MCP host.
|
|
43
|
+
|
|
44
|
+
<details>
|
|
45
|
+
<summary><strong>Quick setup for Vizro-MCP using uv</strong></summary>
|
|
46
|
+
|
|
47
|
+
You must first install [uv](https://docs.astral.sh/uv/getting-started/installation/).
|
|
48
|
+
|
|
49
|
+
Next, open a terminal window and type `uv` to confirm that is available. To get the path to `uvx`, type the following:
|
|
50
|
+
|
|
51
|
+
```shell
|
|
52
|
+
which uv
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Copy the path returned, and add the following to the JSON file used to configure MCP servers for your LLM app. Be sure to substitute your path to uv as returned above, for the placeholder given:
|
|
56
|
+
|
|
57
|
+
```
|
|
58
|
+
{
|
|
59
|
+
"mcpServers": {
|
|
60
|
+
"vizro-mcp": {
|
|
61
|
+
"command": "/placeholder-path/uvx",
|
|
62
|
+
"args": [
|
|
63
|
+
"vizro-mcp"
|
|
64
|
+
]
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
**Quick install**
|
|
71
|
+
|
|
72
|
+
| Host | Prerequisite | Link |
|
|
73
|
+
| ----------------------------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
74
|
+
| [Cursor](https://www.cursor.com/) | [uv](https://docs.astral.sh/uv/getting-started/installation/) | [](https://cursor.com/en/install-mcp?name=vizro-mcp&config=eyJjb21tYW5kIjoidXZ4IHZpenJvLW1jcCJ9) |
|
|
75
|
+
| [VS Code](https://code.visualstudio.com/) | [uv](https://docs.astral.sh/uv/guides/tools/) | [](https://insiders.vscode.dev/redirect/mcp/install?name=vizro-mcp&config=%7B%22command%22%3A%22uvx%22%2C%22args%22%3A%5B%22vizro-mcp%22%5D%7D) |
|
|
76
|
+
|
|
77
|
+
</details>
|
|
78
|
+
|
|
79
|
+
<details>
|
|
80
|
+
<summary><strong>Quick setup for Vizro-MCP using Docker</strong></summary>
|
|
81
|
+
|
|
82
|
+
You must first install [Docker](https://www.docker.com/get-started/).
|
|
83
|
+
|
|
84
|
+
Next, add the following to the JSON file used to configure MCP servers for your LLM app.
|
|
85
|
+
|
|
86
|
+
```
|
|
87
|
+
{
|
|
88
|
+
"mcpServers": {
|
|
89
|
+
"vizro-mcp": {
|
|
90
|
+
"command": "docker",
|
|
91
|
+
"args": [
|
|
92
|
+
"run",
|
|
93
|
+
"-i",
|
|
94
|
+
"--rm",
|
|
95
|
+
"mcp/vizro"
|
|
96
|
+
]
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
**To use local data with Docker**
|
|
103
|
+
|
|
104
|
+
Mount your data directory or directories into the container with the following extended configuration. Replace `</absolute/path/to/allowed/dir>` (syntax for folders) or `</absolute/path/to/data.csv>` (syntax for files) with the absolute path to your data on your machine. For consistency, we recommend that the `dst` path matches the `src` path.
|
|
105
|
+
|
|
106
|
+
```
|
|
107
|
+
{
|
|
108
|
+
"mcpServers": {
|
|
109
|
+
"vizro-mcp": {
|
|
110
|
+
"command": "docker",
|
|
111
|
+
"args": [
|
|
112
|
+
"run",
|
|
113
|
+
"-i",
|
|
114
|
+
"--rm",
|
|
115
|
+
"--mount",
|
|
116
|
+
"type=bind,src=</absolute/path/to/allowed/dir>,dst=</absolute/path/to/allowed/dir>",
|
|
117
|
+
"--mount",
|
|
118
|
+
"type=bind,src=</absolute/path/to/data.csv>,dst=</absolute/path/to/data.csv>",
|
|
119
|
+
"mcp/vizro"
|
|
120
|
+
]
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
**Quick install**
|
|
127
|
+
|
|
128
|
+
| Host | Prerequisite | Link | Notes |
|
|
129
|
+
| ----------------------------------------- | --------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
|
|
130
|
+
| [Cursor](https://www.cursor.com/) | [Docker](https://www.docker.com/get-started/) | [](https://cursor.com/en/install-mcp?name=vizro-mcp&config=eyJjb21tYW5kIjoiZG9ja2VyIHJ1biAtaSAtLXJtIG1jcC92aXpybyIsImVudiI6e319) | For local data access, [mount your data directory](#setup-instructions) |
|
|
131
|
+
| [VS Code](https://code.visualstudio.com/) | [Docker](https://www.docker.com/get-started/) | [](https://insiders.vscode.dev/redirect/mcp/install?name=vizro-mcp&config=%7B%22command%22%3A%22docker%22%2C%22args%22%3A%5B%22run%22%2C%22-i%22%2C%22--rm%22%2C%22mcp%2Fvizro%22%5D%7D) | For local data access, [mount your data directory](#setup-instructions) |
|
|
132
|
+
|
|
133
|
+
</details>
|
|
134
|
+
|
|
135
|
+
## Disclaimers
|
|
136
|
+
|
|
137
|
+
### Transparency and trust
|
|
138
|
+
|
|
139
|
+
MCP servers are a relatively new concept, and it is important to be transparent about what the tools are capable of so you can make an informed choice as a user. Overall, the Vizro MCP server only reads data, and never writes, deletes or modifies any data on your machine.
|
|
140
|
+
|
|
141
|
+
### Third party API
|
|
142
|
+
|
|
143
|
+
Users are responsible for anything done via their host LLM application.
|
|
144
|
+
|
|
145
|
+
Users are responsible for procuring any and all rights necessary to access any third-party generative AI tools and for complying with any applicable terms or conditions thereof.
|
|
146
|
+
|
|
147
|
+
Users are wholly responsible for the use and security of the third-party generative AI tools and of Vizro.
|
|
148
|
+
|
|
149
|
+
### Legal information
|
|
150
|
+
|
|
151
|
+
<details>
|
|
152
|
+
<summary><strong>User acknowledgments</strong></summary>
|
|
153
|
+
|
|
154
|
+
Users acknowledge and agree that:
|
|
155
|
+
|
|
156
|
+
Any results, options, data, recommendations, analyses, code, or other information (“Outputs”) generated by any third-party generative AI tools (“GenAI Tools”) may contain some inaccuracies, biases, illegitimate, potentially infringing, or otherwise inappropriate content that may be mistaken, discriminatory, or misleading.
|
|
157
|
+
|
|
158
|
+
McKinsey & Company:
|
|
159
|
+
|
|
160
|
+
(i) expressly disclaims the accuracy, adequacy, timeliness, reliability, merchantability, fitness for a particular purpose, non-infringement, safety or completeness of any Outputs,
|
|
161
|
+
|
|
162
|
+
(ii) shall not be liable for any errors, omissions, or other defects in, delays or interruptions in such Outputs, or for any actions taken in reliance thereon, and
|
|
163
|
+
|
|
164
|
+
(iii) shall not be liable for any alleged violation or infringement of any right of any third party resulting from the users’ use of the GenAI Tools and the Outputs.
|
|
165
|
+
|
|
166
|
+
The Outputs shall be verified and validated by the users and shall not be used without human oversight and as a sole basis for making decisions impacting individuals.
|
|
167
|
+
|
|
168
|
+
Users remain solely responsible for the use of the Output, in particular, the users will need to determine the level of human oversight needed to be given the context and use case, as well as for informing the users’ personnel and other affected users about the nature of the GenAI Output. Users are also fully responsible for their decisions, actions, use of Vizro and Vizro-MCP and compliance with applicable laws, rules, and regulations, including but not limited to confirming that the Outputs do not infringe any third-party rights.
|
|
169
|
+
|
|
170
|
+
</details>
|
|
171
|
+
|
|
172
|
+
<details>
|
|
173
|
+
<summary><strong>Warning and safety usage for generative AI models</strong></summary>
|
|
174
|
+
|
|
175
|
+
Vizro-MCP is used by generative AI models because large language models (LLMs) represent significant advancements in the AI field. However, as with any powerful tool, there are potential risks associated with connecting to a generative AI model.
|
|
176
|
+
|
|
177
|
+
We recommend users research and understand the selected model before using Vizro-MCP. We also recommend users to check the MCP server code before using it.
|
|
178
|
+
|
|
179
|
+
Users are encouraged to treat AI-generated content as supplementary, always apply human judgment, approach with caution, review the relevant disclaimer page, and consider the following:
|
|
180
|
+
|
|
181
|
+
<ol>
|
|
182
|
+
<li>Hallucination and misrepresentation</li>
|
|
183
|
+
Generative models can potentially generate information while appearing factual, being entirely fictitious or misleading.
|
|
184
|
+
|
|
185
|
+
The vendor models might lack real-time knowledge or events beyond its last updates. Vizro-MCP output may vary and you should always verify critical information. It is the user's responsibility to discern the accuracy, consistent, and reliability of the generated content.
|
|
186
|
+
|
|
187
|
+
<li>Unintended and sensitive output</li>
|
|
188
|
+
The outputs from these models can be unexpected, inappropriate, or even harmful. Users as human in the loop is an essential part. Users must check and interpret the final output. It is necessary to approach the generated content with caution, especially when shared or applied in various contexts.
|
|
189
|
+
|
|
190
|
+
<li>Data privacy</li>
|
|
191
|
+
Your data is sent to model vendors if you connect to LLMs via their APIs. For example, if you connect to the model from OpenAI, your data will be sent to OpenAI via their API. Users should be cautious about sharing or inputting any personal or sensitive information.
|
|
192
|
+
|
|
193
|
+
<li>Bias and fairness</li>
|
|
194
|
+
Generative AI can exhibit biases present in their training data. Users need to be aware of and navigate potential biases in generated outputs and be cautious when interpreting the generated content.
|
|
195
|
+
|
|
196
|
+
<li>Malicious use</li>
|
|
197
|
+
These models can be exploited for various malicious activities. Users should be cautious about how and where they deploy and access such models.
|
|
198
|
+
</ol>
|
|
199
|
+
It's crucial for users to remain informed, cautious, and ethical in their applications.
|
|
200
|
+
|
|
201
|
+
</details>
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
<!-- <a href="https://glama.ai/mcp/servers/@mckinsey/vizro">
|
|
2
|
+
<img width="380" height="200" src="https://glama.ai/mcp/servers/@mckinsey/vizro/badge" />
|
|
3
|
+
</a> -->
|
|
4
|
+
|
|
5
|
+
# Vizro-MCP
|
|
6
|
+
|
|
7
|
+
Vizro-MCP is a [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server, which works alongside an LLM to help you create Vizro dashboards and charts.
|
|
8
|
+
|
|
9
|
+
<img src="docs/assets/images/vizro-mcp.gif" width="600" alt="Vizro-MCP Demo">
|
|
10
|
+
|
|
11
|
+
To find out more, consult the [Vizro-MCP documentation](https://vizro.readthedocs.io/projects/vizro-mcp/).
|
|
12
|
+
|
|
13
|
+
## Set up Vizro-MCP
|
|
14
|
+
|
|
15
|
+
Vizro-MCP is best used with Claude Desktop, Cursor or VS Code. However, it can be used with most LLM products that enable configuration of MCP server usage.
|
|
16
|
+
|
|
17
|
+
> 💡 Tip: For best performance, we recommend using the `claude-4-sonnet` model, or another high-performing model of your choice. Using the often offered `auto` setting may lead to inconsistent or unexpected results.
|
|
18
|
+
|
|
19
|
+
Our documentation offers separate, detailed steps for [Claude Desktop](https://vizro.readthedocs.io/projects/vizro-mcp/en/latest/pages/guides/set-up-vizro-mcp-with-claude/), [Cursor](https://vizro.readthedocs.io/projects/vizro-mcp/en/latest/pages/guides/set-up-vizro-mcp-with-cursor/) and [VS Code](https://vizro.readthedocs.io/projects/vizro-mcp/en/latest/pages/guides/set-up-vizro-mcp-with-vscode/).
|
|
20
|
+
|
|
21
|
+
### Basic configuration
|
|
22
|
+
|
|
23
|
+
The following is for those familiar with MCP server setup who are comfortable with basic configuration settings. You must have downloaded and installed the LLM app you want to configure and use as a MCP host.
|
|
24
|
+
|
|
25
|
+
<details>
|
|
26
|
+
<summary><strong>Quick setup for Vizro-MCP using uv</strong></summary>
|
|
27
|
+
|
|
28
|
+
You must first install [uv](https://docs.astral.sh/uv/getting-started/installation/).
|
|
29
|
+
|
|
30
|
+
Next, open a terminal window and type `uv` to confirm that is available. To get the path to `uvx`, type the following:
|
|
31
|
+
|
|
32
|
+
```shell
|
|
33
|
+
which uv
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Copy the path returned, and add the following to the JSON file used to configure MCP servers for your LLM app. Be sure to substitute your path to uv as returned above, for the placeholder given:
|
|
37
|
+
|
|
38
|
+
```
|
|
39
|
+
{
|
|
40
|
+
"mcpServers": {
|
|
41
|
+
"vizro-mcp": {
|
|
42
|
+
"command": "/placeholder-path/uvx",
|
|
43
|
+
"args": [
|
|
44
|
+
"vizro-mcp"
|
|
45
|
+
]
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
**Quick install**
|
|
52
|
+
|
|
53
|
+
| Host | Prerequisite | Link |
|
|
54
|
+
| ----------------------------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
55
|
+
| [Cursor](https://www.cursor.com/) | [uv](https://docs.astral.sh/uv/getting-started/installation/) | [](https://cursor.com/en/install-mcp?name=vizro-mcp&config=eyJjb21tYW5kIjoidXZ4IHZpenJvLW1jcCJ9) |
|
|
56
|
+
| [VS Code](https://code.visualstudio.com/) | [uv](https://docs.astral.sh/uv/guides/tools/) | [](https://insiders.vscode.dev/redirect/mcp/install?name=vizro-mcp&config=%7B%22command%22%3A%22uvx%22%2C%22args%22%3A%5B%22vizro-mcp%22%5D%7D) |
|
|
57
|
+
|
|
58
|
+
</details>
|
|
59
|
+
|
|
60
|
+
<details>
|
|
61
|
+
<summary><strong>Quick setup for Vizro-MCP using Docker</strong></summary>
|
|
62
|
+
|
|
63
|
+
You must first install [Docker](https://www.docker.com/get-started/).
|
|
64
|
+
|
|
65
|
+
Next, add the following to the JSON file used to configure MCP servers for your LLM app.
|
|
66
|
+
|
|
67
|
+
```
|
|
68
|
+
{
|
|
69
|
+
"mcpServers": {
|
|
70
|
+
"vizro-mcp": {
|
|
71
|
+
"command": "docker",
|
|
72
|
+
"args": [
|
|
73
|
+
"run",
|
|
74
|
+
"-i",
|
|
75
|
+
"--rm",
|
|
76
|
+
"mcp/vizro"
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
**To use local data with Docker**
|
|
84
|
+
|
|
85
|
+
Mount your data directory or directories into the container with the following extended configuration. Replace `</absolute/path/to/allowed/dir>` (syntax for folders) or `</absolute/path/to/data.csv>` (syntax for files) with the absolute path to your data on your machine. For consistency, we recommend that the `dst` path matches the `src` path.
|
|
86
|
+
|
|
87
|
+
```
|
|
88
|
+
{
|
|
89
|
+
"mcpServers": {
|
|
90
|
+
"vizro-mcp": {
|
|
91
|
+
"command": "docker",
|
|
92
|
+
"args": [
|
|
93
|
+
"run",
|
|
94
|
+
"-i",
|
|
95
|
+
"--rm",
|
|
96
|
+
"--mount",
|
|
97
|
+
"type=bind,src=</absolute/path/to/allowed/dir>,dst=</absolute/path/to/allowed/dir>",
|
|
98
|
+
"--mount",
|
|
99
|
+
"type=bind,src=</absolute/path/to/data.csv>,dst=</absolute/path/to/data.csv>",
|
|
100
|
+
"mcp/vizro"
|
|
101
|
+
]
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
**Quick install**
|
|
108
|
+
|
|
109
|
+
| Host | Prerequisite | Link | Notes |
|
|
110
|
+
| ----------------------------------------- | --------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
|
|
111
|
+
| [Cursor](https://www.cursor.com/) | [Docker](https://www.docker.com/get-started/) | [](https://cursor.com/en/install-mcp?name=vizro-mcp&config=eyJjb21tYW5kIjoiZG9ja2VyIHJ1biAtaSAtLXJtIG1jcC92aXpybyIsImVudiI6e319) | For local data access, [mount your data directory](#setup-instructions) |
|
|
112
|
+
| [VS Code](https://code.visualstudio.com/) | [Docker](https://www.docker.com/get-started/) | [](https://insiders.vscode.dev/redirect/mcp/install?name=vizro-mcp&config=%7B%22command%22%3A%22docker%22%2C%22args%22%3A%5B%22run%22%2C%22-i%22%2C%22--rm%22%2C%22mcp%2Fvizro%22%5D%7D) | For local data access, [mount your data directory](#setup-instructions) |
|
|
113
|
+
|
|
114
|
+
</details>
|
|
115
|
+
|
|
116
|
+
## Disclaimers
|
|
117
|
+
|
|
118
|
+
### Transparency and trust
|
|
119
|
+
|
|
120
|
+
MCP servers are a relatively new concept, and it is important to be transparent about what the tools are capable of so you can make an informed choice as a user. Overall, the Vizro MCP server only reads data, and never writes, deletes or modifies any data on your machine.
|
|
121
|
+
|
|
122
|
+
### Third party API
|
|
123
|
+
|
|
124
|
+
Users are responsible for anything done via their host LLM application.
|
|
125
|
+
|
|
126
|
+
Users are responsible for procuring any and all rights necessary to access any third-party generative AI tools and for complying with any applicable terms or conditions thereof.
|
|
127
|
+
|
|
128
|
+
Users are wholly responsible for the use and security of the third-party generative AI tools and of Vizro.
|
|
129
|
+
|
|
130
|
+
### Legal information
|
|
131
|
+
|
|
132
|
+
<details>
|
|
133
|
+
<summary><strong>User acknowledgments</strong></summary>
|
|
134
|
+
|
|
135
|
+
Users acknowledge and agree that:
|
|
136
|
+
|
|
137
|
+
Any results, options, data, recommendations, analyses, code, or other information (“Outputs”) generated by any third-party generative AI tools (“GenAI Tools”) may contain some inaccuracies, biases, illegitimate, potentially infringing, or otherwise inappropriate content that may be mistaken, discriminatory, or misleading.
|
|
138
|
+
|
|
139
|
+
McKinsey & Company:
|
|
140
|
+
|
|
141
|
+
(i) expressly disclaims the accuracy, adequacy, timeliness, reliability, merchantability, fitness for a particular purpose, non-infringement, safety or completeness of any Outputs,
|
|
142
|
+
|
|
143
|
+
(ii) shall not be liable for any errors, omissions, or other defects in, delays or interruptions in such Outputs, or for any actions taken in reliance thereon, and
|
|
144
|
+
|
|
145
|
+
(iii) shall not be liable for any alleged violation or infringement of any right of any third party resulting from the users’ use of the GenAI Tools and the Outputs.
|
|
146
|
+
|
|
147
|
+
The Outputs shall be verified and validated by the users and shall not be used without human oversight and as a sole basis for making decisions impacting individuals.
|
|
148
|
+
|
|
149
|
+
Users remain solely responsible for the use of the Output, in particular, the users will need to determine the level of human oversight needed to be given the context and use case, as well as for informing the users’ personnel and other affected users about the nature of the GenAI Output. Users are also fully responsible for their decisions, actions, use of Vizro and Vizro-MCP and compliance with applicable laws, rules, and regulations, including but not limited to confirming that the Outputs do not infringe any third-party rights.
|
|
150
|
+
|
|
151
|
+
</details>
|
|
152
|
+
|
|
153
|
+
<details>
|
|
154
|
+
<summary><strong>Warning and safety usage for generative AI models</strong></summary>
|
|
155
|
+
|
|
156
|
+
Vizro-MCP is used by generative AI models because large language models (LLMs) represent significant advancements in the AI field. However, as with any powerful tool, there are potential risks associated with connecting to a generative AI model.
|
|
157
|
+
|
|
158
|
+
We recommend users research and understand the selected model before using Vizro-MCP. We also recommend users to check the MCP server code before using it.
|
|
159
|
+
|
|
160
|
+
Users are encouraged to treat AI-generated content as supplementary, always apply human judgment, approach with caution, review the relevant disclaimer page, and consider the following:
|
|
161
|
+
|
|
162
|
+
<ol>
|
|
163
|
+
<li>Hallucination and misrepresentation</li>
|
|
164
|
+
Generative models can potentially generate information while appearing factual, being entirely fictitious or misleading.
|
|
165
|
+
|
|
166
|
+
The vendor models might lack real-time knowledge or events beyond its last updates. Vizro-MCP output may vary and you should always verify critical information. It is the user's responsibility to discern the accuracy, consistent, and reliability of the generated content.
|
|
167
|
+
|
|
168
|
+
<li>Unintended and sensitive output</li>
|
|
169
|
+
The outputs from these models can be unexpected, inappropriate, or even harmful. Users as human in the loop is an essential part. Users must check and interpret the final output. It is necessary to approach the generated content with caution, especially when shared or applied in various contexts.
|
|
170
|
+
|
|
171
|
+
<li>Data privacy</li>
|
|
172
|
+
Your data is sent to model vendors if you connect to LLMs via their APIs. For example, if you connect to the model from OpenAI, your data will be sent to OpenAI via their API. Users should be cautious about sharing or inputting any personal or sensitive information.
|
|
173
|
+
|
|
174
|
+
<li>Bias and fairness</li>
|
|
175
|
+
Generative AI can exhibit biases present in their training data. Users need to be aware of and navigate potential biases in generated outputs and be cautious when interpreting the generated content.
|
|
176
|
+
|
|
177
|
+
<li>Malicious use</li>
|
|
178
|
+
These models can be exploited for various malicious activities. Users should be cautious about how and where they deploy and access such models.
|
|
179
|
+
</ol>
|
|
180
|
+
It's crucial for users to remain informed, cautious, and ethical in their applications.
|
|
181
|
+
|
|
182
|
+
</details>
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
---
|
|
2
|
+
hide:
|
|
3
|
+
- navigation
|
|
4
|
+
- toc
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Vizro-MCP
|
|
8
|
+
|
|
9
|
+
Vizro-MCP is a [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server, which works alongside a LLM to help you create Vizro dashboards and charts.
|
|
10
|
+
|
|
11
|
+
<img src="./assets/images/vizro-mcp.gif" width="600" alt="Vizro-MCP Demo">
|
|
12
|
+
|
|
13
|
+
<div class="grid cards" markdown>
|
|
14
|
+
|
|
15
|
+
- :fontawesome-solid-wand-magic-sparkles:{ .lg .middle } __Benefits of Vizro-MCP__
|
|
16
|
+
|
|
17
|
+
- One consistent framework for charts and dashboards with one common design language.
|
|
18
|
+
|
|
19
|
+
- Validated config output that is readable and easy to alter or maintain.
|
|
20
|
+
|
|
21
|
+
- Live preview of the dashboard to iterate the design until the dashboard is perfect.
|
|
22
|
+
|
|
23
|
+
- Use of local or remote datasets simply by providing a path or URL.
|
|
24
|
+
|
|
25
|
+
- :fontawesome-solid-heart-crack:{ .lg .middle } __Without Vizro-MCP__
|
|
26
|
+
|
|
27
|
+
- Limited guidance, design principles, and consistency.
|
|
28
|
+
|
|
29
|
+
- Results tend to be a vibe-coded mess that may or may not run, but certainly is not very maintainable.
|
|
30
|
+
|
|
31
|
+
- No way to easily preview the dashboard.
|
|
32
|
+
|
|
33
|
+
- No easy way to connect to real data.
|
|
34
|
+
|
|
35
|
+
</div>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# API reference
|
|
2
|
+
|
|
3
|
+
The API reference serves mostly as a reference what tools are available to the model and what prompts are available to the user. The Vizro-MCP server works by allowing the LLM to call this set of carefully crafted tools. You will never call these tools directly, but this reference gives an overview over what these tools do and what the model will get as information when deciding which tool to call. Should your host not support tool calling, the usability of the MCP server is limited.
|
|
4
|
+
|
|
5
|
+
!!! note
|
|
6
|
+
The `validate_dashboard_config` tool opens a link to a live preview of the dashboard, which will take you to [PyCafe](https://py.cafe). If you don't want to open the link, you can tell the LLM to not do so.
|
|
7
|
+
|
|
8
|
+
The `load_and_analyze_data` tool loads a CSV file from a local path or URL into a pandas DataFrame and provides detailed analysis of its structure and content. It only uses `pd.read_xxx`, so in general there is no need to worry about privacy or data security. However, you should only run Vizro-MCP locally, not as a hosted server, because there is currently no authentication to manage access.
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
::: vizro_mcp.server
|
|
12
|
+
options:
|
|
13
|
+
filters:
|
|
14
|
+
- "!^Data"
|
|
15
|
+
- "!^Model"
|
|
16
|
+
- "!^Validate"
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Contribute to Vizro-MCP
|
|
2
|
+
|
|
3
|
+
We are always happy to receive contributions to [Vizro](https://github.com/mckinsey/vizro) and Vizro-MCP!
|
|
4
|
+
|
|
5
|
+
To contribute to Vizro-MCP you'll need to follow the same [contribution process as for the parent Vizro project](https://vizro.readthedocs.io/en/stable/pages/explanation/contributing/).
|
|
6
|
+
|
|
7
|
+
## How to use a developer build of Vizro-MCP
|
|
8
|
+
|
|
9
|
+
If you are a developer, or if you are running Vizro-MCP from source, you need to clone the [Vizro GitHub repository](https://github.com/mckinsey/vizro/tree/main).
|
|
10
|
+
|
|
11
|
+
To configure the Vizro-MCP server details:
|
|
12
|
+
|
|
13
|
+
Add the following to your MCP configuration:
|
|
14
|
+
|
|
15
|
+
```json
|
|
16
|
+
{
|
|
17
|
+
"mcpServers": {
|
|
18
|
+
"vizro-mcp": {
|
|
19
|
+
"command": "uv",
|
|
20
|
+
"args": [
|
|
21
|
+
"run",
|
|
22
|
+
"--directory",
|
|
23
|
+
"<PATH TO VIZRO>/vizro-mcp/",
|
|
24
|
+
"vizro-mcp"
|
|
25
|
+
]
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Replace `<PATH TO VIZRO>` with the actual path to the clone of the Vizro repository.
|
|
32
|
+
|
|
33
|
+
You may also need to provide the full path to your `uv` executable, so instead of `"uv"` you would use something like `"/Users/<your-username>/.local/bin/uv"`. To discover the path of `uv` on your machine, in your terminal app, type `which uv`.
|