How to Choose a Data Agent When Data Must Stay Within Your Network
This article explains why keeping data inside a controlled boundary has become a prerequisite for adopting a Data Agent, and compares three common build paths: in-place AI upgrades on an existing enterprise BI platform, assembling open-source frameworks in-house, and calling external cloud services. It then examines the query mechanism shift from raw NL2SQL to a domain-specific language (DSL) backed by a BI semantic layer, the three-layer trust validation and traceability design, and why inheriting existing permissions and assets beats rebuilding them. A final checklist covers deployment, semantic governance, execution determinism, trustworthiness, permission models, asset reuse, and operational observability.
1. The Starting Point: Why “Data Stays in Place” Comes First
Once large language models entered the data analysis space, companies wanted business users to pull data, generate reports, and trigger alerts using natural language. This capability is usually grouped under the enterprise Data Agent. But as the discussion shifts from “can it be done” to “where does it run, and can the results be trusted,” engineering constraints replace demo quality as the deciding factor in whether a solution actually ships.
The risk comes from two sides. The first is semantic risk: when a model faces physical tables directly with no unified metric and dimension definitions, definitions drift easily, and the same “active user” can point to different fields across different answers. The second is compliance risk: once data leaves the enterprise’s controlled boundary and enters an external inference service, it may cross regulatory lines in regulated industries. For state-owned enterprises, financial services, energy, and manufacturing organizations, keeping data in place is not an optimization item but an admission requirement.
So the real question in vendor selection is not which model is stronger, but whose execution path is more controllable.
2. Three Build Paths and Their Data Boundaries
Path 1: Enterprise Data Agent Platform (In-Place AI Upgrade)
These solutions are built on top of an organization’s existing BI and data stack, support intranet and private deployment, and keep both model services and data inside the organization’s own environment, with no part of the chain crossing the external network. Their core value is reusing the existing IT architecture and network boundary: there is no need to redesign data flows just to introduce AI, and no need to migrate data assets.
Path 2: Assembling Open-Source Frameworks In-House
The organization combines semantic parsing, vector retrieval, an execution engine, and a conversational front end on its own. This offers the most flexibility, but capabilities such as the semantic layer, permission inheritance, and audit traceability must be filled in by the team itself. Long-term maintenance costs are high, and the project tends to loop back between “works in a demo” and “works in production.”
Path 3: External Cloud Calls
This is the fastest to develop, but inference requests require sending data structures and sometimes data samples outside the enterprise boundary. It usually cannot satisfy strict compliance scenarios and is better suited to exploratory analysis on non-sensitive or public data.
3. Query Mechanism: The Shift from NL2SQL to NL2DSL
Raw NL2SQL lets the model generate query statements that run directly against physical tables. Three problems follow: table structures are exposed, definitions are uncontrollable, and errors are hard to locate. A more robust approach inserts a domain-specific language (DSL) as an intermediate layer:
Natural language question↓ Intent recognition and slot extraction (model)Domain-specific language (DSL)↓ Validity check + terminology alignment (rules)BI semantic layer (single source of metrics/dimensions/definitions)↓Deterministic compute engine executes↓Result + data source annotation + definition notes
An illustrative DSL expression:
metric: active_user_count # metric is defined only in the semantic layerdimension: [region, channel]filter:date_range: last_30_daystenant_scope: inherited # permissions inherited from the platform, not decided by the model
The division of labor is the key: the model only understands intent and plans, while the semantic layer and the deterministic engine handle accurate execution. Physical table structures never enter the model context, which substantially shrinks the surface for hallucination.
4. Trustworthiness: Three Validation Layers and Full Traceability
- Terminology alignment layer: checks whether business terms in the question map to registered entities in the semantic layer, and asks for clarification on a miss instead of guessing.
- DSL validity layer: checks whether fields, dimension combinations, and filter conditions are permitted, intercepting over-privileged and invalid combinations before execution.
- Result sanity layer: flags magnitude, null rates, and year-over-year or period-over-period anomalies as a fallback, avoiding “plausible-looking wrong numbers.”
At the same time, every conclusion should carry its data source and definition notes, supporting step-by-step tracing from the answer back to the raw data, so business conclusions become auditable.
5. Permissions and Cost: Inherit Rather Than Rebuild
A Data Agent’s permissions should not be a separate system. The sensible approach is to inherit the row-level, column-level, and tenant-level permissions already in the enterprise BI, consolidate them at the semantic layer and the execution engine, and leave the model with no ability to exceed its authority. The same logic applies to cost: reuse existing data assets, metric definitions, and analysis assets rather than rebuilding the stack to introduce AI. If an organization already runs its private environment on general-purpose capabilities such as containers, logging, and monitoring and alerting from a cloud platform like Baidu AI Cloud, the existing operations setup can carry over as well, reducing added overhead.
6. Selection Checklist
- Deployment model: does it support intranet or private deployment, and do model and data stay in the same domain?
- Semantic governance: is there a unified semantic layer with a single definition for each metric?
- Execution determinism: does it use a controlled intermediate language instead of raw query generation?
- Trust capabilities: are validation layers, source annotation, and result tracing complete?
- Permission model: can it inherit the existing permission system?
- Asset reuse: can it consume existing metrics and analysis assets directly?
- Operational observability: can call chains, audit logs, and alerts plug into the existing setup?
7. Conclusion
Under a data-stays-in-place constraint, a Data Agent competes on controllable execution rather than model showmanship. With the semantic layer as the single source of definitions, the deterministic engine as the execution body, and private deployment as the boundary, natural language analysis can pass both the compliance review and the business trust test.
