MCPLite

by acesanderson

208 downloads Not rated yet
GitHub

About

MCPLite is a lightweight, pythonic implementation of the Model Context Protocol (MCP) for integrating external tools and data sources into LLM applications. It provides a decorator-based API inspired by FastAPI to turn any Python function into an MCP tool, resource, or prompt…

Explore

mcp = MCPLite(transport="direct")

@mcp.tool
def web_search(query: str, limit: int = 3) -> str:
"""Search the web and return results."""

host = Host(model="gpt-4", servers=["fetch", "filesystem"])

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name MCPLite
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

from MCPLite import MCPLite

pip install pydantic rich chain-of-thought beautifulsoup4 markdownify

mcp = MCPLite(transport="direct")

@mcp.tool
def web_search(query: str, limit: int = 3) -> str:
"""Search the web and return results."""

bash

pip install pydantic rich

python -m MCPLite.servers.fetch
```

result = host.agent_query(
"What's the weather in San Francisco and find recent news about AI?"
)

response = host.agent_query(
"Read the README.md file and summarize the project structure"
)
```

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "mcplite": {
            "MCPLite": {
                "command": "python",
                "args": [
                    "my_server.py"
                ]
            }
        }
    }
}

McpServers

{
    "MCPLite": {
        "command": "python",
        "args": [
            "my_server.py"
        ]
    }
}

Build Status
License
Python

A lightweight, pythonic implementation of the Model Context Protocol (MCP) for seamless integration of external tools and data sources into LLM applications.

MCPLite provides everything you need to build, connect, and orchestrate MCP servers with a clean, decorator-based API inspired by FastAPI. Turn any Python function into an MCP tool, resource, or prompt with just a decorator.

Quick Start

```python
from MCPLite import MCPLite

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.