Recall it
Ask for the name
Search finds the saved sentence from a word in it, without you pasting the sentence again.
The question is only the word name. The result is the full sentence.
Example
from praisonai.memory import FileMemory
memory = FileMemory(user_id="learner")
memory.add_long_term("The learner name is Nila.")
found = memory.search("name")
print(found[0]["item"]["content"])Example explained
- search — Words to look for. The saved sentence comes back.
Wrong keyword
Search for a word that is not in the fact. Expect no useful hit — same discipline as RAG misses.
Example
from praisonai.memory import FileMemory
memory = FileMemory(user_id="learner")
memory.add_long_term("The learner name is Nila.")
found = memory.search("invoice")
print("hits:", len(found))Example explained
- from praisonai.memory import FileMemory — Imports FileMemory needed for wrong keyword.
- Memory store — Persists facts on disk so later turns or runs can recall them.
Reference: documentation