How it works
Every operation that modifies a table creates a new version:Viewing history
Human-readable history
Programmatic access
Time travel queries
Query any historical version using thetable_name:version syntax:
Use cases
- Debugging: Compare data before and after a problematic update
- Auditing: Track who changed what and when
- Recovery: Find and extract accidentally deleted or modified data
- Reproducibility: Query exact data used for a specific model training run
Reverting changes
Undo the most recent change withrevert():
revert() multiple times to go back further, but cannot revert past version 0 or past a version referenced by a snapshot.
Snapshots
Create named, persistent point-in-time copies for long-term preservation:- Time travel (
pxt.get_table('table:N')) queries historical versions in place - Snapshots create a named, independent copy that persists even if the source table is modified or deleted
Data lineage
Pixeltable tracks the complete lineage of your data:Schema lineage
Every computed column records its dependencies:View lineage
Views automatically track their source tables:What’s tracked
Best practices
Use Snapshots for Milestones
Create snapshots before major data loads, model training runs, or production deployments.
Version Numbers for Reproducibility
Log table version numbers alongside model artifacts:
products.get_versions()[0]['version']Revert for Quick Fixes
Use
revert() immediately after mistakes. For older issues, use time travel to identify the problem.Namespace by Environment
Use directories like
dev/products, staging/products to isolate versioning across environments.Comparison with other systems
Next steps
Hands-On Tutorial
Step-by-step cookbook with runnable examples