Skip to content

Commit

Permalink
fix: fixed bug when existing agent state is loaded via cli (#1783)
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaliniR8 authored Sep 25, 2024
1 parent 0ee4cba commit 7f3c9ec
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion letta/cli/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -492,7 +492,7 @@ def run(
# agent_config = AgentConfig.load(agent)
# agent_state = ms.get_agent(agent_name=agent, user_id=user_id)
printd("Loading agent state:", agent_state.id)
printd("Agent state:", agent_state.state)
printd("Agent state:", agent_state.name)
# printd("State path:", agent_config.save_state_dir())
# printd("Persistent manager path:", agent_config.save_persistence_manager_dir())
# printd("Index path:", agent_config.save_agent_index_dir())
Expand Down Expand Up @@ -549,6 +549,7 @@ def run(
)

# create agent
tools = [ms.get_tool(tool_name, user_id=client.user_id) for tool_name in agent_state.tools]
letta_agent = Agent(agent_state=agent_state, interface=interface(), tools=tools)

else: # create new agent
Expand Down

0 comments on commit 7f3c9ec

Please sign in to comment.