supermemory/apps/docs
sreedharsreeram e672af6b3d Supermemory-Cartesia SDK (#744)
### TL;DR

Added Python SDK for integrating Supermemory with Cartesia Line voice agents, enabling persistent memory capabilities.

### What changed?

Created a new Python SDK package (`supermemory_cartesia`) that provides:

- `SupermemoryCartesiaAgent` wrapper class that enhances Cartesia Line agents with memory capabilities
- Memory retrieval and storage functionality that integrates with the Supermemory API
- Utility functions for memory formatting, deduplication, and time formatting
- Custom exception classes for error handling
- Comprehensive documentation and type hints

The implementation includes:
- Memory enrichment for user queries
- Automatic storage of conversation history
- Configurable memory retrieval modes (profile, query, full)
- Background processing to avoid blocking the main conversation flow

### How to test?

```python
from supermemory_cartesia import SupermemoryCartesiaAgent
from line.llm_agent import LlmAgent, LlmConfig
import os

# Create base LLM agent
base_agent = LlmAgent(
    model="gemini/gemini-2.5-flash-preview-09-2025",
    config=LlmConfig(
        system_prompt="You are a helpful assistant.",
        introduction="Hello!"
    )
)

# Wrap with Supermemory
memory_agent = SupermemoryCartesiaAgent(
    agent=base_agent,
    api_key=os.getenv("SUPERMEMORY_API_KEY"),
    user_id="user-123",
)

# Use memory_agent in your Cartesia Line application
```

### Why make this change?

This SDK enables Cartesia Line voice agents to maintain persistent memory across conversations, enhancing user experience by:

1. Providing contextual awareness of past interactions
2. Remembering user preferences and important information
3. Reducing repetition in conversations
4. Creating more personalized and natural voice interactions

The integration is designed to be lightweight and non-blocking, ensuring that memory operations don't impact the responsiveness of voice interactions.
2026-04-15 16:27:23 +00:00
..
.cursor/rules migrate docs to public 2025-09-28 16:42:06 -07:00
add-memories docs: clarify metadata-only PATCH does not reindex (#784) 2026-03-17 20:48:52 +00:00
ai-sdk pkg(tools): Expose raw search results in MemoryPromptData for prompt templates (#787) 2026-03-19 00:38:53 +00:00
changelog chore: rename ClawdBot to OpenClaw across web and docs (#811) 2026-03-26 22:10:57 -07:00
concepts docs: add entity context documentation and fix MDX parsing (#723) 2026-02-03 22:53:21 +00:00
connectors docs: clarity on document limit for connectors (#841) 2026-04-09 15:17:49 +00:00
cookbook docs changes (#678) 2026-01-18 16:55:32 -08:00
deployment migrate docs to public 2025-09-28 16:42:06 -07:00
images feat: mcp modal with better instructions (#836) 2026-04-08 19:20:11 +00:00
integrations Supermemory-Cartesia SDK (#744) 2026-04-15 16:27:23 +00:00
list-memories docs changes (#678) 2026-01-18 16:55:32 -08:00
logo migrate docs to public 2025-09-28 16:42:06 -07:00
memory-api docs: clarity on document limit for connectors (#841) 2026-04-09 15:17:49 +00:00
memory-graph docs changes (#678) 2026-01-18 16:55:32 -08:00
memory-router docs changes (#678) 2026-01-18 16:55:32 -08:00
memorybench Add MemScore documentation to memorybench docs (#797) 2026-03-23 15:19:40 -07:00
migration docs changes (#678) 2026-01-18 16:55:32 -08:00
model-enhancement fix: model names 2025-10-03 02:41:49 -07:00
openai-sdks migrate docs to public 2025-09-28 16:42:06 -07:00
overview migrate docs to public 2025-09-28 16:42:06 -07:00
search docs changes (#678) 2026-01-18 16:55:32 -08:00
snippets migrate docs to public 2025-09-28 16:42:06 -07:00
supermemory-mcp feat: mcp modal with better instructions (#836) 2026-04-08 19:20:11 +00:00
update-delete-memories docs: clarify metadata-only PATCH does not reindex (#784) 2026-03-17 20:48:52 +00:00
user-profiles docs changes (#678) 2026-01-18 16:55:32 -08:00
.gitignore migrate docs to public 2025-09-28 16:42:06 -07:00
add-memories.mdx docs: clarify metadata-only PATCH does not reindex (#784) 2026-03-17 20:48:52 +00:00
analytics.mdx fix: all broken links 2025-10-07 17:25:39 -07:00
authentication.mdx docs: add scoped key deletion endpoint to auth docs (#756) 2026-02-28 01:06:12 +00:00
docs.json voltagent-sdk (#791) 2026-04-14 20:22:46 +00:00
document-operations.mdx docs: clarify metadata-only PATCH does not reindex (#784) 2026-03-17 20:48:52 +00:00
favicon.png migrate docs to public 2025-09-28 16:42:06 -07:00
install.md docs: add entity context documentation and fix MDX parsing (#723) 2026-02-03 22:53:21 +00:00
intro.mdx trigger: Mintlify build (#725) 2026-02-04 14:56:37 -07:00
introduction.mdx docs changes (#678) 2026-01-18 16:55:32 -08:00
memory-operations.mdx direct add memory support 2026-02-09 18:32:24 -08:00
n8n.mdx add(docs): migration guide from zep to supermemory (#612) 2025-12-20 00:47:52 +00:00
package.json update quickstart 2025-11-27 09:53:11 -07:00
quickstart.mdx docs changes (#678) 2026-01-18 16:55:32 -08:00
README.md migrate docs to public 2025-09-28 16:42:06 -07:00
search.mdx docs changes (#678) 2026-01-18 16:55:32 -08:00
style.css feat: mobile responsive, lint formats, toast, render issue fix (#688) 2026-01-21 03:11:53 +00:00
test.py docs changes (#678) 2026-01-18 16:55:32 -08:00
test.ts mastra integration (#717) 2026-02-03 00:43:08 +00:00
user-profiles.mdx docs changes (#678) 2026-01-18 16:55:32 -08:00
vibe-coding.mdx docs changes (#678) 2026-01-18 16:55:32 -08:00
zapier.mdx add(docs): migration guide from zep to supermemory (#612) 2025-12-20 00:47:52 +00:00

supermemory Docs