medical_records_processing · healthcare · workflow

MSD uses Amazon Bedrock and Claude 3.5 Sonnet to translate natural language into SQL for complex healthcare databases

MSD analysts and data scientists spend considerable time manually querying complex healthcare databases, slowing productivity and delaying data-driven decision-making. Healthcare datasets pose additional challenges including coded columns, non-intuitive column names, long medical code lists, and ambiguous queries.

How it works
Common implementation structure
How this type of workflow is generally built, generalized across documented cases — not tied to any one vendor's stack. Click any stage to read what happens there. Specific products that implement these stages appear in “Tools commonly seen” below.
Stage 1 · Analyst submits NL question
An analyst submits a natural language question instead of writing a complex SQL query.
Tools used
Amazon BedrockClaude 3.5 SonnetConverse APISQLiteStreamlit
Outcome

The text-to-SQL solution at MSD markedly accelerated data access and boosted analyst productivity by simplifying the SQL query process, allowing analysts to dedicate more time to data interpretation and strategic decision-making.

What failed first

Out-of-the-box text-to-SQL libraries required a custom approach because they could not handle coded columns, non-intuitive names, excessively long medical code lists, and query ambiguity inherent in healthcare datasets.

Results
Time savedpotentially reducing query time from hours to minutes
Source

https://aws.amazon.com/blogs/machine-learning/how-merck-uses-amazon-bedrock-to-translate-natural-language-into-sql-for-complex-healthcare-databases?tag=soumet-20

How we source this →

Grounding & classification
Source type: technical build writeup
27 fields verified against source quotes.
agentic workflowcode generationconversational aidata extractionmedical recordfailure mode describednamed customerproduction runtime claimedsource backedtools describedvendor confirmedworkflow describedpharma life sciencescycle time reductionemployee productivitytime savedtechnical build writeupback office opsmedical records processingagentic task execution