Content
## This project is based on Xiaoge MCP implementation
Original project address: https://github.com/78/mcp-calculator
## Video demonstration
https://www.bilibili.com/video/BV1TpTNzbE3u/?vd_source=3cdb33659e80ec67cacea8b3ce284283
## Environment Requirements
- Python 3.7+
- websockets>=11.0.3
- python-dotenv>=1.0.0
- mcp>=1.8.1
- pydantic>=2.11.4
## Environment Setup
### Method 1: venv Environment (Recommended)
#### macOS/Linux Users
```bash
# Automatically set up the environment
./setup_venv.sh
# Activate the environment
./activate_venv.sh
# Or activate manually: source venv/bin/activate
# Run the project
python mcp_pipe.py yo_mcp.py
```
#### Windows Users
```cmd
# Automatically set up the environment
setup_venv.bat
# Activate the environment
activate_venv.bat
# Or activate manually: venv\Scripts\activate.bat
# Run the project
python mcp_pipe.py yo_mcp.py
```
### Method 2: conda Environment (Traditional Method)
```bash
# Create conda environment
conda create -n xiaozhi-mcp python=3.10
# Activate the environment
conda activate xiaozhi-mcp
# Install dependencies
pip install -r requirements.txt
```
> **💡 It is recommended to use the venv environment**: lighter, more standard, and faster to start.
>
> - For detailed instructions, please refer to [VENV_SETUP.md](VENV_SETUP.md)
> - Windows user-specific guide: [WINDOWS_GUIDE.md](WINDOWS_GUIDE.md)
## Configuration
After installing the dependencies, don't forget to create the .env file with the following content:
```bash
# Xiaozhi MCP MCP access point address
MCP_ENDPOINT = wss://api.xiaozhi.me/mcp/?token=xxx
# Visual recognition related configuration
# Whether to enable the IP camera MCP. If there is no camera, this configuration value should be false; otherwise, it should be true.
ENABLED_IP_CAMERA = false
# ONVIF camera IP address
ONVIF_CAMERA_IP = 192.168.10.143
# ONVIF camera port, the port for Tiandy camera is 80, modify according to your camera's port
ONVIF_CAMERA_PORT = 80
# ONVIF camera username
ONVIF_CAMERA_USERNAME = admin
# ONVIF camera password
ONVIF_CAMERA_PASSWORD = 123456
# Whether to enable ONVIF PTZ control (cameras with PTZ can be enabled; if not enabled, control registration will not be activated)
ONVIF_CAMERA_PTZ_ENABLED = false
# Whether to enable ONVIF camera recognition and save logs
ONVIF_CAMERA_LOG = false
# Whether to enable ONVIF screenshot saving to local
ONVIF_CAMERA_CAPTURE = false
# Home Assistant related configuration
# Home Assistant service address
HA_ADDRESS = http://192.168.1.197:8123
# Home Assistant access token
HA_AUTH_TOKEN = eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.xxxxxx
```
## Start
```bash
python mcp_pipe.py yo_mcp.py
```
# If you find this useful, don't forget to give it a star for support!
**Note!!!! Due to the control of PC devices and other functions being implemented based on MacOS, Windows users will need to modify it themselves.**
Connection Info
You Might Also Like
Git
Model Context Protocol Servers
TrendRadar
🎯 Say goodbye to information overload. AI helps you understand news hotspots...
repomix
📦 Repomix is a powerful tool that packs your entire repository into a...
Mastra
The TypeScript AI agent framework. ⚡ Assistants, RAG, observability....
Blender
BlenderMCP integrates Blender with Claude AI for enhanced 3D modeling.
cua
Open-source infrastructure for Computer-Use Agents. Sandboxes, SDKs, and...