MCP server for X-ray spectroscopy analysis via xraylarch
Wellknown found it in public sources; nobody has proven control of it yet. Claiming takes one click if the repository is under your GitHub account, or a small file on your domain otherwise. Verified owners get the badge, 15-minute checks, status alerts, edits that outrank crawled data, and a ranking boost.
Agents can do it too: POST https://wellknown.network/api/v1/claims with {"agent":"xraylarch-mcp","method":"well_known_file"} — machine-readable steps at claim.json, guide at /docs/claim.
Everything here was measured by our prober or read from a registry. Nothing is self-reported.
Attributed to the source that supplied each field. Treated as claims, not facts.
# xraylarch-mcp MCP (Model Context Protocol) server that wraps [xraylarch](https://xraypy.github.io/xraylarch/) for X-ray spectroscopy analysis. Load, process, analyze, and plot XAS/XAFS spectra through Claude Desktop or Claude Code with natural language tool calls. Supports XANES normalization, EXAFS extraction, Fourier transforms, linear combination fitting, PCA, FEFFIT shell fitting, and publication-quality plotting. ## Installation ```bash pip install xraylarch-mcp ``` ## Configuration ### Claude Desktop Add to your Claude Desktop configuration (`claude_desktop_config.json`): ```json { "mcpServers": { "xraylarch": { "command": "python", "args": ["-m", "xraylarch_mcp"] } } } ``` ### Claude Code ```bash claude mcp add xraylarch -- python -m xraylarch_mcp ``` ## Quick Start Ask Claude: > "Load the spectrum at ~/data/fe_foil.xdi and show me the normalized XANES" Claude will: 1. Call `larch_load_spectrum` to read your data 2. Call `larch_normalize` to perform pre-edge subtraction and normalization 3. Call `larch_plot` with `plot_type="norm"` to generate a publication-quality plot ## Tool Reference ### I/O Tools | Tool | Description | |------|-------------| | `larch_load_spectrum` | Load a spectrum from file (.xdi, .dat, .csv, .prj, etc.) | | `larch_read_athena_project` | Read/inspect Athena project files | | `larch_list_groups` | List all loaded spectrum groups | | `larch_inspect_group` | Detailed view of a group's arrays and scalars | | `larch_remove_group` | Remove a group to free memory | ### XAFS Analysis Tools | Tool | Description | |------|-------------| | `larch_normalize` | Pre-edge subtraction and normalization (wraps `pre_edge`) | | `larch_autobk` | EXAFS background removal (AUTOBK algorithm) | | `larch_xftf` | Forward Fourier transform: chi(k) -> chi(R) | | `larch_xftr` | Back Fourier transform: chi(R) -> chi(q) | | `larch_fluo_corr` | Fluorescence se…
Mapped onto the structured taxonomy from declared text and observed tool names. Confidence shown for derived entries.
Every source is kept verbatim. Field changes are logged as events.