set_session_attributes
API reference for set_session_attributes
set_session_attributes
set_session_attributes()
Add Fiddler-specific session attributes to an agent’s metadata.
Session attributes provide context about the agent’s execution environment, such as user roles, cost centers, or any custom metadata that should be tracked across all invocations within a session.
Parameters
agent
Agent
✗
None
The Strands Agent instance to add session attributes to
Example
set_session_attributes
set_session_attributes()
Add Fiddler-specific session attributes to an agent’s metadata.
Session attributes provide context about the agent’s execution environment, such as user roles, cost centers, or any custom metadata that should be tracked across all invocations within a session.
Parameters
agent
Agent
✗
None
The Strands Agent instance to add session attributes to
Example
from strands import Agent
from fiddler_strandsagents import set_session_attributes
agent = Agent(model=model, system_prompt="...")
set_session_attributes(agent, role="customer_support", region="us-west")
Last updated
Was this helpful?