mcp-mad-lucky
使用 Model Context Protocol (MCP) 构建 Monad 链上 AI 彩票预测市场,旨在推动大规模应用。
(目前仅为概念验证,代码尚未达到生产环境标准)
项目完成后,用户只需输入以下命令:
help me buy 100 mon ticket for AI-STRATEGY-100 pool
help me get the result of AI-STRATEGY-100 pool
help me get the history of AI-STRATEGY-100 pool
help me get my account balance
AI 将协助用户进行彩票投注并获取结果。
什么是 MCP?
Model Context Protocol (MCP) 是一种允许 AI 模型与外部工具和服务交互的标准协议。
前置条件
- Node.js (v16 或更高版本)
npm
或yarn
- Claude Desktop
快速开始
- 克隆本仓库
- 安装依赖:
- 在
.env
文件中配置私钥
构建 MCP 服务器
Monad 测试网相关配置已添加到
src
文件夹中的 index.ts
文件。定义服务器实例
定义工具
bet-lottery
工具的框架:get-lottery-result
工具的框架:get-lottery-history
工具的框架:get-account-balance
工具的框架:从 main
函数初始化传输和服务器
(开发中)
构建项目
服务器现已准备就绪!
将 MCP 服务器添加到 Claude Desktop
- 打开 "Claude Desktop"
/static/1.png
- 打开设置
Claude > Settings > Developer
/static/claude_settings.gif
- 打开
claude_desktop_config.json
/static/config.gif
- 添加 MCP 服务器详细信息并保存文件。
- 重启 "Claude Desktop"
使用 MCP 服务器
尚未达到生产环境标准
更多资源
- Author:waytomcp
- URL:https://www.waytomcp.com/article/vimday/mcp-mad-lucky
- Copyright:All articles in this blog, except for special statements, adopt BY-NC-SA agreement. Please indicate the source!