WG

weinaike/galaxy_morphology_mcp

Developer tools

This page was translated automatically. Technical details may differ from the original. View the original

7 stars 6 forks Quality 70 Trend 35

Galaxy Morphology Tools MCP Server

Overview

一个用于星系形态学分析的 MCP (Model Context Protocol) 服务器,封装了 GALFIT 和 GalfitS 工具,支持单波段和多波段星系图像拟合与分析。同时提供基于 FastAPI + Celery 的 HTTP 服务接口,支持异步任务提交。 - optimized_fits_file: 包含原始数据、模型和残差的 FITS 文件 - image_file: 2×3 科学对比图(行0:低/高动态范围原图 \| 模型;行1:全场残差/σ \| 残差放大 \| 1D 表面亮度剖面) - summary_file: Markdown 格式的拟合参数摘要 - summary_files: .gssummary 拟合摘要文件 - imagefit_pngs: 多波段图像拟合对比图 - sedmodel_pngs: SED (光谱能量分布) 模型图 - result_fits: 最佳拟合 FITS 结果文件 除 MCP 协议外,还提供基于 FastAPI + Celery 的 HTTP 服务,支持异步拟合任务提交: - POST /api/fitting/ — 提交拟合任务(支持 image fitting / pure sed fitting / image sed fitting 三种模式) - GET /api/fitting-status/{task_id} — 查询任务状态 - GET /health — MCP 服务健康检查 - GET /api/tools — 列出当前可用的 MCP 工具 - Python >= 3.10 - GALFIT(用于单波段拟合,可选) - GalfitS(用于多波段拟合,可选) 服务包含两个容器: - : Web 服务 (端口 8000),负责任务提交和状态查询 - : 异步任务 Worker,执行后台拟合计算 - :创建 .env 文件(参考 .env.example),服务启动时自动加载。 - :优先在 .mcp.json 的 env 字段中配置环境变量,无需 .env 文件。

Install

This server does not publish a one-line install command.

Open the repository installation guide New to MCP? Start with the mcpskill.org guide →

Configuration

{ "mcpServers": { "galmcp": { "command": "python", "args": [ "src/mcp_server.py", "--transport", "stdio" ], "env": { "GALFIT_BIN": "/usr/bin/galfit", "GALFITS_BIN": "python /path/to/GalfitS/src/galfits/galfitS.py", "GS_DATA_PATH": "/path/to/GalfitS", "OPENAI_API_KEY": "your-apikey", "OPENAI_BASE_URL": "https://open.bigmodel.cn/api/coding/paas/v4", "OPENAI_MODEL": "glm-4.6v", "ANALYSIS_MODE": "vlm", "CLAUDECODE_API_KEY": "your-anthropic-apikey", "CLAUDECODE_BASE_URL": "", "CLAUDECODE_MODEL": "gemini-3-flash-preview" } } } }