
Thermo Orbitrap (Instrument API)
io.github.K-Dense-AI由 GitHub 帳號 K-Dense-AI 發布v0.1.1更新於 Oct 27, 2026
MCP server adapter for Thermo Fisher Orbitrap mass spectrometers via the licensed Instrument API.
概覽
此轉接器讓 AI 助理在 Windows 儀器電腦上,透過 Thermo 授權的 Instrument API 監控並操控 Thermo Fisher Orbitrap 質譜儀。
- 可以做什麼
- 查看連線資訊、儀器模式、真空度、授權與安全上限
- 讀取最近的掃描(MS 階數、前驅離子 m/z、注入時間、最強質心),並等待下一次掃描
- 列出儀器可接受的掃描參數
- 送出經驗證的自訂掃描,設定或取消重複掃描
- 啟動、暫停、繼續、停止採集至 raw 檔,斷電後可重新連線
- 檢視原始指令日誌,並可將掃描質心匯出為新的 CSV 檔
- 適用情境
- 適用於在 Windows 儀器電腦上執行受支援 Orbitrap(Tribrid、Exploris 240/480、Q Exactive)且已取得 Thermo 簽署 IAPI 授權的實驗室,希望助理即時查看掃描或送出掃描、執行採集。內建模擬器可在沒有硬體時試用。
- 執行需求
- 需在 Windows 儀器電腦安裝 Python 3.10+ 與 windows 附加套件(pythonnet)、安裝 Tune、取得並套用 Thermo 簽署的 IAPI 授權,並將 IAPI 組件放入指定資料夾。以儀器型號、assembly_dir 等選項設定,另可選用環境變數 LABMCP_ADDRESS、LABMCP_LIMITS、LABMCP_READ_ONLY、LABMCP_SIMULATE。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Thermo Orbitrap (Instrument API),將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Thermo Orbitrap (Instrument API): MCP Server
Let an AI agent watch and steer a Thermo Fisher Orbitrap mass spectrometer in real time: check the instrument mode and vacuum, read the scans streaming off the instrument (filtered by MS order, with the most intense centroids), place validated custom scans and pick up their results, set a repeating scan, and start, pause or stop acquisitions to a raw file. It does this through Thermo's own Instrument API (IAPI).
[!IMPORTANT] This is an adapter. It contains no Thermo software. The IAPI is a Windows .NET API. To use it you need a signed IAPI software licence agreement with Thermo Fisher Scientific, with the licence applied to your instrument (legal requirements, licence FAQ, how to obtain a licence). This package never bundles or downloads the IAPI assemblies: you point it at the ones you obtained. It has never been tested on real hardware. Everything below was developed against the official IAPI interface definitions and examples and a simulator.
Try it without hardware
The simulator is an Orbitrap Exploris 480 by default (--option sim_model=eclipse or qexactive-hf for the others). It runs a synthetic tryptic digest: MS1 survey scans in On mode, a data-dependent top-10 method during an acquisition, custom and repeating scans that come back with their access id, realistic transient and injection times, and a status log with vacuum readings every ~5 s.
Connect your instrument
On the Windows instrument PC, with Tune installed and your IAPI licence applied:
- Get the IAPI assemblies that come with your licence (for a Tribrid:
API-2.0.dll,Spectrum-1.0.dll,Thermo.TNG.Factory.dllandFusion.API-2.0.dllfor Tune 4.3 orFusion.API-1.0.dllfor Tune 4.2 and earlier). Put them in a folder, e.g.C:\IAPI. - Install Python 3.10+ and the server with pythonnet:
- Test the connection (the instrument family picks the connection recipe from the IAPI examples):
The server gives a specific message if it is not running on Windows, pythonnet is missing, the folder or an assembly is missing, the IAPI service does not connect (Tune not running), or IAPI refuses a command for lack of a licence.
Other options: readbacks=Name1;Name2 (instrument values to show in get_instrument_status; the tool lists the names your instrument exposes), exclusive_scans=true (exclusive rather than cooperative IScans access), runtime=coreclr, connect_timeout_s, buffer_size (scans kept in memory, default 500).
Add to your MCP client
Add --read-only to let the agent watch scans and status but not place scans or start acquisitions. The stop and cancel tools stay available. To reach the server from another computer, run it with --transport http --host 0.0.0.0 --port 8000 on the instrument PC and protect that port.
Tools
get_connection_info, get_command_log and reconnect are built into every LabMCP server. Every IAPI control call (with the exact scan values sent) is recorded in the command log.
Safety limits
Override at launch: --limit max_custom_scans_per_minute=600.
On top of these limits, every custom and repeating scan value is checked against the instrument's own IScans.PossibleParameters before anything is sent: the parameter name must exist, numbers must lie inside the instrument's range (for example the m/z range for FirstMass/LastMass), and choice parameters such as OrbitrapResolution must be one of the allowed values. IAPI itself silently ignores illegal values, which is why the server checks first, and why accepted values are sent in the instrument's own spelling (hcd goes out as HCD, 2.0 for an integer parameter as 2).
stop_acquisition attempts every step (cancel the acquisition, the custom scans, the repeating scan, Standby) even if one fails, and reports what failed.
Example prompts
- "Is the Orbitrap in On mode and what are the vacuum readings? How many scans came in during the last minute?"
- "Show me the last 5 MS2 scans with their precursor m/z, injection times and top 10 fragments."
- "Place a 120k SIM scan on m/z 524.26 with a 10 m/z window and tell me the most intense peaks you see."
- "Start a 30-minute acquisition to D:\Data\HeLa_test.raw with sample name HeLa 200 ng, then check every few minutes that MS2 scans are still arriving."
Notes
- Instrument mode: scans only arrive in On mode, and custom scans and acquisitions need it too.
stop_acquisition(standby=true)switches to Standby. This server has no tool to switch back to On (do that in Tune). - Custom scans: values you leave out come from the instrument's defaults, as Thermo documents for
IScanDefinition.Values.running_numbercomes back as the scan'saccess_id(trailer itemAccess Id:). The server numbers scans automatically if you don't. A custom scan usually finishes before the agent's next tool call, sowait_for_scan(access_id=...)also returns a result that arrived after the scan was placed but before the wait started. IAPI leaves the result undefined when several custom scans are placed before the instrument has processed the earlier ones; the rate limit keeps this under control. - Parameter names differ by model and Tune version (e.g.
Analyzeron Tribrids). Useget_possible_scan_parametersand pass anything that has no named argument throughextra_parameters. - Scan headers:
scan_number,ms_order,scan_modeandprecursor_mzcome from header keys used in Thermo's examples (Scan,MSOrder,ScanMode,PrecursorMass[0]).master_scan_number,agc_targetandinjection_time_msare read from the trailer names Thermo raw files use (Master Scan Number:,AGC Target:,Ion Injection Time (ms):). The IAPI repository doesn't document these, so they may benullon your instrument. Useinclude_header_trailer=trueto see exactly what it sends. - Readbacks: IAPI has no fixed list of readback names (vacuum gauges, voltages).
get_instrument_statusshows the names fromIInstrumentValues.ValueNamesand the latest scanStatusLog, where the vacuum readings usually appear. - Licence check: on Exploris instruments the server reports whether an API licence is present (
IExplorisInstrumentAccess.Licenses). Tribrid and Exactive instruments enforce the licence in the instrument service, and a refused command reports it. - Verified API surface: every IAPI member the pythonnet backend touches is listed with its source file in
iapi_members.py(checked against thermofisherlsms/iapi@c246dcc). A test fails if the backend uses a name that isn't in that list. - Scan data: each scan's .NET object is copied and disposed at once, as Thermo's examples require (otherwise the instrument's shared memory stays blocked). Up to 5 000 centroids per scan are kept.
max_centroidslimits what a tool returns, andget_recent_scans(save_path=...)writes all kept centroids to a new CSV file (the path must end in.csvand must not exist yet: existing files are never overwritten).
Hardware verification
來源:servers/chemistry/thermo-iapi/README.md,提交 46545ea
工具
0版本歷史
1- v0.1.1最新Sep 27, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分