serving-openmed-rest-api

Expose OpenMed clinical NER, PII extraction, and de-identification via a self-hosted FastAPI REST API.

5.0k|615|Updated Oct 4, 2025
One-click install
npx skills add https://github.com/maziyarpanahi/openmed --skill serving-openmed-rest-api
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: serving-openmed-rest-api
Source: https://github.com/maziyarpanahi/openmed/tree/main/skills/serving-openmed-rest-api
Command: npx skills add https://github.com/maziyarpanahi/openmed --skill serving-openmed-rest-api

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you expose OpenMed clinical NER, PII extraction, and de-identification as a self-hosted HTTP service without sending sensitive patient data to the cloud.

Core Features & Use Cases

  • FastAPI REST service: Launch OpenMed inference endpoints for clinical text analysis and structured entity extraction.
  • Privacy-preserving de-identification: Detect and mask, remove, replace, hash, or shift dates for 55+ PHI types on infrastructure you control.
  • Production operations: Configure model preloading, keep-alive behavior, resident model limits, dynamic batching, health checks, and model unloading.
  • Use Case: Deploy an internal service that receives clinical notes from approved applications, returns NER or de-identified results, and remains protected behind your organization's authentication, TLS, and CORS controls.

Quick Start

Install the OpenMed service extra, launch the FastAPI application with Uvicorn, and call its health, analysis, extraction, or de-identification endpoints over HTTP.

Frequently Asked Questions about serving-openmed-rest-api

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deploy a self-hosted REST API for clinical de-identification?

You can deploy a self-hosted REST API for clinical de-identification by launching the OpenMed FastAPI service with Uvicorn to process clinical notes and mask PHI internally without cloud dependency.

What PHI types can a FastAPI de-identification service detect and mask?

A FastAPI de-identification service can detect and process over 55 PHI types, allowing you to mask, remove, replace, hash, or shift dates for sensitive patient data within your own infrastructure.

Can I configure dynamic batching and model preloading for clinical NER inference?

Yes, you can configure dynamic batching, model preloading, keep-alive behavior, and resident model limits for clinical NER inference to optimize throughput and manage the model lifecycle effectively.

How do I add health checks and model lifecycle management to a FastAPI model serving application?

You add health checks and model lifecycle management by utilizing the production operations features included with the OpenMed FastAPI service, which support health endpoints, model unloading, and strict request schemas.

Does the OpenMed REST API prevent protected health information from leaking in error responses?

Yes, the OpenMed REST API implements no-PHI error handling, ensuring that strict request schemas and error responses do not expose sensitive patient data during clinical text analysis or extraction failures.