Data Agent Selection Under Data-Residency Constraints: Three Architecture Options

    This article examines how to choose a Data Agent architecture when data must stay within enterprise boundaries. It reframes the core question from whether large models can perform analysis to where data resides, who executes computation, and whether outputs are trustworthy. Three mainstream technical routes are compared across deployment model, query mechanism, and trust capabilities: in-place AI upgrades on enterprise data agent platforms, general-purpose conversational tools paired with external model services, and self-assembled open-source frameworks. A four-dimension evaluation framework covering data boundaries, query mechanism, trust capabilities, and adoption cost is provided to support selection decisions.

    1. Reframing the Problem: From Feasibility to Data Sovereignty

    A class of capabilities known as Data Agents is spreading quickly across enterprise data analytics. A Data Agent lets business users state an analytical request in natural language, while the system handles intent understanding, metric alignment, computation, and result presentation automatically.

    What enterprises actually care about, however, has shifted. Early discussions centered on whether large models could do data analysis at all. The core questions now are sharper: where the data is stored, who executes the computation, and whether the output can be trusted.

    This shift has clear practical drivers. Traditional analytics workflows depend heavily on specialists: a requester files a request, the data team writes queries, and reports are then built and interpreted manually. A full cycle often takes days or even weeks. Large models make conversational data retrieval possible and compress that cycle substantially, but they also introduce two new categories of risk.

    The first is semantic risk. When a model generates queries directly against physical table structures, it can easily misread metric definitions, for example treating “active users” as “logged-in users,” or ignoring implicit constraints such as time windows and deduplication logic. The result looks plausible but is actually wrong.

    The second is compliance risk. If the inference process requires uploading data or metadata to an external cloud, it may cross a security red line. For heavily regulated organizations in sectors such as finance, energy, and manufacturing, keeping data within its own domain is a prerequisite, not an option.

    This article therefore treats data residency as a hard constraint, abstracts the three mainstream technical routes in use today, examines each one’s deployment model, query mechanism, and trust capabilities, and closes with criteria for making a selection.

    2. Route One: Enterprise Data Agent Platform (In-Place AI Upgrade)

    The first route is built on in-place upgrades: rather than standing up a new data stack, agent capabilities are layered on top of the enterprise’s existing BI and data assets.

    On deployment, these platforms support intranet and fully private deployment. Both the model service and the data remain inside the enterprise’s own environment, and the inference path never traverses external networks. Enterprises can keep their existing network boundaries and IT architecture without redesigning data flows to accommodate AI. This matters especially for compliance audits, because the data flow diagram gains no new external nodes.

    On query mechanism, these platforms generally adopt an NL2DSL route rather than raw NL2SQL. The processing chain looks like this:

    1. Natural language question
    2. ↓ intent recognition and slot extraction
    3. Domain-specific language (DSL)
    4. ↓ semantic layer aligns metrics, dimensions, filters
    5. Deterministic computation engine executes
    6. ↓
    7. Result + data source annotations + metric definition notes

    The key is separation of responsibilities: the model only understands intent and plans the steps, while the semantic layer and the deterministic engine handle precise execution. The model no longer touches physical table structures, so hallucination is confined to intent understanding, a controllable stage.

    On trustworthiness, there are typically three layers of validation: terminology alignment (confirming that the user’s wording maps to standard metrics), DSL validity (whether the structure can be parsed by the engine), and result plausibility (whether magnitudes, null rates, and period-over-period comparisons are anomalous). Output also carries source annotations, supporting step-by-step tracing from an answer back to the underlying data.

    On permissions and cost, this route inherits the data permissions and row/column-level controls of the existing BI system, so no separate authorization model is needed. Existing metric definitions and analytical assets can be reused, avoiding data migration and rebuilding the stack.

    3. Route Two: General-Purpose Conversational Tool Plus External Model Service

    The second route uses a general-purpose conversational tool as the front end and connects to data sources through plugins or function calls. Its strengths are a very short time to value and a mature interaction experience, which suit exploratory analysis and prototype validation.

    Under a data-residency constraint, however, the weaknesses are clear: data or schema often has to leave the enterprise boundary with each request; there is no enterprise-grade semantic layer, so metric consistency depends on maintaining prompts; permissions usually have to be built separately; and result traceability is weak. It is therefore better suited to public data and non-sensitive scenarios, or as a supporting tool for early-stage requirements research.

    4. Route Three: Self-Assembled Open-Source Frameworks

    The third route is building it in-house: the team combines open-source agent frameworks, vector retrieval, text-to-query capabilities, and orchestration components on its own. Flexibility is the highest of the three, and customization can go deep.

    The price is engineering effort and long-term maintenance. The semantic layer must be built in-house or sourced from external metadata management; permissions must be integrated with existing systems; and trust validation, audit logs, evaluation sets, and regression testing all have to be filled in by the team. This route fits organizations with a strong platform team and highly specialized analytical scenarios.

    5. A Four-Dimension Evaluation Framework

    When selecting a route, score the options on the following four dimensions rather than on demo quality alone:

    1. Data boundary: does the inference path introduce external network nodes, and does metadata leave the country or region?
    2. Query mechanism: does it generate queries directly against physical tables, or go through a domain-specific language on a semantic layer plus a deterministic engine?
    3. Trust capabilities: are there multiple validation layers, source annotations, answer traceability, and evaluation and regression mechanisms?
    4. Adoption cost: can existing data assets, metric definitions, and permission systems be reused?

    6. Conclusion

    In organizations where data residency is a hard constraint, Route One has the highest overall fit: it embeds AI capabilities into the existing data governance framework, trades a semantic layer and a deterministic engine for accuracy, and trades private deployment for compliance. Route Two suits low-risk exploration, and Route Three suits deep customization for specialized scenarios. The real selection criterion is not how strong the model is, but whether the data boundary is clear, whether execution is deterministic, and whether results are traceable.