plugins/healthcare/skills/contracts/skills/queue-triage/SKILL.md
After a sweep round, dedupe and triage worker unknowns into the human queue. Self-resolve the obvious (visibly); blocking items end the round.
npx skillsauth add anthropics/healthcare queue-triageInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Workers return findings with kind='unknown' for anything they couldn't
resolve. Your job: roll those up into a small, useful set of questions.
bun $ANT_CONTRACTS_CLI sql "SELECT id,worker,claim FROM findings WHERE run_id='$ANT_CONTRACTS_RUN_ID' AND round=<r> AND kind='unknown'"
Many workers hit the same ambiguity ("does §4.2 in amendment 3 supersede the base or only the prior amendment?"). One queue item, not twelve. Group by what's actually being asked, not by which document raised it.
If the answer is obvious from the corpus, the brief, or ratified knowledge, resolve it yourself — but visibly:
bun $ANT_CONTRACTS_CLI write queue_items '{"run_id":"'$ANT_CONTRACTS_RUN_ID'","brief_id":<b>,"round":<r>,"question":"…","context":"…","blocking":0,"status":"self_resolved","answer":"…","answered_by":"agent"}'
The trigger requires answered_by on self-resolved items. Provenance is
the point — a human reviewing the run sees what you decided and why.
Genuine ambiguity the corpus can't resolve and you shouldn't guess. State
the question plainly, give the options you see, and link the citation that
shows the ambiguity. Mark it blocking:1 only if the answer changes what
the next sweep round reads or how findings are interpreted. No drama.
bun $ANT_CONTRACTS_CLI write queue_items '{"run_id":"'$ANT_CONTRACTS_RUN_ID'","brief_id":<b>,"round":<r>,"question":"…","context":"…","blocking":1}'
bun $ANT_CONTRACTS_CLI write queue_citations '{"queue_item_id":<q>,"citation_id":<c>}'
If any open blocking item exists → set runs $ANT_CONTRACTS_RUN_ID status awaiting_human
and return. Otherwise continue to synthesize.
tools
Extract plain text from a document file - PDF, DOCX, XLSX, PPTX, RTF, or plain text/markdown/HTML. Use when a binary document needs to be turned into text, for example a contract PDF or an EHR DocumentReference attachment. Other skills (fhir) invoke scripts/extract.ts directly; the contracts MCP server bundles its own copy (servers/documents/src/extract.mjs) so its bundle stays self-contained — port fixes to both.
testing
Answer a question across a corpus of contract documents with verified citations. Use when the user asks what a contract says, which contracts have a clause, what changed between amendments, or any question that needs reading and citing across a set of contract files. The corpus must be on the local filesystem (see README).
tools
Connect to a hospital's FHIR R4 server (Epic, Oracle Health/Cerner, MEDITECH, athenahealth, or any SMART-on-FHIR endpoint), pull a patient's clinical data and notes, and extract structured findings. Use when users say "connect to the EHR", "connect to Epic/Cerner", "pull notes for patient X", "what do the last 6 months of notes say about Y", or any task that starts from a live EHR rather than pasted text.
tools
Assign CPT and HCPCS Level II procedure codes from clinical documentation the way a professional coder builds the claim. Use when users say "code this encounter for procedures", "what CPT codes apply", "assign HCPCS codes", "code this op note", or when turning visit notes or operative reports into claim-ready procedure codes.