Lix is not a git replacement, nor is it designed for software engineering. The goal is to enable change-related workflows like CI/CD, open source, or AI agents in industries other than software engineering.
Traditional version control systems like Git are designed for text files and source code. While Git excels at tracking code, it falls short for structured data, binary formats, and embedded application use:
| Aspect | Git | Lix |
|---|---|---|
| Change Granularity | Line-based | Entity-based (semantic) |
| Data Understanding | Opaque text | Format-aware via plugins |
| Query Interface | CLI commands | SQL queries |
| Runtime | Separate tool | Embedded JavaScript SDK |
| Persistence | .git directory | Portable .lix blob (SQLite) |
| Primary Use Case | Source code | Structured data + AI agents |
Line-by-line diffing loses semantic meaning: Git sees line changes without understanding the data structure. In JSON, CSV, or databases, this makes it hard to track what actually changed semantically.
No support for binary formats: Excel, design files, and PDFs are opaque blobs to Git—you can't query "what changed in cell C45?"
Not designed to run inside applications: Git is a CLI tool, not an SDK. There's no way to embed Git in a browser app, query change history with SQL, or build custom workflows programmatically.
1. Entity-Level Change Tracking
Lix tracks changes at an entity level, not text lines. This makes Lix semantically aware of what changes:
/sku_124/price)This enables fine-grained diffs, precise commenting at the entity level, and smart merging when different entities on the same line change.
2. Embedded JavaScript SDK
Lix runs inside your application—in browsers, Node.js, or Web Workers. The portable .lix blob format (SQLite binary) can be stored anywhere:
3. SQL Query Engine
Query changes programmatically instead of parsing CLI output:
// Time-travel: query file state history
const history = await lix.db
.selectFrom("file_state_history")
.where("file_id", "=", "catalog.json")
.orderBy("lixcol_depth", "asc")
.execute();
// Attribution: who changed what in a file
const changes = await lix.db
.selectFrom("change")
.innerJoin("account", "change.author_id", "account.id")
.where("change.file_id", "=", "catalog.json")
.where("change.entity_id", "=", "/sku_124/price")
.execute();
// Cross-version file comparison
const diff = await lix.db
.selectFrom("file_state as v1")
.innerJoin("file_state as v2", "v1.file_id", "v2.file_id")
.where("v1.lixcol_version_id", "=", versionA)
.where("v2.lixcol_version_id", "=", versionB)
.where("v1.file_id", "=", "catalog.json")
.execute();4. Plugin System for Any Format
Plugins teach Lix to understand file formats by defining:
Official plugins support JSON, CSV, and Markdown. Custom plugins can handle Excel, design files, or proprietary formats.
5. Built for AI Agents
Lix enables safe, auditable AI workflows:
6. On-Demand State Materialization
Unlike Git's full snapshots, Lix stores only raw changes and materializes state on-demand:
This reduces storage footprint while maintaining fast query performance through internal caching.
Git shows line replacements, which is noisy for structured data:
{
"sku_123": { "price": 100, "name": "Red Chair" },
- "sku_124": { "price": 200, "name": "Blue Sofa" }
+ "sku_124": { "price": 250, "name": "Blue Sofa" }
}Why this hurts:
price on sku_124?"—it's just line churn.Lix diff rows are structured (real shape from selectVersionDiff / selectWorkingDiff with snapshots joined from the change table). The built-in JSON plugin emits one entity per JSON Pointer, so a price change is reported like this:
{
"entity_id": "/sku_124/price",
"schema_key": "plugin_json_pointer_value",
"file_id": "catalog.json",
"status": "modified",
"before_change_id": "chg_price_200",
"after_change_id": "chg_price_250",
"before_snapshot": { "path": "/sku_124/price", "value": 200 },
"after_snapshot": { "path": "/sku_124/price", "value": 250 }
}Because Lix diffs carry entity IDs, schema keys, and before/after snapshots, review UIs can highlight just the changed field and keep JSON valid, instead of showing raw line noise.