Skip to content

Commit

Permalink
Remove unused 'add_memory' method on the agent to simplify the API. T…
Browse files Browse the repository at this point in the history
…he correct approach to adding a memory is to call 'observe'. For this to work, you have to make sure there is a component like observation that writes observations to memory. If you want to configure the importance, as was possible with 'add_memory', then you can also accomplish that through the memory writing component.

PiperOrigin-RevId: 636301686
Change-Id: I3fdd6dab637de2a014f851bccf1dc752ca0035fb
  • Loading branch information
jzleibo authored and copybara-github committed May 22, 2024
1 parent 2826a7b commit a55d7a3
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions concordia/agents/basic_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,9 +287,6 @@ def get_externality(externality):

return output

def add_memory(self, memory: str, importance: float | None = None):
self._memory.add(memory, importance=importance)

def say(self, conversation: str) -> str:
convo_context = (
f'{self._agent_name} is in the following'
Expand Down

0 comments on commit a55d7a3

Please sign in to comment.