Kingbase Banner

AI data infrastructure: ACID

Nested transparent glass shells surrounding a solid ceramic core on a linen surface

Deconstructing the ‘AI Database’ Myth

The term "AI Database" often misleads enterprise architects into searching for a single product that replaces their entire data stack. In reality, AI-ready data infrastructure supports two distinct workload patterns: batch processing for large-scale training and real-time or near-real-time data for inference and decision-making. These patterns have conflicting requirements for latency, consistency, and storage format.

Traditional enterprise systems, such as those built on relational models, excel at transactional integrity and complex aggregations. They serve as the System of Record for operational data. However, they are not optimized for the semantic similarity search over unstructured content at scale that modern AI applications require.

Vector databases address this gap by providing specialized indexing for high-dimensional vectors. Document databases offer schema flexibility for storing raw text chunks. Lakehouses provide governed SQL analytics over very large datasets. Combining these into a unified operational data platform requires careful architectural planning to avoid data silos and synchronization delays.

The Four-Layer Architecture

A robust AI application data infrastructure typically consists of four logical layers. Each layer serves a specific function, and conflating them introduces operational risk.

1. Transactional System of Record

This layer handles structured business data, user identities, and access control policies. Commercial databases like KingbaseES are often deployed here due to their maturity, tooling, and transactional integrity. This layer ensures that user permissions and metadata are consistent. It does not perform semantic search.

2. Document and Chunk Store

AI applications, particularly Retrieval-Augmented Generation (RAG) systems, ingest unstructured data. This layer stores the raw text, PDFs, or logs. It requires schema flexibility and fast reads of whole records. Document databases or object storage systems often serve this role.

3. Vector Retrieval Layer

This layer stores the embeddings generated from the document store. It uses specialized indexing structures to perform similarity searches. When a user queries the AI, this layer retrieves the most relevant chunks based on semantic closeness, not just keyword matching.

4. Orchestration and Generation Layer

This layer connects the user query to the retrieval layer and the Large Language Model (LLM). It handles context assembly, prompt engineering, and response generation. It relies on the freshness of data provided by the previous three layers.

Integration with KingbaseES

KingbaseES is a commercial relational database. It serves as a strong candidate for the Transactional System of Record. It manages the metadata, user profiles, and access control lists that govern who can access which AI-generated insights. It does not replace the need for a dedicated vector retrieval layer unless explicitly integrated with external components. KingbaseES does not provide native vector search or embedding generation; any vector capabilities would require external integration or specific extensions not covered in the general evidence.

The Freshness Paradox: ACID vs. Vector Readiness

A common misconception is that ACID transactions guarantee data readiness for AI. This is incorrect. ACID ensures that when a transaction commits, the data in the relational table is consistent. It does not trigger downstream processes.

The Embedding Gap

When a document is updated in the System of Record, the embedding does not update automatically. The application must detect the change, regenerate the embedding using the current model version, and write the new vector to the retrieval layer.

Index Maintenance

Updating a vector column in a database may cause a native index to be maintained through normal DML behavior. However, whether a separate rebuild or refresh command is required depends on the exact vector extension and index implementation. Architects must verify these mechanics for their specific stack. KingbaseES is a transactional database, and vector index maintenance is an external or extension-specific process, not a native ACID guarantee.

Latency Implications

Moving data from the transactional layer to the vector layer introduces latency. If the embedding generation pipeline is slow, the AI retrieval layer serves stale data. This results in hallucinations or irrelevant responses. Enterprise architects must design retry mechanisms and stale-vector detection to handle these failures.

Hybrid Retrieval Mechanics

Modern AI applications rarely rely on pure semantic search. They use hybrid retrieval, combining vector similarity with keyword matching and metadata filtering. This approach improves relevance and ensures strict access control.

Semantic Search

Vector search finds documents with similar meaning. It is robust against synonymy and phrasing differences. However, it can be computationally expensive and may miss exact keyword matches.

Metadata Filtering

Metadata filtering applies constraints (e.g., date range, department, document type) before or during the vector search. This is critical for enterprise governance. It ensures that the AI only retrieves data the user is authorized to see.

Access Control Propagation

Database permissions do not automatically inherit to every RAG component. Protection depends on query execution identity, policy configuration, and application service accounts. The orchestration layer must enforce these policies by passing metadata filters to the retrieval layer.

Execution Order

SQL databases do not necessarily perform metadata filtering before vector calculation. Actual execution depends on indexes, query planning, and implementation. In multi-model or fusion database environments, the optimizer may choose the most efficient path. Architects must benchmark this for their target workload.

Governance and Security

Securing unstructured data in AI pipelines requires a comprehensive governance framework. Sensitive operational or consumer data demands protection throughout its lifecycle.

Key Security Requirements

  • Access Controls: Implement granular permissions at the row, column, and document level.
  • Encryption: Encrypt data at rest and in transit. Ensure encryption keys are managed securely.
  • Monitoring: Log all data access and AI interactions for auditability.
  • Identity Propagation: Ensure user identity is preserved from the transactional layer through to the vector retrieval layer.

Data Residency

Enterprises must consider data residency requirements. In Malaysia, the Personal Data Protection Act (PDPA) sets specific standards for data handling, though it does not create a blanket data-residency mandate for all sectors. Infrastructure design must allow for data localization without compromising AI performance. Specific regulatory approvals for KingbaseES in Malaysia are not covered in this general concept article.

Architecture Trade-offs: Polyglot vs. Multi-Model

Organizations face a choice between polyglot persistence (multiple specialized databases) and multi-model fusion databases.

Feature Polyglot Persistence (Multi-DB) Multi-Model (Fusion) Database
Architecture Separate systems for OLTP, Vector, Document. Single system supporting multiple data models.
Consistency Requires external synchronization mechanisms. Internal consistency within the transactional layer.
Complexity High operational complexity; multiple vendors to manage. Lower operational complexity; single system to manage.
Scalability Independent scaling of each layer. Shared resource pool; may require vertical scaling.
Integration Requires APIs and data pipelines between systems. Direct access to different data models within one system.
Use Case Best-in-breed specialized components. Consolidated operational data platform.

A unified SQL architecture may reduce cross-database replication. It can simplify data management under specific conditions. However, it does not eliminate the need for embedding generation or vector-index maintenance. The choice depends on the organization’s existing skills, latency requirements, and data volume. KingbaseES is an example of a multi-model database that can support these models, but the article must not claim it is a ‘native vector database’.

Evaluation Framework

When assessing AI application data infrastructure, enterprise architects should evaluate vendors against the following criteria:

  • Latency Sensitivity: Measure the end-to-end latency from user query to AI response. Identify bottlenecks in embedding retrieval and context assembly.
  • Scalability: Test the system’s ability to handle fluctuating AI query loads. Ensure the vector retrieval layer can scale independently if using a polyglot approach.
  • Data Freshness: Verify how the system handles document updates. Does it support real-time upserts? How long does it take for a vector index to reflect a change?
  • Integration Complexity: Assess the ease of integrating the data layer with existing enterprise sources. Look for mature connectors and API support.
  • Security & Governance: Confirm that access controls are enforced across all layers. Verify encryption standards and audit logging capabilities.

FAQ

What are the key architectural differences between traditional data infrastructure and infrastructure optimized for RAG and LLMs?

Traditional infrastructure focuses on transactional integrity and structured data aggregation. RAG-optimized infrastructure adds layers for unstructured document storage, vector embedding generation, and semantic similarity search. It requires handling high-dimensional data and low-latency retrieval alongside traditional ACID transactions.

How do vector embeddings and semantic search change the requirements for data storage and retrieval latency?

Vector embeddings require specialized storage formats and indexing structures (e.g., specialized vector indexes) that differ from B-tree or GIN indexes. Semantic search adds computational overhead during retrieval. This increases the complexity of the query execution plan and may require dedicated hardware or optimized software to maintain low latency.

What governance frameworks are necessary to secure unstructured data used for AI training and inference?

Governance must include strict access controls, encryption, and monitoring. Identity propagation from the transactional layer to the vector layer is essential. Metadata filtering must be enforced to ensure users only retrieve authorized data. Regular audits of data lineage and access logs are required to maintain compliance.


💡 More Resources

If you would like to dive deeper into KingbaseES and its application practices across various industries, we have compiled the following official resources to help you get started quickly and develop and operate with efficiency:

  • Kingbase Community: A one-stop interactive platform for technical exchanges, Q&A, and experience sharing—join forces with fellow DBAs and developers.
  • Kingbase Solutions: One-stop full-stack database migration and cloud-native solutions, supporting smooth migration of multi-source heterogeneous data, ensuring high availability, real-time integration, and sustained high performance.
  • Kingbase Case Studies: Real-world user scenarios and implementation outcomes, showcasing KingbaseES’s outstanding capabilities in high availability, high performance, and IT adaptation.
  • Kingbase Documentation: Authoritative and comprehensive product manuals and technical guides, covering the entire lifecycle from installation and deployment to development, programming, and operations management.
  • Free Download: Get the latest installation packages, drivers, tools, and patches, supporting multiple platforms and domestic chip architectures.
  • Digital Construction Encyclopedia: Covers digital strategy planning, data integration, metrics management, database visualization applications, and more to empower enterprise digital transformation.

Open Source Resources:

Welcome to explore the resources above and begin your Kingbase journey!