add-incremental-loading

Adds incremental loading with merge deduplication to dlt filesystem pipelines.

Updated Jun 15, 2026
One-click install
npx skills add https://github.com/aminojagh/LLMZC --skill add-incremental-loading-aminojagh
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: add-incremental-loading
Source: https://github.com/aminojagh/LLMZC/tree/main/05_02_dlt_workshop/.claude/skills/add-incremental-loading
Command: npx skills add https://github.com/aminojagh/LLMZC --skill add-incremental-loading-aminojagh

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires dlt.

What problem does it solve? Filesystem pipelines that reload every file on each run waste time and compute, and replace-mode loads cannot deduplicate updated records. This Skill converts a working dlt filesystem pipeline so each run only reads new or modified files and merges records by primary key. ## Core Features & Use Cases - File-level incremental loading: Adds incremental=dlt.sources.incremental("modification_date") to the filesystem() call so only new or modified files are read. - Record-level filtering and deduplication: Applies apply_hints with a primary key and timestamp column, switching the write disposition from replace to merge (or append when no key exists). - State-safe configuration: Removes dev_mode=True so pipeline state persists across runs, then verifies behavior with a two-run test. - Use Case: You have a dlt pipeline loading CSVs from an S3 bucket in replace mode. Use this Skill to convert it so nightly runs only ingest files modified since the last run and upsert changed records by their ID column. ## Quick Start Convert my dlt filesystem pipeline to incremental loading with merge on the order_id primary key and updated_at as the record timestamp column.

Frequently Asked Questions about add-incremental-loading

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add incremental loading to a dlt filesystem pipeline?▼

Add incremental=dlt.sources.incremental("modification_date") to the filesystem() call so only new or modified files are read. Then switch write_disposition from replace to merge and remove dev_mode=True so pipeline state persists across runs.

How to deduplicate records in dlt with merge write disposition?▼

Call apply_hints on the reader with a primary_key and an incremental timestamp column, then run the pipeline with write_disposition="merge". dlt upserts records matching the primary key instead of appending duplicates.

What if my data has no primary key for dlt merge?▼

Use append write disposition instead of merge and skip the apply_hints call. File-level incremental filtering by modification_date still works, but dlt will accumulate rows without deduplicating updated records.

Why does dlt incremental loading reload all files every run?▼

The most common cause is dev_mode=True in dlt.pipeline, which generates a fresh dataset name each run and breaks state tracking. Remove dev_mode so the modification_date cursor persists between runs.

How do I verify dlt incremental loading works correctly?▼

Run the pipeline twice: the first run loads all matching files, and the second run with no new files should load zero rows. Check row counts and inspect pipeline state to confirm the modification_date cursor advanced.