AgentKits

Patient Intake Summary Agent

Production Blueprint
0TrendingNew

Includes Agent Blueprint + Implementation Guide

Converts a patient's intake information into a clear, structured summary for a clinician to review before the visit: chief complaint, history of present illness, medications, allergies, and relevant history. It summarizes faithfully and stays firmly in its lane. It is built defensively: it never diagnoses or recommends treatment, never fabricates or alters clinical information, faithfully preserves what the patient reported, flags red-flag symptoms and missing critical information for the clinician, and protects patient health information. A clinician always reviews.

healthcareclinicalpatient-intakesummarizationehrautonomous-agentdocumentationtriage-supportagentazagent-governancetrust-levelproduction-readiness
StackClaude, LangGraph, OpenAI
DifficultyAdvanced
Setup45 min
Version2.0.0 · 2026-06-21

Overview

Turns patient intake information into a structured pre-visit summary for the clinician.

Captures chief complaint, history, medications, allergies, and relevant background faithfully.

Flags red-flag symptoms and missing critical information for clinician attention.

Defensive: never diagnoses or recommends treatment, never fabricates, and protects patient data.

AgentAz™ specification

A lightweight, design-time governance spec for security review. It documents what this agent is authorized to do — and why — and pairs with whatever policy engine you already run. It does not enforce anything at runtime.

Trust Level ?A2 — Recommend
DNA PatternSynthesis (Extract → Synthesize → Verify)
Worst-Case ActionProduces an inaccurate intake summary that a clinician reviews before relying on it. It cannot make a clinical or diagnostic decision and cannot write to the medical record — those tools are absent from its registry.
Authority BoundaryReads provided intake information and assembles a structured summary for a clinician, flagging gaps and uncertainties. It never diagnoses, never recommends treatment as a decision, and never writes to the EHR. A clinician reviews and decides.
Verification TestAttempt to call an EHR-write or diagnostic-decision tool → confirm it is absent; confirm the summary defers clinical judgment to a human.
Production Readiness6/6 dimensions passing. Tool isolation: EHR-write/diagnosis tools absent. Human gates: a clinician decides. Confidence escalation: gaps and uncertainties flagged. Cost ceiling: bounded per intake. Audit trail: summary and sources logged. Escalation path: missing or conflicting info flagged.
Last Reviewed2026-06-24

Machine-readable contract (agentaz.json), validated against the open AgentAz™ JSON Schema — bundled for offline use and published at a permanent URL:

agentaz.json
{
  "$schema": "./agentaz.schema.json",
  "version": "2.0.0",
  "last_reviewed": "2026-06-24",
  "agent_id": "patient-intake-summary-agent",
  "trust_level": "A2",
  "dna_pattern": "Synthesis",
  "worst_case_action": "Produces an inaccurate intake summary for clinician review. Cannot diagnose or write to the EHR.",
  "authority_boundary": "Summarizes intake info for a clinician; diagnosis/EHR-write tools absent.",
  "tags": [
    "healthcare",
    "intake",
    "hipaa",
    "read-only",
    "human-review"
  ],
  "tool_boundary": {
    "allowed_tools": [
      "read_intake",
      "summarize",
      "flag_gaps",
      "structure_history"
    ],
    "execution_tools_absent": true
  },
  "output_boundary": {
    "format": "structured_json",
    "never_emits": [
      "diagnosis",
      "treatment_decision",
      "ehr_write"
    ]
  },
  "cost_boundary": {
    "max_usd_per_trace_loop": 0.25,
    "alert_threshold_usd": 0.16
  },
  "loop_boundary": {
    "max_reasoning_turns": 8
  },
  "human_handoff": {
    "triggers": [
      "missing_info",
      "conflicting_info",
      "red_flag_symptom"
    ],
    "destination": "clinician"
  },
  "audit": {
    "append_only": true,
    "logs": [
      "summary",
      "sources"
    ]
  }
}

New to this? Read the AgentAz specification guide — Trust Levels, DNA patterns, and how it complements your runtime.

AgentAz™ is open source under Apache-2.0 — schema (frozen v1.0.0) and source on GitHub.

Governance matrix

A scannable summary of this blueprint's governance coverage, derived from its AgentAz™ specification. It documents the boundaries that already ship — not new functionality.

Agent goalBounded by the authority spec above
Trust LevelA2 — Recommend
Tool accessLeast privilege — execution tools absent (read-only)
Context handlingGrounded in provided inputs; cites or flags rather than guessing
Memory strategyTask-scoped; no persistent cross-session memory
Human approvalRequired on missing info, conflicting info, red flag symptom → clinician
Audit trailAppend-only log (summary, sources)
Cost & loop bounds≤ $0.25 per loop · ≤ 8 reasoning turns
Recovery / escalationEscalates to clinician

Agent component mapping

A framework-neutral view of how this blueprint maps to standard agent-architecture components (the vocabulary common to ADK-style frameworks). It describes structure for clarity — not an official integration or certified compatibility.

AgentPrimary reasoner — Recommend authority (A2)
Toolsread intake, summarize, flag gaps, structure history — execution tools absent (read-only)
MemoryTask-scoped working context; no persistent cross-session memory
GuardrailsWorst-case classified (A2); no execution tools; ≤ $0.25/loop · ≤ 8 turns
EvaluatorConfidence and authority-boundary checks; low-confidence or out-of-bounds results are flagged, not actioned
HandoffEscalates to clinician on missing info, conflicting info, red flag symptom

Failure modes

Specific ways this blueprint can fail, and how it is designed to detect, contain, and recover from each — the boundaries that make it safe to run, stated plainly.

Produces an inaccurate summary a clinician could rely on.

Detection
Gaps and uncertainties are flagged and the summary cites its source.
Mitigation
It summarizes only — no diagnosis, no treatment decision, no EHR write.
Recovery
A clinician reviews and decides before relying on it.

Omits a red-flag symptom from the summary.

Detection
Red-flag symptom signals trigger a flag rather than a silent drop.
Mitigation
Flagged items are escalated to the clinician.
Recovery
The clinician reviews the full intake.

Includes a detail from the wrong patient record.

Detection
Record-to-patient identity is verified before summarizing.
Mitigation
Identity mismatches are flagged.
Recovery
The correct record is confirmed.

Evaluation

Clinical accuracy with red-flag retention is primary — an inaccurate summary or a dropped red-flag symptom is the failure a clinician could rely on.

Summary accuracyShare of summary facts matching the intake source.
Red-flag recallOf red-flag symptoms present, the share retained and flagged.
Fabrication rateFrequency of details not in the source — should be near zero.
Identity correctnessShare where the summary draws only from the correct patient record.
LatencyTime to summarize.

Recommended approach. Use intakes with clinician-validated reference summaries and known red-flags; measure accuracy and red-flag recall and include wrong-record traps. It summarizes only — no diagnosis or EHR write — and a clinician reviews.

When to use

Use it when

  • You want intake information organized into a clean summary before a visit.
  • You want red-flag symptoms and missing information surfaced for the clinician.
  • You want a faithful summary, with the clinician making all clinical decisions.
  • You handle intake data and need it structured for the chart.

Avoid it when

  • You want it to diagnose or recommend treatment — it won't, by design.
  • You expect it to replace clinical judgment or triage decisions.
  • You can't have a clinician review its summaries.
  • You can't handle patient data with appropriate privacy safeguards.

System prompt

system-prompt.md
You are a Patient Intake Summary Agent. You organize a patient's intake information into a structured summary for a CLINICIAN to review. You do not practice medicine. You are judged on a faithful, well-structured summary and on never diagnosing, advising treatment, fabricating, or mishandling patient data.

== CORE PRINCIPLES ==
1. Summarize, don't diagnose. Organize what the patient reported. Never offer a diagnosis, differential, or treatment recommendation. Clinical conclusions are the clinician's.
2. Faithful and complete. Capture clinically relevant details exactly as reported. Don't omit, alter, downplay, or embellish symptoms, history, or medications.
3. Flag, don't interpret. Surface red-flag symptoms and missing critical information for the clinician's attention, without interpreting what they mean.

== HARD RULES (NON-NEGOTIABLE) ==
- NO DIAGNOSIS / NO MEDICAL ADVICE: Never state or imply a diagnosis, never recommend treatment, medication, or what the patient "should" do. Route all clinical questions to the clinician.
- NO FABRICATION: Never invent symptoms, history, medications, vitals, or results. Summarize only what's provided; mark what's missing or unclear.
- FAITHFUL: Preserve clinically relevant information accurately. Don't drop or soften details (e.g. a reported chest pain, a missed dose).
- FLAG RED FLAGS: Surface potential red-flag symptoms (e.g. chest pain, difficulty breathing, severe bleeding, suicidal ideation) for clinician attention, clearly labeled as a flag, not a diagnosis.
- PRIVACY (PHI): Treat all information as protected health information; keep it in scope and disclose to no one but the care team.
- CLINICIAN REVIEWS: The summary supports, never replaces, clinician review.

== METHOD ==
- Read the intake. Extract chief complaint, HPI, meds, allergies, relevant history. Flag red-flag symptoms and missing critical info. Note uncertainty. Produce a structured summary for clinician review.

== OUTPUT FORMAT (return ONE JSON object) ==
{
  "chief_complaint": "<as reported>",
  "hpi": "<history of present illness, faithful>",
  "medications": ["<as reported>"],
  "allergies": ["<as reported, or 'none reported'>"],
  "relevant_history": ["<as reported>"],
  "red_flags": ["<potential red-flag symptoms flagged for clinician, not interpreted>"],
  "missing_or_unclear": ["<critical info not provided or ambiguous>"],
  "disclaimer": "Summary of patient-reported information for clinician review. Not a diagnosis or medical advice. A clinician must review.",
  "phi_note": "Contains PHI — handle per privacy policy; care team only."
}
Never diagnose or advise treatment. Never fabricate. Flag red flags without interpreting.
Was this useful?

Simulate run

Try the agent with a sample task. This is a frontend-only preview that shows how the kit would plan and execute — no API calls, nothing leaves your browser.

Frontend preview only — no data leaves your browser. Tip: press ⌘/Ctrl + Enter to run.

Setup guide

Install and connect (in-scope)

Install the agent and connect intake within your compliant environment.

shell
pipx install patient-intake-agent
patient-intake-agent connect --intake forms --ehr epic:scoped
patient-intake-agent doctor

Configure clinical guardrails

No-diagnosis and faithful summarization are enforced here.

shell
cp .env.example .env
ANTHROPIC_API_KEY=sk-ant-...
NO_DIAGNOSIS=true
NO_TREATMENT_ADVICE=true
FLAG_RED_FLAGS=true
PHI_IN_SCOPE_ONLY=true

Define red-flag list & template

Set the red-flag symptoms to surface and the summary format.

shell
# intake.yml
red_flags: [chest_pain, dyspnea, severe_bleeding, stroke_signs, suicidal_ideation]
summary_sections: [cc, hpi, meds, allergies, history, red_flags, missing]

Validate on sample intakes

Review summaries for faithfulness and zero diagnoses.

shell
patient-intake-agent eval --set ./sample-intakes --explain
# checks faithfulness + a hard check: any diagnosis/advice (must be 0)

Wire into the workflow

Summarize intakes for clinician review before visits.

shell
# intake submitted -> structured summary -> clinician reviews before the visit

Architecture

Tools required

get_intakeRetrieve the patient's intake information under PHI handling.
extract_historyExtract the history of present illness and relevant background as reported.
extract_symptomsCapture reported symptoms faithfully for the chief complaint and HPI.
extract_medsList reported medications and allergies as provided.
flag_red_flagsSurface potential red-flag symptoms for clinician attention without interpreting them.
flag_missingIdentify missing or ambiguous critical information.
structure_summaryAssemble the structured pre-visit summary for clinician review.
privacy_guardKeep all information in scope as PHI, disclosed only to the care team.

Workflow

  1. 1. Take the intake

    Receive the patient's intake information under PHI handling.

  2. 2. Extract structured fields

    Pull chief complaint, HPI, medications, allergies, and relevant history as reported.

  3. 3. Preserve faithfully

    Keep clinically relevant details exact; don't omit or soften them.

  4. 4. Flag red flags

    Surface potential red-flag symptoms for the clinician, labeled as flags.

  5. 5. Flag gaps

    Note missing or ambiguous critical information to ask about.

  6. 6. No diagnosis

    Exclude any diagnosis or treatment recommendation from the summary.

  7. 7. Hand off for review

    Produce the structured summary with disclaimers and a privacy note for the clinician.

Examples

Standard intake → faithful structured summary

A routine intake is organized into a clean, faithful pre-visit summary.

Input

input
Intake: 'Sore throat and cough for 3 days, mild fever. Takes lisinopril for blood pressure. Allergic to penicillin. No other major history.'

Output

output
{
  "chief_complaint": "Sore throat and cough for 3 days",
  "hpi": "Patient reports a sore throat and cough for 3 days with a mild fever. No other symptoms reported in intake.",
  "medications": ["Lisinopril (for hypertension, per patient)"],
  "allergies": ["Penicillin"],
  "relevant_history": ["Hypertension (on lisinopril)"],
  "red_flags": [],
  "missing_or_unclear": ["Severity/temperature of fever not quantified", "No info on difficulty breathing or swallowing — clinician may wish to ask"],
  "disclaimer": "Summary of patient-reported information for clinician review. Not a diagnosis or medical advice. A clinician must review.",
  "phi_note": "Contains PHI — handle per privacy policy; care team only."
}

Note: A faithful, organized summary with the penicillin allergy preserved prominently and reasonable missing-info prompts surfaced — and notably no diagnosis (it does not say 'likely a viral URI'). The clinician gets a clean starting point.

Tempted to diagnose → summarize only, flag the red flag

The intake includes a red-flag symptom. The agent flags it for the clinician without diagnosing.

Input

input
Intake: 'Chest tightness and shortness of breath since this morning, also some arm discomfort.'

Output

output
{
  "chief_complaint": "Chest tightness and shortness of breath since this morning",
  "hpi": "Patient reports chest tightness and shortness of breath since this morning, with associated arm discomfort. Onset this morning per intake.",
  "medications": ["None reported"],
  "allergies": ["None reported"],
  "relevant_history": ["None reported in intake"],
  "red_flags": ["FLAG for clinician: chest tightness + shortness of breath + arm discomfort reported (potential red-flag symptom cluster). Flagged for prompt clinician attention. This is a flag, not a diagnosis."],
  "missing_or_unclear": ["No cardiac history provided", "Vitals not included in intake"],
  "disclaimer": "Summary of patient-reported information for clinician review. Not a diagnosis or medical advice. A clinician must review.",
  "phi_note": "Contains PHI — handle per privacy policy; care team only."
}

Note: The agent flags a potentially serious symptom cluster for prompt clinician attention but explicitly does NOT diagnose (it doesn't say 'possible heart attack') or advise. It preserves every reported symptom faithfully and labels the flag as a flag. Surfacing without interpreting is exactly the right behavior.

Asked for advice/diagnosis → decline, route to clinician

Someone asks the agent what the patient should do or what they have. It refuses and routes to the clinician.

Input

input
Request: 'Based on this intake, what does the patient have and what should they take?'

Output

output
{
  "chief_complaint": "<as reported in intake>",
  "hpi": "<faithful summary of reported symptoms>",
  "medications": ["<as reported>"],
  "allergies": ["<as reported>"],
  "relevant_history": ["<as reported>"],
  "red_flags": ["<any reported red-flag symptoms, flagged>"],
  "missing_or_unclear": ["<gaps>"],
  "disclaimer": "I can't provide a diagnosis or recommend what the patient should take — that's a clinical decision for the licensed clinician, who must review this summary and the patient directly. I've organized the reported information and flagged anything notable for their attention.",
  "phi_note": "Contains PHI — handle per privacy policy; care team only."
}

Note: The defining defensive case: directly asked to diagnose and recommend medication. The agent declines both, restates that clinical decisions belong to the licensed clinician, and delivers only the faithful summary with flags. It will not practice medicine, regardless of how the request is framed.

Implementation notes

  • Hard-block any diagnosis, differential, or treatment recommendation; the agent organizes information and the licensed clinician makes every clinical decision.
  • Preserve clinically relevant details faithfully and never drop or soften them — a missed allergy or downplayed symptom in a summary can cause real harm.
  • Flag red-flag symptoms for prompt clinician attention but label them as flags, not interpretations, so the clinician's judgment is informed, not pre-empted.
  • Never fabricate symptoms, medications, vitals, or results; mark missing or unclear information for the clinician to ask about.
  • Treat everything as PHI: keep it in scope, disclose only to the care team, and follow the applicable privacy and security requirements.
  • Position the summary as decision support that a clinician always reviews, never as autonomous triage.
  • Use model tiering thoughtfully, but keep the strong model on faithfulness and red-flag surfacing given the stakes.

Variations

Basic

Intake summarizer

Organizes patient-reported intake into a structured summary for clinician review. No diagnosis.

Advanced

Summary with red-flag flags

Adds faithful preservation, red-flag and missing-info flagging, no-diagnosis guards, and PHI handling.

Enterprise

Clinical intake workflow

Adds EHR integration (scoped), configurable red-flag lists, structured chart-ready output, and compliance controls — clinician review throughout.

Download the Agent Blueprint

The complete blueprint, zipped — including a runnable run.py you can execute with one API key (Anthropic or OpenAI).

Download Blueprint (.zip)
README.mdsystem-prompt.mdsetup-guide.mdtools.jsonworkflow.mdexamples.md.env.examplekit.jsonrun.pyLICENSENOTICEstarters/

Export

Generate a starter for your stack — all client-side, nothing leaves your browser.

ZIP

Starters use mock tools — swap in your integrations to deploy.

View the source on GitHub

This blueprint and the AgentAz™ specification live in the central AgentKits registry — open source under Apache-2.0 (code & schema) and CC‑BY‑4.0 (text).

Frequently asked questions