Skip to content
Pilotoo
v0.1

@pilotoo/memory-core

@pilotoo/memory-core is the domain of Brain: memories, access by membership and labels, sources, pages and facts, review, curation, health, audit and agent access, as services over ports. It has no Nest, no pg and no model SDK, so you can run it over any store. @pilotoo/memory-server supplies the PostgreSQL stores and the Nest controllers.

@pilotoo/memory-core is at version 0.1.0, is marked private and is not published to a registry. It is also not part of the tarballs that pnpm release:check packs, so today it is used from the kit workspace:

Terminal window
pnpm install
pnpm --filter @pilotoo/memory-core build

Inside the workspace, depend on it with "@pilotoo/memory-core": "workspace:^". Its build first builds the kit packages it depends on.

createBrain builds the services from the stores and the ports:

src/brain.ts
import { createBrain } from '@pilotoo/memory-core';
const brain = createBrain({
stores,
clock,
ids,
directory,
tokenSecrets,
embedder, // optional
pageCompiler, // optional
answerer, // optional
});
Port Required What it does
directory Yes Name, email and picture of the people Brain shows.
clock, ids, tokenSecrets Yes Time, id generation and token hashing. @pilotoo/memory-server provides systemClock, randomIds and sha256TokenSecrets.
embedder No Semantic search.
extractor No Text from uploaded files.
labelSuggester No Label suggestions for a new source.
pageCompiler No Compiling sources into pages.
answerer No Answers with citations. Without one ask replies with modelOff: true.
factReconciler No Reconciling a new fact of a personal memory with the old ones.

brain.capabilities reports which of these are present. See What runs without a model.

Import Provides
@pilotoo/memory-core The only entry point: createBrain, the store and model ports, the compile worker, connector and curation services, visibility, validation and the errors.

@pilotoo/memory-protocol and zod. It has no peer dependencies.