The Problem

Healthcare data is among the most complex, high-stakes information in any organization. Physicians, organizations, payments, referral networks, and outcomes are all deeply interconnected — but that richness comes at a cost. For most healthcare technology companies, accessing meaningful insights from this data requires technical specialists who know how to write queries, navigate relational database schemas, and stitch together answers from multiple sources. It is not merely a training gap: on Spider, a cross-domain text-to-SQL benchmark of 10,181 questions and 5,693 complex queries over 200 multi-table databases in 138 domains, the best model of its day managed 12.4% exact-match accuracy against databases it had not seen [2], and on the later BIRD benchmark, grounded in large real database content, the leading model reached 40.08% execution accuracy where human annotators reached 92.96% [1]. Business users — analysts, account managers, even executives — are effectively locked out.

The consequences are real and compounding. When a non-technical team member needs a data answer, they either wait in a queue for an analyst, make decisions without the data they need, or spend hours manually pulling and reconciling information from disparate systems. For companies serving large enterprise clients like pharmaceutical manufacturers or health systems, this bottleneck doesn't just slow down internal operations — it degrades the quality of the product they deliver.

Scaling this problem makes it worse. As a healthcare data company adds clients, each with unique reporting needs and varying levels of data sophistication, the demand on technical resources grows linearly while the ability to serve that demand stays flat. Security and multi-tenancy requirements add further complexity: every client needs isolated, auditable access, and isolation is a separate discipline from login. AWS puts the distinction bluntly: "tenant isolation is separate from general security mechanisms... the fact that a tenant user is authenticated does not mean that your system has achieved isolation," and "a user could be authenticated and authorized, and still access the resources of another tenant" [7] — which is why crossing that boundary "would represent a significant and potentially unrecoverable event for a SaaS business" [8]. Without a smarter architecture, growth itself becomes the enemy.


The Solution

AI-powered data agents represent a fundamental shift in how organizations interact with complex, multi-source data. Rather than requiring users to understand data structures, write queries, or know which database holds which information, a data agent acts as an intelligent intermediary — translating natural language questions into precise data retrieval operations and returning clear, context-rich answers.

At its core, this approach combines several capabilities working in concert. A large language model interprets the user's intent, understanding domain-specific terminology and ambiguous phrasing. A relationship-aware reasoning layer maps entities across multiple databases — understanding, for example, that a question about a physician's payment relationships requires joining data across three separate tables. The system then synthesizes the results into a coherent, human-readable response, surfacing the insight rather than the raw data.

A technical diagram showing the flow of a user query through a security layer, into an LLM intent interpreter, connecting to a relationship reasoning layer that joins multiple disparate database tables, and returning a synthesized insight to the user.
A technical diagram showing the flow of a user query through a security layer, into an LLM intent interpreter, connecting to a relationship reasoning layer that joins multiple disparate database tables, and returning a synthesized insight to the user.

What makes this production-viable for enterprise healthcare is the architecture around it: multi-tenant access controls that ensure client data isolation [8], integration with enterprise identity providers for authentication — OpenID Connect being the interoperable layer, "a simple identity layer on top of the OAuth 2.0 protocol" [11] — and guardrails that prevent the system from returning inaccurate or out-of-scope responses, which in a managed retrieval stack means separately configured guardrails, metadata filters and reranking rather than one setting [12]. Grounding the answer in retrieved records rather than model weights is the same move retrieval-augmented generation was introduced to make, given that "providing provenance for their decisions and updating their world knowledge remain open research problems" for parametric models [3]. The goal is not just to make data accessible — it's to make it trustworthy.


ROI & Business Value

OutcomeImpact
Time reclaimed100+ hours of manual data analysis eliminated per month
Speed to insightBusiness users get answers in seconds instead of days
Technical dependencyNon-technical users operate independently, no analyst required
Deployment speedProduction-ready proof of concept achievable in weeks, not quarters
ScalabilitySingle platform serves multiple enterprise clients simultaneously
Decision qualityStakeholders act on complete, cross-database insights rather than partial views
Competitive positioningData accessibility becomes a differentiator in client retention and acquisition

The compounding effect here matters: when analysts are no longer fielding repetitive data requests, they redirect their capacity toward higher-value work — building models, identifying trends, and supporting strategic decisions rather than running the same ad hoc queries week after week.


Practical Implementation Guide

  1. Audit your current data request volume. Quantify how many hours per week are spent fulfilling data requests from non-technical stakeholders. This becomes your baseline ROI case and helps prioritize which query types to automate first.

  2. Map your data relationships. Before any AI layer can work reliably, you need a clear entity-relationship model. Document how your key data entities connect across systems — this is the foundation for accurate, cross-database responses.

  3. Define your user personas and query patterns. Identify who will use the system and what questions they actually ask. Grouping queries by type (e.g., lookup, aggregation, comparison, trend analysis) helps you design the agent's reasoning paths and test coverage.

  4. Choose a foundation model and cloud infrastructure. Select an LLM with strong structured-data reasoning capabilities and deploy it within an architecture that supports your data residency and compliance requirements. Enterprise healthcare typically demands that data stay within controlled infrastructure — and the managed-model providers now document that boundary explicitly, with AWS stating that model providers cannot reach the deployment accounts and so "don't have access to Amazon Bedrock logs or to customer prompts and completions" [9].

  5. Build and test your security and access control layer first. Multi-client environments require rigorous tenant isolation, which "focuses exclusively on using tenant context to limit access to resources" and is applied separately from the authentication and authorization already in the application [7]. Implement role-based access controls and test them before enabling any natural language query capability — security is not a post-launch consideration. In a HIPAA environment the specific obligations are named: access control that allows access "only to those persons or software programs that have been granted access rights," audit controls, integrity, authentication and transmission security [4], plus the minimum necessary standard limiting each use, disclosure or request to "the minimum necessary to accomplish the intended purpose" [5].

  6. Start narrow, then expand. Launch with a limited set of high-frequency, well-defined query types. Validate accuracy against known answers, gather user feedback, and iterate before broadening scope.

  7. Instrument for observability. Log queries, responses, and confidence signals — deliberately, because model invocation logging on a mainstream inference platform is disabled by default and only begins capturing request and response bodies once a CloudWatch Logs or S3 destination is configured [10]. This data is essential for improving accuracy over time and for demonstrating compliance with audit requirements in regulated industries, where HIPAA requires procedures to "regularly review records of information system activity, such as audit logs, access reports, and security incident tracking reports" [6] and healthcare buyers increasingly ask for it against a harmonized control library covering 70-plus standards [13].

  8. Train users, not just the model. Roll out with structured onboarding that shows business users how to ask effective questions. Natural language interfaces are intuitive — but setting expectations about scope and accuracy builds trust faster.

    A linear 8-step workflow diagram starting from data auditing and relationship mapping, moving through infrastructure setup and security layer building, and ending with iterative testing and user onboarding.
    A linear 8-step workflow diagram starting from data auditing and relationship mapping, moving through infrastructure setup and security layer building, and ending with iterative testing and user onboarding.


FAQ

Does this work under HIPAA, and can the data stay inside our own infrastructure?

The architecture is built to make those controls enforceable, not to certify them. HIPAA's technical safeguards name what has to be true — access control limited to "those persons or software programs that have been granted access rights," plus audit controls, integrity, authentication and transmission security [4] — and the minimum necessary standard constrains what any single query is permitted to return [5]. On residency, the managed-model providers now document the boundary directly: AWS states that model providers cannot reach the deployment accounts and therefore "don't have access to Amazon Bedrock logs or to customer prompts and completions" [9]. The compliance conclusion still comes from your own assessment, not from the architecture diagram.

What drives the cost?

This case study reports reclaimed analyst hours, not a price, and the cost is dominated by work that happens before any query runs. Mapping the entity relationships across your databases is the largest single item — mostly one-time, but not small. After that: query volume against your chosen model; the retrieval configuration surface you have to tune and keep tuned, since guardrails, metadata filtering, chunk counts, reranking and query decomposition are separately configured controls rather than one setting [12]; log retention, which only begins accruing once a destination is configured [10]; and the isolation model, which gets more expensive the harder you enforce it per client.

How long does it take, and what was the hardest part?

A production-ready proof of concept is achievable in weeks rather than quarters — but that is the proof of concept, not org-wide coverage. The hardest part is accuracy on exactly the questions that justify the project: multi-table joins across systems. The benchmark evidence is blunt about the gap. On BIRD, grounded in large real database content, the strongest model tested reached 40.08% execution accuracy where human annotators reached 92.96% [1]. That gap is why this deployment runs narrow-then-broad, validating answers against known-good results before widening scope, rather than pointing a model at the full schema on day one.

What did the team need in place before starting?

A documented entity-relationship model is the real prerequisite. Without a clear picture of how key entities connect across systems, a cross-database answer has nothing reliable to be derived from, and the AI layer inherits the ambiguity instead of resolving it. Alongside that: an enterprise identity provider to integrate with, OpenID Connect being the interoperable layer for it [11]; a defined set of user personas and the questions they actually ask, so reasoning paths and test coverage have a target; infrastructure that already satisfies your residency requirements; and a baseline measurement of current request volume, which is what the ROI case is built from.

Where would this approach not work?

Three places. Where relationships between systems are undocumented or genuinely inconsistent — the agent will produce fluent answers over an incoherent model, which is worse than no answer at all. Where the question requires judgment the data does not contain: this makes existing data askable, it does not supply data you never captured. And in any multi-client environment where retrieval cannot be scoped by tenant context, because authentication does not deliver isolation — a user "could be authenticated and authorized, and still access the resources of another tenant" [7], and crossing that boundary is described as "a significant and potentially unrecoverable event" [8].


References

  1. On BIRD, a text-to-SQL benchmark grounded in large real-world database content, the strongest LLM tested reached 40.08% execution accuracy against 92.96% for human annotators — a 52.88-point gap on exactly the kind of multi-table enterprise question this deployment answers — Li et al. (2023): https://arxiv.org/abs/2305.03111
  2. Spider comprises 10,181 questions and 5,693 unique complex SQL queries over 200 multi-table databases across 138 domains, with train and test sets deliberately drawn from different databases; "the best model achieves only 12.4% exact matching accuracy on a database split setting" — Yu, Zhang, Yang et al. (2018): https://arxiv.org/abs/1809.08887
  3. The paper introducing retrieval-augmented generation notes that pre-trained models' "ability to access and precisely manipulate knowledge is still limited," and that "providing provenance for their decisions and updating their world knowledge remain open research problems" — the case for grounding answers in retrieved records — Lewis, Perez, Piktus et al., NeurIPS (2020): https://arxiv.org/abs/2005.11401
  4. The HIPAA Security Rule's technical safeguards require access control policies that "allow access only to those persons or software programs that have been granted access rights," audit controls that "record and examine activity in information systems that contain or use electronic protected health information," integrity protection, person-or-entity authentication and transmission security — 45 CFR 164.312, via Cornell Legal Information Institute: https://www.law.cornell.edu/cfr/text/45/164.312
  5. HIPAA's minimum necessary standard requires a covered entity or business associate to "make reasonable efforts to limit protected health information to the minimum necessary to accomplish the intended purpose of the use, disclosure, or request" — the constraint a natural-language query interface has to enforce at retrieval time — 45 CFR 164.502(b), via Cornell Legal Information Institute: https://www.law.cornell.edu/cfr/text/45/164.502
  6. HIPAA's administrative safeguards require procedures to "regularly review records of information system activity, such as audit logs, access reports, and security incident tracking reports," plus workforce clearance, termination procedures, and periodic technical and non-technical evaluation — 45 CFR 164.308, via Cornell Legal Information Institute: https://www.law.cornell.edu/cfr/text/45/164.308
  7. AWS states that "tenant isolation is separate from general security mechanisms," that "the fact that a tenant user is authenticated does not mean that your system has achieved isolation," and that "a user could be authenticated and authorized, and still access the resources of another tenant" — isolation instead "focuses exclusively on using tenant context to limit access to resources" — Amazon Web Services, SaaS Architecture Fundamentals whitepaper (archived for historical reference): https://docs.aws.amazon.com/whitepapers/latest/saas-architecture-fundamentals/tenant-isolation.html
  8. The AWS Well-Architected SaaS Lens treats tenant isolation as "one of the foundational topics that every SaaS provider must address," noting that crossing the tenant boundary "would represent a significant and potentially unrecoverable event for a SaaS business" and that isolation strategy varies by domain, compliance regime, deployment model and service selection — Amazon Web Services (2026): https://docs.aws.amazon.com/wellarchitected/latest/saas-lens/tenant-isolation.html
  9. Amazon Bedrock deploys each model provider's inference software into a service-owned Model Deployment Account per Region and provider; because "the model providers don't have access to those accounts, they don't have access to Amazon Bedrock logs or to customer prompts and completions" — Amazon Web Services (2026): https://docs.aws.amazon.com/bedrock/latest/userguide/data-protection.html
  10. Amazon Bedrock model invocation logging "is disabled by default"; once a CloudWatch Logs or Amazon S3 destination is configured it records the full request and response with the caller's IAM/STS ARN, model ID, operation, timestamp and token counts, queryable per principal — Amazon Web Services (2026): https://docs.aws.amazon.com/bedrock/latest/userguide/model-invocation-logging.html
  11. OpenID Connect Core 1.0 is "a simple identity layer on top of the OAuth 2.0 protocol" that "enables Clients to verify the identity of the End-User based on the authentication performed by an Authorization Server" — OpenID Foundation (2023): https://openid.net/specs/openid-connect-core-1_0.html
  12. A managed retrieval layer exposes guardrails, manual and implicit metadata filtering, chunk counts, hybrid versus semantic search, reranking and query decomposition as separately configured controls — the mechanism for scoping what a query is allowed to retrieve — Amazon Web Services (2026): https://docs.aws.amazon.com/bedrock/latest/userguide/kb-test-config.html
  13. The HITRUST CSF is "a unified control library that harmonizes over 70 standards and regulations into a single, integrated approach for defining and assessing security controls," integrating ISO/IEC, NIST, HIPAA, PCI and GDPR requirements, with e1 (43 core controls), i1 (182 control requirements) and r2 certifications — HITRUST Alliance (2026): https://hitrustalliance.net/hitrust-framework