Spectron stores memory by extracting structured entities, attributes, and relations from text — not by accepting opaque key-value blobs. Every write runs through the reconciler (calibration, supersession, uncertainty on conflict).
Register scope paths before first write:
Primary write paths
| Path | Use when |
|---|---|
POST /api/v1/{ctx}/facts | Single utterance, raw triples (infer: "triples"), or literal (infer: "none") |
POST /api/v1/{ctx}/facts/batch | Full conversation transcript in one request (preferred for harnesses) |
source.kind on persisted records is typically "turn" for conversational ingest and "document" for upload pipeline output.
CLI
Flags: --infer full|triples|preview|none, --session, --transcript, --extract whole_conversation|per_message (batch only).
Note
HTTP — single fact
Optional observed_at (RFC 3339) stamps derived facts at a caller-supplied known time instead of wall-clock ingest. Use this for narrative playback — ingest an entire canon but answer only as far as the user has read or watched (see Spoiler-safe narrative memory). Omitted keeps the default (ingest time).
Response (infer: full): nested extraction with entities, attributes, relations, instructions, and uncertainties, plus sessionId and turnId.
Response (infer: none): chunkId, sessionId, and turnId for the literal memory chunk. Long text is split into multiple memory_chunk rows (one embedding per sub-chunk) so vector recall covers the full passage — chunkId returns the first row’s id.
HTTP — batch
extract: whole_conversation (default) sends the full transcript in one LLM pass; per_message runs extraction once per message.
Returns extractions, sessionId, and turnIds.
SDK (Python)
Sessions
Sessions group episodic turns for transcript browsing and session-scoped context. Creating a session is optional when using /facts/batch with an explicit session_id.
See Sessions and turns.
Authoritative content
Manuals, policies, and files use the document path, not /facts:
See Knowledge hub.
What you do not do
Write arbitrary JSON blobs to a “memory table”
Use removed
/knowledge/nodesAPIs
Extraction, reconciliation, and provenance are described in Extraction pipeline and Provenance and traceability.