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 attribute | Value |
|---|---|
| Primary persona | Medical information specialist |
| Primary aggregate | EnquiryCase |
| Cosmos DB containers | 2 |
| Grounding data | labels, publications, approved responses |
| Development estimate | USD 60-220 monthly dev estimate |
| Runtime options | Python FastAPI and C# ASP.NET Core |
Productivity hypothesis
These measures reflect the workflow, evidence, decision boundary, and industry risk for this use case.
| Impact type | Measure | Conservative internal assumption | Customer measurement |
|---|---|---|---|
| Productivity | Approved response cycle time | 8-16% reduction | (baseline median response-preparation minutes - assisted median minutes) / baseline median minutes * 100 |
| Quality or risk | Evidence discovery time | 20-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
- Baseline the current workflow with representative users and tasks.
- Run the accelerator on the same task mix with human review retained.
- Measure approved response cycle time and evidence discovery time with the documented formulas.
- 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

| Stage | Actor | Input → output | Approval |
|---|---|---|---|
| 1. Capture and classify the enquiry | Medical information specialist | Call, email, or portal enquiry from a healthcare professional → EnquiryCase with product, country, and classification | Policy controlled |
| 2. Screen for adverse events and product complaints | Safety screening agent | Enquiry free text → Adverse-event linkage flag and safety routing | Policy controlled |
| 3. Retrieve approved responses and label scope | Retrieval agent | Classified enquiry and country code → Candidate approved content within the local label | Policy controlled |
| 4. Draft the referenced reply | Response agent | Approved content and cleared publications → ResponseDraft with on-label and off-label segmentation | Policy controlled |
| 5. Medical review and release | Qualified medical reviewer | Draft with segmentation and citations → Released response and archived enquiry record | Human required |
Technical architecture

Cosmos DB data model
| Container | Hierarchical partition key | Documents | Search paths |
|---|---|---|---|
enquiryCases | /tenantId, /enquiryId | EnquiryCase, ResponseDraft | /enquiryTextVectorEmbedding, /responseVectorEmbedding, /enquiryTextVector, /responseVector |
medicalContentLibrary | /tenantId, /contentDocumentId | ApprovedResponseDocument, ProductLabelSection, PublicationReference | /bodyVectorEmbedding, /sectionVectorEmbedding, /abstractVectorEmbedding, /bodyVector, /sectionVector, /abstractVector |
Query contract
| Query | Container | Scope | Purpose |
|---|---|---|---|
| Enquiry case assembly | enquiryCases | single-partition | Read 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 content | medicalContentLibrary | cross-partition-bounded | Knowledge-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 queue | enquiryCases | cross-partition-bounded | Bounded 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 enquiries | enquiryCases | cross-partition-bounded | Bounded 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

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
- Launch signed-in demo
- Implementation article
- Domain data model
- Workflow and API contract
- Python application
- C# application
- Domain container Bicep
- Platform Bicep
- Cost and configuration
- Source repository