Medical Calculator MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| DEBUG | No | Enable debug mode | false |
| SSL_DIR | No | SSL cert directory (Docker only) | ./nginx/ssl |
| MCP_HOST | No | Host to bind | 0.0.0.0 |
| MCP_MODE | No | Transport mode (stdio, sse, http) | stdio |
| MCP_PORT | No | Port to bind | 8000 |
| LOG_LEVEL | No | Logging level | INFO |
| SSL_ENABLED | No | Enable SSL/TLS | false |
| SSL_KEYFILE | No | Path to SSL private key file | |
| CORS_ORIGINS | No | CORS origins | * |
| SSL_CA_CERTS | No | Path to CA certificates (optional) | |
| SSL_CERTFILE | No | Path to SSL certificate file | |
| SECURITY_API_KEYS | No | Comma-separated API keys | |
| SECURITY_AUTH_PARAM | No | Query param name | api_key |
| SECURITY_AUTH_HEADER | No | Header name | X-API-Key |
| SECURITY_AUTH_ENABLED | No | Enable API authentication | false |
| SECURITY_RATE_LIMIT_RPM | No | Requests per minute | 60 |
| SECURITY_RATE_LIMIT_BURST | No | Burst size | 10 |
| SECURITY_RATE_LIMIT_BY_IP | No | Per-IP rate limiting | true |
| SECURITY_RATE_LIMIT_ENABLED | No | Enable rate limiting | false |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| discoverA | 🔍 統一的工具發現入口 (High-Level) 幫助 Agent 找到合適的醫學計算器。支援多種發現模式。 Args: by: 發現模式 - "all": 列出所有分類 (專科和臨床情境) - 預設 - "specialty": 依專科篩選工具 - "context": 依臨床情境篩選工具 - "keyword": 關鍵字搜尋 - "tools": 列出所有工具 value: 篩選值 (當 by 不是 "all" 或 "tools" 時必填) limit: 最多回傳幾個結果 Returns: 根據模式返回不同內容: - all: 可用的專科和情境清單 - specialty/context: 該分類下的工具清單 - keyword: 匹配的工具清單 - tools: 所有工具清單 Examples: 規則:
⏭️ 下一步: 找到工具後,使用 get_tool_schema(tool_id) 查看參數 |
| get_related_toolsA | 🔗 取得相關工具 (High-Level 語義發現) 基於共享參數和專科自動發現相關工具。 純 Python 算法,無 ML 依賴。 Args: tool_id: 工具 ID limit: 最多回傳幾個相關工具 Returns: 相關工具清單及相似度分數 Example: 💡 相關性基於: 共享參數、相同專科、相同臨床情境 |
| find_tools_by_paramsA | 🔍 根據已有參數找工具 (High-Level 反向查找) 「我有這些數值,可以計算什麼?」 Args: params: 參數名稱列表 Examples: ["creatinine", "age", "weight"] ["gcs", "pupil", "motor"] ["bilirubin", "inr", "ascites"] Returns: 可使用這些參數的工具清單 Example: 💡 適合場景: 已有病患數據,想知道能計算哪些評分 |
| calculateA | 🧮 通用醫學計算工具 使用指定的計算器執行計算。支援所有 75+ 種醫學計算器。 使用流程:
嚴格規則:
Args: tool_id: 計算器 ID (例如: "sofa", "apache_ii", "ckd_epi_2021") params: 計算參數字典 (從 get_tool_schema 取得參數名稱) Returns: 計算結果,包含: - success: 是否成功 - score_name: 評分名稱 - result: 計算結果 (分數或數值) - unit: 單位 - interpretation: 臨床解讀 - references: 參考文獻 Examples: Example 1 - SOFA Score: Example 2 - CKD-EPI 2021: Example 3 - RCRI (Revised Cardiac Risk Index): 常用計算器:
⏮️ 上一步: get_tool_schema(tool_id) 查看完整參數說明 |
| calculate_batchA | 🧮 批次計算多個工具 - 減少 round-trip,提高效率 一次執行多個計算,並提供結果間的事實關係分析。 適合需要同時評估多個指標的臨床情境。 Args: calculations: 計算請求列表,每個元素包含: - tool_id: 計算器 ID - params: 參數字典 Returns: - results: 各計算的結果 - summary: 結果摘要 - cross_analysis: 結果間的事實關係 (非臨床推理) - all_success: 是否全部成功 Example - Sepsis 評估: Cross-analysis 提供的事實判斷 (非推理):
💡 這不是臨床建議,只是根據指引標準的事實陳述 |
| get_tool_schemaA | 📋 取得工具完整資訊 + 參數 Schema + 來源提示 (Low-Level) 整併了原本的 get_calculator_info 和 get_calculation_schema, 提供 Agent 執行計算所需的所有資訊:
Args: tool_id: 計算器 ID (從 discover() 取得) include_references: 是否包含參考文獻 (預設 True) - True: 包含完整參考文獻 (citation, PMID, DOI) - False: 省略以節省 tokens include_param_sources: 是否包含參數來源提示 (預設 True) - True: 包含 clinical_hint, common_sources, normal_range - False: 只返回基本 type/unit Returns: 完整的工具資訊,包含: - tool_id, name, purpose - specialties, contexts (High-Level 分類) - required_params (必要參數列表) - param_schemas (每個參數的詳細 Schema) - references (參考文獻,若 include_references=True) Example: ⏭️ 下一步: calculate(tool_id, params) 執行計算 |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| tool_usage_playbook | Tool Usage Playbook - 小模型工具使用作戰手冊 A strict operating playbook for smaller or less capable models. |
| sepsis_evaluation | Sepsis Evaluation Workflow - 敗血症評估工作流程 A structured approach to evaluate patients with suspected sepsis using Sepsis-3 criteria. |
| preoperative_risk_assessment | Preoperative Risk Assessment Workflow - 術前風險評估工作流程 A structured approach to evaluate surgical risk before non-cardiac surgery. |
| icu_daily_assessment | ICU Daily Assessment Workflow - 加護病房每日評估工作流程 A structured approach for daily ICU patient rounds. |
| pediatric_drug_dosing | Pediatric Drug Dosing Workflow - 兒科藥物劑量工作流程 A structured approach for safe pediatric medication dosing. |
| acute_kidney_injury_assessment | Acute Kidney Injury Assessment Workflow - 急性腎損傷評估工作流程 A structured approach to evaluate and stage acute kidney injury. |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| get_tool_usage_playbook_resource | Get the recommended start-here SOP for smaller models. |
| get_calculator_list | Get list of all available calculators |
TDQS
Scored across 6 tools
The three discovery tools (discover, find_tools_by_params, get_related_tools) have distinct primary intents—categorical discovery, reverse parameter lookup, and similarity-based relatedness—but they could still be confused in edge cases, especially discover(by='keyword') versus find_tools_by_params. The calculation tools are clearly distinct.
All names use snake_case and imperative verbs, which is consistent, but the pattern is not uniformly verb_noun: 'discover' and 'calculate' are bare verbs while others have objects. This is a minor deviation rather than a chaotic mix.
Six tools is well-scoped for a meta-server wrapping 75+ calculator implementations. The surface is kept small by exposing discovery, schema retrieval, single calculation, and batch calculation rather than one tool per calculator.
The server covers the full workflow: discover available tools, inspect required schemas, run single or batch calculations, and find alternative/related calculators. Since calculators are static and read-only, no update/delete operations are expected. The tool set leaves no obvious dead ends.