cuba_sync
Export and import knowledge graph entities, observations, and relations to/from JSON files for version control. Compare disk state with database or check pending imports.
Instructions
Git-friendly export/import of the knowledge graph (v0.8). action='export' writes one JSON file per entity (with embedded observations) plus episodes/decisions/errors/relations under CUBA_SYNC_DIR (default ./.cuba-memorys/). 'import' merges files back via INSERT...ON CONFLICT DO NOTHING (idempotent). 'diff' compares disk vs DB. 'status' lists not-yet-imported manifests. Embeddings are omitted by default (set with_embeddings=true to include the binary blob).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dir | No | Directory override (default $CUBA_SYNC_DIR or ./.cuba-memorys/) | |
| scope | No | Export scope: only the active project (default) or all data | |
| action | Yes | Sync mode | |
| conflict | No | Import conflict policy (default merge) | |
| with_embeddings | No | Include the embeddings.bin.zst blob on export (default false) |