For the complete BrainAPI documentation index, see llms.txt. A markdown version of any docs page is available by appending .md to its URL. Docs MCP: /docs/mcp.
Retrieve
How to retrieve data from the memory store
Importing
Start by importing the Driver class.
import { LumenBrainDriver } from "lumen-brain";// Initialize the driver with your API keyconst brain = new LumenBrainDriver("your-api-key");Retrieving additional context
You can retrieve additional context based on the user's message and append it to the prompt for the LLM. The additional context will include relevant information extracted from the memory and the conversation history if conversation_id is provided.
const queryResult = await brain.queryMemory( "What was the test message?", "memory-uuid", "conversation-123");Prop
Type
