MCP Playground

Một triển khai máy chủ MCP trình diễn bằng Go với tính năng giao tiếp tệp hai chiều thời gian thực.

GitHubDùng thử MCP nàyĐược tài trợ

Tài liệu

MCP Playground

A demonstration Model Context Protocol (MCP) server implementation in Go featuring real-time bidirectional file communication.

🎯 Features

  • Real-Time Communication: Bidirectional file-based communication with live notifications
  • MCP Resources: Live-updating resources with automatic change notifications
  • File Monitoring: External file changes detected and reported in real-time
  • Rich Tool Set: Complete set of tools for file interaction and monitoring

🚀 Quick Start

# Build the server
task build

# Start monitoring and interact with the file
task run

🔧 MCP Tools

  • start_file_monitoring - Start real-time file monitoring
  • write_to_file - Write messages to communication file
  • read_communication_file - Read current file contents
  • get_recent_changes - Get list of recent external changes
  • get_monitoring_status - Check monitoring status

📡 MCP Resources

  • file://communication - Live communication file with real-time updates

🧪 Testing

# Test real-time notifications
./test_realtime_resources.sh

# Test basic file monitoring  
./test_file_monitoring.sh

🔌 Claude Desktop Integration

Copy configuration to your Claude Desktop config:

{
  "mcpServers": {
    "mcp-playground": {
      "command": "/path/to/mcp-playground/bin/mcp-playground",
      "args": []
    }
  }
}

📖 How It Works

  1. Start monitoring with start_file_monitoring tool
  2. External changes to communication.txt are detected automatically
  3. Real-time notifications sent via MCP notifications/resources/updated
  4. Claude Desktop receives live updates and can react to external changes

Perfect for experimenting with MCP real-time capabilities! 🎪