
A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

A Python AST-based safe expression calculator MCP service supporting basic math operations and error protection.
Calculator MCP Server is cataloged as an MCP server attributed to xiaoyingv. A Python AST-based safe expression calculator MCP service supporting basic math operations and error protection. It is categorized under developer tools. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.
Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.
Catalog license label: MIT License. Check the source repository's current license and terms before using, modifying or distributing this software.
Capability definitions are not reviewed. Unreviewed imports are not exposed as trusted interfaces.
No reviewed records to display. This does not establish that upstream lacks this capability.
No reviewed records to display. This does not establish that upstream lacks this capability.
No reviewed records to display. This does not establish that upstream lacks this capability.
Email delivery is not connected. This page does not collect email addresses or create subscriptions.
Browse the registry for current listings instead.
Reviews for Calculator MCP Server are not available yet
Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.
It parses expressions with Python's AST instead of using eval.
It returns a division-by-zero error message instead of a result.
README.md · 33730ac72699 · Fetched 2026-11-13 10:41:03 UTC
Original upstream text, without AI rewriting. Scripts, forms and unsafe links are filtered for safety.
Showing the last retrieved documentation snapshot; check the source for current changes.
基于 Python AST 的安全表达式计算器 MCP 服务,支持基础数学运算和错误防护机制。
+, -, *, /)**)+5, -3)eval)pip install mcp-calculate-server
from mcp.server.fastmcp import FastMCP
# 启动计算器服务
calculator = FastMCP("CalculatorServer")
calculator.run(transport='stdio')
perform_calculation(expression: str) -> str接收数学表达式字符串,返回格式化结果或错误信息
>>> perform_calculation("5+3")
"🧮 计算结果:5+3 = 8"
>>> perform_calculation("10/3")
"🧮 计算结果:10/3 = 3.333333333333333"
>>> perform_calculation("10**20")
"🧮 计算结果:10**20 = 100000000000000000000"
>>> perform_calculation("2**3")
"🧮 计算结果:2**3 = 8"
>>> perform_calculation("10/0")
"❌ 错误:除数不能为零"
>>> perform_calculation("0**-1")
"❌ 错误:零的负数次幂未定义"
>>> perform_calculation("(-1)**0.5")
"❌ 错误:负数的非整数次幂未定义"
| 操作符 | 说明 | 示例 |
|---|---|---|
| + | 加法 | 3+4 |
| - | 减法 | 5-2 |
| * | 乘法 | 6*7 |
| / | 除法 | 8/2 |
| ** | 幂运算 | 2**3 |
| -x | 取负 | -5 |
| +x | 取正 | +3 |
| 错误类型 | 示例输出 |
|---|---|
| 语法错误 | ❌ 表达式语法错误:unexpected EOF |
| 不支持的运算符 | ❌ 不支持的运算符:Mod |
| 除零错误 | ❌ 错误:除数不能为零 |
| 非法操作数类型 | TypeError: 不支持的常量类型 |
| 零的负数次幂 | ❌ 错误:零的负数次幂未定义 |
| 负数的非整数次幂 | ❌ 错误:负数的非整数次幂未定义 |
mcp-server 库(自动安装)MIT License,详情见 LICENSE
GitHub: https://github.com/xiaoyingv/mcp_calculate_server
欢迎提交 PR 和报告 issue,提交前请阅读 CONTRIBUTING.md
Claim this server with your GitHub account to request manual ownership verification.
Link to the catalog listing for Calculator MCP Server from your README. This badge does not certify ownership, compatibility or security.
[](https://awesome-mcp.com/servers/mcp-calculate-server-xiaoyingv)Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.
Separate sources, scopes and periods. Never combined or treated as installations, active users or security reviews.
No reviewed package or image identity; download statistics are not listed yet.
Alternative and complementary servers in the same category

A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

A hosted MCP service for browsing and searching through Singapore mobile-network proxies.

A directory listing describing a Markdown-to-PDF service. The configured public GitHub repository returned 404 during source verification.