Documentation Index
Fetch the complete documentation index at: https://docs.trynebula.ai/llms.txt
Use this file to discover all available pages before exploring further.
Memories and Sources
In Nebula, everything is stored as a memory. A memory is a container with a uniquememory_id that holds one or more sources:
- Document Memory: An entire document, automatically split into sources for processing. You can upload text, pre-chunked text, or a file. A short piece of text (like a user preference) is a document memory with a single source.
- Conversation Memory: A full conversation where each message is a source. Set
engram_type="conversation"and pass amessageslist of{role, content}objects to create one.
Document Memories
Conversation Memories
Create a conversation by passingengram_type="conversation" and an initial messages list. Append more messages by calling memories.append() with the conversation’s memory_id.
The Vector Graph
When you store memories, Nebula automatically extracts structured knowledge and builds a graph of entities and relationships. When you search, the response contains four layers of memory:- Semantics: Subject-predicate-value assertions (e.g., “Sarah - led - the Aurora migration”), with confidence that grows through corroboration across sources
- Procedures: User preferences and behavioral patterns (e.g., “Prefers dark mode”)
- Episodes: Temporally clustered events with timestamps
- Sources: The original source text that grounds each assertion, providing provenance back to the stored memory
Memory Lifecycle
- Creation:
memories.create()creates a new memory - Expansion:
memories.append(memory_id, ...)adds content to an existing memory - Extraction: Nebula extracts entities, facts, and relationships into the vector graph
- Retrieval:
memories.search()returns semantics, procedures, episodes, and sources;memories.retrieve(id)returns the raw memory with all sources - Source Provenance: Use source IDs to trace retrieval results back to stored memory content
- Deletion:
memories.delete(id)removes an entire memory and all its sources
Next Steps
- Memory Operations - Store, retrieve, and delete memories
- Collections - Organize memories into collections
- Search - Semantic search and filtering