Purpose
This repository provides an MCP (Model-Control-Protocol) server for bridging AI models with Trino data. Through this server, AI models can access data and tools in a Trino cluster in a standardized way.
Main Capabilities
- Provide the list of Trino tables as MCP resources.
- Read table contents through MCP.
- Provide a tool for executing arbitrary SQL queries.
Usage
The server is written in Python and relies on Trino's Python client (trino.dbapi) to connect to the Trino host, catalog, and schema. The runtime environment requires Python 3.9+ (or a version compatible with mcp, trino, and asyncio), and requires installing trino (Trino's Python driver) and mcp (the Model-Control-Protocol Python library). Trino connection details are read through environment variables.
Applicable Scenarios
Suitable for scenarios where AI models need to query and access Trino cluster data through the MCP protocol, such as data analysis, table structure exploration, and SQL query execution.
Limitations
The materials do not provide specific environment variable names, installation commands, configuration examples, or usage steps; this information is not currently provided.