RN

royerlab/napari-mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

47 stars 7 forks 质量 65 趋势 0BSD-3-Clause

Royerlab/NAPARI-MCP 是从 https://github.com/royerlab/napari-mcp. 导入的 MCP 服务器候选。

概览

Royerlab/NAPARI-MCP 是从 https://github.com/royerlab/napari-mcp. 导入的 MCP 服务器候选。

概述(AI 翻译)

MCP服务器,通过模型上下文协议(MCP)远程控制napari观察器。非常适合AI辅助显微镜分析,配合Claude Desktop及其他大型语言模型应用。

https://github.com/user-attachments/assets/d261674c-9875-4671-8c60-a7f49d6f1b84

🚀 快速入门(3步)

1.安装该软件包

2.自动配置你的人工智能应用

3.重启你的应用并开始使用

重启你的AI应用,你就准备好了!试着问:

→ 详见完整文档获取详细指南

🔌 作为 napari 插件使用

Napari-MCP 也可以作为 NAPARI 插件,直接集成到正在运行的 Napari 会话:

  1. 正常开始 napari: napari
  2. 打开小部件:napari-mcp 插件→ MCP 服务器控制
  3. 点击“启动服务器” 以向 AI 助手展示当前会话
  4. **使用标准安装程序连接你的AI应用:napari-mcp-install install

该模式使 AI 助手能够控制你当前的 napari 会话,而不是重新开启一个新的查看器。非常适合与现有工作流程整合!

→ 详见插件指南获取详细说明

🎯 你能做什么?

基础图像分析

高级工作流程

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Napari MCP Server

MCP server for remote control of napari viewers via Model Context Protocol (MCP). Perfect for AI-assisted microscopy analysis with Claude Desktop and other LLM applications.

https://github.com/user-attachments/assets/d261674c-9875-4671-8c60-a7f49d6f1b84

🚀 Quick Start (3 Steps)

1. Install the Package

pip install napari-mcp

2. Auto-Configure Your AI Application

# For Claude Desktop
napari-mcp-install install claude-desktop

# Include a napari GUI backend in the uv environment
napari-mcp-install install claude-desktop --backend pyqt6

# For other applications (Claude Code, Cursor, Cline, etc.)
napari-mcp-install install --help  # See all options

3. Restart Your Application & Start Using

Restart your AI app and you’re ready! Try asking:

"Can you call session_information() to show my napari session details?"

→ See Full Documentation for detailed guides

🔌 Using as a napari Plugin

napari-mcp can also be used as a napari plugin for direct integration with a running napari session:

  1. Start napari normally: napari
  2. Open the widget: Plugins → napari-mcp: MCP Server Control
  3. Click “Start Server” to expose your current session to AI assistants
  4. Connect your AI app using the standard installer: napari-mcp-install install

This mode enables AI assistants to control your current napari session rather than starting a new viewer. Perfect for integrating with existing workflows!

→ See Plugin Guide for detailed instructions

🎯 What Can You Do?

Basic Image Analysis

"Load the image from ./data/sample.tif and apply a viridis colormap"
"Create point annotations at coordinates [[100,100], [200,200]]"
"Take a screenshot and save it"

Advanced Workflows

"Execute this code to create a filtered version:
from scipy import ndimage
filtered = ndimage.gaussian_filter(viewer.layers[0].data, sigma=2)
viewer.add_image(filtered, name='filtered')"

"Install scikit-image and segment the cells in this microscopy image"

3D/4D Navigation

"Switch to 3D display mode"
"Navigate to time point 5, Z-slice 10"
"Create a rotating animation of this volume"

Automated Workflows

在 GitHub 查看完整 README

安装

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

Open the repository installation guide 新手?先看 mcpskill.org 教程 →