Cal Server 是一个基于 FastMCP 框架构建的简单数学表达式计算服务,使用 Bun 运行时环境。它利用 expr-eval 库解析和计算用户输入的数学表达式,并通过标准输入输出(stdio)与外界交互。该项目旨在提供一个轻量、高效的计算工具,支持基本数学运算和内置常量。 - 表达式计算:支持用户输入数学表达式并返回计算结果。 - E:Bun 环境中的 Math.E。 - PI:Bun 环境中的 Math.PI。 - true:逻辑真值。 - false:逻辑假值。 - 工具名称:cal。 - 参数:接受一个字符串类型的数学表达式(exp)。 - fastmcp:用于构建 MCP 服务。 - expr-eval:用于解析和计算数学表达式。 - zod:用于参数验证。 - 确保已安装 Bun 运行时(推荐最新版本)。 To install cal-mcp for Claude D
Add this skill
npx mdskills install pwh-pwh/cal-mcpLightweight math expression calculator with clear documentation and multiple installation options
Cal Server 是一个基于 FastMCP 框架构建的简单数学表达式计算服务,使用 Bun 运行时环境。它利用 expr-eval 库解析和计算用户输入的数学表达式,并通过标准输入输出(stdio)与外界交互。该项目旨在提供一个轻量、高效的计算工具,支持基本数学运算和内置常量。
E:Bun 环境中的 Math.E。PI:Bun 环境中的 Math.PI。true:逻辑真值。false:逻辑假值。cal。exp)。fastmcp:用于构建 MCP 服务。expr-eval:用于解析和计算数学表达式。zod:用于参数验证。To install cal-mcp for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install @pwh-pwh/cal-mcp --client claude
"cal-mcp": {
"name": "计算",
"description": "",
"isActive": true,
"command": "bunx",
"args": [
"cal-mcp"
]
}
git clone
bun install
启动服务:
bun run index.ts
服务将通过标准输入输出(stdio)运行。
输入数学表达式:
2 + 3 * PI支持的表达式示例:
2 + 2 → 4PI * 2 → 6.283185307179586E ^ 2 + 1 → 8.38905609893065stdio 交互。Install via CLI
npx mdskills install pwh-pwh/cal-mcpCal Server is a free, open-source AI agent skill. Cal Server 是一个基于 FastMCP 框架构建的简单数学表达式计算服务,使用 Bun 运行时环境。它利用 expr-eval 库解析和计算用户输入的数学表达式,并通过标准输入输出(stdio)与外界交互。该项目旨在提供一个轻量、高效的计算工具,支持基本数学运算和内置常量。 - 表达式计算:支持用户输入数学表达式并返回计算结果。 - E:Bun 环境中的 Math.E。 - PI:Bun 环境中的 Math.PI。 - true:逻辑真值。 - false:逻辑假值。 - 工具名称:cal。 - 参数:接受一个字符串类型的数学表达式(exp)。 - fastmcp:用于构建 MCP 服务。 - expr-eval:用于解析和计算数学表达式。 - zod:用于参数验证。 - 确保已安装 Bun 运行时(推荐最新版本)。 To install cal-mcp for Claude D
Install Cal Server with a single command:
npx mdskills install pwh-pwh/cal-mcpThis downloads the skill files into your project and your AI agent picks them up automatically.
Cal Server works with Claude Code, Claude Desktop, Cursor, Vscode Copilot, Windsurf, Continue Dev, Gemini Cli, Amp, Roo Code, Goose. Skills use the open SKILL.md format which is compatible with any AI coding agent that reads markdown instructions.