diff --git a/docs/user-guide/MCP/mcp_connectivity.md b/docs/user-guide/MCP/mcp_connectivity.md new file mode 100644 index 0000000..fcf21a7 --- /dev/null +++ b/docs/user-guide/MCP/mcp_connectivity.md @@ -0,0 +1,43 @@ +# MCP Connectivity Overview + +This directory provides examples and configuration files to help you connect MCP servers with Datu. +Datu uses the [mcp-use](https://github.com/mcp-use/mcp-use) package to implement MCP clients and manage connectivity. + + +## Purpose + +With Datu, you can connect to your MCP servers and use their tools through the Datu AI Analyst. + +## Enabling MCP Servers + +To enable MCP connectivity, set the following environment variable (see also [configurations.md](../configurations.md)): + +```sh +export DATU_ENABLE_MCP=true +``` + +Alternatively, add it to your .env file: + +```sh +DATU_ENABLE_MCP=true +``` + + +### Connecting MCP Servers + +MCP servers are defined in a JSON configuration file (e.g. mcp_config.json). +Each server entry specifies the command, arguments, and environment needed to start it. + +**Structure of mcp_config.json** + +```sh +{ + "mcpServers": { + "sql_generator": { + "command": "python", + "args": ["-m", "datu.mcp.tools.sql_generator"], + "env": { "PYTHONPATH": "." } + } + } +} +``` diff --git a/mkdocs.yml b/mkdocs.yml index e465be1..9ee1f8c 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -56,12 +56,8 @@ nav: - user-guide/configurations.md - Deploy: - Container service: user-guide/deploy/deploy_as_container_service.md - - MCP Connectivity: - - user-guide/MCP Connectivity/mcp_connectivity.md - - Contribute ❤️: https://github.com/Datuanalytics/datu-core/blob/main/CONTRIBUTING.md - - - + - MCP: + - user-guide/MCP/mcp_connectivity.md - Architecture: - Overview: architecture/README.md - Contribute ❤️: https://github.com/Datuanalytics/datu-core/blob/main/CONTRIBUTING.md