Clinical Trial Protocol Copilot
Outcome
Accelerate clinical trial protocol authoring by drafting sections from prior protocols, regulatory standards, and study assumptions while surfacing feasibility and patient-burden risks for the study team to resolve.
| Portfolio attribute | Value |
|---|---|
| Primary persona | Clinical operations lead |
| Primary aggregate | ProtocolDocument |
| Cosmos DB containers | 2 |
| Grounding data | protocols, standards, study assumptions |
| 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 | Protocol task cycle time | 10-18% reduction | (baseline median protocol-task minutes - assisted median minutes) / baseline median minutes * 100 |
| Quality or risk | Rework rate | 5-12% reduction | (baseline corrected or repeated protocol-task rate - assisted rate) / baseline rate * 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: Standards and study assumptions support faster protocol drafting and review preparation in an approval-gated workflow.
Pilot guardrail: Clinical, statistical, regulatory, ethical, and operational approvals remain mandatory.
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 protocol task cycle time and rework rate 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. Define study assumptions and comparators | Clinical operations lead | Indication, phase, endpoints, and prior study references → ProtocolDocument shell with assumption set | Policy controlled |
| 2. Retrieve precedent protocols and standards | Retrieval agent | Indication and phase filters → Precedent sections and applicable guidance clauses | Policy controlled |
| 3. Draft protocol sections with lineage | Authoring agent | Precedents, standards, and assumptions → ProtocolSectionDraft set with source lineage | Policy controlled |
| 4. Model feasibility and patient burden | Feasibility analytics service | Eligibility criteria and visit schedule → FeasibilityAssessment with recruitment estimates | Policy controlled |
| 5. Study team review and version release | Medical monitor and study team | Drafted protocol with feasibility findings → Released protocol version for review board submission | Human required |
Technical architecture

Cosmos DB data model
| Container | Hierarchical partition key | Documents | Search paths |
|---|---|---|---|
protocolDocuments | /tenantId, /studyId | ProtocolDocument, ProtocolSectionDraft, EligibilityCriterion, FeasibilityAssessment | /sectionVectorEmbedding, /criterionVectorEmbedding, /sectionVector, /criterionVector |
regulatoryStandardsLibrary | /tenantId, /standardId | RegulatoryStandardClause | /clauseVectorEmbedding, /clauseVector |
Query contract
| Query | Container | Scope | Purpose |
|---|---|---|---|
| Protocol assembly by section | protocolDocuments | single-partition | Read the current draft of every section for the study in one partition query. |
| Restrictive criteria review | protocolDocuments | single-partition | Find eligibility criteria whose modelled screening impact is severe. |
| Applicable guidance lookup | regulatoryStandardsLibrary | cross-partition-bounded | Knowledge-container query against regulatoryStandardsLibrary (bounded fan-out across the /tenantId + /standardId partitions named by the shortlist): retrieve the clauses in force for the standards that govern this study, fanned out across the small fixed set of applicable standard ids. |
| Open protocol issues | protocolDocuments | single-partition | List sections carrying unresolved authoring issues before version release. |
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/clinical-trial-protocol-copilot
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