Skip to main content

Module graph_migrate

Module graph_migrate 

Source
Expand description

Graph schema versioning and migration engine.

Stores a (:SchemaVersion) node inside the graph. On open, the code checks the graph version against CURRENT_SCHEMA_VERSION and runs sequential migrations if the graph is behind. Each migration is idempotent.

§Version History

  • v0: Pre-versioning (no SchemaVersion node)
  • v1: Stamp version node (current schema, no data changes)
  • v2: Add last_validated_at, decay_rate, embedding_model_version to Memory nodes

Enums§

VersionCheck
Result of a schema version check.

Constants§

CURRENT_SCHEMA_VERSION
Current schema version that this code expects.

Functions§

check_version
Fallback when graph feature is disabled.
effective_confidence
Calculate effective confidence with time-based decay.
run_migrations
Fallback when graph feature is disabled.