Sessions
Background
Optional guidance for how the agent should explore memories.
background is optional guidance for how the agent should explore memories. Your server sets it when creating a createAgentTask session. The React SDK only receives a clientToken and cannot change it.
How background applies per task type:
| Task type | background |
|---|---|
EXPLORE_MEMORIES | Optional. A string that steers the agent, such as a role or domain. |
EXPLORE_PRODUCT | Not supported |
MEMORY_CHAT | Not supported |
MEMORY_SEARCH | Not supported |
STREAMING_CHAT_COMPLETION | Not supported |
STRUCTURED_CHAT_COMPLETION | Not supported |
How they work
Use background to tell the agent how to approach Explore Memories. Leave it off when the default behavior is enough. Sending background on any other task type is rejected.
Examples
EXPLORE_MEMORIES
{
createAgentTask: {
taskType: 'EXPLORE_MEMORIES',
background: 'You help users find relevant contracts from document content and metadata.',
},
}See Sessions for full request bodies per task type.