Agent skill · Data & Analytics

batch-processing-clinical-text

Run large-scale batch NER, PII extraction, or de-identification over many clinical notes on-device with OpenMed, with sharding, checkpointing, resumability, and append-only JSONL output. Use when the user needs to process a corpus or folder of notes, de-identify a dataset, run NER over thousands of documents, build a resumable batch pipeline, or stream results to JSONL without holding everything in memory. Covers process_batch / BatchProcessor / BatchItem / BatchResult, the operation= selector (analyze_text | extract_pii | deidentify), iter_process streaming, the PHI-safe on_progress callback,

maziyarpanahigithub.com/maziyarpanahiGitHub ↗
claude-codeApache-2.0
Install
npx skills add maziyarpanahi/openmed --skill batch-processing-clinical-text --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 9 KB
Bundled scripts: none
Version: 1.0
Path: skills/batch-processing-clinical-text/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 4,851
Language: Python
Read our review of the source →

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Batch processing clinical text `openmed.processing` runs OpenMed over many documents efficiently, with progress tracking, per-item error isolation, and streaming. It runs **fully on-device**: the corpus, the model, and the output never leave the host. This skill shows a **resumable** runner — sharded, checkpointed, append-only JSONL — that you can restart without reprocessing. ## When to use this skill For corpora, folders, or datasets — anything beyond a handful of notes. For a single note, just call `openmed.analyze_text` / `deidentify` directly (`extracting-clinical-entities`, `deidentifying-clinical-text`). For an always-on HTTP service, see `serving-openmed-rest-api`. ## Quick start ```python from openmed import process_batch texts = ["Patient has type 2 diabetes.", "No acute distress. BP 120/80."] result = process_batch(texts, model_name="disease_detection_superclinical") print(result.summary()) # PHI-safe counts + timing print(result.successful_items, "/", result.total_items) for item in result.get_successful_results(): print(item.id, item.result.to_dict()["entities"]) # spans only; avoid raw text in logs ``` `process_batch(...)` is a thin wrapper over `BatchProcessor`. Re

What's inside
Steps it walks through
  1. When to use this skill
  2. Quick start
  3. Choosing the operation
  4. Streaming + PHI-safe progress
  5. Workflow
  6. A resumable batch runner
  7. Chunking long documents
  8. Hand-off to / from OpenMed
  9. Edge cases & gotchas
  10. Standards & references
More from openmed
All skills →
About this skill
What does the batch-processing-clinical-text skill do?

Run large-scale batch NER, PII extraction, or de-identification over many clinical notes on-device with OpenMed, with sharding, checkpointing, resumability, and append-only JSONL output. Use when the user needs to process a corpus or folder of notes, de-identify a dataset, run NER over thousands of documents, build a resumable batch pipeline, or stream results to JSONL without holding everything in memory. Covers process_batch / BatchProcessor / BatchItem / BatchResult, the operation= selector (analyze_text | extract_pii | deidentify), iter_process streaming, the PHI-safe on_progress callback,

How do I install it?

Run `npx skills add maziyarpanahi/openmed --skill batch-processing-clinical-text --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From maziyarpanahi/openmed, a repository with 4,851 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going