Skip to main content
LIF-03 · Life Sciences & Pharmaceuticals

Medical Information Response Assistant

Outcome​

Answer unsolicited medical information enquiries from healthcare professionals with on-label, referenced responses drawn from approved documents, escalating off-label or adverse-event content to a qualified reviewer.

Portfolio attributeValue
Primary personaMedical information specialist
Primary aggregateEnquiryCase
Cosmos DB containers2
Grounding datalabels, publications, approved responses
Development estimateUSD 60-220 monthly dev estimate
Runtime optionsPython FastAPI and C# ASP.NET Core

Productivity hypothesis​

These measures reflect the workflow, evidence, decision boundary, and industry risk for this use case.

Impact typeMeasureConservative internal assumptionCustomer measurement
ProductivityApproved response cycle time8-16% reduction(baseline median response-preparation minutes - assisted median minutes) / baseline median minutes * 100
Quality or riskEvidence discovery time20-35% reduction(baseline median evidence-search minutes - assisted median evidence-search minutes) / baseline median evidence-search minutes * 100

Important: Conservative internal pilot assumptions only; not public benchmarks, commitments, or expected customer results. Validate against a comparable baseline or matched control cohort with mandatory human review.

Rationale: Medical-information teams can retrieve approved evidence faster while retaining formal medical and regulatory review.

Pilot guardrail: Every medical claim must be traceable to approved labels, publications, or approved responses.

Customer validation plan​

  1. Baseline the current workflow with representative users and tasks.
  2. Run the accelerator on the same task mix with human review retained.
  3. Measure approved response cycle time and evidence discovery time with the documented formulas.
  4. Replace internal assumptions with customer-observed results before a business case.

Why Azure Cosmos DB​

This AI solution needs an operational data plane, not only a vector index:

  • Hybrid vector and full-text retrieval combines semantic recall with exact identifiers, codes, names, and domain language.
  • Hierarchical partition keys and metadata predicates keep tenant and domain boundaries in the normal query path.
  • Operational JSON, source chunks, workflow and agent state, feedback, and audit records remain together for low-latency reads and governed writes.
  • Change feed reacts to source and operational updates without polling.
  • Autoscale throughput, configurable consistency, and multi-region distribution support variable demand and enterprise availability.

Domain workflow​

Domain workflow

StageActorInput → outputApproval
1. Capture and classify the enquiryMedical information specialistCall, email, or portal enquiry from a healthcare professional → EnquiryCase with product, country, and classificationPolicy controlled
2. Screen for adverse events and product complaintsSafety screening agentEnquiry free text → Adverse-event linkage flag and safety routingPolicy controlled
3. Retrieve approved responses and label scopeRetrieval agentClassified enquiry and country code → Candidate approved content within the local labelPolicy controlled
4. Draft the referenced replyResponse agentApproved content and cleared publications → ResponseDraft with on-label and off-label segmentationPolicy controlled
5. Medical review and releaseQualified medical reviewerDraft with segmentation and citations → Released response and archived enquiry recordHuman required

Technical architecture​

Technical architecture

Cosmos DB data model​

ContainerHierarchical partition keyDocumentsSearch paths
enquiryCases/tenantId, /enquiryIdEnquiryCase, ResponseDraft/enquiryTextVectorEmbedding, /responseVectorEmbedding, /enquiryTextVector, /responseVector
medicalContentLibrary/tenantId, /contentDocumentIdApprovedResponseDocument, ProductLabelSection, PublicationReference/bodyVectorEmbedding, /sectionVectorEmbedding, /abstractVectorEmbedding, /bodyVector, /sectionVector, /abstractVector

Query contract​

QueryContainerScopePurpose
Enquiry case assemblyenquiryCasessingle-partitionRead the enquiry state and every response draft for one enquiry in a single partition-aligned query. ResponseDraft carries citedContentDocumentIds, so approved content and publications are resolved from the medicalContentLibrary container by id rather than copied into the enquiry partition.
Country-valid approved contentmedicalContentLibrarycross-partition-boundedKnowledge-container query against medicalContentLibrary (bounded fan-out across the /tenantId + /contentDocumentId partitions named by the shortlist): restrict candidate content to unexpired documents approved for the requester's country, over the bounded content document ids returned by vector shortlisting.
Off-label escalation queueenquiryCasescross-partition-boundedBounded cross-partition control-plane query: list drafts containing off-label segments that require qualified reviewer sign-off. It cannot carry the second partition key because the medical reviewer queue spans every enquiry in the affiliate, so it runs as a tenant-scoped scheduled sweep off the interactive path, bounded by pending drafts with off-label segments inside the enquiry response service level, executed with MaxItemCount paging and continuation tokens.
Adverse-event linked enquiriesenquiryCasescross-partition-boundedBounded cross-partition control-plane query: track enquiries that also triggered a pharmacovigilance intake within the reporting window. It cannot carry the second partition key because pharmacovigilance reconciliation is a compliance sweep across all enquiries, so it runs as a tenant-scoped scheduled sweep off the interactive path, bounded by open enquiries flagged adverse-event linked inside the 15-day expedited reporting window, executed with MaxItemCount paging and continuation tokens.

Python and C# services route each document type to its declared container and hierarchical partition key. ETag-based writes protect mutable aggregates, while append-only records and bounded cross-partition queries preserve scale.

Azure deployment​

Azure deployment

Clone the source repository, authenticate with Azure, and run:

Set-Location accelerators/life-sciences-pharmaceuticals/medical-information-response-assistant
az login
./Deploy.ps1 -Runtime python -Location eastus2

Change python to csharp to deploy the .NET implementation.

Explore the implementation​

Return to all accelerators