MnemosyneEcto.Schema.Node (mnemosyne_ecto v0.2.0)

Copy Markdown View Source

Shared definition for the polymorphic mnemosyne_nodes table schema.

All node types (semantic, episodic, procedural, etc.) live in a single table with JSON data/links fields and a vector embedding column. The embedding column type is the only thing that differs between database engines, so the concrete schema modules (MnemosyneEcto.Schema.Node.Postgres and MnemosyneEcto.Schema.Node.SQLite) inject it via use.

use MnemosyneEcto.Schema.Node, embedding_type: Pgvector.Ecto.Vector