Math MCP Learning

io.github.clouatre-labs由 GitHub 帳號 clouatre-labs 發布v0.12.5更新於 Oct 24, 2026

Educational MCP server with 17 math/stats tools, visualizations, and persistent workspace

已驗證Streamable HTTP可網頁執行資料與分析AI 與機器學習

概覽

AI 產生的概覽

一個教育用途的數學伺服器,為助理提供 17 個工具,用於計算、統計、矩陣、單位換算、繪圖和持久工作區。

可以做什麼
計算運算式、統計量、複利和單位換算(長度、重量、溫度)。執行矩陣運算:乘法、轉置、行列式、反矩陣和特徵值。產生函數圖、直方圖、折線圖、散佈圖、箱型圖以及合成的金融價格走勢圖。在持久工作區中儲存和讀取計算結果,並提供工作區摘要、歷史、函數、常數和變數等資源。提供輔導和公式講解提示。
適用情境
適合教學、作業輔導或需要助理進行數值計算、單位換算、矩陣運算或產生圖表的場景,無需依賴外部服務。託管端點適合不想在本機安裝的使用者。
執行需求
可使用託管的 HTTP 端點,或透過 uvx 從 PyPI 套件 math-mcp-learning-server 在本機安裝。繪圖工具需要 matplotlib,因此需安裝繪圖或科學計算附加元件。未宣告驗證、API 金鑰或環境變數。
安裝前請注意
工作區工具會把計算結果寫入重新啟動後仍保留的持久儲存,避免儲存敏感資料。金融繪圖工具只產生合成資料,並非真實市場資料。運算式求值使用帶白名單的受限 eval,但本質上仍是求值器。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Math MCP Learning,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.clouatre-labs%2Fmath-mcp-learning-server/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。

{
  "mcpServers": {
    "math-learning": {
      "type": "http",
      "url": "https://math-mcp.fastmcp.app/mcp"
    }
  }
}

README

math-mcp-learning-server

[PyPI] [Python] [License] [REUSE] [OpenSSF Best Practices]

Educational MCP server with 17 tools, persistent workspace, and cloud hosting. Built with FastMCP and the official Model Context Protocol Python SDK.

Available on the MCP Registry (io.github.clouatre-labs/math-mcp-learning-server) and PyPI.

Demo

[math-mcp Demo]

See CONTRIBUTING.md for instructions to record your own demo.

Quick Start

Cloud (No Installation)

Connect your MCP client to the hosted server:

Claude Desktop (claude_desktop_config.json):

json
{  "mcpServers": {    "math-cloud": {      "transport": "http",      "url": "https://math-mcp.fastmcp.app/mcp"    }  }}

Local Installation

json
{  "mcpServers": {    "math": {      "command": "uvx",      "args": ["math-mcp-learning-server[scientific,plotting]"]    }  }}

For other installation options (basic, scientific-only, plotting-only), see CONTRIBUTING.md.

Tools

CategoryToolDescription
Workspaceworkspace_saveSave calculations to persistent storage
workspace_loadRetrieve previously saved calculations
Mathcalc_expressionSafely evaluate mathematical expressions
calc_statisticsStatistical analysis (mean, median, mode, std_dev, variance)
calc_interestCalculate compound interest for investments
calc_unitsConvert between units (length, weight, temperature)
Matrixmatrix_multiplyMultiply two matrices
matrix_transposeTranspose a matrix
matrix_determinantCalculate matrix determinant
matrix_inverseCalculate matrix inverse
matrix_eigenvaluesCalculate eigenvalues
Visualizationplot_functionPlot mathematical functions
plot_histogramCreate statistical histograms
plot_line_chartCreate line charts
plot_scatterCreate scatter plots
plot_box_plotCreate box plots
plot_financial_lineCreate financial line charts

Resources

  • math://workspace - Persistent calculation workspace summary
  • math://history - Chronological calculation history
  • math://functions - Available mathematical functions reference
  • math://constants/{constant} - Mathematical constants (pi, e, golden_ratio, etc.)
  • math://catalog/tools - Tool catalog with metadata and usage examples
  • math://variables - Active variables in the current workspace
  • math://test - Server health check

Prompts

  • math_tutor - Structured tutoring prompts (configurable difficulty)
  • formula_explainer - Formula explanation with step-by-step breakdowns

See Usage Examples for detailed examples.

Development

See CONTRIBUTING.md for development setup, testing, and contribution guidelines.

Security

  • OpenSSF Best Practices Silver - Fewer than 1% of open source projects reach this level
  • REUSE/SPDX - License compliance for all files
  • Signed Commits - GPG-signed commits required
  • Dependency Scanning - Automated updates via Renovate
  • pip-audit CVE Scanning - Automated dependency vulnerability checks
  • gitleaks Secret Scanning - Detects secrets in code and history
  • zizmor GitHub Actions Security - Workflow security scanning
  • commitlint Enforcement - Conventional commit validation in CI
  • OpenSSF Scorecard - Continuous open source security assessment
calc_expression safety

The calc_expression tool uses restricted eval() with a whitelist of allowed characters and functions, restricted global scope (only math module and abs), and no access to dangerous built-ins or imports. All tool inputs are validated with Pydantic models. File operations are restricted to the designated workspace directory. Complete type hints and validation are enforced for all operations.

Documentation

來源:README.md,提交 4ceaf7d

工具

17

calc_expression

Mathematical Calculator

Safely evaluate mathematical expressions with support for basic operations and math functions. Supported operations: +, -, *, /, **, () Supported functions: sin, cos, tan, log, sqrt, abs, pow

輸入參數expression必填

calc_statistics

Statistical Analysis

Perform statistical calculations on a list of numbers. Available operations: mean, median, mode, std_dev, variance

輸入參數numbers必填operation必填

calc_interest

Compound Interest Calculator

Calculate compound interest for investments. Formula: A = P(1 + r/n)^(nt) Where: - P = principal amount - r = annual interest rate (as decimal) - n = number of times interest compounds per year - t = time in years

輸入參數rate必填time必填principal必填compounds_per_year

calc_units

Unit Converter

Convert between different units of measurement. Supported unit types: - length: mm, cm, m, km, in, ft, yd, mi - weight: g, kg, oz, lb - temperature: c, f, k (Celsius, Fahrenheit, Kelvin)

輸入參數value必填to_unit必填from_unit必填unit_type必填

matrix_multiply

Matrix Multiplication

Multiply two matrices (A × B).

輸入參數matrix_a必填matrix_b必填

matrix_transpose

Matrix Transpose

Transpose a matrix (swap rows and columns).

輸入參數matrix必填

matrix_determinant

Matrix Determinant

Calculate the determinant of a square matrix.

輸入參數matrix必填

matrix_inverse

Matrix Inverse

Calculate the inverse of a square matrix.

輸入參數matrix必填

matrix_eigenvalues

Matrix Eigenvalues

Calculate the eigenvalues of a square matrix.

輸入參數matrix必填

workspace_save

Save Calculation to Workspace

Save calculation to persistent workspace (survives restarts).

輸入參數name必填result必填expression必填

workspace_load

Load Variable

Load previously saved calculation result from workspace.

輸入參數name必填

plot_function

Function Plotter

Generate mathematical function plots (requires matplotlib).

輸入參數x_range必填expression必填num_points

plot_histogram

Statistical Histogram

Create statistical histograms (requires matplotlib).

輸入參數binsdata必填title

plot_line_chart

Line Chart

Create a line chart from data points (requires matplotlib).

輸入參數colortitlex_data必填y_data必填x_labely_labelshow_grid

plot_scatter

Scatter Plot

Create a scatter plot from data points (requires matplotlib).

輸入參數colortitlex_data必填y_data必填x_labely_labelpoint_size

plot_box_plot

Box Plot

Create a box plot for comparing distributions (requires matplotlib).

輸入參數colortitley_labeldata_groups必填group_labels

plot_financial_line

Financial Line Chart

Generate and plot synthetic financial price data (requires matplotlib). Creates realistic price movement patterns for educational purposes. Does not use real market data.

輸入參數dayscolortrendstart_price

版本歷史

1
  1. v0.12.5最新Sep 16, 2026

評分

已滿足適用檢查項的 90%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

    請在儲存庫或註冊中心條目中宣告授權條款。