Code lives in version control. The documents, spreadsheets, and data a company runs on do not.
Lix is a version control system for files and data beyond code: one repository that combines files, a database, and version control.
- 📄 Works with any file format. Plugins map DOCX, CSV, Markdown, or your own format to versioned entities.
- 🔍 Semantic changes. Review the clause, cell, or row that changed, not lines of bytes.
- 🗄️ SQL and transactions. Query file content, app data, and history; update files and rows in one ACID transaction.
- 👥 Real-time collaboration. People and agents share a repository and see changes live.
- 🔌 Pluggable storage. An S3 bucket, the local filesystem, or OPFS in the browser: Lix is easy to embed and scale, in contrast to existing VCS like Git that assume a local POSIX filesystem.
- 🔐 Permissions (soon). Finance, legal, and contractors need different access. Permissions will live inside the repository: per file, per group, and versioned like any other change.
Flashtype is a Markdown editor for Claude and Codex built on Lix. Open local Markdown files, let agents edit them, review changes as diffs, and restore previous versions from history.
JavaScript ·
Python ·
Rust ·
Go
npm install @lix-js/sdkRun locally with LocalFilesystem:
import { LocalFilesystem, openLix } from "@lix-js/sdk";
const lix = await openLix({
storage: new LocalFilesystem({ path: "./workspace", syncAllFiles: true }),
});
await lix.execute("INSERT INTO lix_file (path, content) VALUES ($1, $2)", [
"/notes/status.txt",
new TextEncoder().encode("ready"),
]);Or against a server:
const lix = await openLix({
server: {
mode: "remote",
url: "https://example.com/workspaces/acme",
},
});Plugins map files to SQL rows. A paragraph, cell, or property becomes a row Lix can version.
The file stays a normal file on disk. The rows are queryable with SQL. Lix tracks every change to both.
The SDK includes plugins for Markdown and CSV. Add a plugin for other formats, such as JSON, XLSX, DOCX, or PDF.
Lix embeds in your app and runs on storage adapters: in memory, on the local filesystem, or on an S3 bucket.
Existing VCS like Git assume a local POSIX filesystem, which makes them hard to embed and scale. See the Persistence and Storage docs.
Git versions files but cannot query them. PostgreSQL and SQLite query rows but have no files and no history. Lix does both.
database
│
PostgreSQL / SQLite │ ★ Lix
rows, no history │ rows + files,
│ versioned
│
──────────────────────┼──────────────────▶ version control
│
│ Git
│ text files only
│
| Capability | Git | PostgreSQL / SQLite | Lix |
|---|---|---|---|
| Normal files | Yes | No | Yes |
| SQL and transactions | No | Yes | Yes |
| Branches and merging | Yes | No | Yes |
| Diffs by cell, clause, or row | Text lines only | No | Yes, via plugins |
| Pluggable storage | No | No | Yes |
Give each agent its own branch. The agent works with normal files while the main branch stays stable. Preview its work, then merge or discard it.
const main = await lix.activeBranchId();
const task = await lix.createBranch({ name: "Agent task" });
await lix.switchBranch({ branchId: task.id });
// Run the agent. Its file and SQL writes are isolated to this branch.
await lix.switchBranch({ branchId: main });
const preview = await lix.mergeBranchPreview({ sourceBranchId: task.id });
if (preview.conflicts.length === 0) {
await lix.mergeBranch({ sourceBranchId: task.id });
}Agents already know how to read and write files. Put contracts, pricing sheets, and order data in a repository, and agents can work on them without custom integrations.
Lix records every change automatically. When an agent updates an orders CSV, reviewers see the row field that changed before the change merges:
order_id 1002 status:
- pending
+ shippedMerge good changes, discard bad ones, and restore any earlier state of the company.
Build editors, knowledge bases, and document workflows on normal files. Use SQL for app logic and Lix for history, rollback, branches, merging, and review.
Plugins define the parts Lix tracks. You can review a change to a paragraph, cell, property, or row instead of only bytes and lines.
Query changes without reading every file:
const changes = await lix.execute(`
SELECT created_at, schema_key, entity_pk, snapshot_content
FROM lix_change
ORDER BY created_at DESC
LIMIT 20
`);Update Lix files and rows in one ACID transaction. Lix records the history automatically.
Read more about semantic changes →
The goal is one repository for everything a company produces. Code lives in git. Contracts, spreadsheets, app data, and agent output get the same foundation with Lix: one history, queryable with SQL, safe to branch and merge.
contracts.docx pricing.xlsx app data agent output
│ │ │ │
└────────────────┴───────┬──────┴──────────────┘
▼
┌─────────────────── ONE LIX REPOSITORY ───────────────────┐
│ │
│ ┌──────────────┐ ┌──────────────┐ ┌────────────┐ │
│ │ FILESYSTEM │ × │ DATABASE │ × │ VERSION │ │
│ │ │ │ │ │ CONTROL │ │
│ │ tools and │ │ SQL queries │ │review/merge│ │
│ │ agents │ │ transactions │ │ rollback │ │
│ └──────────────┘ └──────────────┘ └────────────┘ │
│ │
└──────────────────────────────────────────────────────────┘
- Getting Started Guide - Build your first app with Lix
- Documentation - Full API reference and guides
- Discord - Get help and join the community
- GitHub - Report issues and contribute