CLI
snapshot
Inspect the current state of a branch.
The snapshot command shows the current state of a branch: which snapshot version it points to, which tables exist, their versions, and how many rows each contains. It is a quick way to understand what a branch looks like without running a query.
Usage
omnigraph snapshot <path> [options]Arguments
| Argument | Required | Description |
|---|---|---|
path | yes | Path to the Omnigraph repository |
Options
| Option | Required | Default | Description |
|---|---|---|---|
--branch | no | main | Branch to inspect |
--json | no | — | Output as JSON |
Example
Inspect the default branch (main):
omnigraph snapshot ./repo.omnibranch: main
manifest_version: 5
TABLE VERSION BRANCH ROWS
Person v3 main 847
Company v2 main 124
WorksAt v2 main 912
Knows v1 main 2,341Inspect a specific branch:
omnigraph snapshot ./repo.omni --branch feature-xbranch: feature-x
manifest_version: 7
TABLE VERSION BRANCH ROWS
Person v4 feature-x 853
Company v2 main 124
WorksAt v3 feature-x 918
Knows v1 main 2,341Notice that Company and Knows show BRANCH: main — these tables have not been modified on feature-x, so they still share storage with main (copy-on-write). Only Person and WorksAt have diverged.
JSON output
omnigraph snapshot ./repo.omni --json{
"branch": "main",
"manifest_version": 5,
"tables": [
{ "table_key": "Person", "table_version": 3, "table_branch": "main", "row_count": 847 },
{ "table_key": "Company", "table_version": 2, "table_branch": "main", "row_count": 124 },
{ "table_key": "WorksAt", "table_version": 2, "table_branch": "main", "row_count": 912 },
{ "table_key": "Knows", "table_version": 1, "table_branch": "main", "row_count": 2341 }
]
}Output fields
| Field | Description |
|---|---|
branch | The branch being inspected |
manifest_version | The snapshot version this branch currently points to |
table_key | The name of the node or edge type |
table_version | How many times this table has been written to |
table_branch | The branch that owns this table's current data (shows copy-on-write sharing) |
row_count | Number of rows in the table |
When to use snapshot
- Before merging — Check what a branch contains to understand the scope of a merge.
- After loading — Verify that a load wrote the expected number of rows to the right tables.
- Debugging — Confirm which tables have diverged from
mainand which still share storage. - Monitoring — Track graph size and table growth over time.