09 Memory#

Script: example/09_memory.py.

This is the key-free local memory quickstart. flow.Agent(memory="local") opens the default local memory backend, then uses explicit remember/recall calls. If an LLM key is present, the script also runs a live turn and commits the transcript.

python example/09_memory.py

API

Behavior

flow.Agent(..., memory="local")

Attach a local MemoryStore.

remember_memory(text)

Write durable text memory.

recall_memory(query, top_k=...)

Search memory; local falls back to BM25 when no embedding provider is configured.

commit_memory(session)

Optional model-assisted session archive and extraction.

The no-key path proves memory is not tied to a hosted vector service. Add llm.embedding_provider later if you want embedding-ranked local recall.

← Runnable Examples