1---2name: clinical-note-summarization3description: <!--4---5<!--6# COPYRIGHT NOTICE7# This file is part of the "Universal Biomedical Skills" project.8# Copyright (c) 2026 MD BABU MIA, PhD <md.babu.mia@mssm.edu>9# All Rights Reserved.10#11# This code is proprietary and confidential.12# Unauthorized copying of this file, via any medium is strictly prohibited.13#14# Provenance: Authenticated by MD BABU MIA1516-->1718---19name: clinical-note-summarization20description: Structure raw clinical notes into SOAP-format summaries with explicit contradictions, missing data, and ICD-linked assessments using the provided prompt + usage script.21allowed-tools:22 - read_file23 - run_shell_command24---2526## At-a-Glance27- **description (10-20 chars):** SOAP builder28- **keywords:** clinical-notes, SOAP, guardrails, ICD10, gaps29- **measurable_outcome:** Produce SOAP markdown + JSON (when requested) covering all four sections with ≥95% note coverage and explicit missing info in ≤2 minutes per note.3031## Inputs32- `note_text` (dictation, OCR, or EHR export) and optional `patient_context` metadata.33- `output_format` (`markdown` default, `json` when downstream validators need schema).3435## Outputs361. Structured SOAP summary with Subjective/Objective/Assessment/Plan bulleting.372. Alerts plus missing-information checklist.383. Optional JSON payload using schema from README.3940## Workflow411. **Load system prompt:** `prompt.md` enforces no hallucinations + data gap surfacing.422. **Normalize input:** Pre-clean vitals, labs, and timeline context when available.433. **Generate summary:** Call preferred LLM (OpenAI, Anthropic, Gemini, OSS) using `usage.py` as a template.444. **Validate:** Cross-check extracted values vs. source text and ensure contradictions/missing data are spelled out.455. **Deliver output:** Provide markdown + JSON as required and log PHI handling steps.4647## Guardrails48- Never invent findings; state "not provided" explicitly.49- Mark outputs as documentation support only—not clinical decisions.50- Strip/re-mask PHI before storing prompts/responses.5152## References53- For detailed schema, guardrails, and integration snippets see `README.md`, `prompt.md`, and `usage.py`.545556<!-- AUTHOR_SIGNATURE: 9a7f3c2e-MD-BABU-MIA-2026-MSSM-SECURE -->