Friday, 20 November 2026

Beyond Static ERPs: Context-Assembled Business Processes, Borrowed from Clinical Informatics

 

Beyond Static ERPs: Context-Assembled Business Processes, Borrowed from Clinical Informatics

Traditional ERP systems are built like filing cabinets. They ship with fixed procurement forms, fixed inventory screens and fixed approval chains, designed for bookkeeping and audit rather than for the decision someone is making right now. A purchase order for routine office stationery goes through the same screens as an urgent order for a single-source component from a vendor whose risk score just dropped.

When conditions change, static workflows fail. A new regional tax rule, a port disruption or a failed supplier audit all need different questions asked at different moments. If the ERP doesn't prompt for them, structure them and map them to a standard code, the critical context ends up in email threads and spreadsheet side-notes, outside the system of record.

I ran into this problem first in healthcare. In my recent posts on the Context-Aware EMR Enhancer in VibeRounds, I explored a simple idea: the clinical situation should dictate the data structure. This post argues that the same pattern applies to ERP.

The Pattern: Context as an Active Schema Modifier

In the EMR work, a diagnosis (or a patient's live trajectory of conditions, labs and medications) selects and assembles the exact documentation modules needed. Four design decisions make that work, and each one has an ERP counterpart.

  1. A canonical, standards-bound intermediate representation. In health IT this is FHIR R4 SDC Questionnaire, bound to SNOMED CT and LOINC. In ERP the equivalent is a versioned process-module schema (JSON Schema or OpenAPI-style) bound to industry taxonomies such as UNSPSC, HS codes and tax-jurisdiction codes.

  2. LLM synthesis behind deterministic guardrails. An LLM drafts the module, but a rule-based validator checks every code, formula and constraint before a human domain owner sees it. In healthcare that owner is an informatician. In ERP it is a compliance officer or finance controller.

  3. Runtime composition instead of monolithic forms. Small, focused modules are stitched together according to live state. In an EMR that state is comorbidities and labs. In an ERP it is vendor risk, stock position, contract terms and regional regulation.

  4. A closed feedback loop. Every accepted, dismissed or edited recommendation is logged and used to tighten the triggers on the modules.

What a Context-Assembled ERP Looks Like

Take one scenario: an urgent purchase of a regulated component from a new overseas vendor.

  • Module 1, Cross-Border Import Compliance: triggered by the HS code and country of origin. It captures licence numbers, duty classification and restricted-party screening results.
  • Module 2, New-Vendor Due Diligence: triggered by vendor age and the absence of any prior transaction history. It captures bank verification, beneficial ownership and sanctions checks.
  • Module 3, Expedite Justification: triggered by the urgency flag and a value above threshold. It captures the business reason and the approver.
  • Suppressed Module: Annual Vendor Questionnaire. It was completed 60 days ago, so asking again would only add friction.

A conventional ERP presents one long purchase order form with every optional field. The context-assembled version presents the three modules that matter, pre-populated from existing records, and hides the rest. Suppressing what is already known is as important as surfacing what is missing, because users stop trusting a system that asks twice.

Mapping the Layers: EMR to ERP

Layer Clinical (VibeRounds / FHIR) ERP equivalent
Canonical schema FHIR R4 SDC Questionnaire Versioned process-module schema
Code bindings SNOMED CT, LOINC UNSPSC, HS codes, tax and GL codes
Validation Terminology and logic checks Business-rule, tax and segregation-of-duties checks
Human sign-off Informatician Domain controller or compliance owner
Trigger engine Diagnosis, labs, medications Vendor risk, inventory, contract and regulatory events
Pre-population SDC $populate Master-data and transaction-history prefill
External portal Patient PHR check-ins Vendor and field-technician portals
Feedback loop CDS Hooks feedback Recommendation accept, dismiss and edit logs

The Vendor and Field Portal: The ERP's PHR

In the clinical design, patients get short, condition-specific check-ins that feed structured data back into the record. The ERP analogue is the supplier or field-technician portal.

Rather than a generic supplier dashboard, a vendor receives a short, adaptive checklist tied to the active purchase order. This could be a delivery-readiness confirmation, a certificate-of-conformance upload or a delay-reason capture. If everything is on track, it takes seconds. If a threshold is breached, conditional questions expand and an alert goes to the buyer. Responses are extracted into coded records, so the ERP's trajectory view of that vendor is current when the next order is placed.

Where This Can Fail

I don't want to oversell this. The pattern is a design hypothesis for ERP, and I have only started testing the clinical version. Three failure modes decide whether it works.

  • Schema and logic drift. If two composed modules ask conflicting questions or write to the same field, users lose trust quickly. Composition needs explicit conflict rules.
  • Governance bottlenecks. If reviewing an LLM-drafted module is harder than writing it by hand, the supply of approved modules dries up.
  • Recommendation overload. A recommender that surfaces too many modules becomes the clutter it was meant to remove. Surfacing one or two high-signal modules is the right target.

The test is empirical. Pick one narrow process, run real transactions through the full loop, and measure the results: validation catch rate, time per transaction, missed-compliance incidents and recommendation dismissal rate.

Built to Adapt, Not to Replace

This approach doesn't require replacing SAP, Odoo or ERPNext. The module registry and recommender can sit above them as a middleware layer, with adapters that expose the same module to different host systems and a richer composition layer where you control the runtime.

The clinical implementation lives in the VibeRounds repository, and the ERP pattern is a direction I plan to prototype next. If you work in ERP implementation, compliance or process design, I'd welcome your critique, especially on where this pattern would break.

Previous posts in this series:

Project repository: VibeRounds-Clinical-Analytics-App



No comments:

Post a Comment