mcpField
C

cookwith-mcp

本地服务
github.com/blaideinc健康医疗059 周前更新

关于 cookwith-mcp

cookwith-mcp 是用于生成食谱并按饮食和营养要求改编现有食谱的 MCP 服务,面向需要通过自然语言调用食谱工具的烹饪应用和助手。

主要功能

  1. 01根据文本提示生成食谱
  2. 02改编现有食谱
  3. 03考虑过敏和饮食限制
  4. 04设定热量与蛋白质目标
  5. 05调整份数

适用场景

  1. 01按指定饮食要求生成晚餐食谱
  2. 02修改食谱以避开过敏原
  3. 03调整餐食份数
  4. 04按营养目标改编食谱

MCP 相关

向 MCP 客户端提供食谱生成和改编工具。工具可接收自然语言请求,以及食谱、饮食限制、份数和营养目标等参数。

配置

本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。

暂未收录安装方式

我们还没有获取到这个服务的安装包或远程地址,请按项目 README 中的说明安装。

代码仓库

工具

还没有获取到工具列表

本地服务需要在你的电脑上运行后才能读取工具,维护者暂未提供工具列表。

详细介绍

Cookwith MCP 服务

一个 MCP(Model Context Protocol)服务,使用 Cookwith 的先进烹饪 AI 提供 AI 驱动的食谱生成与转换工具。

功能

  • 食谱生成:根据自然语言描述创建定制食谱
  • 食谱转换:根据饮食需求、份数或其他要求修改现有食谱
  • 饮食支持:处理过敏、饮食限制和营养目标
  • 智能调整:调整热量、蛋白质目标和份数

安装

通过 MCP Registry
npx @modelcontextprotocol/create-server install @cookwith/mcp-server
通过 npm
npm install -g @cookwith/mcp-server
用于 Claude Desktop

将以下内容添加到 Claude Desktop 配置中:

macOS:~/Library/Application Support/Claude/claude_desktop_config.json Windows:%APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "cookwith": {
      "command": "npx",
      "args": ["@cookwith/mcp-server"]
    }
  }
}

可用工具

generate_recipe

根据自然语言指令生成新食谱。

参数:

  • prompt(string,必填):对所需食谱的自然语言描述
  • dietaryRestrictions(array):饮食限制(例如,素食、纯素、无麸质)
  • allergies(array):因过敏而需避免的食材
  • dislikes(array):用户不喜欢的食物
  • calories(string):每份的目标热量
  • protein(string):每份的目标蛋白质克数
  • servings(number):份数(1-20,默认值:4)

示例:

{
  "prompt": "A healthy pasta dish with lots of vegetables",
  "dietaryRestrictions": ["vegetarian"],
  "calories": "500",
  "servings": 2
}
transform_recipe

根据指令转换或修改现有食谱。

参数:

  • recipe(object,必填):要转换的食谱
    • title(string):食谱标题
    • description(string):食谱描述
    • ingredients(array):食材列表
    • instructions(array):烹饪说明
    • servings(number):份数
    • 其他营养、用时等可选字段
  • instructions(string,必填):如何转换食谱
  • calories(string):每份新的目标热量
  • protein(string):每份新的目标蛋白质
  • servings(number):新的份数

示例:

{
  "recipe": {
    "title": "Classic Spaghetti Carbonara",
    "description": "Traditional Italian pasta dish",
    "ingredients": ["400g spaghetti", "200g guanciale", "4 eggs", "100g pecorino"],
    "instructions": ["Cook pasta", "Fry guanciale", "Mix eggs and cheese", "Combine"],
    "servings": 4
  },
  "instructions": "Make it vegetarian and reduce calories",
  "calories": "400"
}

使用示例

使用 Claude

配置完成后,你可以使用自然语言与这些工具交互:

"Generate a healthy dinner recipe for 2 people with chicken and vegetables, around 500 calories per serving"

"Transform this pasta recipe to be gluten-free and dairy-free"
编程方式使用
import { Client } from '@modelcontextprotocol/sdk';

const client = new Client({
  name: 'my-app',
  version: '1.0.0'
});

await client.connect('npx', ['@cookwith/mcp-server']);

// Generate a recipe
const result = await client.callTool('generate_recipe', {
  prompt: 'Quick and healthy breakfast',
  calories: '350',
  servings: 1
});

开发

从源代码构建
git clone https://github.com/blaideinc/cookwith-mcp
cd cookwith-mcp
npm install
npm run build
本地运行
npm start
测试
npm test

API 端点

也可以通过 HTTP 访问 MCP 服务:

  • 生产环境:https://cookwith.co/api/mcp
  • 开发环境:http://localhost:3000/api/mcp

许可证

MIT

支持

关于 Cookwith

Cookwith 是一个 AI 驱动的烹饪平台,可根据你的偏好、饮食限制和口味特点生成个性化食谱。了解更多信息,请访问 cookwith.co。

评论

支持 Markdown

第一次接触 MCP?

从协议是什么,到在客户端里装上第一个服务,这几条回答覆盖了大多数入门问题。

一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。