Build plan
Competitor lessons and phased prompts. Phases 1 and 3–6 run in this prototype; 2 and 11 are partly in place.
Imaging & AI expansion
Ambient notes and administrative agents already exist in competing systems; no evidence supports claiming these features are absent from all practice software.
Added: imaging metadata and report review for every patient; records-request tasks; AI dictation-to-SOAP drafts; differential and treatment discussion with retrieved PubMed-indexed abstracts; report summaries; patient explanations; authorization drafts; documentation gaps; care handoffs; coverage-aware operational action plans; private saved AI drafts.
Differentiation to validate: explicit skill-matched coverage constraints, evidence provenance and missing-data handling, acceptance-aware workload planning, and transparent uncertainty rather than autonomous clinical decisions.
Not implemented: PACS/DICOM viewing, EHR/FHIR integration, e-prescribing, lab ordering, payer submission, live patient messaging, automatic clinical decisions, real workforce permissions or HIPAA-ready production use.
Production prerequisites: tenant isolation and assigned roles, clinician validation, PHI/BAA and vendor review, consent and retention policies, clinical safety evaluation, imaging interoperability and externally verified payer rules.
Competitor sources: athenahealth AI · eClinicalWorks AI Workbench · eClinicalWorks EHR / Sunoh scribe. Vendor claims, not independently measured performance.
Part 1. What competitors do well and where they fall short
Ratings and quotes come from public review sites. They show recurring themes, not representative samples. | Vendor | Public rating signal | What users praise | What users complain about | |---|---|---|---| | ModMed (EMA) | 4.5 on Capterra (574 reviews) | iPad app, specialty exam templates, adaptive coding suggestions | Complex reporting, restrictive multi-year contracts, steep per-user pricing, slow support on billing issues | | athenaOne | 3.8 on Capterra (916); 3.4 on G2 (115) | Customization, automatic claim checks, integrated scheduling, charting, and billing | Slow support, steep learning curve, weak reporting, integration limits with third-party tools, dropped message notifications, vendor billing staff editing claims without the practice's consent | | Tebra | 4.0 on Capterra (1,396); 4.1 on G2 (268); 1.79 on BBB (76) | Easy interface, little training needed, all-in-one | Reporting needs manual compiling, tab-heavy navigation, billing and contract disputes, hard-to-reach support | | NextGen Enterprise | 3.8 on G2 (227); 4.3 on Capterra (83) | Deep functionality, configurable templates, billing compliance | Too many clicks and pop-ups, weak financial and AR reports, slow and generic support, interface connection problems, costly customization without a programmer | | AdvancedMD | 3.7 (Software Finder, 434) | Intuitive interface, integrated billing | Reporting and workflow complexity | | eClinicalWorks / healow | 3.5 (Software Finder, 460); healow 2.1 (16) | AI documentation tools, deep claims management | Steep learning curve, clunky UI, inconsistent support, slow integrations | Sources: ModMed on Capterra [1](https://www.capterra.com/p/124590/EMA/reviews/), athenaOne on Capterra [2](https://www.capterra.com/p/98735/athenaOne/reviews/), on G2 [3](https://www.g2.com/products/athenaone/reviews?qs=pros-and-cons), and on Software Advice [4](https://www.softwareadvice.com/medical/athenacollector-athenaclinicals-profile/reviews/), Tebra on Capterra [5](https://www.capterra.com/p/129169/Tebra/reviews/), on G2 [6](https://www.g2.com/products/tebra-previously-kareo-patientpop/reviews?qs=pros-and-cons), and on BBB [7](https://www.bbb.org/us/ca/corona-dl-mar/profile/computer-software-developers/tebra-1126-100073805/customer-reviews), NextGen Enterprise on G2 [8](https://www.g2.com/products/nextgen-enterprise/reviews), on Capterra [9](https://www.capterra.com/p/228336/NextGen-Enterprise/reviews/), and on TrustRadius [10](https://www.trustradius.com/products/nextgen-healthcare-ehr/reviews), AdvancedMD [11](https://softwarefinder.com/emr-software/advancedmd), eClinicalWorks [12](https://softwarefinder.com/emr-software/eclinicalworks) and healow [13](https://softwarefinder.com/emr-software/healow) on Software Finder.
Patterns across vendors
**What wins:** 1. **Specialty fit.** The highest-rated product (ModMed) was built around specialty workflows by practicing physicians. 2. **Speed at the point of care.** Touch-friendly, low-click documentation earns the most praise. 3. **One place for the day's work.** Users value scheduling, charting, and billing that connect. **What fails, repeatedly:** 1. **Reporting.** Weak or manual reporting is the most common complaint at athena, Tebra, NextGen, ModMed, and AdvancedMD. 2. **Support and vendor responsiveness.** Slow or generic support shows up for nearly every vendor. 3. **Learning curve and click count.** Users cite pop-ups, tabs, and screens. 4. **Integrations.** Third-party connections are limited or fragile. 5. **Trust in commercial terms and actions.** Users report multi-year contracts, auto-renewal disputes, and vendor staff changing claims without consent.
Design principles for Practice ManagementOS (derived from the patterns)
| Competitor failure | ManagementOS answer | |---|---| | Weak reporting | Role dashboards are built in from the first slice, with denominators, missing-data rates, and one-click CSV export | | Slow support; work stuck with one person | Every task has an owner, a qualified backup, a due date, a next action, and an evidence trail; nothing lives in a personal inbox | | Learning curve and clicks | Practices get a "Today" view per role, keyboard and touch actions, and no modal pop-ups for routine work | | Fragile integrations | Integration health is a visible dashboard; every integration has a stated manual fallback | | Silent edits by others | Nothing is changed without an audited actor, reason, and timestamp; the platform never edits signed notes, orders, or claims | | Contract lock-in | Full data export is available to the practice owner at any time (positioning choice, not a technical feature) | ---
Part 2. Master development prompt
Updated competitor coverage and automation opportunities
The former standalone Competitor gaps page is consolidated here for planning only. This is a summary of public product information and review themes, not a verified feature-by-feature audit of every vendor. Potential gaps below are hypotheses to validate in product demonstrations and pilot practices; they do not establish that a competitor lacks a capability. Ratings above are historical research signals, not current rankings. | Product | Strengths to learn from | Potential limitations to validate | |---|---|---| | athenaOne (athenahealth) | Cloud revenue-cycle management, payer-rule network, ambient AI notes | Specialty depth, cross-team handoffs, collections-based commercial terms | | eClinicalWorks | Broad EHR and practice management, healow patient access, AI documentation | Training burden, interface density, reporting and integration effort | | NextGen Healthcare | Specialty templates, configurable workflows, ambient AI | Setup complexity, prior-authorization effort, multi-site staff coverage | | ModMed | Specialty-first charting and integrated practice management | Cross-stage reconciliation and integration of patient and business agreements | | AdvancedMD | Independent-practice billing, scheduling and telehealth | Configuration effort and qualification-aware staff coverage | | Tebra | Independent-practice billing, marketing and patient engagement | Procedure-pathway depth, reporting effort and payer follow-up | | DrChrono / EverHealth | Mobile charting, APIs and digital forms | Payer connectivity and provider assignment across offices, ASCs and hospitals | | Epic / Community Connect | Clinical records and interoperability across large systems | Pilot cost, implementation effort and independent-practice control over changes | | Nextech / gMed | Specialty and ambulatory-procedure workflows | Specialty fit and integration of contracts, signatures and staff training | Additional vendor starting points for validation: https://www.drchrono.com/ ; https://www.epic.com/software/ ; https://www.nextech.com/ . Public vendor pages describe offered capabilities, not independently measured performance. Revalidate the earlier review sources before using competitive claims externally.
Competitor-informed automation inventory
“Prototype” below means synthetic workflow support, not a production integration or proof of time savings. Clinical decisions, signatures, payer-policy application and exceptions remain human-reviewed. | Operational opportunity | Qevatrix response | Current status | |---|---|---| | Work lost between front desk, clinical, authorization and billing | Shared queue, accountable owners, skill-matched backups and coverage-aware handoffs | Prototype | | Drift between ordered, authorized, scheduled, performed, documented and billed details | Deterministic cross-stage reconciliation and discrepancy blocks on claims | Prototype | | Authorization deadlines and insurance changes | Expiry tasks, authorization board and insurance-change readiness invalidation | Prototype; payer responses simulated | | Managers need actionable backlog guidance | AI operations plans grounded in current synthetic tasks, coverage and overdue work | Live authenticated AI; plans never execute themselves | | Training disconnected from actual workflow | Pathway Coach, patient-to-payment journey and wall flowchart | Prototype with live authenticated AI coaching | | Patient and business documents scattered across tools | Document library, ordered signing, consent and audit trail | Synthetic signing simulation; no external delivery or durable signed-record storage | | AI vendors lack reviewed privacy and data-use terms | AI provider BAA outline, no-training terms and go-live evidence checklist | Starter outlines; legal and vendor review required | | Patients counted complete before all work is done | Completion checks for every planned procedure, insurer payment, patient balance and follow-up | Prototype; all payer traffic simulated | | No-shows and overdue follow-ups disappear | Manual outreach logging and no-show recovery tasks | Prototype; nothing auto-sent |
Next build prompts: automation priorities
These are planning items, not features implemented by this update. Production work depends on verified tenant permissions, appropriate vendor agreements, approved clinical governance and PHI-capable storage; the existing real-patient lock remains in force. **Priority 1 — Connected document delivery and electronic signing.** Replace synthetic signing with a reviewed signing-service integration for patient, contractor, vendor and AI-provider agreements. Add lawyer-approved versioned templates, verified recipient identity, consent, ordered signers, owner/manager countersignatures, reminders, expiry, revocation before completion, immutable completed copies and downloadable audit evidence. Verify authenticated callbacks, prevent duplicate processing, reconcile delivery failures and preserve manual fallback. Acceptance: only the intended signer can sign; a callback replay cannot duplicate a signature; completed records cannot be edited; delivery alone never means signed. Do not assume a service connection alone establishes legal validity or HIPAA compliance. **Priority 2 — Patient self-service intake and document access.** Add authenticated patient access to existing intake data, communication preferences, missing forms and approved documents, with staff review of changes. Acceptance: patients cannot access another patient's records, opted-out channels receive no automated outreach, duplicate intake is not silently merged, and urgent symptoms route to clinical review rather than automated reassurance. Never advance a clinical plan from patient input. **Priority 2 implementation status:** Added a staff-only synthetic patient preview and submission review inbox. Intake creates staff review work without changing authoritative records; duplicate pending submissions and stale source updates are blocked, insurance changes require separate reconciliation, and medical concerns open independent clinical review tasks. Contact choices take effect immediately, default to no consent, and nothing is sent automatically. Only explicitly released patient-specific document snapshots are visible/downloadable; outlines remain unsigned and require legal review. This is not authenticated patient access: live patient identities, persistent patient records and secure isolation remain blocked on PHI-capable storage and go-live approvals. Preview submissions reset on reload. **Priority 3 — Controlled-substance administrative monitoring.** Track clinician-entered PDMP check dates, controlled-substance agreement renewals and clinician-owned review/taper tasks. Acceptance: overdue items create review work, not prescribing or taper decisions; missing information stays missing; any PDMP connection requires jurisdiction-specific approval and access rules. **Priority 3 implementation status:** Synthetic monitoring register added with clinician-entered due dates, PDMP/medication/taper review records, agreement renewal tracking linked to the document library, append-only evidence history and deduplicated clinician-owned due tasks. No live PDMP queries, prescribing, taper recommendations or regulatory compliance certification. Assigned available physicians/APPs record completed reviews and the next date; managers cannot make clinical entries. Demo monitoring resets on reload. Connected signing remains pending because the service connection was declined. **Priority 4 — Payer underpayment detection.** Compare versioned, reviewer-approved contract rates against adjudicated payments; account for units, modifiers, place of service, patient responsibility and adjustments. Route supported variances to a biller with source evidence. Acceptance: unknown rates are marked unknown, duplicate remittances do not inflate revenue, and alerts never automatically change claims or send appeals. Continue using simulated rates and payer records until a reviewed integration is available. **Priority 4 implementation status:** Claims & payments now includes synthetic contract-rate versions, explicit owner/manager approval, exact code-bundle/modifier/location and service-date matching, verified billing units, patient responsibility and evidence-backed payer reductions. Supported shortfalls can open deduplicated tasks for a qualified available biller with contract and remittance evidence; unknown or ambiguous rates remain unknown. Supplemental payments use incremental allocations; duplicate references on the same claim are rejected. Alerts never edit claims, record recovered revenue or send appeals. Sample rates are not actual fee schedules; all practice state resets on reload. Connected signing remains blocked on the declined service connection; authenticated patient self-service remains unbuilt. **Success measures for each priority:** Track staff minutes including AI review/correction, referral-to-visit time, no-show recovery rate, signature completion time, denied/underpaid dollars recovered and patient completion rates. Show denominators and missing data; validate baseline versus pilot results before claiming productivity or revenue gains. Use this as the project's standing context before any phase prompt. > Build **Practice ManagementOS**, an operations platform for independent interventional pain practices (3–15 providers), later expanding to orthopedic spine and spine-focused neurosurgery. It sits **alongside** the practice's existing EHR and billing system; it does not replace them. > > **Core job:** make sure every administrative task from referral to follow-up has an owner, a qualified backup, a due date, a next action, and evidence of completion, so work continues when any staff member is out. > > **Flow covered:** referral → patient record → encounter → clinician-selected treatment → authorization → procedure readiness → signed documentation (in the EHR) → coding review → reimbursement tracking → follow-up → outcomes → registry preparation. > > **Non-negotiable rules:** > - **Synthetic data only.** No real patient information. Show a persistent "Synthetic demo data" banner. > - **Label every simulated external result** (eligibility, authorization, claim, payment, message, external booking, registry submission) with a **SIMULATED** badge. > - **Clinical decisions stay with clinicians.** The platform never recommends or advances treatment, changes an order, signs a note, or advises on medication. > - **Administrative reassignment never grants clinical privileges,** signature authority, prescribing rights, or restricted-record access. > - **Never infer absence from inactivity.** Absence is set by a manager or a leave schedule. > - **No approval bypass.** Restricted actions wait for an authorized person, even near a deadline. > - **Every state change is audited:** actor, role, timestamp, before and after values, reason. > - **Use deterministic code** for permissions, date windows, workflow transitions, and reconciliation. AI may extract, summarize, and draft only, and its output is labeled "AI draft, needs review" with source links. > - **Missing data stays missing.** Absence of a record never becomes "no symptoms," "no complication," or "success." > > **Roles:** Practice owner, practice manager, physician, APP (NP/PA), nurse/MA, referral and scheduling coordinator, authorization specialist, coder/biller, registry coordinator, read-only auditor. > > **Design:** Calm, clinical, high-density interface. Each role lands on a "Today" view. Keep routine actions inline, without modal pop-ups, and keep primary actions within two clicks. Accessible contrast and keyboard navigation. > > **Backend:** Lovable Cloud for auth, database, and role-based row-level security. Roles live in a separate user-roles table, never on the profile. ---
Part 3. Sequential build prompts
Each prompt lists: problem, roles, screens, entities, states, AI behavior, integration fallback, ownership, security, demo data, acceptance criteria, and exclusions. Every slice includes its own security rules and tests; none are deferred to the end.
Prompt 1. Tenant, users, roles, and coverageIn prototype
- **Problem:** Practices cannot see who covers whom, and permissions leak when people cover for each other. - **Roles:** Owner and manager administer; everyone else views their own coverage. - **Screens:** Sign-in; Team (people, roles, locations, skills); Coverage calendar (planned leave, holidays, business hours, time zones); Availability toggle set by a manager. - **Entities:** tenant, location, user profile, user_role (separate table), skill, coverage_assignment (primary, backup, start, end), holiday_calendar, audit_event. - **States:** available → on planned leave → unavailable (manual) → returned. - **AI:** None. - **Ownership:** A backup must hold the same administrative role and skill. Coverage never adds clinical permissions. - **Security:** Tenant isolation through row-level security; role check function; MFA prompt; access revocation on departure. - **Demo data:** "Virtuoso Spine & Joint," 2 locations, 6 providers, 10 staff, a planned leave next week, and one holiday. - **Acceptance:** A user from tenant B cannot read tenant A data. Reassigning a scheduler to cover the authorization queue does not grant note-signing. Deactivating a user removes access immediately and moves their open tasks to backup. - **Excluded:** SSO; payroll.
Prompt 2. Patient records and source-linked documentsPartial
- **Problem:** Staff re-enter data and cannot tell verified facts from unverified ones. - **Screens:** Patient list with duplicate warnings; Patient workspace (demographics, insurance with effective dates, referring and treating providers, communication preferences, documents, timeline); Duplicate review queue. - **Entities:** patient, insurance_coverage, provider (internal and referring), clinical_document, document_version, data_field_provenance (source, author, event date, import date, verification status: imported / patient-reported / AI-extracted / clinician-verified / signed). - **AI:** Extracts demographic and referral fields from an uploaded synthetic PDF as "AI draft" with a source page reference. A human confirms each field. - **Security:** Uploaded document text is untrusted and cannot change permissions. Corrections are audited; there is no silent merge. - **Acceptance:** Two patients with the same name and birth date are flagged, not merged. Each field shows its provenance badge. An edited field keeps revision history. - **Excluded:** Real EHR import.
Prompt 3. Shared queues, workflow engine, and escalationIn prototype
- **Problem:** Work hides in personal inboxes and gets dropped during absences. - **Screens:** "Today" per role; Team queue (filter by owner, role, location, due, blocked); Task detail (linked patient or episode, next action, blockers, evidence, history); Handoff summary; Escalations board. - **Entities:** task (type, linked record, responsible role, owner, backup, priority, due, state, blocking_dependency, next_action, evidence, escalation_rule), handoff, escalation. - **States:** open → in progress → blocked → awaiting approval → done (with evidence) or cancelled (with reason). - **Routing:** When an owner goes on leave, eligible administrative tasks move to the qualified backup, who must accept. If the backup declines or none exists, the task escalates to the manager. Due dates that fall on holidays move per the practice rule and show the change. - **AI:** Drafts a handoff summary (what happened, what remains, next action, deadline, contacts, open discrepancies) with links to sources. It is marked as an AI draft. - **Acceptance:** Planned leave reassigns tasks with acknowledgment. Sudden absence set by a manager reassigns within the same day. A no-backup case escalates. Return from leave shows the reconciled task list with no duplicates. - **Excluded:** Automated phone outreach.
Prompt 4. Referrals and schedulingIn prototype
- **Problem:** Referrals stall waiting for records; procedures get booked before they are ready. - **Screens:** Referral inbox (received → records requested → under review → scheduled → attended → closed); Referral detail with missing-records checklist; Scheduler showing consults, follow-ups, procedures, and medication-management visits with provider, room, and equipment constraints; Readiness badge on every procedure slot. - **Entities:** referral, records_request, appointment, appointment_type, room, equipment, facility (internal or external), external_booking (requested / confirmed by facility / declined). - **Rules:** No double-booking. An external facility booking stays "requested" until a staff member records the facility's confirmation. Cancellations can be filled only from an approved waitlist. - **AI:** Drafts the records-request letter to the referring office for staff approval. - **Integration fallback:** Fax and portal steps are manual tasks with evidence upload. - **Acceptance:** Overlapping bookings are blocked. An unconfirmed external booking never shows as confirmed. Clinical concerns in a referral are routed to a nurse task, not handled by the scheduler.
Prompt 5. Treatment episodes and procedure readinessIn prototype
- **Problem:** Multi-visit pain pathways lose track of prior responses, authorizations, and prerequisites. - **Screens:** Episode timeline per patient (ESI, medial branch block → RFA, SI joint, SCS trial → permanent, PNS, intrathecal pump, medication management); Readiness checklist per planned procedure; Physician plan entry (clinician selects the plan). - **Entities:** treatment_episode, episode_plan (clinician-selected, versioned), procedure (planned / scheduled / performed), prior_response (documented by clinician), readiness_item (records, authorization, consent, escort, instructions sent, facility, equipment). - **Rules:** Only a physician or APP can create or change a plan. A plan change creates impact tasks on authorization, scheduling, instructions, and facility coordination. The checklist never advances the clinical pathway on its own. - **Acceptance:** Changing a planned level or laterality generates review tasks and marks readiness "needs review." SCS trial-to-permanent shows that both stages need separate readiness.
Prompt 6. Authorization and policy managementIn prototype
- **Problem:** Authorizations expire, mismatch scope, or fall outside the vendor service's coverage. - **Screens:** Authorization board (needed → submitted → pending info → approved / denied → expiring → expired); Authorization detail (payer, plan, codes, levels, units, validity window, reference number); Exceptions queue (missing documentation, additional-information request, scope mismatch, changed insurance, external orders, retro-authorization, peer-to-peer); Policy library (versioned, source, effective date, retrieval date, review status). - **Rules:** Authorization appeals and claim appeals are separate types. A new policy version flags potentially affected active cases for review and never applies itself automatically or retroactively. The previous policy version stays linked to cases already decided. - **AI:** Drafts additional-information responses and appeal letters from linked, signed documentation only. It never invents findings. - **Demo data:** All payer responses carry the SIMULATED badge. - **Acceptance:** An authorization expiring in 7 days creates a task. Changed insurance invalidates readiness. A policy update lists affected scheduled cases and assigns reviewers.
Prompt 7. Continuous discrepancy detectionNext
- **Problem:** Ordered, scheduled, authorized, performed, documented, and billed details drift apart. - **Screens:** Reconciliation view per procedure (a column per stage, mismatches highlighted); Discrepancy queue by severity and required reviewer. - **Entities:** discrepancy (field, stages compared, values, severity, reviewer role, status, resolution, approved exception with rationale, reviewer, timestamp). - **Fields compared:** Patient, procedure and codes, region, levels, laterality, units, provider, facility, place of service, date versus authorization window, device details. - **Rules:** Deterministic comparison only. The platform never edits a signed note or an order to make records match. A resolution requires a correction task or an approved exception. - **Acceptance:** Left versus right laterality between the authorization and the schedule is flagged high severity. Units mismatch is flagged. A date outside the authorization window blocks "ready."
Prompt 8. Documentation and billing handoffsNext
- **Problem:** Unsigned notes and coding questions delay claims; status words get confused. - **Screens:** Unsigned and missing-note queue (physician); Coding review queue (coder); Claim tracker with separate statuses for documentation complete, authorization valid, claim prepared, submitted, accepted by clearinghouse or payer, adjudicated, paid, and denied; Denial and appeal workspace. - **Rules:** Professional-fee workflow only. The platform tracks claims and never submits them in this phase. Signed versions are read-only; amendments are linked. - **AI:** Suggests codes with links to the documented evidence, for coder review. Drafts denial appeals. - **Acceptance:** "Submitted" never displays as "paid." A suggested code without supporting evidence is flagged. Duplicate claim or payment entries are flagged.
Prompt 9. Patient communicationNext
- **Problem:** Patients get contradictory, excessive, or missed messages. - **Screens:** Communication timeline per patient; Template library (referral acknowledgment, reminders, missing forms, approved prep instructions, follow-up questionnaires); Consent and preference panel; Inbound routing queue. - **Rules:** Respect opt-out, preferred channel, language, and frequency caps. Delivery does not count as understanding. Messages that mention possibly urgent symptoms route immediately to a clinical task and never get an automated reassurance. Medication questions route to a clinician. - **Demo data:** All sends are SIMULATED; no real SMS or email. - **Acceptance:** An opted-out patient receives nothing. Two conflicting reminders for the same visit are blocked. A message saying "new leg weakness" creates an urgent nurse task.
Prompt 10. Outcomes and registry preparationNext
- **Problem:** Follow-up data is incomplete and missing values get read as good results. - **Screens:** Follow-up schedule per episode (baseline, windows); Instrument entry (synthetic versions of pain and function scores, noting licensing needs for real instruments); Registry workspace (schema version, eligibility review, consent status, missing-field queries, export history). - **Rules:** Every missed follow-up needs an explicit reason (not reached, declined, deceased, transferred, unknown). Raw, normalized, and derived values are stored separately. No automatic enrollment, and no external disclosure; exports are CSV only, audited, and authorized. - **Acceptance:** A missing 3-month score shows "missing: not reached," never "improved." An export without consent status is blocked.
Prompt 11. Dashboards and net-effort measurementPartial
- **Problem:** Reporting is the most common complaint across competitors. - **Screens:** Role dashboards for physician, owner, manager, coordinator, authorization specialist, coder, registry coordinator, and coverage staff. - **Metrics:** Referral-to-visit and visit-to-procedure times; readiness rate; expiring and mismatched authorizations; open discrepancies; unsigned notes; claim and denial status; follow-up completeness; unowned tasks and coverage gaps; overdue escalations; AI drafts accepted, edited, and rejected; total human minutes, including review and correction; integration failures. - **Rules:** Show denominators and missing-data rates. No unadjusted provider quality rankings. No staff productivity ranking that penalizes approved leave. Every chart exports to CSV. - **Acceptance:** Each metric shows its denominator. AI review time is included in effort totals.
Prompt 12. Integration recovery and production-readiness checksNext
- **Problem:** Integrations fail silently and retries duplicate work. - **Screens:** Integration health (simulated EHR, clearinghouse, fax, messaging connectors: last success, failures, queued items); Exception and dead-letter queue; Manual fallback checklist per integration; "AI off" switch. - **Rules:** Idempotency keys on every outbound action; reconcile before replay after downtime; a successful API response does not mark business completion. Turning AI off leaves every workflow usable manually. - **Acceptance:** A simulated outage queues messages and replays them once without duplicates. A partial write is detected and routed to exceptions. With AI off, a referral moves from intake to scheduled manually. ---
Part 4. Expansion prompts (later phases)
**E1. Orthopedic spine module.** Add imaging and report availability, prior conservative-treatment documentation, a surgeon-selected surgical plan, surgeon, facility, and anesthesia coordination, pre-op clearances, implant and instrument availability, a changed-plan impact assessment, operative-note and professional-billing handoffs, post-op coordination, global-period coding review, and disability and return-to-work paperwork. Surgeons choose the surgery, implant, approach, and levels. **E2. Spine-focused neurosurgery.** Reuse E1 components; validate neurosurgery workflows separately; add hospital dependencies and patient or proxy communication. Never decide that a possibly urgent neurological complaint can wait. **E3. Registry and analytics expansion.** Versioned external registry schemas, data dictionaries, critical-field verification, query workflows, and supported export formats. Keep care delivery, quality improvement, and research permissions separate. **E4. Real integrations (only after a compliant, BAA-covered backend is in place).** One EHR (the first pilot's), one clearinghouse, fax, and messaging. Each one needs documented read and write scope, sandbox testing, rate limits, and a manual fallback. ---
Part 5. Prioritized backlog
| Priority | Item | Phase | |---|---|---| | P0 | Tenant isolation, roles table, audit log | 1 | | P0 | Task ownership, backup coverage, escalation | 1, 3 | | P0 | Referral inbox and missing-records tracking | 4 | | P0 | Procedure readiness checklist | 5 | | P0 | Authorization board with expiry alerts | 6 | | P0 | Physician "Today" briefing and approval inbox | 3, 8 | | P1 | Discrepancy detection across stages | 7 | | P1 | Policy library with affected-case review | 6 | | P1 | Unsigned-note and coding-review queues | 8 | | P1 | Role dashboards with CSV export | 11 | | P2 | Patient communication templates and consent | 9 | | P2 | Outcomes schedule and missing-reason capture | 10 | | P2 | Integration health and AI-off switch | 12 | | P3 | Registry exports | 10, E3 | | P3 | Orthopedic spine and neurosurgery modules | E1, E2 | **First build:** Prompts 1 through 5, plus the physician briefing from Prompt 3. This is enough to demo continuity during absence, referral flow, and procedure readiness on synthetic data.

