Skip to main content

mcp-numpy

An MCP server that exposes NumPy functionality

PyPI Python Coverage Ruff

Install

pip install mcp-numpy

Usage

As an MCP Server

To use with Claude Desktop or other MCP clients, add to your mcp.json:

{
  "mcpServers": {
    "mcp-numpy": {
      "command": "mcp-numpy"
    }
  }
}

Available Tools

The server exposes the following NumPy functionality as MCP tools:

Array Creation

  • np_array - Create a NumPy array
  • np_zeros - Create zeros array
  • np_ones - Create ones array
  • np_full - Create array filled with value
  • np_arange - Create array with range
  • np_linspace - Create evenly spaced array
  • np_eye - Create identity matrix
  • np_diag - Create diagonal array

Array Manipulation

  • np_reshape - Reshape array
  • np_transpose - Transpose array
  • np_concatenate - Concatenate arrays
  • np_split - Split array
  • np_tile - Tile array
  • np_repeat - Repeat elements
  • np_squeeze - Remove single-dimensional entries
  • np_flatten - Flatten array

Mathematical Operations

  • np_sum, np_mean, np_std, np_var - Summary statistics
  • np_min, np_max, np_argmin, np_argmax - Min/max operations
  • np_dot, np_matmul, np_cross - Matrix operations
  • np_trace, np_cumsum, np_cumprod, np_diff - Array operations

Linear Algebra

  • np_inv - Matrix inverse
  • np_det - Matrix determinant
  • np_eig - Eigenvalues and eigenvectors
  • np_svd - Singular value decomposition
  • np_solve - Solve linear system
  • np_linalg_norm - Matrix/vector norm

Random

  • np_rand - Random floats
  • np_randn - Random normal
  • np_randint - Random integers
  • np_random_choice - Random choice
  • np_shuffle - Shuffle array

Statistics

  • np_percentile, np_quantile - Percentiles/quantiles
  • np_histogram - Histogram
  • np_correlate, np_corrcoef - Correlation

Element-wise Math

  • np_add, np_subtract, np_multiply, np_divide - Arithmetic
  • np_power, np_mod - Power and modulo
  • np_sqrt, np_abs - Basic math
  • np_exp, np_log, np_log10 - Logarithms
  • np_sin, np_cos, np_tan - Trigonometry
  • np_arcsin, np_arccos, np_arctan - Inverse trig
  • np_sinh, np_cosh, np_tanh - Hyperbolic

Array Properties

  • np_shape, np_ndim, np_size, np_dtype - Properties
  • npastype - Type conversion

Development

git clone https://github.com/daedalus/mcp-numpy.git
cd mcp-numpy
pip install -e ".[test]"

# run tests
pytest

# format
ruff format src/ tests/

# lint
ruff check src/ tests/

# type check
mypy src/

mcp-name: io.github.daedalus/mcp-numpy

Metadata

Release files for mcp-numpy 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mcp-numpy 0.1.0
File Size Uploaded
mcp_numpy-0.1.0.tar.gz 9.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for mcp-numpy 0.1.0
File Interpreter ABI Platform
mcp_numpy-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.5 kB

Release files / mcp_numpy-0.1.0.tar.gz

Download URL mcp_numpy-0.1.0.tar.gz
Size 9.9 kB
Tags Source
SHA-256 checksum
How to use checksums
981ac4ce24eb3b4b0747573898cb676d474556c4586859711992a112b0e3b81e
BLAKE2b-256 checksum
How to use checksums
886e80736d5c8017daa8b7dcbf7d51b27c55ae5c3ce316d182125ec033fc3f88
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 30, 2026.

Transparency log

Release files / mcp_numpy-0.1.0-py3-none-any.whl

Download URL mcp_numpy-0.1.0-py3-none-any.whl
Size 10.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
45127f8649c407d91fa1db2daee75ec8be4c9f12539c6b2786b9be83bb25acac
BLAKE2b-256 checksum
How to use checksums
cc4158aeda71a65e7f55251f0a2cfe65bae1e54e73b02a80409fe24e9f7335bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 30, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page