Skip to content

[docs] Allergy Intolerance for 3.1 - #107

Open
rithviknishad wants to merge 7 commits into
mainfrom
claude/allergy-intolerance-module-update-4f0b98
Open

rithviknishad wants to merge 7 commits into
mainfrom
claude/allergy-intolerance-module-update-4f0b98

Conversation

@rithviknishad

Copy link
Copy Markdown
Member

What this changes

Updates the Allergy Intolerance documentation for Care 3.1 so it matches the 3.1 code. All six existing pages are rewritten in place (same URLs):

  • Concept: concepts/clinical/allergy-intolerance.mdx (now titled "Allergy intolerance")
  • Reference: references/clinical/allergy-intolerance.mdx (now titled "Allergy intolerance")
  • Flows in flows/clinical/allergy-intolerance/:
    1. Record an allergy
    2. Update an allergy
    3. Mark an allergy as entered in error
    4. View a patient's allergies (was "View allergy history"; it now also covers the Allergies panel on the encounter Overview)
  • Media in static/media/clinical/allergy-intolerance/: one narrated, subtitled video per flow, and screenshots of the steps with the relevant control outlined.

Only 3.1 is changed. The 3.0 pages are untouched: they were not re-verified against the 3.0 branch.

What was wrong in the old pages

The old pages made 231 checkable statements. 201 were confirmed, 26 were wrong in 3.1, and 4 could not be verified. The main corrections:

  • Save button. It is Save Changes, not "Submit".
  • Permissions. The flows listed "Can submit questionnaire about patient encounters", which nothing checks for allergies. Recording an allergy needs "Can Update a Patient's data". Once the patient has any saved allergy, every save also needs "Update Encounter related clinical data". That is because the form re-sends every saved allergy.
  • Saving re-links allergies. Saving the form links every saved allergy in it to the current encounter. The earlier encounter keeps a copy as it was. The product team confirmed this is intended: you re-confirm the allergy list at every encounter.
  • Closed encounters. On a closed encounter, the allergy controls are hidden, not read-only.
  • Clinical history. It leaves out Entered in Error allergies and keeps no change history.

What it was verified against

  • care @ ddfd840dbe314b4e53d2a719d2138324d970634b (develop, 2026-11-23)
  • care_fe @ 5e02f9aa4f690e08375da310511e14606985f788 (develop, 2026-11-26)

Every statement rests on one of three kinds of fact:

  • a cited line of the pinned code whose quote is machine-checked (496 facts, 0 failing);
  • a runtime check;
  • a product decision.

Two fresh-context reviews checked each sentence against its fact.

Runtime. A disposable local stack was built from exactly those commits: an empty database plus Care's fixtures, with invented people only. On it:

  • Probes: 11 API checks ran as non-superusers. They confirmed the permission paths, the re-linking and snapshot copies, the closed-encounter refusal, the 100-allergy limit, and the validation messages.
  • Recordings: every flow was recorded as a Doctor or a Nurse holding the role in a department. Each recording's API log matched the traced permission path, with no 403. The recordings also corrected two sentences:
    • a saved allergy's Note field is already shown;
    • "Go to Encounter" leaves the clinical history, so the old last two steps were merged.

Deliberate differences from the house style

  • Language. Simplified Technical English rules apply to steps, prerequisites and outcomes. Explanations use plain, consistent English.

  • Versions. Only the version that was verified is written.

  • Permissions. Each Permissions table covers the whole path to the action, not only the final permission, and says where each permission must be held.

  • Titles. H1s are sentence case, per review checklist item 9. That renames the concept and reference titles from "Allergy Intolerance" to "Allergy intolerance". Flow H1s are the task title, not the template's "How to …".

  • Concept sections. The concept keeps ## Where you see allergies and ## Permissions. Neither is in the concept template, but the concept skill asks for Permissions.

  • Value meanings. Status and criticality values are listed without definitions, because Care does not define them.

  • Media markup. Videos carry a WebVTT track, and steps have inline screenshots, as in the Workspaces pages.

  • Narration. Each video has a voice that reads a short script per step: the step, plus a sentence or two of context from the page. The subtitles show the spoken words. The voice is AI-generated with ElevenLabs (model eleven_v4), using cloned voices that take turns flow by flow:

    • Bill-eng, cloned from Bill's voice: Record, and Mark as entered in error.
    • Gauri-eng, cloned from Gauri's voice: Update, and View.

    Where a line is longer than its step on screen, a settled frame is held and the subtitles are timed to match.

Left out, and open questions

These are written with the most conservative reading and are open for the product team:

  • Completed encounters. Should every user see the same allergies on a completed encounter? The pages say only that the panel lists the allergies linked to that encounter.
  • Entered in Error. Is marking an allergy as Entered in Error final? The pages describe what a large screen does: the row can't be changed back, so record the allergy again.
  • Type and onset. The concept does not mention allergy vs intolerance, or onset. The screen never sets them; the reference keeps both fields.
  • Slug. The slug allergy-entered-in-error is kept to avoid breaking links.
  • Admin role. "Admin" means the facility Admin role.

Product findings (not filed)

  • Staff can't save once the patient has an allergy. By default, Staff can record an allergy only while the patient has none. After that, the whole save fails with "Failed to submit questionnaire". The product team says this is not intended. The pages describe today's behaviour.
  • Different lists for one completed encounter. Two users can see different allergy lists for the same completed encounter, depending on how they reach the patient. On a cancelled encounter, a user whose only access is through that encounter is refused the list.
  • Entered in Error on phones and tablets. It stays editable there, and the backend accepts changing it back.
  • Facility allergen lists. The search offers a facility's own allergens, but saving one of them is refused with "Code does not exist in the valueset".
  • History icon. It is shown to users who cannot open the history.
  • Translations. The verification and category options in the form are not translated.
  • Note field. It shows open for every saved allergy, even one with no note.
  • Patient header. At 1440 px wide, a patient with no tags has their name wrapped letter by letter on the profile. The demo patients in the recordings carry two invented tags ("Regular follow-up", "Outpatient clinic") so the header reads normally.
  • Authorization issue in the allergy API. One issue is not described here. It is being reported privately.

What the skill learned

In its own commit:

  • Set the recorder's EZ_API_URL to the same host the frontend build calls. 127.0.0.1 vs localhost gives an empty API log.
  • The narration scripts read flat out/<slug>.vtt/.mp4 files. Link per-flow output folders to them before running.
  • Subagents cannot write findings or report files, so they return findings as text and the main session saves them.

🤖 Generated with Claude Code

Open Healthcare Network and others added 2 commits November 27, 2026 09:40
Rewrite the concept, reference and four flow pages from the 3.1 code
(care ddfd840, care_fe 5e02f9a), and add narrated videos and step
screenshots for the flows. "View allergy history" is retitled
"View a patient's allergies" and now covers the encounter Overview panel.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- media: EZ_API_URL must match the frontend build's API URL exactly
  (127.0.0.1 vs localhost gives an empty API log).
- narration: link per-flow recording folders flat before make_plan.
- subagents may be refused writing findings files; save them yourself.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 27, 2026 •

Copy link
Copy Markdown

Deploying coredocs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 6c47ef5
Status: ✅  Deploy successful!
Preview URL: https://712eec2e.coredocs.pages.dev
Branch Preview URL: https://claude-allergy-intolerance-m.coredocs.pages.dev

View logs

@rithviknishad
rithviknishad marked this pull request as ready for review November 27, 2026 04:23
billjohnc and others added 5 commits November 29, 2026 00:31
The facility role pickers never offer a role named Admin. Care defines two
roles with that name; the role sync looks roles up by name, so the database
keeps one Admin role, for role organizations (care
sync_permissions_roles.py:37-45, roles/role.py:57-67,81-93), and the facility
screens list roles with context FACILITY (care_fe RoleSelect.tsx:140,
LinkFacilityUserSheet.tsx:207, PatientUsers.tsx:164; care
security/api/viewsets/roles.py:10-15). The concept's explanation said the
opposite; it now says why Admin is left out. Every other role in the lists
matches care security/permissions/patient.py and encounter.py.

Pinned care ddfd840, care_fe 5e02f9a.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The concept said you can attach allergies to a referral. The referral
screens cannot: the Add record picker builds its Record type list from
REFERRAL_ATTACHABLE_RESOURCE_TYPES, which has no allergy (care_fe
types/emr/referral/referralResource.ts:29-38, ReferralResourcePicker.tsx:
114-115,258), and the other two attach calls send only file_upload and
appointment (ReferralUploadDialog.tsx:58-63, useAppointmentReferral.ts:
129-133). The backend still accepts allergy_intolerance (care
emr/resources/referral/spec.py:219-230), and Shared records lists one under
Allergies (ReferralSharedRecords.tsx:94). The concept bullet and the
reference now say this.

Pinned care ddfd840, care_fe 5e02f9a.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The pages assume the standard encounter Overview. A facility can set up
its own workspaces (facility settings, Can Create/Update Workspaces). A
workspace renders only the pages it lists and can hide system pages,
including the Overview (care_fe EncounterWorkspaceContent.tsx:44-79,
parseEncounterWorkspace.ts:152-164). Custom pages place the allergies and
quick_actions sections anywhere, give them their own title, or leave them
out (types/workspace/encounterWorkspace.ts:91-99, widgetConfigSchemas.ts:
420-432, WorkspaceWidget.tsx:259-264,397-401, allergy/list.tsx:185). The
clinical history tabs, Allergies among them, can be hidden or left out
(encounterWorkspace.ts:65-74, ClinicalHistoryWorkspace.tsx:106-118). One
note in the concept says so.

Pinned care ddfd840, care_fe 5e02f9a.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The concept listed the patient's questionnaire responses as a place to see
allergies. Care does file a response record for each saved allergy (care
emr/api/viewsets/base.py:105-119), but it has no form, and every response list
asks for a form subject type (care_fe QuestionnaireResponsesList.tsx:819,860;
care viewsets/questionnaire_response.py:52; the clinical history Responses tab
reuses the same list). So no screen shows these records. The reference keeps
the API-level description. Pinned care ddfd840, care_fe 5e02f9a.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each narrated video now plays from the Open Healthcare Network YouTube
channel (playlist "Care 3.1 documentation"), with its subtitles on
YouTube. The .mp4, .vtt and poster files are removed from this branch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants