Skip to content

§B2 · The consult itself, in person

The procedure, end to end

Eleven steps, in order. Who acts, what happens, what is recorded — and, marked as such, the steps where no software is involved at all.

Modality

In person, at the dispensary. No telemedicine. This is the § 5(a) design decision — “I will not do it via telemedicine” — and it is stricter than Pennsylvania law requires: § 1161a.25(a) would permit synchronous interaction. Being narrower than the statute is the point.

Actors: the cardholder (recipient — no account), the pharmacist (professional), the door’s budtender, a Rishi reviewer.

The eleven steps

offline marks a step with no software in it. Software does not reach these steps, and the honesty of where it does and does not reach is a feature of this document.

  1. 01

    Walt arrives, card checked at the door by dispensary staff

    System

    dispensary's system only

    What happens / what is recorded

    Rishi is not in this step and has no visibility into it

  2. 02

    Budtender routes him to the consult desk — either because the certifier did not specify form/dosage (§ 1181a.27(c)(7)(ii) makes the consult mandatory here), or because Walt asked

    System

    offline — no software

    What happens / what is recorded

    GAP-13: nothing in Rishi records why a consult was triggered, so the mandatory-vs-elective split — which is exactly what Marcus wants to audit — is not measurable

  3. 03

    The door's system issues an opaque consult_ref

    System

    dispensary's system

    What happens / what is recorded

    This is the entire identity handoff. The PHI stays on their side of the line

  4. 04

    Priya opens the consult. She asks what else Walt takes before discussing any product

    System

    offline — no software

    What happens / what is recorded

    The conversion moment (A4). Also the clinically load-bearing one: warfarin, clobazam, tacrolimus, CNS depressants (memo 03 §4)

  5. 05

    Protocol drives it. Priya works from the approved protocol for the condition cluster

    System

    protocols where status='approved'

    What happens / what is recorded

    A draft/in_review/retired protocol may never be used — enforced downstream at step 9 with 422

  6. 06

    Products are restricted to this door's shelf, fresh

    System

    GET /api/shelf-observations/recommend?locationId=…&conditionCode=…&maxAgeDays=14

    What happens / what is recorded

    see below

  7. 07

    Interaction screen runs

    System

    protocols.interaction_flags (jsonb) → read by a human

    What happens / what is recorded

    GAP-14. There is no interaction-screening engine. interaction_flags is content on the protocol; consult_records.interaction_flags_raised is a jsonb array the caller supplies. Grep confirms no route computes, matches or validates a flag. The screen is Priya reading the protocol's flag list against what Walt tells her, and then typing what she raised. This is the single largest gap between the pitch and the software.

  8. 08

    Priya advises: form, starting dose, titration step, onset/duration, stop rules, what to do if nothing happens

    System

    offline — no software

    What happens / what is recorded

    from protocols.titration_steps, route, onset_profile, contraindications

  9. 09

    Documentation written

    System

    POST /api/consult-recordsconsult_records

    What happens / what is recorded

    fields: consult_ref, protocol_id, protocol_version, condition_cluster, products_recommended (jsonb), interaction_flags_raised (jsonb), route_used, duration_min, plus location_id, professional_user_id, optional shift_id. No patient column exists. Starts qa_status='pending'

  10. 10

    Priya may correct the record — only while pending

    System

    PATCH /api/consult-records/[id]

    What happens / what is recorded

    rejected once reviewed. A reviewed consult is immutable

  11. 11

    QA review

    System

    POST /api/consult-records/[id]/reviewpassed \

    What happens / what is recorded

    flagged, with reviewed_by_id + reviewed_at from the session, qa_notes

Known limitations — stated, not buried

GAP-14 · blocks a pilot

There is no interaction-screening engine.

No interaction-screening engine. protocols.interaction_flags is content; consult_records.interaction_flags_raised is caller-supplied jsonb. Nothing computes, matches or validates a flag. The screen is a human reading a list

The screen is the pharmacist reading the protocol’s flag list against what the patient reports, and then typing what she raised. This is the single largest gap between the pitch and the software. Nothing computes, matches or validates a flag.

Journeys B2, C2 · the largest gap between the pitch and the software

GAP-13 · will be hit in the first month

Nothing records why a consult was triggered.

Nothing records why a consult was triggered — the mandatory § 1181a.27(c)(7)(ii) case vs elective. Exactly the split Marcus wants to audit

Journeys B2 · one column

What is missing from this journey — the source list, verbatim
  • GAP-14 (above): no interaction-screening engine.
  • GAP-15: POST /api/consult-records does not require an active coverage_assignment or an active coverage_contract. A consult can be recorded at a door outside any covered window. The credential gate fires; the "was this door actually covered at that moment" gate does not exist.
  • GAP-16: products_recommended is an unvalidated jsonb array. Nothing checks that the products recorded were actually on that door's fresh shelf — the recommend endpoint is a read path, structurally disconnected from the write path. A consult can record a product the recommender would have refused to surface.
  • GAP-17: there is no consult UI. Every route above is an API. What Priya actually uses at the desk does not exist.

What the patient IS told

What the patient is NOT told

This list is the compliance surface. It is not trimmed.

What step 6 actually returns

GET /api/shelf-observations/recommend (app/api/shelf-observations/recommend/route.ts):

  • 404 NO_APPROVED_PROTOCOL if the org has no status='approved' protocol for that conditionCode. Ranking is never attempted. No approved protocol, no recommendation — full stop.
  • 404 LOCATION_NOT_FOUND for a cross-org door.
  • results[] — products on this door's location_products whose last_seen_date >= cutoff (default 14 days) and whose latest shelf_observations row is not in_stock = false.
  • stale[] — a separate array, never mixed into results (§B4).
  • Ranking: ratioClassMatch (MEASURED total_thc_pct/total_cbd_pct from the latest product_lots row, classified at a 2:1 dominance threshold) → then formMatch (protocol route → product form) → then name, then id. Terpenes, "entourage", indica/sativa and strain name are never ranking variables and are returned tagged "claimed — manufacturer assertions; display-only, NEVER a ranking or matching variable" (memo 03 §5; Jikomes 2022).
  • A claimRung string on every response: "rung-2/3: … the product is ON THE SHELF at this door and lab-MEASURED … It does NOT say the product works for this condition."