Skip to main content

llama-index-memory-itsuki

Itsuki long-term memory for LlamaIndex, as a memory block inside the host's own Memory class.

pip install llama-index-memory-itsuki
from llama_index.memory.itsuki import itsuki_memory

memory = itsuki_memory(user_id="user_42", session_id="thread_9")
response = await agent.run("What am I working on?", memory=memory)

Set ITSUKI_API_KEY in your environment. Create one at itsuki.app under API Keys.

A block, not a replacement

LlamaIndex has deprecated the BaseMemory generation that older third-party integrations target — ChatMemoryBuffer, SimpleComposableMemory and friends are on the way out. The current architecture is the Memory class composing BaseMemoryBlock subclasses, so that is what this ships.

Short-term chat history keeps working exactly as the host intends. Itsuki becomes the long-term half: _aget supplies durable memory for the turn, and _aput stages messages as they flush out of short-term memory.

Compose it yourself if you want a different arrangement:

from llama_index.core.memory import Memory
from llama_index.memory.itsuki import itsuki_memory_block

memory = Memory.from_defaults(
    session_id="thread_9",
    memory_blocks=[itsuki_memory_block("user_42", session_id="thread_9")],
)

Async, on purpose

BaseMemoryBlock is async-first, so this uses the Itsuki SDK's AsyncMemoryClient. A synchronous client here would block the event loop the agent runs on, once per step, for the length of an HTTP round trip.

Scoping

Argument Meaning
user_id the memory space — required, no default
session_id the conversation, and the de-duplication anchor
agent_id, run_id attribution only
project_id attribution, and enables project-scoped recall

search_msg_limit (default 5) controls how many recent turns inform the recall query.

Behaviour under failure

_aget returns an empty string and _aput returns quietly. A memory outage costs the agent context, never the answer. The API key is a private attribute, so it never appears in model_dump(), an export, or serialized agent state.

License

Apache-2.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llama_index_memory_itsuki-0.1.1.tar.gz (14.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llama_index_memory_itsuki-0.1.1-py3-none-any.whl (17.0 kB view details)

Uploaded Python 3

File details

Details for the file llama_index_memory_itsuki-0.1.1.tar.gz.

File metadata

File hashes

Hashes for llama_index_memory_itsuki-0.1.1.tar.gz
Algorithm Hash digest
SHA256 c4cb0e44858efeccc678c70fb8f6b765ab9137438b6bb5e2fd017bbf5947fce7
MD5 8b2753b8b516e639934d2c380a0d364b
BLAKE2b-256 2236bca5a1ec7bac2c7526e8f86cc26a011fd490a95e94431c73fd1d75eea2a6

See more details on using hashes here.

Provenance

The following attestation bundles were made for llama_index_memory_itsuki-0.1.1.tar.gz:

Publisher: publish-pypi.yml on 12ziyad/universal-memory-engine

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file llama_index_memory_itsuki-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for llama_index_memory_itsuki-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6dc76f874be1b500deaf9fe59f3389d3fd042f927ca7b8a729a5d991d68658e8
MD5 28b4b4e2308dd223893dffd0ab86bef3
BLAKE2b-256 cfc22803e6bc10a20d1424661461be324cc7fe1d54ec306c7da3b29eedc6811c

See more details on using hashes here.

Provenance

The following attestation bundles were made for llama_index_memory_itsuki-0.1.1-py3-none-any.whl:

Publisher: publish-pypi.yml on 12ziyad/universal-memory-engine

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page