huangzesen avatar

HelioSPICE

huangzesen/heliospice

This wraps NASA's SPICE ephemeris toolkit for heliophysics missions, handling kernel downloads and caching automatically. You get position, velocity, and trajectory queries for spacecraft like Parker Solar Probe, Solar Orbiter, and Voyager through get_ephemeris, plus coordinate transforms between frames like ECLIPJ2000, GSE, and RTN. It returns structured data as Python dicts or pandas DataFrames with distance in AU and velocity vectors. Reach for this when you need accurate spacecraft positions for mission planning or analysis without manually managing NAIF kernel files. The MCP layer exposes compute_distance for relative positioning and manage_kernels for cache control.

tools
6
transport
STDIO
last updated
Mar 10, 2026

Tools

6 tools

Public tool metadata for what this MCP can expose to an agent.

get_ephemerisPosition/velocity — single time (inline) or timeseries (CSV)

Position/velocity — single time (inline) or timeseries (CSV)

No parameter schema in public metadata yet.

compute_distanceDistance between two bodies

Distance between two bodies

No parameter schema in public metadata yet.

transform_coordinatesCoordinate frame transform

Coordinate frame transform

No parameter schema in public metadata yet.

list_spice_missionsSupported missions

Supported missions

No parameter schema in public metadata yet.

list_coordinate_framesAvailable frames with descriptions

Available frames with descriptions

No parameter schema in public metadata yet.

manage_kernelsKernel cache management

Kernel cache management

No parameter schema in public metadata yet.

Sponsors

Readme

xhelio-spice

Spacecraft ephemeris made easy — auto-managed SPICE kernels for heliophysics missions.

xhelio-spice wraps SpiceyPy with automatic kernel download, caching, and loading. Ask for a spacecraft position and xhelio-spice handles the rest: downloading the right NAIF kernels, loading them in the correct order, and returning results as Python dicts or pandas DataFrames.

Installation

pip install xhelio-spice

For MCP server support (Claude Desktop, Claude Code, Cursor, etc.):

pip install xhelio-spice[mcp]

Quick Start

from xhelio_spice import get_position, get_trajectory

# Where is Parker Solar Probe right now?
pos = get_position("PSP", observer="SUN", time="2024-01-15", frame="ECLIPJ2000")
print(f"PSP is {pos['r_au']:.3f} AU from the Sun")

# Get a month of trajectory data as a DataFrame
df = get_trajectory(
    "PSP", observer="SUN",
    time_start="2024-01-01", time_end="2024-01-31",
    step="1h", frame="ECLIPJ2000",
)
print(df[["r_au"]].describe())

View the full README on GitHub

Details

Repository
github.com/huangzesen/heliospice
Package
heliospice
Transport
STDIO
Registry
MCP registry, active

More from huangzesen