This commit is contained in:
madgrizzle
2024-08-02 20:05:54 -04:00
parent 319abdcb88
commit 45be6f2e1a
2 changed files with 3 additions and 2 deletions

View File

@@ -1212,7 +1212,7 @@ def delete(option: str, name: str):
client.delete_source(source_id=source.id)
elif option == "agent":
agent = client.get_agent(agent_name=name)
assert agent is not None, f"Agent {name} does not exist"
assert agent is not None, f"Agent {name} does not exist"
client.delete_agent(agent_id=agent.id)
elif option == "human":
human = client.get_human(name=name)

View File

@@ -98,13 +98,14 @@ class ChatMemory(BaseMemory):
"human": MemoryModule(name="human", value=human, limit=limit),
}
def core_memory_append(self, name: str, content: str) -> Optional[str]:
def core_memory_append(self, name: str, content: str, subsection: Optional[str] = "None") -> Optional[str]:
"""
Append to the contents of core memory.
Args:
name (str): Section of the memory to be edited (persona or human).
content (str): Content to write to the memory. All unicode (including emojis) are supported.
subsection (Optional[str]): Name of sub-section to store memory. Must be "public", "private", or "relationship". Defaults to "private".
Returns:
Optional[str]: None is always returned as this function does not produce a response.