Data sharding is the practice of horizontally partitioning a large dataset into smaller, independent, and mutually exclusive subsets called shards. In the context of machine unlearning, this architecture ensures that a specific data point's influence is confined to a single shard rather than being distributed across the entire model. This isolation is the foundational principle of the SISA (Sharded, Isolated, Sliced, and Aggregated) training framework, which drastically reduces the computational cost of data deletion by limiting the scope of required retraining.
Glossary
Data Sharding

What is Data Sharding?
Data sharding is a database architecture pattern that horizontally partitions a training dataset into mutually exclusive subsets to isolate the impact of individual data points and simplify incremental unlearning.
By training an independent sub-model on each shard and aggregating their outputs, the system achieves exact unlearning for a deletion request by retraining only the single affected shard. This approach transforms the right to be forgotten from a computationally prohibitive full retraining problem into an incremental, cost-effective operation. The granularity of the sharding strategy directly dictates the trade-off between unlearning speed and model accuracy, making it a critical design parameter for privacy-compliant Large Language Model Operations.
Key Characteristics of Data Sharding for Unlearning
Data sharding horizontally partitions training datasets into mutually exclusive subsets, enabling targeted and efficient machine unlearning by isolating the impact of individual data points to specific model replicas.
Mutually Exclusive Partitioning
The dataset is divided into disjoint shards where no data point exists in more than one shard. This strict isolation ensures that a deletion request affects only a single subset. The partitioning strategy often uses a deterministic hash function on a primary key to guarantee consistent assignment and prevent data leakage between shards during incremental unlearning operations.
Independent Model Replicas
Each shard trains a completely separate model instance with its own weights and parameters. This architectural choice means that when a user requests data deletion, only the model associated with the contaminated shard requires retraining or unlearning. The other replicas remain untouched, preserving their learned knowledge and avoiding catastrophic forgetting across the entire system.
Incremental Retraining Scope
Sharding transforms the computational cost of unlearning from O(n) to O(1) relative to total dataset size. Instead of retraining a monolithic model on the entire remaining corpus, engineers retrain only the single affected shard model on its cleaned subset. This makes compliance with the Right to be Forgotten economically feasible for large-scale production systems.
SISA Training Framework
The Sharded, Isolated, Sliced, and Aggregated framework formalizes this approach:
- Sharding: Partition data into disjoint subsets
- Isolation: Train independent models per shard
- Slicing: Further divide each shard into incremental slices for checkpointing
- Aggregation: Combine outputs via ensembling at inference time This structure limits retraining to the smallest affected slice when a deletion request arrives.
Inference Aggregation Strategy
Since multiple independent models exist, a voting or averaging mechanism combines their outputs at inference time. Common strategies include:
- Majority voting for classification tasks
- Arithmetic mean for regression outputs
- Confidence-weighted averaging based on each model's validation score The aggregation layer must be stateless and fast to avoid introducing latency penalties.
Storage and Provenance Overhead
Sharding requires robust data lineage tracking to map every training point to its exact shard and slice. This demands:
- Immutable manifest files recording hash-to-shard mappings
- Tombstone records to prevent accidental re-ingestion of deleted data
- Versioned shard snapshots for audit compliance The provenance infrastructure is as critical as the model architecture itself for verifiable unlearning.
Frequently Asked Questions
Explore the technical mechanics of horizontally partitioning training datasets to enable efficient, targeted model unlearning and compliance with data deletion requests.
Data sharding is the practice of horizontally partitioning a training dataset into mutually exclusive, non-overlapping subsets called shards. In the context of machine unlearning, this architecture isolates the impact of individual data points to a specific, bounded sub-model. When a deletion request arrives, only the shard containing the target data needs to be retrained, rather than the entire model. This transforms the computational complexity of unlearning from O(N)—retraining on the entire dataset—to O(N/S), where S is the number of shards. The SISA framework (Sharded, Isolated, Sliced, and Aggregated) is the canonical implementation of this approach, where each shard trains an independent constituent model, and their outputs are aggregated via a voting or averaging mechanism for final inference.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
Data sharding is a foundational architectural pattern that enables efficient machine unlearning. Explore the interconnected concepts that make sharded, isolated training possible.
SISA Training
The Sharded, Isolated, Sliced, and Aggregated framework is the primary architecture that operationalizes data sharding for unlearning. It partitions data into mutually exclusive shards, trains independent constituent models on each shard, and aggregates their outputs. When a deletion request arrives, only the model trained on the shard containing the target data requires retraining, reducing computational cost from O(n) to O(1) relative to dataset size.
Incremental Unlearning
A strategy that processes deletion requests sequentially by isolating affected shards. Key characteristics:
- Targeted retraining: Only the sub-model for the contaminated shard is rebuilt
- Ensemble continuity: Unaffected shard models continue serving predictions without interruption
- Linear scaling: Unlearning cost scales with shard size, not total dataset size This approach transforms unlearning from a batch crisis into a routine maintenance operation.
Data Lineage
The prerequisite for effective sharding-based unlearning. Data lineage tracks the origin, movement, and transformation of every data point throughout the ingestion and training pipeline. Without precise lineage:
- Shard contamination becomes undetectable
- Deletion requests cannot be mapped to specific shards
- Audit trails break, violating GDPR accountability principles Lineage metadata must include shard assignment timestamps and model version identifiers.
Tombstone Records
After data is deleted from a shard, a tombstone record persists as a metadata marker. This serves critical functions:
- Re-ingestion prevention: Prevents accidentally reintroducing deleted data into the training pipeline
- Audit trail integrity: Provides immutable proof that a deletion occurred at a specific timestamp
- Distributed consistency: In federated sharding architectures, tombstones propagate deletion state across nodes Tombstones are the persistent memory of forgetting.
Catastrophic Forgetting
The primary risk when retraining a shard model in isolation. Catastrophic forgetting occurs when a neural network abruptly loses previously learned knowledge upon learning new information. In the sharding context:
- Retraining a single shard model on the remaining data can shift its decision boundaries
- The aggregation layer must be recalibrated to prevent the ensemble from degrading
- Techniques like Elastic Weight Consolidation apply quadratic penalties to preserve important weights during shard retraining
Unlearning Verification
The empirical process of proving that a shard model no longer retains influence from deleted data. Methods include:
- Membership Inference Attacks: Test whether the model behaves differently on deleted vs. non-deleted samples
- Shadow Model Testing: Train surrogate models on similar distributions to predict the target model's behavior
- Backdoor Triggers: Inject known patterns during training and verify they no longer activate post-unlearning Verification is the only way to transform a sharding architecture from a technical claim into a compliance guarantee.

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us