-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Description
When updating or changing the instructions during an active session, the agent continues to follow earlier instructions from the session history. The new instructions are not reliably taken into account unless a new session is created. This makes it difficult to dynamically adapt agent behavior mid-session.
To Reproduce
Steps to reproduce the behavior:
1. Create a session with a new LLmAgent .
2. Start a conversation with an initial set of instructions.
3. Send a few invocations.
4. Update the instructions with a different system prompt (e.g., completely changing the greeting).
5. The agent still behaves according to the old instructions, ignoring or mixing the new ones, unless a new session is created.
Expected behavior
The agent should consistently get updated with the latest instructions provided, even within an existing session.