Memory SDK
Agent memory — episodic, semantic, procedural, entity, trust-weighted, temporal types with hash-chain provenanceOperations
| Method | Description |
|---|---|
lucidAddEpisodicMemory | Store episodic memory |
lucidAddSemanticMemory | Store semantic memory (extracted fact) |
lucidAddProceduralMemory | Store procedural memory (learned rule) |
lucidAddEntityMemory | Store entity memory (knowledge graph node) |
lucidAddTrustWeightedMemory | Store trust-weighted memory (cross-agent trust) |
lucidAddTemporalMemory | Store temporal memory (time-bounded fact) |
lucidRecallMemory | Recall relevant memories via two-stage retrieval |
lucidCompactMemory | Trigger memory compaction |
lucidMemoryHealth | Memory store health and diagnostics |
lucidStartMemorySession | Start a new conversation session |
lucidListMemorySessions | List sessions for an agent |
lucidVerifyMemoryChain | Verify memory hash chain integrity |
lucidGetMemoryEntry | Read a single memory entry |
lucidListMemoryEntries | List memory entries with filters |
lucidCloseMemorySession | Close a memory session |
lucidGetMemorySessionContext | Get session context |
lucidGetMemoryProvenanceChain | Get provenance chain |
lucidGetMemoryEntryProvenance | Single entry provenance |
lucidGetMemoryStats | Memory diagnostics |
Generated Reference
Overview
Agent memory — episodic, semantic, procedural, entity, trust-weighted, temporal types with hash-chain provenanceAvailable Operations
- lucidAddEpisodicMemory - Store episodic memory
- lucidAddSemanticMemory - Store semantic memory (extracted fact)
- lucidAddProceduralMemory - Store procedural memory (learned rule)
- lucidAddEntityMemory - Store entity memory (knowledge graph node)
- lucidAddTrustWeightedMemory - Store trust-weighted memory (cross-agent trust)
- lucidAddTemporalMemory - Store temporal memory (time-bounded fact)
- lucidRecallMemory - Recall relevant memories via two-stage retrieval
- lucidCompactMemory - Trigger memory compaction
- lucidMemoryHealth - Memory store health and diagnostics
- lucidStartMemorySession - Start a new conversation session
- lucidListMemorySessions - List sessions for an agent
- lucidVerifyMemoryChain - Verify memory hash chain integrity
- lucidGetMemoryEntry - Read a single memory entry
- lucidListMemoryEntries - List memory entries with filters
- lucidCloseMemorySession - Close a memory session
- lucidGetMemorySessionContext - Get session context
- lucidGetMemoryProvenanceChain - Get provenance chain
- lucidGetMemoryEntryProvenance - Single entry provenance
- lucidGetMemoryStats - Memory diagnostics
lucidAddEpisodicMemory
Store a conversation turn as episodic memory. Requires session_id, role, and content.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidAddEpisodicMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryWriteResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidAddSemanticMemory
Store semantic memory (extracted fact)Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidAddSemanticMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryWriteResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidAddProceduralMemory
Store procedural memory (learned rule)Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidAddProceduralMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryWriteResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidAddEntityMemory
Store entity memory (knowledge graph node)Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidAddEntityMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryWriteResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidAddTrustWeightedMemory
Store trust-weighted memory (cross-agent trust)Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidAddTrustWeightedMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryWriteResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidAddTemporalMemory
Store temporal memory (time-bounded fact)Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidAddTemporalMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryWriteResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidRecallMemory
Two-stage recall: vector similarity search (if embeddings available) followed by metadata-aware reranking. Scoring: 0.55similarity + 0.20recency + 0.15type_bonus + 0.10quality.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidRecallMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<models.MemoryRecallResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidCompactMemory
Tiered compaction: warm (archive old episodics), cold (hard-prune archived past retention). Self-healing: auto-compacts before rejecting writes when limits are exceeded.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidCompactMemoryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidCompactMemoryResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidMemoryHealth
Returns store type, entry/vector counts, embedding pipeline status, and store capabilities.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidMemoryHealthRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidMemoryHealthResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidStartMemorySession
Start a new conversation sessionExample Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidStartMemorySessionRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidStartMemorySessionResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidListMemorySessions
List sessions for an agentExample Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidListMemorySessionsRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidListMemorySessionsResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidVerifyMemoryChain
Verify memory hash chain integrityExample Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidVerifyMemoryChainRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidVerifyMemoryChainResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidGetMemoryEntry
Retrieve a single memory entry by its unique identifier.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidGetMemoryEntryRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidGetMemoryEntryResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.ErrorResponse | 404 | application/json |
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidListMemoryEntries
List memory entries for an agent, optionally filtered by type and namespace. Supports pagination via page and per_page query parameters.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidListMemoryEntriesRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidListMemoryEntriesResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidCloseMemorySession
Close an active memory session, preventing further writes.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidCloseMemorySessionRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidCloseMemorySessionResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidGetMemorySessionContext
Retrieve the full context for a memory session, including recent turns, extracted facts, and relevant procedural rules.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidGetMemorySessionContextRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidGetMemorySessionContextResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidGetMemoryProvenanceChain
Return the full hash-chain provenance for a given agent and namespace, ordered from oldest to newest.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidGetMemoryProvenanceChainRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidGetMemoryProvenanceChainResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidGetMemoryEntryProvenance
Retrieve the provenance record for a single memory entry.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidGetMemoryEntryProvenanceRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidGetMemoryEntryProvenanceResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.ErrorResponse | 404 | application/json |
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
lucidGetMemoryStats
Return memory statistics and diagnostics for a specific agent, including entry counts by type, storage usage, and hash chain integrity status.Example Usage
Standalone function
The standalone function version of this method:Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | operations.LucidGetMemoryStatsRequest | :heavy_check_mark: | The request object to use for the request. |
options | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
options.fetchOptions | RequestInit | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All Request options, except method and body, are allowed. |
options.retries | RetryConfig | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
Response
Promise<operations.LucidGetMemoryStatsResponse>Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| errors.RaijinLabsLucidAiDefaultError | 4XX, 5XX | */* |
.png?fit=max&auto=format&n=VsjUqn6fLqEhBiuI&q=85&s=8b4c7e6431e9a6af1ef23b77bb4ff5fd)
.png?fit=max&auto=format&n=VsjUqn6fLqEhBiuI&q=85&s=d5651a45e4bfbabc33f74e146af3f94a)